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
d0d8a782
Commit
d0d8a782
authored
Mar 31, 2015
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 31, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Take WINED3D_PIXEL_CENTER_INTEGER into account when calculating vpos.
parent
ae7aee3d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
glsl_shader.c
dlls/wined3d/glsl_shader.c
+8
-2
No files found.
dlls/wined3d/glsl_shader.c
View file @
d0d8a782
...
...
@@ -1420,8 +1420,14 @@ static void shader_generate_glsl_declarations(const struct wined3d_context *cont
* centers instead of the pixel corners. This code will behave correctly
* on drivers that returns integer values. */
if
(
version
->
type
==
WINED3D_SHADER_TYPE_PIXEL
&&
reg_maps
->
vpos
)
shader_addline
(
buffer
,
"vpos = floor(vec4(0, ycorrection[0], 0, 0) + gl_FragCoord * vec4(1, ycorrection[1], 1, 1));
\n
"
);
{
if
(
shader
->
device
->
wined3d
->
flags
&
WINED3D_PIXEL_CENTER_INTEGER
)
shader_addline
(
buffer
,
"vpos = floor(vec4(0, ycorrection[0], 0, 0) + gl_FragCoord * vec4(1, ycorrection[1], 1, 1));
\n
"
);
else
shader_addline
(
buffer
,
"vpos = vec4(0, ycorrection[0], 0, 0) + gl_FragCoord * vec4(1, ycorrection[1], 1, 1);
\n
"
);
}
}
/*****************************************************************************
...
...
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