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
3ac924a2
Commit
3ac924a2
authored
Mar 13, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 14, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Get rid of IWineD3DCubeTexture::Map().
parent
13b05b9d
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
39 deletions
+21
-39
cubetexture.c
dlls/d3d8/cubetexture.c
+11
-7
cubetexture.c
dlls/d3d9/cubetexture.c
+10
-6
cubetexture.c
dlls/wined3d/cubetexture.c
+0
-20
wined3d.idl
include/wine/wined3d.idl
+0
-6
No files found.
dlls/d3d8/cubetexture.c
View file @
3ac924a2
...
...
@@ -306,20 +306,24 @@ static HRESULT WINAPI IDirect3DCubeTexture8Impl_GetCubeMapSurface(IDirect3DCubeT
}
static
HRESULT
WINAPI
IDirect3DCubeTexture8Impl_LockRect
(
IDirect3DCubeTexture8
*
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
const
RECT
*
pR
ect
,
DWORD
F
lags
)
D3DCUBEMAP_FACES
face
,
UINT
level
,
D3DLOCKED_RECT
*
locked_rect
,
const
RECT
*
r
ect
,
DWORD
f
lags
)
{
IDirect3DCubeTexture8Impl
*
This
=
impl_from_IDirect3DCubeTexture8
(
iface
);
IDirect3DCubeTexture8Impl
*
texture
=
impl_from_IDirect3DCubeTexture8
(
iface
);
struct
wined3d_resource
*
sub_resource
;
UINT
sub_resource_idx
;
HRESULT
hr
;
TRACE
(
"iface %p, face %#x, level %u, locked_rect %p, rect %p, flags %#x.
\n
"
,
iface
,
FaceType
,
Level
,
pLockedRect
,
pRect
,
F
lags
);
iface
,
face
,
level
,
locked_rect
,
rect
,
f
lags
);
wined3d_mutex_lock
();
sub_resource_idx
=
IWineD3DCubeTexture_GetLevelCount
(
This
->
wineD3DCubeTexture
)
*
FaceType
+
Level
;
hr
=
IWineD3DCubeTexture_Map
(
This
->
wineD3DCubeTexture
,
sub_resource_idx
,
(
WINED3DLOCKED_RECT
*
)
pLockedRect
,
pRect
,
Flags
);
sub_resource_idx
=
IWineD3DCubeTexture_GetLevelCount
(
texture
->
wineD3DCubeTexture
)
*
face
+
level
;
if
(
!
(
sub_resource
=
IWineD3DCubeTexture_GetSubResource
(
texture
->
wineD3DCubeTexture
,
sub_resource_idx
)))
hr
=
D3DERR_INVALIDCALL
;
else
hr
=
IDirect3DSurface8_LockRect
((
IDirect3DSurface8
*
)
wined3d_resource_get_parent
(
sub_resource
),
locked_rect
,
rect
,
flags
);
wined3d_mutex_unlock
();
return
hr
;
...
...
dlls/d3d9/cubetexture.c
View file @
3ac924a2
...
...
@@ -322,19 +322,23 @@ static HRESULT WINAPI IDirect3DCubeTexture9Impl_GetCubeMapSurface(IDirect3DCubeT
}
static
HRESULT
WINAPI
IDirect3DCubeTexture9Impl_LockRect
(
IDirect3DCubeTexture9
*
iface
,
D3DCUBEMAP_FACES
FaceType
,
UINT
Level
,
D3DLOCKED_RECT
*
pLockedRect
,
const
RECT
*
pRect
,
DWORD
F
lags
)
D3DCUBEMAP_FACES
face
,
UINT
level
,
D3DLOCKED_RECT
*
locked_rect
,
const
RECT
*
rect
,
DWORD
f
lags
)
{
IDirect3DCubeTexture9Impl
*
This
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
IDirect3DCubeTexture9Impl
*
texture
=
(
IDirect3DCubeTexture9Impl
*
)
iface
;
struct
wined3d_resource
*
sub_resource
;
UINT
sub_resource_idx
;
HRESULT
hr
;
TRACE
(
"iface %p, face %#x, level %u, locked_rect %p, rect %p, flags %#x.
\n
"
,
iface
,
FaceType
,
Level
,
pLockedRect
,
pRect
,
F
lags
);
iface
,
face
,
level
,
locked_rect
,
rect
,
f
lags
);
wined3d_mutex_lock
();
sub_resource_idx
=
IWineD3DCubeTexture_GetLevelCount
(
This
->
wineD3DCubeTexture
)
*
FaceType
+
Level
;
hr
=
IWineD3DCubeTexture_Map
(
This
->
wineD3DCubeTexture
,
sub_resource_idx
,
(
WINED3DLOCKED_RECT
*
)
pLockedRect
,
pRect
,
Flags
);
sub_resource_idx
=
IWineD3DCubeTexture_GetLevelCount
(
texture
->
wineD3DCubeTexture
)
*
face
+
level
;
if
(
!
(
sub_resource
=
IWineD3DCubeTexture_GetSubResource
(
texture
->
wineD3DCubeTexture
,
sub_resource_idx
)))
hr
=
D3DERR_INVALIDCALL
;
else
hr
=
IDirect3DSurface9_LockRect
((
IDirect3DSurface9
*
)
wined3d_resource_get_parent
(
sub_resource
),
locked_rect
,
rect
,
flags
);
wined3d_mutex_unlock
();
return
hr
;
...
...
dlls/wined3d/cubetexture.c
View file @
3ac924a2
...
...
@@ -336,25 +336,6 @@ static struct wined3d_resource * WINAPI IWineD3DCubeTextureImpl_GetSubResource(I
return
basetexture_get_sub_resource
(
texture
,
sub_resource_idx
);
}
static
HRESULT
WINAPI
IWineD3DCubeTextureImpl_Map
(
IWineD3DCubeTexture
*
iface
,
UINT
sub_resource_idx
,
WINED3DLOCKED_RECT
*
locked_rect
,
const
RECT
*
rect
,
DWORD
flags
)
{
IWineD3DBaseTextureImpl
*
texture
=
(
IWineD3DBaseTextureImpl
*
)
iface
;
struct
wined3d_resource
*
sub_resource
;
TRACE
(
"iface %p, sub_resource_idx %u, locked_rect %p, rect %s, flags %#x.
\n
"
,
iface
,
sub_resource_idx
,
locked_rect
,
wine_dbgstr_rect
(
rect
),
flags
);
if
(
!
(
sub_resource
=
basetexture_get_sub_resource
(
texture
,
sub_resource_idx
)))
{
WARN
(
"Failed to get sub-resource.
\n
"
);
return
WINED3DERR_INVALIDCALL
;
}
return
IWineD3DSurface_Map
((
IWineD3DSurface
*
)
surface_from_resource
(
sub_resource
),
locked_rect
,
rect
,
flags
);
}
static
HRESULT
WINAPI
IWineD3DCubeTextureImpl_Unmap
(
IWineD3DCubeTexture
*
iface
,
UINT
sub_resource_idx
)
{
...
...
@@ -420,7 +401,6 @@ static const IWineD3DCubeTextureVtbl IWineD3DCubeTexture_Vtbl =
IWineD3DCubeTextureImpl_IsCondNP2
,
IWineD3DCubeTextureImpl_GetSubResource
,
/* IWineD3DCubeTexture */
IWineD3DCubeTextureImpl_Map
,
IWineD3DCubeTextureImpl_Unmap
,
IWineD3DCubeTextureImpl_AddDirtyRect
};
...
...
include/wine/wined3d.idl
View file @
3ac924a2
...
...
@@ -2382,12 +2382,6 @@ interface IWineD3DTexture : IWineD3DBaseTexture
]
interface
IWineD3DCubeTexture
:
IWineD3DBaseTexture
{
HRESULT
Map
(
[
in
]
UINT
sub_resource_idx
,
[
out
]
WINED3DLOCKED_RECT
*
locked_rect
,
[
in
]
const
RECT
*
rect
,
[
in
]
DWORD
flags
)
;
HRESULT
Unmap
(
[
in
]
UINT
sub_resource_idx
)
;
...
...
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