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
03d7f527
Commit
03d7f527
authored
Dec 01, 2010
by
Henri Verbeet
Committed by
Alexandre Julliard
Dec 02, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Move min_rel_offset / max_rel_offset to the shader_reg_maps structure.
parent
a4477fea
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
21 deletions
+10
-21
shader.c
dlls/wined3d/shader.c
+9
-18
wined3d_private.h
dlls/wined3d/wined3d_private.h
+1
-3
No files found.
dlls/wined3d/shader.c
View file @
03d7f527
...
...
@@ -399,17 +399,8 @@ static void shader_record_register_usage(IWineD3DBaseShaderImpl *shader, struct
case
WINED3DSPR_CONST
:
if
(
reg
->
rel_addr
)
{
if
(
shader_type
!=
WINED3D_SHADER_TYPE_PIXEL
)
{
if
(
reg
->
idx
<
((
IWineD3DVertexShaderImpl
*
)
shader
)
->
min_rel_offset
)
{
((
IWineD3DVertexShaderImpl
*
)
shader
)
->
min_rel_offset
=
reg
->
idx
;
}
if
(
reg
->
idx
>
((
IWineD3DVertexShaderImpl
*
)
shader
)
->
max_rel_offset
)
{
((
IWineD3DVertexShaderImpl
*
)
shader
)
->
max_rel_offset
=
reg
->
idx
;
}
}
if
(
reg
->
idx
<
reg_maps
->
min_rel_offset
)
reg_maps
->
min_rel_offset
=
reg
->
idx
;
if
(
reg
->
idx
>
reg_maps
->
max_rel_offset
)
reg_maps
->
max_rel_offset
=
reg
->
idx
;
reg_maps
->
usesrelconstF
=
TRUE
;
}
else
...
...
@@ -1904,21 +1895,21 @@ HRESULT vertexshader_init(IWineD3DVertexShaderImpl *shader, IWineD3DDeviceImpl *
if
(
device
->
vs_selected_mode
==
SHADER_ARB
&&
(
gl_info
->
quirks
&
WINED3D_QUIRK_ARB_VS_OFFSET_LIMIT
)
&&
shader
->
min_rel_offset
<=
shader
->
max_rel_offset
)
&&
reg_maps
->
min_rel_offset
<=
reg_maps
->
max_rel_offset
)
{
if
(
shader
->
max_rel_offset
-
shader
->
min_rel_offset
>
127
)
if
(
reg_maps
->
max_rel_offset
-
reg_maps
->
min_rel_offset
>
127
)
{
FIXME
(
"The difference between the minimum and maximum relative offset is > 127.
\n
"
);
FIXME
(
"Which this OpenGL implementation does not support. Try using GLSL.
\n
"
);
FIXME
(
"Min: %
d, Max: %d.
\n
"
,
shader
->
min_rel_offset
,
shader
->
max_rel_offset
);
FIXME
(
"Min: %
u, Max: %u.
\n
"
,
reg_maps
->
min_rel_offset
,
reg_maps
->
max_rel_offset
);
}
else
if
(
shader
->
max_rel_offset
-
shader
->
min_rel_offset
>
63
)
else
if
(
reg_maps
->
max_rel_offset
-
reg_maps
->
min_rel_offset
>
63
)
{
shader
->
rel_offset
=
shader
->
min_rel_offset
+
63
;
shader
->
rel_offset
=
reg_maps
->
min_rel_offset
+
63
;
}
else
if
(
shader
->
max_rel_offset
>
63
)
else
if
(
reg_maps
->
max_rel_offset
>
63
)
{
shader
->
rel_offset
=
shader
->
min_rel_offset
;
shader
->
rel_offset
=
reg_maps
->
min_rel_offset
;
}
else
{
...
...
dlls/wined3d/wined3d_private.h
View file @
03d7f527
...
...
@@ -568,7 +568,7 @@ typedef struct shader_reg_maps
/* Whether or not loops are used in this shader, and nesting depth */
unsigned
loop_depth
;
unsigned
highest_render_target
;
UINT
min_rel_offset
,
max_rel_offset
;
}
shader_reg_maps
;
/* Keeps track of details for TEX_M#x# instructions which need to maintain
...
...
@@ -2868,8 +2868,6 @@ typedef struct IWineD3DVertexShaderImpl {
/* Vertex shader attributes. */
struct
wined3d_shader_attribute
attributes
[
MAX_ATTRIBS
];
UINT
min_rel_offset
,
max_rel_offset
;
UINT
rel_offset
;
}
IWineD3DVertexShaderImpl
;
...
...
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