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
237cdefe
Commit
237cdefe
authored
Jan 18, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Jan 19, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Pass an IWineD3DVolumeImpl pointer to volume_bind_and_dirtify().
parent
ace5f8e6
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
7 deletions
+7
-7
volume.c
dlls/wined3d/volume.c
+7
-7
No files found.
dlls/wined3d/volume.c
View file @
237cdefe
...
...
@@ -27,10 +27,10 @@
WINE_DEFAULT_DEBUG_CHANNEL
(
d3d_surface
);
/* Context activation is done by the caller. */
static
void
volume_bind_and_dirtify
(
IWineD3DVolume
*
iface
)
{
IWineD3DVolumeImpl
*
This
=
(
IWineD3DVolumeImpl
*
)
iface
;
const
struct
wined3d_gl_info
*
gl_info
=
&
This
->
resource
.
device
->
adapter
->
gl_info
;
IWineD3DBaseTextureImpl
*
container
=
(
IWineD3DBaseTextureImpl
*
)
This
->
container
;
static
void
volume_bind_and_dirtify
(
struct
IWineD3DVolumeImpl
*
volume
)
{
const
struct
wined3d_gl_info
*
gl_info
=
&
volume
->
resource
.
device
->
adapter
->
gl_info
;
IWineD3DBaseTextureImpl
*
container
=
(
IWineD3DBaseTextureImpl
*
)
volume
->
container
;
DWORD
active_sampler
;
/* We don't need a specific texture unit, but after binding the texture the current unit is dirty.
...
...
@@ -50,14 +50,14 @@ static void volume_bind_and_dirtify(IWineD3DVolume *iface) {
ENTER_GL
();
glGetIntegerv
(
GL_ACTIVE_TEXTURE
,
&
active_texture
);
LEAVE_GL
();
active_sampler
=
This
->
resource
.
device
->
rev_tex_unit_map
[
active_texture
-
GL_TEXTURE0_ARB
];
active_sampler
=
volume
->
resource
.
device
->
rev_tex_unit_map
[
active_texture
-
GL_TEXTURE0_ARB
];
}
else
{
active_sampler
=
0
;
}
if
(
active_sampler
!=
WINED3D_UNMAPPED_STAGE
)
{
IWineD3DDeviceImpl_MarkStateDirty
(
This
->
resource
.
device
,
STATE_SAMPLER
(
active_sampler
));
IWineD3DDeviceImpl_MarkStateDirty
(
volume
->
resource
.
device
,
STATE_SAMPLER
(
active_sampler
));
}
container
->
baseTexture
.
texture_ops
->
texture_bind
(
container
,
FALSE
);
...
...
@@ -289,7 +289,7 @@ static HRESULT WINAPI IWineD3DVolumeImpl_LoadTexture(IWineD3DVolume *iface, int
TRACE
(
"iface %p, level %u, srgb %#x, format %s (%#x).
\n
"
,
iface
,
gl_level
,
srgb_mode
,
debug_d3dformat
(
format
->
id
),
format
->
id
);
volume_bind_and_dirtify
(
iface
);
volume_bind_and_dirtify
(
This
);
TRACE
(
"Calling glTexImage3D %x level=%d, intfmt=%x, w=%d, h=%d,d=%d, 0=%d, glFmt=%x, glType=%x, Mem=%p
\n
"
,
GL_TEXTURE_3D
,
gl_level
,
format
->
glInternal
,
This
->
currentDesc
.
Width
,
This
->
currentDesc
.
Height
,
...
...
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