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
870b3cb4
Commit
870b3cb4
authored
Apr 15, 2010
by
Henri Verbeet
Committed by
Alexandre Julliard
Apr 16, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Simply pass an IWineD3DSurfaceImpl pointer to context_apply_attachment_filter_states().
parent
bc2850a5
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
10 deletions
+10
-10
context.c
dlls/wined3d/context.c
+10
-10
No files found.
dlls/wined3d/context.c
View file @
870b3cb4
...
@@ -114,15 +114,15 @@ static void context_destroy_fbo(struct wined3d_context *context, GLuint *fbo)
...
@@ -114,15 +114,15 @@ static void context_destroy_fbo(struct wined3d_context *context, GLuint *fbo)
}
}
/* GL locking is done by the caller */
/* GL locking is done by the caller */
static
void
context_apply_attachment_filter_states
(
IWineD3DSurface
*
surface
)
static
void
context_apply_attachment_filter_states
(
IWineD3DSurface
Impl
*
surface
)
{
{
IWineD3DBaseTextureImpl
*
texture_impl
;
IWineD3DBaseTextureImpl
*
texture_impl
;
/* Update base texture states array */
/* Update base texture states array */
if
(
SUCCEEDED
(
IWineD3DSurface_GetContainer
(
surface
,
&
IID_IWineD3DBaseTexture
,
(
void
**
)
&
texture_impl
)))
if
(
SUCCEEDED
(
IWineD3DSurface_GetContainer
((
IWineD3DSurface
*
)
surface
,
&
IID_IWineD3DBaseTexture
,
(
void
**
)
&
texture_impl
)))
{
{
IWineD3DSurfaceImpl
*
surface_impl
=
(
IWineD3DSurfaceImpl
*
)
surface
;
IWineD3DDeviceImpl
*
device
=
surface
->
resource
.
device
;
IWineD3DDeviceImpl
*
device
=
surface_impl
->
resource
.
device
;
BOOL
update_minfilter
=
FALSE
;
BOOL
update_minfilter
=
FALSE
;
BOOL
update_magfilter
=
FALSE
;
BOOL
update_magfilter
=
FALSE
;
...
@@ -153,7 +153,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface)
...
@@ -153,7 +153,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface)
GLenum
target
,
bind_target
;
GLenum
target
,
bind_target
;
GLint
old_binding
;
GLint
old_binding
;
target
=
surface
_impl
->
texture_target
;
target
=
surface
->
texture_target
;
if
(
target
==
GL_TEXTURE_2D
)
if
(
target
==
GL_TEXTURE_2D
)
{
{
bind_target
=
GL_TEXTURE_2D
;
bind_target
=
GL_TEXTURE_2D
;
...
@@ -170,7 +170,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface)
...
@@ -170,7 +170,7 @@ static void context_apply_attachment_filter_states(IWineD3DSurface *surface)
glGetIntegerv
(
GL_TEXTURE_BINDING_CUBE_MAP_ARB
,
&
old_binding
);
glGetIntegerv
(
GL_TEXTURE_BINDING_CUBE_MAP_ARB
,
&
old_binding
);
}
}
glBindTexture
(
bind_target
,
surface
_impl
->
texture_name
);
glBindTexture
(
bind_target
,
surface
->
texture_name
);
if
(
update_minfilter
)
glTexParameteri
(
bind_target
,
GL_TEXTURE_MIN_FILTER
,
GL_NEAREST
);
if
(
update_minfilter
)
glTexParameteri
(
bind_target
,
GL_TEXTURE_MIN_FILTER
,
GL_NEAREST
);
if
(
update_magfilter
)
glTexParameteri
(
bind_target
,
GL_TEXTURE_MAG_FILTER
,
GL_NEAREST
);
if
(
update_magfilter
)
glTexParameteri
(
bind_target
,
GL_TEXTURE_MAG_FILTER
,
GL_NEAREST
);
glBindTexture
(
bind_target
,
old_binding
);
glBindTexture
(
bind_target
,
old_binding
);
...
@@ -212,7 +212,7 @@ void context_attach_depth_stencil_fbo(struct wined3d_context *context,
...
@@ -212,7 +212,7 @@ void context_attach_depth_stencil_fbo(struct wined3d_context *context,
else
else
{
{
surface_prepare_texture
(
depth_stencil_impl
,
gl_info
,
FALSE
);
surface_prepare_texture
(
depth_stencil_impl
,
gl_info
,
FALSE
);
context_apply_attachment_filter_states
(
depth_stencil
);
context_apply_attachment_filter_states
(
depth_stencil
_impl
);
if
(
format_flags
&
WINED3DFMT_FLAG_DEPTH
)
if
(
format_flags
&
WINED3DFMT_FLAG_DEPTH
)
{
{
...
@@ -265,7 +265,7 @@ void context_attach_surface_fbo(const struct wined3d_context *context,
...
@@ -265,7 +265,7 @@ void context_attach_surface_fbo(const struct wined3d_context *context,
if
(
surface
)
if
(
surface
)
{
{
surface_prepare_texture
(
surface_impl
,
gl_info
,
FALSE
);
surface_prepare_texture
(
surface_impl
,
gl_info
,
FALSE
);
context_apply_attachment_filter_states
(
surface
);
context_apply_attachment_filter_states
(
surface
_impl
);
gl_info
->
fbo_ops
.
glFramebufferTexture2D
(
fbo_target
,
GL_COLOR_ATTACHMENT0
+
idx
,
surface_impl
->
texture_target
,
gl_info
->
fbo_ops
.
glFramebufferTexture2D
(
fbo_target
,
GL_COLOR_ATTACHMENT0
+
idx
,
surface_impl
->
texture_target
,
surface_impl
->
texture_name
,
surface_impl
->
texture_level
);
surface_impl
->
texture_name
,
surface_impl
->
texture_level
);
...
@@ -436,10 +436,10 @@ static void context_apply_fbo_entry(struct wined3d_context *context, struct fbo_
...
@@ -436,10 +436,10 @@ static void context_apply_fbo_entry(struct wined3d_context *context, struct fbo_
for
(
i
=
0
;
i
<
gl_info
->
limits
.
buffers
;
++
i
)
for
(
i
=
0
;
i
<
gl_info
->
limits
.
buffers
;
++
i
)
{
{
if
(
device
->
render_targets
[
i
])
if
(
device
->
render_targets
[
i
])
context_apply_attachment_filter_states
(
device
->
render_targets
[
i
]);
context_apply_attachment_filter_states
(
(
IWineD3DSurfaceImpl
*
)
device
->
render_targets
[
i
]);
}
}
if
(
device
->
stencilBufferTarget
)
if
(
device
->
stencilBufferTarget
)
context_apply_attachment_filter_states
(
device
->
stencilBufferTarget
);
context_apply_attachment_filter_states
(
(
IWineD3DSurfaceImpl
*
)
device
->
stencilBufferTarget
);
}
}
for
(
i
=
0
;
i
<
gl_info
->
limits
.
buffers
;
++
i
)
for
(
i
=
0
;
i
<
gl_info
->
limits
.
buffers
;
++
i
)
...
...
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