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
fdadf26c
Commit
fdadf26c
authored
Jul 09, 2007
by
Stefan Dösinger
Committed by
Alexandre Julliard
Jul 10, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add CTXUSAGE_CLEAR context usage.
parent
97cd8bab
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
15 additions
and
6 deletions
+15
-6
context.c
dlls/wined3d/context.c
+13
-0
device.c
dlls/wined3d/device.c
+1
-6
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-0
No files found.
dlls/wined3d/context.c
View file @
fdadf26c
...
@@ -842,6 +842,19 @@ void ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, ContextU
...
@@ -842,6 +842,19 @@ void ActivateContext(IWineD3DDeviceImpl *This, IWineD3DSurface *target, ContextU
/* This does not require any special states to be set up */
/* This does not require any special states to be set up */
break
;
break
;
case
CTXUSAGE_CLEAR
:
if
(
context
->
last_was_blit
&&
GL_SUPPORT
(
NV_TEXTURE_SHADER2
))
{
glEnable
(
GL_TEXTURE_SHADER_NV
);
checkGLcall
(
"glEnable(GL_TEXTURE_SHADER_NV)"
);
}
glEnable
(
GL_SCISSOR_TEST
);
checkGLcall
(
"glEnable GL_SCISSOR_TEST"
);
context
->
last_was_blit
=
FALSE
;
Context_MarkStateDirty
(
context
,
STATE_RENDER
(
WINED3DRS_SCISSORTESTENABLE
));
Context_MarkStateDirty
(
context
,
STATE_SCISSORRECT
);
break
;
case
CTXUSAGE_DRAWPRIM
:
case
CTXUSAGE_DRAWPRIM
:
/* This needs all dirty states applied */
/* This needs all dirty states applied */
if
(
context
->
last_was_blit
&&
GL_SUPPORT
(
NV_TEXTURE_SHADER2
))
{
if
(
context
->
last_was_blit
&&
GL_SUPPORT
(
NV_TEXTURE_SHADER2
))
{
...
...
dlls/wined3d/device.c
View file @
fdadf26c
...
@@ -4463,12 +4463,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Clear(IWineD3DDevice *iface, DWORD Coun
...
@@ -4463,12 +4463,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_Clear(IWineD3DDevice *iface, DWORD Coun
apply_fbo_state
(
iface
);
apply_fbo_state
(
iface
);
}
}
ActivateContext
(
This
,
This
->
render_targets
[
0
],
CTXUSAGE_RESOURCELOAD
);
ActivateContext
(
This
,
This
->
render_targets
[
0
],
CTXUSAGE_CLEAR
);
glEnable
(
GL_SCISSOR_TEST
);
checkGLcall
(
"glEnable GL_SCISSOR_TEST"
);
IWineD3DDeviceImpl_MarkStateDirty
(
This
,
STATE_SCISSORRECT
);
IWineD3DDeviceImpl_MarkStateDirty
(
This
,
STATE_RENDER
(
WINED3DRS_SCISSORTESTENABLE
));
if
(
Count
>
0
&&
pRects
)
{
if
(
Count
>
0
&&
pRects
)
{
curRect
=
pRects
;
curRect
=
pRects
;
...
...
dlls/wined3d/wined3d_private.h
View file @
fdadf26c
...
@@ -527,6 +527,7 @@ typedef enum ContextUsage {
...
@@ -527,6 +527,7 @@ typedef enum ContextUsage {
CTXUSAGE_RESOURCELOAD
=
1
,
/* Only loads textures: No State is applied */
CTXUSAGE_RESOURCELOAD
=
1
,
/* Only loads textures: No State is applied */
CTXUSAGE_DRAWPRIM
=
2
,
/* OpenGL states are set up for blitting DirectDraw surfacs */
CTXUSAGE_DRAWPRIM
=
2
,
/* OpenGL states are set up for blitting DirectDraw surfacs */
CTXUSAGE_BLIT
=
3
,
/* OpenGL states are set up 3D drawing */
CTXUSAGE_BLIT
=
3
,
/* OpenGL states are set up 3D drawing */
CTXUSAGE_CLEAR
=
4
,
/* Drawable and states are set up for clearing */
}
ContextUsage
;
}
ContextUsage
;
void
ActivateContext
(
IWineD3DDeviceImpl
*
device
,
IWineD3DSurface
*
target
,
ContextUsage
usage
);
void
ActivateContext
(
IWineD3DDeviceImpl
*
device
,
IWineD3DSurface
*
target
,
ContextUsage
usage
);
...
...
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