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
89bf30a2
Commit
89bf30a2
authored
Jul 11, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Jul 11, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Return data as struct wined3d_bo_address in buffer_get_memory().
parent
a3538a15
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
11 additions
and
10 deletions
+11
-10
buffer.c
dlls/wined3d/buffer.c
+8
-7
device.c
dlls/wined3d/device.c
+1
-1
wined3d_private.h
dlls/wined3d/wined3d_private.h
+2
-2
No files found.
dlls/wined3d/buffer.c
View file @
89bf30a2
...
...
@@ -467,10 +467,10 @@ static inline void fixup_transformed_pos(float *p)
}
/* Context activation is done by the caller. */
const
BYTE
*
buffer_get_memory
(
struct
wined3d_buffer
*
buffer
,
const
struct
wined3d_gl_info
*
gl_info
,
GLuint
*
buffer_object
)
void
buffer_get_memory
(
struct
wined3d_buffer
*
buffer
,
const
struct
wined3d_gl_info
*
gl_info
,
struct
wined3d_bo_address
*
data
)
{
*
buffer_object
=
buffer
->
buffer_object
;
data
->
buffer_object
=
buffer
->
buffer_object
;
if
(
!
buffer
->
buffer_object
)
{
if
(
buffer
->
flags
&
WINED3D_BUFFER_CREATEBO
)
...
...
@@ -479,15 +479,16 @@ const BYTE *buffer_get_memory(struct wined3d_buffer *buffer,
buffer
->
flags
&=
~
WINED3D_BUFFER_CREATEBO
;
if
(
buffer
->
buffer_object
)
{
*
buffer_object
=
buffer
->
buffer_object
;
return
NULL
;
data
->
buffer_object
=
buffer
->
buffer_object
;
data
->
addr
=
NULL
;
return
;
}
}
return
buffer
->
resource
.
allocatedMemory
;
data
->
addr
=
buffer
->
resource
.
allocatedMemory
;
}
else
{
return
NULL
;
data
->
addr
=
NULL
;
}
}
...
...
dlls/wined3d/device.c
View file @
89bf30a2
...
...
@@ -213,7 +213,7 @@ void device_stream_info_from_declaration(struct wined3d_device *device,
else
{
TRACE
(
"Stream %u isn't UP, %p
\n
"
,
element
->
input_slot
,
buffer
);
data
.
addr
=
buffer_get_memory
(
buffer
,
&
device
->
adapter
->
gl_info
,
&
data
.
buffer_object
);
buffer_get_memory
(
buffer
,
&
device
->
adapter
->
gl_info
,
&
data
);
/* Can't use vbo's if the base vertex index is negative. OpenGL doesn't accept negative offsets
* (or rather offsets bigger than the vbo, because the pointer is unsigned), so use system memory
...
...
dlls/wined3d/wined3d_private.h
View file @
89bf30a2
...
...
@@ -2405,8 +2405,8 @@ static inline struct wined3d_buffer *buffer_from_resource(struct wined3d_resourc
return
CONTAINING_RECORD
(
resource
,
struct
wined3d_buffer
,
resource
);
}
const
BYTE
*
buffer_get_memory
(
struct
wined3d_buffer
*
buffer
,
const
struct
wined3d_gl_info
*
gl_info
,
GLuint
*
buffer_object
)
DECLSPEC_HIDDEN
;
void
buffer_get_memory
(
struct
wined3d_buffer
*
buffer
,
const
struct
wined3d_gl_info
*
gl_info
,
struct
wined3d_bo_address
*
data
)
DECLSPEC_HIDDEN
;
BYTE
*
buffer_get_sysmem
(
struct
wined3d_buffer
*
This
,
const
struct
wined3d_gl_info
*
gl_info
)
DECLSPEC_HIDDEN
;
struct
wined3d_rendertarget_view
...
...
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