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
88c80635
Commit
88c80635
authored
Apr 21, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Apr 21, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Pass a struct wined3d_shader_src_param to shader_glsl_get_swizzle().
parent
612c32ea
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
5 deletions
+6
-5
glsl_shader.c
dlls/wined3d/glsl_shader.c
+6
-5
No files found.
dlls/wined3d/glsl_shader.c
View file @
88c80635
...
@@ -1257,12 +1257,13 @@ static void shader_glsl_swizzle_to_str(const DWORD swizzle, BOOL fixup, DWORD ma
...
@@ -1257,12 +1257,13 @@ static void shader_glsl_swizzle_to_str(const DWORD swizzle, BOOL fixup, DWORD ma
*
str
=
'\0'
;
*
str
=
'\0'
;
}
}
static
void
shader_glsl_get_swizzle
(
const
DWORD
param
,
BOOL
fixup
,
DWORD
mask
,
char
*
swizzle_str
)
static
void
shader_glsl_get_swizzle
(
const
struct
wined3d_shader_src_param
*
param
,
BOOL
fixup
,
DWORD
mask
,
char
*
swizzle_str
)
{
{
if
(
shader_is_scalar
(
shader_get_regtype
(
param
),
param
&
WINED3DSP_REGNUM_MASK
))
if
(
shader_is_scalar
(
param
->
register_type
,
param
->
register_idx
))
*
swizzle_str
=
'\0'
;
*
swizzle_str
=
'\0'
;
else
else
shader_glsl_swizzle_to_str
(
param
&
WINED3DSP_SWIZZLE_MASK
,
fixup
,
mask
,
swizzle_str
);
shader_glsl_swizzle_to_str
(
param
->
swizzle
,
fixup
,
mask
,
swizzle_str
);
}
}
/* From a given parameter token, generate the corresponding GLSL string.
/* From a given parameter token, generate the corresponding GLSL string.
...
@@ -1281,7 +1282,7 @@ static void shader_glsl_add_src_param(const struct wined3d_shader_instruction *i
...
@@ -1281,7 +1282,7 @@ static void shader_glsl_add_src_param(const struct wined3d_shader_instruction *i
shader_glsl_get_register_name
(
wined3d_src
->
register_type
,
wined3d_src
->
register_idx
,
shader_glsl_get_register_name
(
wined3d_src
->
register_type
,
wined3d_src
->
register_idx
,
wined3d_src
->
rel_addr
,
glsl_src
->
reg_name
,
&
is_color
,
ins
);
wined3d_src
->
rel_addr
,
glsl_src
->
reg_name
,
&
is_color
,
ins
);
shader_glsl_get_swizzle
(
wined3d_src
->
token
,
is_color
,
mask
,
swizzle_str
);
shader_glsl_get_swizzle
(
wined3d_src
,
is_color
,
mask
,
swizzle_str
);
shader_glsl_gen_modifier
(
wined3d_src
->
modifiers
,
glsl_src
->
reg_name
,
swizzle_str
,
glsl_src
->
param_str
);
shader_glsl_gen_modifier
(
wined3d_src
->
modifiers
,
glsl_src
->
reg_name
,
swizzle_str
,
glsl_src
->
param_str
);
}
}
...
@@ -2549,7 +2550,7 @@ static void pshader_glsl_texcoord(const struct wined3d_shader_instruction *ins)
...
@@ -2549,7 +2550,7 @@ static void pshader_glsl_texcoord(const struct wined3d_shader_instruction *ins)
DWORD
src_mod
=
ins
->
src
[
0
].
modifiers
;
DWORD
src_mod
=
ins
->
src
[
0
].
modifiers
;
char
dst_swizzle
[
6
];
char
dst_swizzle
[
6
];
shader_glsl_get_swizzle
(
ins
->
src
[
0
].
token
,
FALSE
,
write_mask
,
dst_swizzle
);
shader_glsl_get_swizzle
(
&
ins
->
src
[
0
]
,
FALSE
,
write_mask
,
dst_swizzle
);
if
(
src_mod
==
WINED3DSPSM_DZ
)
{
if
(
src_mod
==
WINED3DSPSM_DZ
)
{
glsl_src_param_t
div_param
;
glsl_src_param_t
div_param
;
...
...
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