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
81effcf3
Commit
81effcf3
authored
Sep 04, 2008
by
Henri Verbeet
Committed by
Alexandre Julliard
Sep 05, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Set the viewport to the texture size in depth_blt().
parent
16f38d74
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
6 deletions
+11
-6
drawprim.c
dlls/wined3d/drawprim.c
+3
-2
surface.c
dlls/wined3d/surface.c
+2
-2
wined3d_private.h
dlls/wined3d/wined3d_private.h
+6
-2
No files found.
dlls/wined3d/drawprim.c
View file @
81effcf3
...
...
@@ -708,11 +708,11 @@ static void drawStridedSlowVs(IWineD3DDevice *iface, WineDirect3DVertexStridedDa
glEnd
();
}
void
depth_blt
(
IWineD3DDevice
*
iface
,
GLuint
texture
)
{
void
depth_blt
(
IWineD3DDevice
*
iface
,
GLuint
texture
,
GLsizei
w
,
GLsizei
h
)
{
IWineD3DDeviceImpl
*
This
=
(
IWineD3DDeviceImpl
*
)
iface
;
GLint
old_binding
=
0
;
glPushAttrib
(
GL_ENABLE_BIT
|
GL_DEPTH_BUFFER_BIT
|
GL_COLOR_BUFFER_BIT
);
glPushAttrib
(
GL_ENABLE_BIT
|
GL_DEPTH_BUFFER_BIT
|
GL_COLOR_BUFFER_BIT
|
GL_VIEWPORT_BIT
);
glDisable
(
GL_CULL_FACE
);
glEnable
(
GL_BLEND
);
...
...
@@ -723,6 +723,7 @@ void depth_blt(IWineD3DDevice *iface, GLuint texture) {
glDepthFunc
(
GL_ALWAYS
);
glDepthMask
(
GL_TRUE
);
glBlendFunc
(
GL_ZERO
,
GL_ONE
);
glViewport
(
0
,
0
,
w
,
h
);
GL_EXTCALL
(
glActiveTextureARB
(
GL_TEXTURE0_ARB
));
glGetIntegerv
(
GL_TEXTURE_BINDING_2D
,
&
old_binding
);
...
...
dlls/wined3d/surface.c
View file @
81effcf3
...
...
@@ -3995,7 +3995,7 @@ void surface_load_ds_location(IWineD3DSurface *iface, DWORD location) {
attach_depth_stencil_fbo
(
device
,
GL_FRAMEBUFFER_EXT
,
iface
,
FALSE
);
/* Do the actual blit */
depth_blt
((
IWineD3DDevice
*
)
device
,
device
->
depth_blt_texture
);
depth_blt
((
IWineD3DDevice
*
)
device
,
device
->
depth_blt_texture
,
This
->
currentDesc
.
Width
,
This
->
currentDesc
.
Height
);
checkGLcall
(
"depth_blt"
);
if
(
device
->
render_offscreen
)
{
...
...
@@ -4017,7 +4017,7 @@ void surface_load_ds_location(IWineD3DSurface *iface, DWORD location) {
GL_EXTCALL
(
glBindFramebufferEXT
(
GL_FRAMEBUFFER_EXT
,
0
));
checkGLcall
(
"glBindFramebuffer()"
);
depth_blt
((
IWineD3DDevice
*
)
device
,
This
->
glDescription
.
textureName
);
depth_blt
((
IWineD3DDevice
*
)
device
,
This
->
glDescription
.
textureName
,
This
->
currentDesc
.
Width
,
This
->
currentDesc
.
Height
);
checkGLcall
(
"depth_blt"
);
if
(
device
->
render_offscreen
)
{
...
...
dlls/wined3d/wined3d_private.h
View file @
81effcf3
...
...
@@ -785,7 +785,11 @@ struct ffp_settings {
FOG_EXP
,
FOG_EXP2
}
fog
;
unsigned
char
sRGB_write
;
/* Use an int instead of a char to get dword alignment. gcc tends to align the
* size of the whole structure, so there are 3 padding bytes. These remain
* uninitialized in the construction function and cause confusion in the hashmap
*/
unsigned
int
sRGB_write
;
};
struct
ffp_desc
...
...
@@ -2516,6 +2520,6 @@ void stretch_rect_fbo(IWineD3DDevice *iface, IWineD3DSurface *src_surface, WINED
void
bind_fbo
(
IWineD3DDevice
*
iface
,
GLenum
target
,
GLuint
*
fbo
);
void
attach_depth_stencil_fbo
(
IWineD3DDeviceImpl
*
This
,
GLenum
fbo_target
,
IWineD3DSurface
*
depth_stencil
,
BOOL
use_render_buffer
);
void
attach_surface_fbo
(
IWineD3DDeviceImpl
*
This
,
GLenum
fbo_target
,
DWORD
idx
,
IWineD3DSurface
*
surface
);
void
depth_blt
(
IWineD3DDevice
*
iface
,
GLuint
texture
);
void
depth_blt
(
IWineD3DDevice
*
iface
,
GLuint
texture
,
GLsizei
w
,
GLsizei
h
);
#endif
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