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
3529560c
Commit
3529560c
authored
Oct 05, 2006
by
Stefan Dösinger
Committed by
Alexandre Julliard
Oct 06, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add WINED3DUSAGE_OVERLAY.
parent
2bcacf22
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
46 additions
and
12 deletions
+46
-12
device.c
dlls/d3d8/device.c
+6
-6
device.c
dlls/d3d9/device.c
+1
-1
indexbuffer.c
dlls/d3d9/indexbuffer.c
+1
-1
texture.c
dlls/d3d9/texture.c
+1
-1
vertexbuffer.c
dlls/d3d9/vertexbuffer.c
+1
-1
volume.c
dlls/d3d9/volume.c
+1
-1
volumetexture.c
dlls/d3d9/volumetexture.c
+1
-1
ddraw.c
dlls/ddraw/ddraw.c
+4
-0
surface.c
dlls/wined3d/surface.c
+24
-0
surface_gdi.c
dlls/wined3d/surface_gdi.c
+5
-0
wined3d_types.h
include/wine/wined3d_types.h
+1
-0
No files found.
dlls/d3d8/device.c
View file @
3529560c
...
...
@@ -337,7 +337,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateTexture(LPDIRECT3DDEVICE8 iface
object
->
lpVtbl
=
&
Direct3DTexture8_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DFORMAT
)
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DTexture
,
NULL
,
(
IUnknown
*
)
object
,
D3D8CB_CreateSurface
);
if
(
FAILED
(
hrc
))
{
...
...
@@ -375,7 +375,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateVolumeTexture(LPDIRECT3DDEVICE8
object
->
lpVtbl
=
&
Direct3DVolumeTexture8_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DFORMAT
)
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DVolumeTexture
,
NULL
,
(
IUnknown
*
)
object
,
D3D8CB_CreateVolume
);
...
...
@@ -414,7 +414,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateCubeTexture(LPDIRECT3DDEVICE8 i
object
->
lpVtbl
=
&
Direct3DCubeTexture8_Vtbl
;
object
->
ref
=
1
;
hr
=
IWineD3DDevice_CreateCubeTexture
(
This
->
WineD3DDevice
,
EdgeLength
,
Levels
,
Usage
,
hr
=
IWineD3DDevice_CreateCubeTexture
(
This
->
WineD3DDevice
,
EdgeLength
,
Levels
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DFORMAT
)
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DCubeTexture
,
NULL
,
(
IUnknown
*
)
object
,
D3D8CB_CreateSurface
);
...
...
@@ -450,7 +450,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateVertexBuffer(LPDIRECT3DDEVICE8
object
->
lpVtbl
=
&
Direct3DVertexBuffer8_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVertexBuffer
(
This
->
WineD3DDevice
,
Size
,
Usage
,
FVF
,
(
WINED3DPOOL
)
Pool
,
&
(
object
->
wineD3DVertexBuffer
),
NULL
,
(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateVertexBuffer
(
This
->
WineD3DDevice
,
Size
,
Usage
&
WINED3DUSAGE_MASK
,
FVF
,
(
WINED3DPOOL
)
Pool
,
&
(
object
->
wineD3DVertexBuffer
),
NULL
,
(
IUnknown
*
)
object
);
if
(
D3D_OK
!=
hrc
)
{
...
...
@@ -483,7 +483,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateIndexBuffer(LPDIRECT3DDEVICE8 i
object
->
lpVtbl
=
&
Direct3DIndexBuffer8_Vtbl
;
object
->
ref
=
1
;
TRACE
(
"Calling wined3d create index buffer
\n
"
);
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
,
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DIndexBuffer
,
NULL
,
(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
&
WINED3DUSAGE_MASK
,
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DIndexBuffer
,
NULL
,
(
IUnknown
*
)
object
);
if
(
D3D_OK
!=
hrc
)
{
...
...
@@ -533,7 +533,7 @@ static HRESULT WINAPI IDirect3DDevice8Impl_CreateSurface(LPDIRECT3DDEVICE8 iface
TRACE
(
"(%p) : w(%d) h(%d) fmt(%d) surf@%p
\n
"
,
This
,
Width
,
Height
,
Format
,
*
ppSurface
);
hrc
=
IWineD3DDevice_CreateSurface
(
This
->
WineD3DDevice
,
Width
,
Height
,
Format
,
Lockable
,
Discard
,
Level
,
&
object
->
wineD3DSurface
,
Type
,
Usage
,
(
WINED3DPOOL
)
Pool
,
MultiSample
,
MultisampleQuality
,
NULL
,
SURFACE_OPENGL
,
(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateSurface
(
This
->
WineD3DDevice
,
Width
,
Height
,
Format
,
Lockable
,
Discard
,
Level
,
&
object
->
wineD3DSurface
,
Type
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DPOOL
)
Pool
,
MultiSample
,
MultisampleQuality
,
NULL
,
SURFACE_OPENGL
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
||
NULL
==
object
->
wineD3DSurface
)
{
/* free up object */
FIXME
(
"(%p) call to IWineD3DDevice_CreateSurface failed
\n
"
,
This
);
...
...
dlls/d3d9/device.c
View file @
3529560c
...
...
@@ -274,7 +274,7 @@ static HRESULT WINAPI IDirect3DDevice9Impl_CreateSurface(LPDIRECT3DDEVICE9 ifac
TRACE
(
"(%p) : w(%d) h(%d) fmt(%d) surf@%p
\n
"
,
This
,
Width
,
Height
,
Format
,
*
ppSurface
);
hrc
=
IWineD3DDevice_CreateSurface
(
This
->
WineD3DDevice
,
Width
,
Height
,
Format
,
Lockable
,
Discard
,
Level
,
&
object
->
wineD3DSurface
,
Type
,
Usage
,
(
WINED3DPOOL
)
Pool
,
MultiSample
,
MultisampleQuality
,
pSharedHandle
,
SURFACE_OPENGL
,(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateSurface
(
This
->
WineD3DDevice
,
Width
,
Height
,
Format
,
Lockable
,
Discard
,
Level
,
&
object
->
wineD3DSurface
,
Type
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DPOOL
)
Pool
,
MultiSample
,
MultisampleQuality
,
pSharedHandle
,
SURFACE_OPENGL
,(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
||
NULL
==
object
->
wineD3DSurface
)
{
...
...
dlls/d3d9/indexbuffer.c
View file @
3529560c
...
...
@@ -175,7 +175,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateIndexBuffer(LPDIRECT3DDEVICE9 iface,
object
->
lpVtbl
=
&
Direct3DIndexBuffer9_Vtbl
;
object
->
ref
=
1
;
TRACE
(
"Calling wined3d create index buffer
\n
"
);
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
,
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DIndexBuffer
,
pSharedHandle
,
(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateIndexBuffer
(
This
->
WineD3DDevice
,
Length
,
Usage
&
WINED3DUSAGE_MASK
,
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DIndexBuffer
,
pSharedHandle
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
)
{
/* free up object */
...
...
dlls/d3d9/texture.c
View file @
3529560c
...
...
@@ -256,7 +256,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateTexture(LPDIRECT3DDEVICE9 iface, UIN
object
->
lpVtbl
=
&
Direct3DTexture9_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Levels
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DFORMAT
)
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DTexture
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateSurface
);
if
(
FAILED
(
hrc
))
{
...
...
dlls/d3d9/vertexbuffer.c
View file @
3529560c
...
...
@@ -174,7 +174,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVertexBuffer(LPDIRECT3DDEVICE9 iface,
object
->
lpVtbl
=
&
Direct3DVertexBuffer9_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVertexBuffer
(
This
->
WineD3DDevice
,
Size
,
Usage
,
FVF
,
(
WINED3DPOOL
)
Pool
,
&
(
object
->
wineD3DVertexBuffer
),
pSharedHandle
,
(
IUnknown
*
)
object
);
hrc
=
IWineD3DDevice_CreateVertexBuffer
(
This
->
WineD3DDevice
,
Size
,
Usage
&
WINED3DUSAGE_MASK
,
FVF
,
(
WINED3DPOOL
)
Pool
,
&
(
object
->
wineD3DVertexBuffer
),
pSharedHandle
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
)
{
...
...
dlls/d3d9/volume.c
View file @
3529560c
...
...
@@ -219,7 +219,7 @@ HRESULT WINAPI D3D9CB_CreateVolume(IUnknown *pDevice, UINT Width, UINT Height,
object
->
lpVtbl
=
&
Direct3DVolume9_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVolume
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Usage
,
Format
,
hrc
=
IWineD3DDevice_CreateVolume
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Usage
&
WINED3DUSAGE_MASK
,
Format
,
Pool
,
&
object
->
wineD3DVolume
,
pSharedHandle
,
(
IUnknown
*
)
object
);
if
(
hrc
!=
D3D_OK
)
{
/* free up object */
...
...
dlls/d3d9/volumetexture.c
View file @
3529560c
...
...
@@ -258,7 +258,7 @@ HRESULT WINAPI IDirect3DDevice9Impl_CreateVolumeTexture(LPDIRECT3DDEVICE9 ifac
object
->
lpVtbl
=
&
Direct3DVolumeTexture9_Vtbl
;
object
->
ref
=
1
;
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
,
hrc
=
IWineD3DDevice_CreateVolumeTexture
(
This
->
WineD3DDevice
,
Width
,
Height
,
Depth
,
Levels
,
Usage
&
WINED3DUSAGE_MASK
,
(
WINED3DFORMAT
)
Format
,
(
WINED3DPOOL
)
Pool
,
&
object
->
wineD3DVolumeTexture
,
pSharedHandle
,
(
IUnknown
*
)
object
,
D3D9CB_CreateVolume
);
...
...
dlls/ddraw/ddraw.c
View file @
3529560c
...
...
@@ -1806,6 +1806,10 @@ IDirectDrawImpl_CreateNewSurface(IDirectDrawImpl *This,
DDSCAPS_VISIBLE
|
DDSCAPS_LOCALVIDMEM
;
}
if
(
pDDSD
->
ddsCaps
.
dwCaps
&
(
DDSCAPS_OVERLAY
))
{
Usage
|=
WINED3DUSAGE_OVERLAY
;
}
if
(
This
->
depthstencil
)
{
/* The depth stencil creation callback sets this flag.
...
...
dlls/wined3d/surface.c
View file @
3529560c
...
...
@@ -3076,6 +3076,12 @@ HRESULT WINAPI IWineD3DSurfaceImpl_SetOverlayPosition(IWineD3DSurface *iface, LO
FIXME
(
"(%p)->(%d,%d) Stub!
\n
"
,
This
,
X
,
Y
);
if
(
!
(
This
->
resource
.
usage
&
WINED3DUSAGE_OVERLAY
))
{
TRACE
(
"(%p): Not an overlay surface
\n
"
,
This
);
return
DDERR_NOTAOVERLAYSURFACE
;
}
return
WINED3D_OK
;
}
...
...
@@ -3084,6 +3090,12 @@ HRESULT WINAPI IWineD3DSurfaceImpl_GetOverlayPosition(IWineD3DSurface *iface, LO
FIXME
(
"(%p)->(%p,%p) Stub!
\n
"
,
This
,
X
,
Y
);
if
(
!
(
This
->
resource
.
usage
&
WINED3DUSAGE_OVERLAY
))
{
TRACE
(
"(%p): Not an overlay surface
\n
"
,
This
);
return
DDERR_NOTAOVERLAYSURFACE
;
}
return
WINED3D_OK
;
}
...
...
@@ -3093,6 +3105,12 @@ HRESULT WINAPI IWineD3DSurfaceImpl_UpdateOverlayZOrder(IWineD3DSurface *iface, D
FIXME
(
"(%p)->(%08x,%p) Stub!
\n
"
,
This
,
Flags
,
RefImpl
);
if
(
!
(
This
->
resource
.
usage
&
WINED3DUSAGE_OVERLAY
))
{
TRACE
(
"(%p): Not an overlay surface
\n
"
,
This
);
return
DDERR_NOTAOVERLAYSURFACE
;
}
return
WINED3D_OK
;
}
...
...
@@ -3101,6 +3119,12 @@ HRESULT WINAPI IWineD3DSurfaceImpl_UpdateOverlay(IWineD3DSurface *iface, RECT *S
IWineD3DSurfaceImpl
*
Dst
=
(
IWineD3DSurfaceImpl
*
)
DstSurface
;
FIXME
(
"(%p)->(%p, %p, %p, %08x, %p)
\n
"
,
This
,
SrcRect
,
Dst
,
DstRect
,
Flags
,
FX
);
if
(
!
(
This
->
resource
.
usage
&
WINED3DUSAGE_OVERLAY
))
{
TRACE
(
"(%p): Not an overlay surface
\n
"
,
This
);
return
DDERR_NOTAOVERLAYSURFACE
;
}
return
WINED3D_OK
;
}
...
...
dlls/wined3d/surface_gdi.c
View file @
3529560c
...
...
@@ -1509,6 +1509,11 @@ IWineGDISurfaceImpl_PrivateSetup(IWineD3DSurface *iface)
HDC
hdc
;
long
oldsize
=
This
->
resource
.
size
;
if
(
This
->
resource
.
usage
&
WINED3DUSAGE_OVERLAY
)
{
ERR
(
"(%p) Overlays not yet supported by GDI surfaces
\n
"
,
This
);
return
WINED3DERR_INVALIDCALL
;
}
/* Sysmem textures have memory already allocated -
* release it, this avoids an unnecessary memcpy
*/
...
...
include/wine/wined3d_types.h
View file @
3529560c
...
...
@@ -1053,6 +1053,7 @@ typedef enum _WINED3DSAMPLER_TEXTURE_TYPE {
#define WINED3DUSAGE_AUTOGENMIPMAP 0x00000400L
#define WINED3DUSAGE_DMAP 0x00004000L
#define WINED3DUSAGE_MASK 0x00004FFFL
#define WINED3DUSAGE_OVERLAY 0x00010000L
#define WINED3DUSAGE_QUERY_LEGACYBUMPMAP 0x00008000L
#define WINED3DUSAGE_QUERY_FILTER 0x00020000L
...
...
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