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
12369f9f
Commit
12369f9f
authored
Mar 28, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 29, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Fix the VBO check in device_stream_info_from_declaration().
parent
7017ed45
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
15 additions
and
11 deletions
+15
-11
device.c
dlls/wined3d/device.c
+15
-11
No files found.
dlls/wined3d/device.c
View file @
12369f9f
...
...
@@ -172,7 +172,7 @@ static BOOL fixed_get_input(BYTE usage, BYTE usage_idx, unsigned int *regnum)
/* Context activation is done by the caller. */
void
device_stream_info_from_declaration
(
struct
wined3d_device
*
device
,
struct
wined3d_stream_info
*
stream_info
,
BOOL
*
fixup
)
struct
wined3d_stream_info
*
stream_info
,
BOOL
*
all_vbo
)
{
const
struct
wined3d_state
*
state
=
&
device
->
stateBlock
->
state
;
/* We need to deal with frequency data! */
...
...
@@ -234,12 +234,6 @@ void device_stream_info_from_declaration(struct wined3d_device *device,
FIXME
(
"System memory vertex data load offset is negative!
\n
"
);
}
}
if
(
fixup
)
{
if
(
data
.
buffer_object
)
*
fixup
=
TRUE
;
}
}
data
.
addr
+=
element
->
offset
;
...
...
@@ -303,6 +297,8 @@ void device_stream_info_from_declaration(struct wined3d_device *device,
if
(
!
state
->
user_stream
)
{
WORD
map
=
stream_info
->
use_map
;
if
(
all_vbo
)
*
all_vbo
=
TRUE
;
/* PreLoad all the vertex buffers. */
for
(
i
=
0
;
map
;
map
>>=
1
,
++
i
)
...
...
@@ -324,10 +320,17 @@ void device_stream_info_from_declaration(struct wined3d_device *device,
+
(
ptrdiff_t
)
element
->
data
.
addr
;
}
if
(
!
buffer
->
buffer_object
&&
all_vbo
)
*
all_vbo
=
FALSE
;
if
(
buffer
->
query
)
device
->
buffer_queries
[
device
->
num_buffer_queries
++
]
=
buffer
->
query
;
}
}
else
if
(
all_vbo
)
{
*
all_vbo
=
FALSE
;
}
}
static
void
stream_info_element_from_strided
(
const
struct
wined3d_gl_info
*
gl_info
,
...
...
@@ -403,7 +406,7 @@ void device_update_stream_info(struct wined3d_device *device, const struct wined
{
struct
wined3d_stream_info
*
stream_info
=
&
device
->
strided_streams
;
const
struct
wined3d_state
*
state
=
&
device
->
stateBlock
->
state
;
BOOL
fixup
=
FALSE
;
BOOL
all_vbo
;
if
(
device
->
up_strided
)
{
...
...
@@ -411,16 +414,17 @@ void device_update_stream_info(struct wined3d_device *device, const struct wined
TRACE
(
"=============================== Strided Input ================================
\n
"
);
device_stream_info_from_strided
(
gl_info
,
device
->
up_strided
,
stream_info
);
if
(
TRACE_ON
(
d3d
))
device_trace_strided_stream_info
(
stream_info
);
all_vbo
=
FALSE
;
}
else
{
TRACE
(
"============================= Vertex Declaration =============================
\n
"
);
device_stream_info_from_declaration
(
device
,
stream_info
,
&
fixup
);
device_stream_info_from_declaration
(
device
,
stream_info
,
&
all_vbo
);
}
if
(
state
->
vertex_shader
&&
!
stream_info
->
position_transformed
)
{
if
(
state
->
vertex_declaration
->
half_float_conv_needed
&&
!
fixup
)
if
(
state
->
vertex_declaration
->
half_float_conv_needed
&&
!
all_vbo
)
{
TRACE
(
"Using drawStridedSlow with vertex shaders for FLOAT16 conversion.
\n
"
);
device
->
useDrawStridedSlow
=
TRUE
;
...
...
@@ -436,7 +440,7 @@ void device_update_stream_info(struct wined3d_device *device, const struct wined
slow_mask
|=
-!
gl_info
->
supported
[
ARB_VERTEX_ARRAY_BGRA
]
&
((
1
<<
WINED3D_FFP_DIFFUSE
)
|
(
1
<<
WINED3D_FFP_SPECULAR
));
if
((
stream_info
->
position_transformed
||
(
stream_info
->
use_map
&
slow_mask
))
&&
!
fixup
)
if
((
stream_info
->
position_transformed
||
(
stream_info
->
use_map
&
slow_mask
))
&&
!
all_vbo
)
{
device
->
useDrawStridedSlow
=
TRUE
;
}
...
...
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