Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
691086ea
Commit
691086ea
authored
Feb 16, 2016
by
Henri Verbeet
Committed by
Alexandre Julliard
Feb 17, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Introduce wined3d_texture_get_sub_resource_parent().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
4f909e98
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
0 deletions
+17
-0
texture.c
dlls/wined3d/texture.c
+15
-0
wined3d.spec
dlls/wined3d/wined3d.spec
+1
-0
wined3d.h
include/wine/wined3d.h
+1
-0
No files found.
dlls/wined3d/texture.c
View file @
691086ea
...
...
@@ -1485,6 +1485,21 @@ HRESULT CDECL wined3d_texture_update_overlay(struct wined3d_texture *texture, un
return
WINED3D_OK
;
}
void
*
CDECL
wined3d_texture_get_sub_resource_parent
(
struct
wined3d_texture
*
texture
,
unsigned
int
sub_resource_idx
)
{
unsigned
int
sub_count
=
texture
->
level_count
*
texture
->
layer_count
;
TRACE
(
"texture %p, sub_resource_idx %u.
\n
"
,
texture
,
sub_resource_idx
);
if
(
sub_resource_idx
>=
sub_count
)
{
WARN
(
"sub_resource_idx %u >= sub_count %u.
\n
"
,
sub_resource_idx
,
sub_count
);
return
NULL
;
}
return
texture
->
sub_resources
[
sub_resource_idx
].
resource
->
parent
;
}
HRESULT
CDECL
wined3d_texture_create
(
struct
wined3d_device
*
device
,
const
struct
wined3d_resource_desc
*
desc
,
UINT
level_count
,
DWORD
flags
,
const
struct
wined3d_sub_resource_data
*
data
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
,
struct
wined3d_texture
**
texture
)
...
...
dlls/wined3d/wined3d.spec
View file @
691086ea
...
...
@@ -251,6 +251,7 @@
@ cdecl wined3d_texture_get_pitch(ptr long ptr ptr)
@ cdecl wined3d_texture_get_resource(ptr)
@ cdecl wined3d_texture_get_sub_resource(ptr long)
@ cdecl wined3d_texture_get_sub_resource_parent(ptr long)
@ cdecl wined3d_texture_incref(ptr)
@ cdecl wined3d_texture_preload(ptr)
@ cdecl wined3d_texture_release_dc(ptr long ptr)
...
...
include/wine/wined3d.h
View file @
691086ea
...
...
@@ -2447,6 +2447,7 @@ void __cdecl wined3d_texture_get_pitch(const struct wined3d_texture *texture,
struct
wined3d_resource
*
__cdecl
wined3d_texture_get_resource
(
struct
wined3d_texture
*
texture
);
struct
wined3d_resource
*
__cdecl
wined3d_texture_get_sub_resource
(
const
struct
wined3d_texture
*
texture
,
UINT
sub_resource_idx
);
void
*
__cdecl
wined3d_texture_get_sub_resource_parent
(
struct
wined3d_texture
*
texture
,
unsigned
int
sub_resource_idx
);
ULONG
__cdecl
wined3d_texture_incref
(
struct
wined3d_texture
*
texture
);
void
__cdecl
wined3d_texture_preload
(
struct
wined3d_texture
*
texture
);
HRESULT
__cdecl
wined3d_texture_release_dc
(
struct
wined3d_texture
*
texture
,
unsigned
int
sub_resource_idx
,
HDC
dc
);
...
...
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