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
b4e596e7
Commit
b4e596e7
authored
Jul 26, 2007
by
H. Verbeet
Committed by
Alexandre Julliard
Jul 26, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Flip the scissor rect when rendering offscreen.
parent
4194d784
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
6 deletions
+20
-6
context.c
dlls/wined3d/context.c
+2
-0
device.c
dlls/wined3d/device.c
+12
-5
state.c
dlls/wined3d/state.c
+6
-1
No files found.
dlls/wined3d/context.c
View file @
b4e596e7
...
...
@@ -700,6 +700,7 @@ static inline WineD3DContext *FindContext(IWineD3DDeviceImpl *This, IWineD3DSurf
Context_MarkStateDirty
(
context
,
WINED3DTS_PROJECTION
);
Context_MarkStateDirty
(
context
,
STATE_VDECL
);
Context_MarkStateDirty
(
context
,
STATE_VIEWPORT
);
Context_MarkStateDirty
(
context
,
STATE_SCISSORRECT
);
}
}
else
{
...
...
@@ -787,6 +788,7 @@ static inline WineD3DContext *FindContext(IWineD3DDeviceImpl *This, IWineD3DSurf
Context_MarkStateDirty
(
context
,
WINED3DTS_PROJECTION
);
Context_MarkStateDirty
(
context
,
STATE_VDECL
);
Context_MarkStateDirty
(
context
,
STATE_VIEWPORT
);
Context_MarkStateDirty
(
context
,
STATE_SCISSORRECT
);
}
}
if
(
readTexture
)
{
...
...
dlls/wined3d/device.c
View file @
b4e596e7
...
...
@@ -4509,11 +4509,18 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Clear(IWineD3DDevice *iface, DWORD Coun
if
(
!
curRect
)
{
/* In drawable flag is set below */
glScissor
(
This
->
stateBlock
->
viewport
.
X
,
(((
IWineD3DSurfaceImpl
*
)
This
->
render_targets
[
0
])
->
currentDesc
.
Height
-
(
This
->
stateBlock
->
viewport
.
Y
+
This
->
stateBlock
->
viewport
.
Height
)),
This
->
stateBlock
->
viewport
.
Width
,
This
->
stateBlock
->
viewport
.
Height
);
if
(
This
->
render_offscreen
)
{
glScissor
(
This
->
stateBlock
->
viewport
.
X
,
This
->
stateBlock
->
viewport
.
Y
,
This
->
stateBlock
->
viewport
.
Width
,
This
->
stateBlock
->
viewport
.
Height
);
}
else
{
glScissor
(
This
->
stateBlock
->
viewport
.
X
,
(((
IWineD3DSurfaceImpl
*
)
This
->
render_targets
[
0
])
->
currentDesc
.
Height
-
(
This
->
stateBlock
->
viewport
.
Y
+
This
->
stateBlock
->
viewport
.
Height
)),
This
->
stateBlock
->
viewport
.
Width
,
This
->
stateBlock
->
viewport
.
Height
);
}
checkGLcall
(
"glScissor"
);
glClear
(
glMask
);
checkGLcall
(
"glClear"
);
...
...
dlls/wined3d/state.c
View file @
b4e596e7
...
...
@@ -3442,7 +3442,12 @@ static void scissorrect(DWORD state, IWineD3DStateBlockImpl *stateblock, WineD3D
winHeight
=
windowRect
.
bottom
-
windowRect
.
top
;
TRACE
(
"(%p) Setting new Scissor Rect to %d:%d-%d:%d
\n
"
,
stateblock
->
wineD3DDevice
,
pRect
->
left
,
pRect
->
bottom
-
winHeight
,
pRect
->
right
-
pRect
->
left
,
pRect
->
bottom
-
pRect
->
top
);
glScissor
(
pRect
->
left
,
winHeight
-
pRect
->
bottom
,
pRect
->
right
-
pRect
->
left
,
pRect
->
bottom
-
pRect
->
top
);
if
(
stateblock
->
wineD3DDevice
->
render_offscreen
)
{
glScissor
(
pRect
->
left
,
pRect
->
top
,
pRect
->
right
-
pRect
->
left
,
pRect
->
bottom
-
pRect
->
top
);
}
else
{
glScissor
(
pRect
->
left
,
winHeight
-
pRect
->
bottom
,
pRect
->
right
-
pRect
->
left
,
pRect
->
bottom
-
pRect
->
top
);
}
checkGLcall
(
"glScissor"
);
}
...
...
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