Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-fonts
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
Aleksandr Isakov
wine-fonts
Commits
9a27b0ad
Commit
9a27b0ad
authored
Nov 14, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Nov 15, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add support for geometry shaders to the GLSL shader backend.
parent
db3b97de
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
34 additions
and
1 deletion
+34
-1
device.c
dlls/wined3d/device.c
+1
-1
glsl_shader.c
dlls/wined3d/glsl_shader.c
+0
-0
shader.c
dlls/wined3d/shader.c
+24
-0
wined3d_private.h
dlls/wined3d/wined3d_private.h
+9
-0
No files found.
dlls/wined3d/device.c
View file @
9a27b0ad
...
...
@@ -65,7 +65,7 @@ const struct wined3d_matrix identity =
/* Note that except for WINED3DPT_POINTLIST and WINED3DPT_LINELIST these
* actually have the same values in GL and D3D. */
static
GLenum
gl_primitive_type_from_d3d
(
enum
wined3d_primitive_type
primitive_type
)
GLenum
gl_primitive_type_from_d3d
(
enum
wined3d_primitive_type
primitive_type
)
{
switch
(
primitive_type
)
{
...
...
dlls/wined3d/glsl_shader.c
View file @
9a27b0ad
This diff is collapsed.
Click to expand it.
dlls/wined3d/shader.c
View file @
9a27b0ad
...
...
@@ -544,6 +544,30 @@ static HRESULT shader_get_registers_used(struct wined3d_shader *shader, const st
else
reg_maps
->
cb_sizes
[
reg
->
idx
[
0
].
offset
]
=
reg
->
idx
[
1
].
offset
;
}
else
if
(
ins
.
handler_idx
==
WINED3DSIH_DCL_INPUT_PRIMITIVE
)
{
if
(
shader_version
.
type
==
WINED3D_SHADER_TYPE_GEOMETRY
)
shader
->
u
.
gs
.
input_type
=
ins
.
declaration
.
primitive_type
;
else
FIXME
(
"Invalid instruction %#x for shader type %#x.
\n
"
,
ins
.
handler_idx
,
shader_version
.
type
);
}
else
if
(
ins
.
handler_idx
==
WINED3DSIH_DCL_OUTPUT_TOPOLOGY
)
{
if
(
shader_version
.
type
==
WINED3D_SHADER_TYPE_GEOMETRY
)
shader
->
u
.
gs
.
output_type
=
ins
.
declaration
.
primitive_type
;
else
FIXME
(
"Invalid instruction %#x for shader type %#x.
\n
"
,
ins
.
handler_idx
,
shader_version
.
type
);
}
else
if
(
ins
.
handler_idx
==
WINED3DSIH_DCL_VERTICES_OUT
)
{
if
(
shader_version
.
type
==
WINED3D_SHADER_TYPE_GEOMETRY
)
shader
->
u
.
gs
.
vertices_out
=
ins
.
declaration
.
count
;
else
FIXME
(
"Invalid instruction %#x for shader type %#x.
\n
"
,
ins
.
handler_idx
,
shader_version
.
type
);
}
else
if
(
ins
.
handler_idx
==
WINED3DSIH_DEF
)
{
struct
wined3d_shader_lconst
*
lconst
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
*
lconst
));
...
...
dlls/wined3d/wined3d_private.h
View file @
9a27b0ad
...
...
@@ -2558,6 +2558,7 @@ BOOL getColorBits(const struct wined3d_format *format,
BYTE
*
redSize
,
BYTE
*
greenSize
,
BYTE
*
blueSize
,
BYTE
*
alphaSize
,
BYTE
*
totalSize
)
DECLSPEC_HIDDEN
;
BOOL
getDepthStencilBits
(
const
struct
wined3d_format
*
format
,
BYTE
*
depthSize
,
BYTE
*
stencilSize
)
DECLSPEC_HIDDEN
;
GLenum
gl_primitive_type_from_d3d
(
enum
wined3d_primitive_type
primitive_type
)
DECLSPEC_HIDDEN
;
/* Math utils */
void
multiply_matrix
(
struct
wined3d_matrix
*
dest
,
const
struct
wined3d_matrix
*
src1
,
...
...
@@ -2603,6 +2604,13 @@ struct wined3d_vertex_shader
struct
wined3d_shader_attribute
attributes
[
MAX_ATTRIBS
];
};
struct
wined3d_geometry_shader
{
enum
wined3d_primitive_type
input_type
;
enum
wined3d_primitive_type
output_type
;
UINT
vertices_out
;
};
struct
wined3d_pixel_shader
{
/* Pixel shader input semantics */
...
...
@@ -2648,6 +2656,7 @@ struct wined3d_shader
union
{
struct
wined3d_vertex_shader
vs
;
struct
wined3d_geometry_shader
gs
;
struct
wined3d_pixel_shader
ps
;
}
u
;
};
...
...
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