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
473e914c
Commit
473e914c
authored
Jun 07, 2007
by
H. Verbeet
Committed by
Alexandre Julliard
Jun 07, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Turn off filtering for FBO attachments, update the texture's states array.
parent
fe07efb3
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
2 deletions
+26
-2
device.c
dlls/wined3d/device.c
+26
-2
No files found.
dlls/wined3d/device.c
View file @
473e914c
...
...
@@ -5169,6 +5169,7 @@ static void bind_fbo(IWineD3DDevice *iface, GLenum target, GLuint *fbo) {
static
void
attach_surface_fbo
(
IWineD3DDeviceImpl
*
This
,
GLenum
fbo_target
,
DWORD
idx
,
IWineD3DSurface
*
surface
)
{
const
IWineD3DSurfaceImpl
*
surface_impl
=
(
IWineD3DSurfaceImpl
*
)
surface
;
IWineD3DBaseTextureImpl
*
texture_impl
;
GLenum
texttarget
,
target
;
GLint
old_binding
;
...
...
@@ -5178,10 +5179,21 @@ static void attach_surface_fbo(IWineD3DDeviceImpl *This, GLenum fbo_target, DWOR
IWineD3DSurface_PreLoad
(
surface
);
glTexParameteri
(
target
,
GL_TEXTURE_MIN_FILTER
,
GL_
LINEAR
);
glTexParameteri
(
target
,
GL_TEXTURE_MAG_FILTER
,
GL_
LINEAR
);
glTexParameteri
(
target
,
GL_TEXTURE_MIN_FILTER
,
GL_
NEAREST
);
glTexParameteri
(
target
,
GL_TEXTURE_MAG_FILTER
,
GL_
NEAREST
);
glBindTexture
(
target
,
old_binding
);
/* Update base texture states array */
if
(
SUCCEEDED
(
IWineD3DSurface_GetContainer
(
surface
,
&
IID_IWineD3DBaseTexture
,
(
void
**
)
&
texture_impl
)))
{
texture_impl
->
baseTexture
.
states
[
WINED3DTEXSTA_MINFILTER
]
=
WINED3DTEXF_POINT
;
texture_impl
->
baseTexture
.
states
[
WINED3DTEXSTA_MAGFILTER
]
=
WINED3DTEXF_POINT
;
if
(
texture_impl
->
baseTexture
.
bindCount
)
{
IWineD3DDeviceImpl_MarkStateDirty
(
This
,
STATE_SAMPLER
(
texture_impl
->
baseTexture
.
sampler
));
}
IWineD3DBaseTexture_Release
((
IWineD3DBaseTexture
*
)
texture_impl
);
}
GL_EXTCALL
(
glFramebufferTexture2DEXT
(
fbo_target
,
GL_COLOR_ATTACHMENT0_EXT
+
idx
,
texttarget
,
surface_impl
->
glDescription
.
textureName
,
0
));
checkGLcall
(
"attach_surface_fbo"
);
...
...
@@ -5393,6 +5405,7 @@ static void set_depth_stencil_fbo(IWineD3DDevice *iface, IWineD3DSurface *depth_
GL_EXTCALL
(
glFramebufferRenderbufferEXT
(
GL_FRAMEBUFFER_EXT
,
GL_DEPTH_ATTACHMENT_EXT
,
GL_RENDERBUFFER_EXT
,
depth_stencil_impl
->
current_renderbuffer
->
id
));
checkGLcall
(
"glFramebufferRenderbufferEXT()"
);
}
else
{
IWineD3DBaseTextureImpl
*
texture_impl
;
GLenum
texttarget
,
target
;
GLint
old_binding
=
0
;
...
...
@@ -5407,6 +5420,17 @@ static void set_depth_stencil_fbo(IWineD3DDevice *iface, IWineD3DSurface *depth_
glTexParameteri
(
target
,
GL_DEPTH_TEXTURE_MODE_ARB
,
GL_LUMINANCE
);
glBindTexture
(
target
,
old_binding
);
/* Update base texture states array */
if
(
SUCCEEDED
(
IWineD3DSurface_GetContainer
(
depth_stencil
,
&
IID_IWineD3DBaseTexture
,
(
void
**
)
&
texture_impl
)))
{
texture_impl
->
baseTexture
.
states
[
WINED3DTEXSTA_MINFILTER
]
=
WINED3DTEXF_POINT
;
texture_impl
->
baseTexture
.
states
[
WINED3DTEXSTA_MAGFILTER
]
=
WINED3DTEXF_POINT
;
if
(
texture_impl
->
baseTexture
.
bindCount
)
{
IWineD3DDeviceImpl_MarkStateDirty
(
This
,
STATE_SAMPLER
(
texture_impl
->
baseTexture
.
sampler
));
}
IWineD3DBaseTexture_Release
((
IWineD3DBaseTexture
*
)
texture_impl
);
}
GL_EXTCALL
(
glFramebufferTexture2DEXT
(
GL_FRAMEBUFFER_EXT
,
GL_DEPTH_ATTACHMENT_EXT
,
texttarget
,
depth_stencil_impl
->
glDescription
.
textureName
,
0
));
checkGLcall
(
"glFramebufferTexture2DEXT()"
);
}
...
...
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