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
dda91ac0
Commit
dda91ac0
authored
May 24, 2011
by
Stefan Dösinger
Committed by
Alexandre Julliard
May 26, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Call frag_pipe->enable_extension under the GL lock.
parent
dbd058a8
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
18 deletions
+18
-18
arb_program_shader.c
dlls/wined3d/arb_program_shader.c
+1
-3
ati_fragment_shader.c
dlls/wined3d/ati_fragment_shader.c
+1
-3
context.c
dlls/wined3d/context.c
+14
-8
nvidia_texture_shader.c
dlls/wined3d/nvidia_texture_shader.c
+1
-3
state.c
dlls/wined3d/state.c
+1
-1
No files found.
dlls/wined3d/arb_program_shader.c
View file @
dda91ac0
...
...
@@ -5504,10 +5504,9 @@ struct arbfp_ffp_desc
unsigned
int
num_textures_used
;
};
/* Context activation
is
done by the caller. */
/* Context activation
and GL locking are
done by the caller. */
static
void
arbfp_enable
(
BOOL
enable
)
{
ENTER_GL
();
if
(
enable
)
{
glEnable
(
GL_FRAGMENT_PROGRAM_ARB
);
checkGLcall
(
"glEnable(GL_FRAGMENT_PROGRAM_ARB)"
);
...
...
@@ -5515,7 +5514,6 @@ static void arbfp_enable(BOOL enable)
glDisable
(
GL_FRAGMENT_PROGRAM_ARB
);
checkGLcall
(
"glDisable(GL_FRAGMENT_PROGRAM_ARB)"
);
}
LEAVE_GL
();
}
static
HRESULT
arbfp_alloc
(
struct
wined3d_device
*
device
)
...
...
dlls/wined3d/ati_fragment_shader.c
View file @
dda91ac0
...
...
@@ -1054,10 +1054,9 @@ static const struct StateEntryTemplate atifs_fragmentstate_template[] = {
{
0
/* Terminate */
,
{
0
,
0
},
WINED3D_GL_EXT_NONE
},
};
/* Context activation
is
done by the caller. */
/* Context activation
and GL locking are
done by the caller. */
static
void
atifs_enable
(
BOOL
enable
)
{
ENTER_GL
();
if
(
enable
)
{
glEnable
(
GL_FRAGMENT_SHADER_ATI
);
checkGLcall
(
"glEnable(GL_FRAGMENT_SHADER_ATI)"
);
...
...
@@ -1065,7 +1064,6 @@ static void atifs_enable(BOOL enable)
glDisable
(
GL_FRAGMENT_SHADER_ATI
);
checkGLcall
(
"glDisable(GL_FRAGMENT_SHADER_ATI)"
);
}
LEAVE_GL
();
}
static
void
atifs_get_caps
(
const
struct
wined3d_gl_info
*
gl_info
,
struct
fragment_caps
*
caps
)
...
...
dlls/wined3d/context.c
View file @
dda91ac0
...
...
@@ -1649,11 +1649,10 @@ struct wined3d_context *context_create(struct wined3d_swapchain *swapchain,
{
GL_EXTCALL
(
glProvokingVertexEXT
(
GL_FIRST_VERTEX_CONVENTION_EXT
));
}
device
->
frag_pipe
->
enable_extension
(
TRUE
);
LEAVE_GL
();
device
->
frag_pipe
->
enable_extension
(
TRUE
);
TRACE
(
"Created context %p.
\n
"
,
ret
);
return
ret
;
...
...
@@ -1913,14 +1912,13 @@ static void SetupForBlit(struct wined3d_device *device, struct wined3d_context *
Context_MarkStateDirty
(
context
,
STATE_RENDER
(
WINED3DRS_CLIPPING
),
StateTable
);
set_blit_dimension
(
width
,
height
);
device
->
frag_pipe
->
enable_extension
(
FALSE
);
LEAVE_GL
();
context
->
blit_w
=
width
;
context
->
blit_h
=
height
;
Context_MarkStateDirty
(
context
,
STATE_VIEWPORT
,
StateTable
);
Context_MarkStateDirty
(
context
,
STATE_TRANSFORM
(
WINED3DTS_PROJECTION
),
StateTable
);
device
->
frag_pipe
->
enable_extension
(
FALSE
);
}
/* Do not call while under the GL lock. */
...
...
@@ -2208,6 +2206,7 @@ BOOL context_apply_clear_state(struct wined3d_context *context, struct wined3d_d
LEAVE_GL
();
}
ENTER_GL
();
if
(
context
->
last_was_blit
)
{
device
->
frag_pipe
->
enable_extension
(
TRUE
);
...
...
@@ -2216,7 +2215,6 @@ BOOL context_apply_clear_state(struct wined3d_context *context, struct wined3d_d
/* Blending and clearing should be orthogonal, but tests on the nvidia
* driver show that disabling blending when clearing improves the clearing
* performance incredibly. */
ENTER_GL
();
glDisable
(
GL_BLEND
);
glEnable
(
GL_SCISSOR_TEST
);
checkGLcall
(
"glEnable GL_SCISSOR_TEST"
);
...
...
@@ -2286,12 +2284,12 @@ BOOL context_apply_draw_state(struct wined3d_context *context, struct wined3d_de
LEAVE_GL
();
}
ENTER_GL
();
if
(
context
->
last_was_blit
)
{
device
->
frag_pipe
->
enable_extension
(
TRUE
);
}
ENTER_GL
();
for
(
i
=
0
;
i
<
context
->
numDirtyEntries
;
++
i
)
{
DWORD
rep
=
context
->
dirtyArray
[
i
];
...
...
@@ -2381,8 +2379,16 @@ struct wined3d_context *context_acquire(struct wined3d_device *device, struct wi
if
(
context
!=
current_context
)
{
if
(
!
context_set_current
(
context
))
ERR
(
"Failed to activate the new context.
\n
"
);
else
device
->
frag_pipe
->
enable_extension
(
!
context
->
last_was_blit
);
if
(
!
context_set_current
(
context
))
{
ERR
(
"Failed to activate the new context.
\n
"
);
}
else
{
ENTER_GL
();
device
->
frag_pipe
->
enable_extension
(
!
context
->
last_was_blit
);
LEAVE_GL
();
}
if
(
context
->
vshader_const_dirty
)
{
...
...
dlls/wined3d/nvidia_texture_shader.c
View file @
dda91ac0
...
...
@@ -623,10 +623,9 @@ static void nvrc_texfactor(DWORD state, struct wined3d_stateblock *stateblock, s
/* Context activation is done by the caller. */
static
void
nvrc_enable
(
BOOL
enable
)
{}
/* Context activation
is
done by the caller. */
/* Context activation
and GL locking are
done by the caller. */
static
void
nvts_enable
(
BOOL
enable
)
{
ENTER_GL
();
if
(
enable
)
{
glEnable
(
GL_TEXTURE_SHADER_NV
);
checkGLcall
(
"glEnable(GL_TEXTURE_SHADER_NV)"
);
...
...
@@ -634,7 +633,6 @@ static void nvts_enable(BOOL enable)
glDisable
(
GL_TEXTURE_SHADER_NV
);
checkGLcall
(
"glDisable(GL_TEXTURE_SHADER_NV)"
);
}
LEAVE_GL
();
}
static
void
nvrc_fragment_get_caps
(
const
struct
wined3d_gl_info
*
gl_info
,
struct
fragment_caps
*
caps
)
...
...
dlls/wined3d/state.c
View file @
dda91ac0
...
...
@@ -5578,7 +5578,7 @@ static const struct StateEntryTemplate ffp_fragmentstate_template[] = {
{
0
/* Terminate */
,
{
0
,
0
},
WINED3D_GL_EXT_NONE
},
};
/* Context activation
is
done by the caller. */
/* Context activation
and GL locking are
done by the caller. */
static
void
ffp_enable
(
BOOL
enable
)
{}
static
void
ffp_fragment_get_caps
(
const
struct
wined3d_gl_info
*
gl_info
,
struct
fragment_caps
*
caps
)
...
...
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