Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
2e119ecd
Commit
2e119ecd
authored
Sep 17, 2010
by
Henri Verbeet
Committed by
Alexandre Julliard
Sep 18, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Move the texture's target field to the base texture struct.
parent
cdf8d455
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
14 additions
and
8 deletions
+14
-8
cubetexture.c
dlls/wined3d/cubetexture.c
+4
-1
texture.c
dlls/wined3d/texture.c
+5
-5
volumetexture.c
dlls/wined3d/volumetexture.c
+4
-1
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-1
No files found.
dlls/wined3d/cubetexture.c
View file @
2e119ecd
...
...
@@ -308,9 +308,11 @@ static HRESULT WINAPI IWineD3DCubeTextureImpl_BindTexture(IWineD3DCubeTexture *i
static
UINT
WINAPI
IWineD3DCubeTextureImpl_GetTextureDimensions
(
IWineD3DCubeTexture
*
iface
)
{
IWineD3DCubeTextureImpl
*
texture
=
(
IWineD3DCubeTextureImpl
*
)
iface
;
TRACE
(
"iface %p.
\n
"
,
iface
);
return
GL_TEXTURE_CUBE_MAP_ARB
;
return
texture
->
baseTexture
.
target
;
}
static
BOOL
WINAPI
IWineD3DCubeTextureImpl_IsCondNP2
(
IWineD3DCubeTexture
*
iface
)
...
...
@@ -538,6 +540,7 @@ HRESULT cubetexture_init(IWineD3DCubeTextureImpl *texture, UINT edge_length, UIN
texture
->
baseTexture
.
pow2Matrix
[
15
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix_identity
=
FALSE
;
}
texture
->
baseTexture
.
target
=
GL_TEXTURE_CUBE_MAP_ARB
;
/* Generate all the surfaces. */
tmp_w
=
edge_length
;
...
...
dlls/wined3d/texture.c
View file @
2e119ecd
...
...
@@ -327,7 +327,7 @@ static UINT WINAPI IWineD3DTextureImpl_GetTextureDimensions(IWineD3DTexture *ifa
IWineD3DTextureImpl
*
This
=
(
IWineD3DTextureImpl
*
)
iface
;
TRACE
(
"(%p)
\n
"
,
This
);
return
This
->
target
;
return
This
->
baseTexture
.
target
;
}
static
BOOL
WINAPI
IWineD3DTextureImpl_IsCondNP2
(
IWineD3DTexture
*
iface
)
{
...
...
@@ -556,7 +556,7 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT
texture
->
baseTexture
.
pow2Matrix
[
5
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
10
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
15
]
=
1
.
0
f
;
texture
->
target
=
GL_TEXTURE_2D
;
texture
->
baseTexture
.
target
=
GL_TEXTURE_2D
;
texture
->
cond_np2
=
TRUE
;
texture
->
baseTexture
.
minMipLookup
=
minMipLookup_noFilter
;
}
...
...
@@ -570,7 +570,7 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT
texture
->
baseTexture
.
pow2Matrix
[
5
]
=
(
float
)
height
;
texture
->
baseTexture
.
pow2Matrix
[
10
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
15
]
=
1
.
0
f
;
texture
->
target
=
GL_TEXTURE_RECTANGLE_ARB
;
texture
->
baseTexture
.
target
=
GL_TEXTURE_RECTANGLE_ARB
;
texture
->
cond_np2
=
TRUE
;
if
(
texture
->
resource
.
format
->
Flags
&
WINED3DFMT_FLAG_FILTERING
)
...
...
@@ -598,7 +598,7 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT
texture
->
baseTexture
.
pow2Matrix
[
10
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
15
]
=
1
.
0
f
;
texture
->
target
=
GL_TEXTURE_2D
;
texture
->
baseTexture
.
target
=
GL_TEXTURE_2D
;
texture
->
cond_np2
=
FALSE
;
}
TRACE
(
"xf(%f) yf(%f)
\n
"
,
texture
->
baseTexture
.
pow2Matrix
[
0
],
texture
->
baseTexture
.
pow2Matrix
[
5
]);
...
...
@@ -621,7 +621,7 @@ HRESULT texture_init(IWineD3DTextureImpl *texture, UINT width, UINT height, UINT
}
surface_set_container
((
IWineD3DSurfaceImpl
*
)
surface
,
WINED3D_CONTAINER_TEXTURE
,
(
IWineD3DBase
*
)
texture
);
surface_set_texture_target
((
IWineD3DSurfaceImpl
*
)
surface
,
texture
->
target
);
surface_set_texture_target
((
IWineD3DSurfaceImpl
*
)
surface
,
texture
->
baseTexture
.
target
);
texture
->
baseTexture
.
sub_resources
[
i
]
=
(
IWineD3DResourceImpl
*
)
surface
;
TRACE
(
"Created surface level %u @ %p.
\n
"
,
i
,
surface
);
/* Calculate the next mipmap level. */
...
...
dlls/wined3d/volumetexture.c
View file @
2e119ecd
...
...
@@ -244,9 +244,11 @@ static HRESULT WINAPI IWineD3DVolumeTextureImpl_BindTexture(IWineD3DVolumeTextur
static
UINT
WINAPI
IWineD3DVolumeTextureImpl_GetTextureDimensions
(
IWineD3DVolumeTexture
*
iface
)
{
IWineD3DVolumeTextureImpl
*
texture
=
(
IWineD3DVolumeTextureImpl
*
)
iface
;
TRACE
(
"iface %p.
\n
"
,
iface
);
return
GL_TEXTURE_3D
;
return
texture
->
baseTexture
.
target
;
}
static
BOOL
WINAPI
IWineD3DVolumeTextureImpl_IsCondNP2
(
IWineD3DVolumeTexture
*
iface
)
...
...
@@ -453,6 +455,7 @@ HRESULT volumetexture_init(IWineD3DVolumeTextureImpl *texture, UINT width, UINT
texture
->
baseTexture
.
pow2Matrix
[
5
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
10
]
=
1
.
0
f
;
texture
->
baseTexture
.
pow2Matrix
[
15
]
=
1
.
0
f
;
texture
->
baseTexture
.
target
=
GL_TEXTURE_3D
;
/* Generate all the surfaces. */
tmp_w
=
width
;
...
...
dlls/wined3d/wined3d_private.h
View file @
2e119ecd
...
...
@@ -1871,6 +1871,7 @@ typedef struct IWineD3DBaseTextureClass
BOOL
pow2Matrix_identity
;
const
struct
min_lookup
*
minMipLookup
;
const
GLenum
*
magLookup
;
GLenum
target
;
void
(
*
internal_preload
)(
IWineD3DBaseTexture
*
iface
,
enum
WINED3DSRGB
srgb
);
}
IWineD3DBaseTextureClass
;
...
...
@@ -1917,7 +1918,6 @@ typedef struct IWineD3DTextureImpl
IWineD3DBaseTextureClass
baseTexture
;
/* IWineD3DTexture */
UINT
target
;
BOOL
cond_np2
;
}
IWineD3DTextureImpl
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment