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
4082920c
Commit
4082920c
authored
Mar 22, 2010
by
Christian Costa
Committed by
Alexandre Julliard
Mar 22, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9_36: Add stubbed interface for ID3DXEffect.
parent
eabce3e0
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
87 additions
and
0 deletions
+87
-0
effect.c
dlls/d3dx9_36/effect.c
+0
-0
Makefile.in
dlls/d3dx9_36/tests/Makefile.in
+1
-0
effect.c
dlls/d3dx9_36/tests/effect.c
+86
-0
No files found.
dlls/d3dx9_36/effect.c
View file @
4082920c
This diff is collapsed.
Click to expand it.
dlls/d3dx9_36/tests/Makefile.in
View file @
4082920c
...
...
@@ -8,6 +8,7 @@ IMPORTS = d3dx9 d3d9 user32 gdi32 kernel32
C_SRCS
=
\
asm.c
\
core.c
\
effect.c
\
math.c
\
mesh.c
\
shader.c
\
...
...
dlls/d3dx9_36/tests/effect.c
0 → 100644
View file @
4082920c
/*
* Copyright 2010 Christian Costa
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#include "wine/test.h"
#include "d3dx9.h"
static
const
char
effect_desc
[]
=
"Technique
\n
"
"{
\n
"
"}
\n
"
;
static
void
test_create_effect
(
IDirect3DDevice9
*
device
)
{
HRESULT
hr
;
ID3DXEffect
*
effect
;
hr
=
D3DXCreateEffect
(
NULL
,
effect_desc
,
sizeof
(
effect_desc
),
NULL
,
NULL
,
0
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got result %x, expected %x (D3D_INVALIDCALL)
\n
"
,
hr
,
D3DERR_INVALIDCALL
);
hr
=
D3DXCreateEffect
(
device
,
NULL
,
0
,
NULL
,
NULL
,
0
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got result %x, expected %x (D3DERR_INVALIDCALL)
\n
"
,
hr
,
D3DERR_INVALIDCALL
);
hr
=
D3DXCreateEffect
(
device
,
effect_desc
,
0
,
NULL
,
NULL
,
0
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
E_FAIL
,
"Got result %x, expected %x (D3DXERR_INVALIDDATA)
\n
"
,
hr
,
E_FAIL
);
hr
=
D3DXCreateEffect
(
device
,
effect_desc
,
sizeof
(
effect_desc
),
NULL
,
NULL
,
0
,
NULL
,
NULL
,
NULL
);
ok
(
hr
==
D3D_OK
,
"Got result %x, expected 0 (D3D_OK)
\n
"
,
hr
);
hr
=
D3DXCreateEffect
(
device
,
effect_desc
,
sizeof
(
effect_desc
),
NULL
,
NULL
,
0
,
NULL
,
&
effect
,
NULL
);
ok
(
hr
==
D3D_OK
,
"Got result %x, expected 0 (D3D_OK)
\n
"
,
hr
);
effect
->
lpVtbl
->
Release
(
effect
);
}
START_TEST
(
effect
)
{
HWND
wnd
;
IDirect3D9
*
d3d
;
IDirect3DDevice9
*
device
;
D3DPRESENT_PARAMETERS
d3dpp
;
HRESULT
hr
;
wnd
=
CreateWindow
(
"static"
,
"d3dx9_test"
,
0
,
0
,
0
,
0
,
0
,
NULL
,
NULL
,
NULL
,
NULL
);
d3d
=
Direct3DCreate9
(
D3D_SDK_VERSION
);
if
(
!
wnd
)
{
skip
(
"Couldn't create application window
\n
"
);
return
;
}
if
(
!
d3d
)
{
skip
(
"Couldn't create IDirect3D9 object
\n
"
);
DestroyWindow
(
wnd
);
return
;
}
ZeroMemory
(
&
d3dpp
,
sizeof
(
d3dpp
));
d3dpp
.
Windowed
=
TRUE
;
d3dpp
.
SwapEffect
=
D3DSWAPEFFECT_DISCARD
;
hr
=
IDirect3D9_CreateDevice
(
d3d
,
D3DADAPTER_DEFAULT
,
D3DDEVTYPE_HAL
,
wnd
,
D3DCREATE_MIXED_VERTEXPROCESSING
,
&
d3dpp
,
&
device
);
if
(
FAILED
(
hr
))
{
skip
(
"Failed to create IDirect3DDevice9 object %#x
\n
"
,
hr
);
IDirect3D9_Release
(
d3d
);
DestroyWindow
(
wnd
);
return
;
}
test_create_effect
(
device
);
IDirect3DDevice9_Release
(
device
);
IDirect3D9_Release
(
d3d
);
DestroyWindow
(
wnd
);
}
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