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
1fe1676a
Commit
1fe1676a
authored
Oct 08, 2010
by
Henri Verbeet
Committed by
Alexandre Julliard
Oct 08, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: SM4 immediate constants are typeless.
parent
3e45fe74
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
13 additions
and
19 deletions
+13
-19
glsl_shader.c
dlls/wined3d/glsl_shader.c
+2
-2
shader.c
dlls/wined3d/shader.c
+2
-2
shader_sm4.c
dlls/wined3d/shader_sm4.c
+6
-6
wined3d_private.h
dlls/wined3d/wined3d_private.h
+3
-9
No files found.
dlls/wined3d/glsl_shader.c
View file @
1fe1676a
...
...
@@ -1477,11 +1477,11 @@ static void shader_glsl_get_register_name(const struct wined3d_shader_register *
case
WINED3DSPR_IMMCONST
:
switch
(
reg
->
immconst_type
)
{
case
WINED3D_IMMCONST_
FLOAT
:
case
WINED3D_IMMCONST_
SCALAR
:
sprintf
(
register_name
,
"%.8e"
,
*
(
const
float
*
)
reg
->
immconst_data
);
break
;
case
WINED3D_IMMCONST_
FLOAT
4
:
case
WINED3D_IMMCONST_
VEC
4
:
sprintf
(
register_name
,
"vec4(%.8e, %.8e, %.8e, %.8e)"
,
*
(
const
float
*
)
&
reg
->
immconst_data
[
0
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
1
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
2
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
3
]);
...
...
dlls/wined3d/shader.c
View file @
1fe1676a
...
...
@@ -1033,11 +1033,11 @@ static void shader_dump_register(const struct wined3d_shader_register *reg,
TRACE
(
"("
);
switch
(
reg
->
immconst_type
)
{
case
WINED3D_IMMCONST_
FLOAT
:
case
WINED3D_IMMCONST_
SCALAR
:
TRACE
(
"%.8e"
,
*
(
const
float
*
)
reg
->
immconst_data
);
break
;
case
WINED3D_IMMCONST_
FLOAT
4
:
case
WINED3D_IMMCONST_
VEC
4
:
TRACE
(
"%.8e, %.8e, %.8e, %.8e"
,
*
(
const
float
*
)
&
reg
->
immconst_data
[
0
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
1
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
2
],
*
(
const
float
*
)
&
reg
->
immconst_data
[
3
]);
...
...
dlls/wined3d/shader_sm4.c
View file @
1fe1676a
...
...
@@ -90,8 +90,8 @@ enum wined3d_sm4_register_type
enum
wined3d_sm4_immconst_type
{
WINED3D_SM4_IMMCONST_
FLOAT
=
0x1
,
WINED3D_SM4_IMMCONST_
FLOAT4
=
0x2
,
WINED3D_SM4_IMMCONST_
SCALAR
=
0x1
,
WINED3D_SM4_IMMCONST_
VEC4
=
0x2
,
};
struct
wined3d_sm4_data
...
...
@@ -354,14 +354,14 @@ static void shader_sm4_read_src_param(void *data, const DWORD **ptr, struct wine
switch
(
immconst_type
)
{
case
WINED3D_SM4_IMMCONST_
FLOAT
:
src_param
->
reg
.
immconst_type
=
WINED3D_IMMCONST_
FLOAT
;
case
WINED3D_SM4_IMMCONST_
SCALAR
:
src_param
->
reg
.
immconst_type
=
WINED3D_IMMCONST_
SCALAR
;
memcpy
(
src_param
->
reg
.
immconst_data
,
*
ptr
,
1
*
sizeof
(
DWORD
));
*
ptr
+=
1
;
break
;
case
WINED3D_SM4_IMMCONST_
FLOAT
4
:
src_param
->
reg
.
immconst_type
=
WINED3D_IMMCONST_
FLOAT
4
;
case
WINED3D_SM4_IMMCONST_
VEC
4
:
src_param
->
reg
.
immconst_type
=
WINED3D_IMMCONST_
VEC
4
;
memcpy
(
src_param
->
reg
.
immconst_data
,
*
ptr
,
4
*
sizeof
(
DWORD
));
*
ptr
+=
4
;
break
;
...
...
dlls/wined3d/wined3d_private.h
View file @
1fe1676a
...
...
@@ -313,8 +313,8 @@ typedef enum _WINED3DSHADER_PARAM_REGISTER_TYPE
enum
wined3d_immconst_type
{
WINED3D_IMMCONST_
FLOAT
,
WINED3D_IMMCONST_
FLOAT
4
,
WINED3D_IMMCONST_
SCALAR
,
WINED3D_IMMCONST_
VEC
4
,
};
#define WINED3DSP_NOSWIZZLE (0 | (1 << 2) | (2 << 4) | (3 << 6))
...
...
@@ -2821,13 +2821,7 @@ static inline BOOL shader_is_scalar(const struct wined3d_shader_register *reg)
}
case
WINED3DSPR_IMMCONST
:
switch
(
reg
->
immconst_type
)
{
case
WINED3D_IMMCONST_FLOAT
:
return
TRUE
;
default:
return
FALSE
;
}
return
reg
->
immconst_type
==
WINED3D_IMMCONST_SCALAR
;
default:
return
FALSE
;
...
...
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