Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
87627c81
Commit
87627c81
authored
Jan 12, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Jan 12, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Get rid of D3DINITIALIZEBASETEXTURE.
parent
00a4b85f
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
14 additions
and
12 deletions
+14
-12
basetexture.c
dlls/wined3d/basetexture.c
+10
-0
device.c
dlls/wined3d/device.c
+3
-12
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-0
No files found.
dlls/wined3d/basetexture.c
View file @
87627c81
...
...
@@ -27,6 +27,16 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d_texture
);
#define GLINFO_LOCATION This->resource.wineD3DDevice->adapter->gl_info
void
basetexture_init
(
struct
IWineD3DBaseTextureClass
*
texture
,
UINT
levels
,
DWORD
usage
)
{
texture
->
levels
=
levels
;
texture
->
filterType
=
(
usage
&
WINED3DUSAGE_AUTOGENMIPMAP
)
?
WINED3DTEXF_LINEAR
:
WINED3DTEXF_NONE
;
texture
->
LOD
=
0
;
texture
->
dirty
=
TRUE
;
texture
->
is_srgb
=
FALSE
;
texture
->
srgb_mode_change_count
=
0
;
}
void
basetexture_cleanup
(
IWineD3DBaseTexture
*
iface
)
{
IWineD3DBaseTextureImpl
*
This
=
(
IWineD3DBaseTextureImpl
*
)
iface
;
...
...
dlls/wined3d/device.c
View file @
87627c81
...
...
@@ -115,15 +115,6 @@ static void IWineD3DDeviceImpl_AddResource(IWineD3DDevice *iface, IWineD3DResour
TRACE("(%p) : Created resource %p\n", This, object); \
}
#define D3DINITIALIZEBASETEXTURE(_basetexture) { \
_basetexture.levels = Levels; \
_basetexture.filterType = (Usage & WINED3DUSAGE_AUTOGENMIPMAP) ? WINED3DTEXF_LINEAR : WINED3DTEXF_NONE; \
_basetexture.LOD = 0; \
_basetexture.dirty = TRUE; \
_basetexture.is_srgb = FALSE; \
_basetexture.srgb_mode_change_count = 0; \
}
/**********************************************************
* Global variable / Constants follow
**********************************************************/
...
...
@@ -792,7 +783,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateTexture(IWineD3DDevice *iface, U
}
D3DCREATERESOURCEOBJECTINSTANCE
(
object
,
Texture
,
WINED3DRTYPE_TEXTURE
,
0
);
D3DINITIALIZEBASETEXTURE
(
object
->
baseTexture
);
basetexture_init
(
&
object
->
baseTexture
,
Levels
,
Usage
);
object
->
width
=
Width
;
object
->
height
=
Height
;
...
...
@@ -937,7 +928,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateVolumeTexture(IWineD3DDevice *ifa
}
D3DCREATERESOURCEOBJECTINSTANCE
(
object
,
VolumeTexture
,
WINED3DRTYPE_VOLUMETEXTURE
,
0
);
D3DINITIALIZEBASETEXTURE
(
object
->
baseTextur
e
);
basetexture_init
(
&
object
->
baseTexture
,
Levels
,
Usag
e
);
TRACE
(
"(%p) : W(%d) H(%d) D(%d), Lvl(%d) Usage(%d), Fmt(%u,%s), Pool(%s)
\n
"
,
This
,
Width
,
Height
,
Depth
,
Levels
,
Usage
,
Format
,
debug_d3dformat
(
Format
),
debug_d3dpool
(
Pool
));
...
...
@@ -1070,7 +1061,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateCubeTexture(IWineD3DDevice *iface
}
D3DCREATERESOURCEOBJECTINSTANCE
(
object
,
CubeTexture
,
WINED3DRTYPE_CUBETEXTURE
,
0
);
D3DINITIALIZEBASETEXTURE
(
object
->
baseTextur
e
);
basetexture_init
(
&
object
->
baseTexture
,
Levels
,
Usag
e
);
TRACE
(
"(%p) Create Cube Texture
\n
"
,
This
);
...
...
dlls/wined3d/wined3d_private.h
View file @
87627c81
...
...
@@ -1377,6 +1377,7 @@ WINED3DTEXTUREFILTERTYPE basetexture_get_autogen_filter_type(IWineD3DBaseTexture
BOOL
basetexture_get_dirty
(
IWineD3DBaseTexture
*
iface
);
DWORD
basetexture_get_level_count
(
IWineD3DBaseTexture
*
iface
);
DWORD
basetexture_get_lod
(
IWineD3DBaseTexture
*
iface
);
void
basetexture_init
(
struct
IWineD3DBaseTextureClass
*
texture
,
UINT
levels
,
DWORD
usage
);
HRESULT
basetexture_set_autogen_filter_type
(
IWineD3DBaseTexture
*
iface
,
WINED3DTEXTUREFILTERTYPE
filter_type
);
BOOL
basetexture_set_dirty
(
IWineD3DBaseTexture
*
iface
,
BOOL
dirty
);
DWORD
basetexture_set_lod
(
IWineD3DBaseTexture
*
iface
,
DWORD
new_lod
);
...
...
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