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
7c969b05
Commit
7c969b05
authored
Apr 02, 2024
by
Nikolay Sivov
Committed by
Alexandre Julliard
Apr 02, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d2d1/effect: Implement SetSingleTransformNode().
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
parent
3d64da16
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
37 additions
and
9 deletions
+37
-9
effect.c
dlls/d2d1/effect.c
+25
-3
d2d1.c
dlls/d2d1/tests/d2d1.c
+12
-6
No files found.
dlls/d2d1/effect.c
View file @
7c969b05
...
@@ -364,11 +364,33 @@ static UINT32 STDMETHODCALLTYPE d2d_transform_graph_GetInputCount(ID2D1Transform
...
@@ -364,11 +364,33 @@ static UINT32 STDMETHODCALLTYPE d2d_transform_graph_GetInputCount(ID2D1Transform
}
}
static
HRESULT
STDMETHODCALLTYPE
d2d_transform_graph_SetSingleTransformNode
(
ID2D1TransformGraph
*
iface
,
static
HRESULT
STDMETHODCALLTYPE
d2d_transform_graph_SetSingleTransformNode
(
ID2D1TransformGraph
*
iface
,
ID2D1TransformNode
*
node
)
ID2D1TransformNode
*
object
)
{
{
FIXME
(
"iface %p, node %p stub!
\n
"
,
iface
,
node
);
struct
d2d_transform_graph
*
graph
=
impl_from_ID2D1TransformGraph
(
iface
);
struct
d2d_transform_node
*
node
;
unsigned
int
i
,
input_count
;
HRESULT
hr
;
return
E_NOTIMPL
;
TRACE
(
"iface %p, object %p.
\n
"
,
iface
,
object
);
d2d_transform_graph_clear
(
graph
);
if
(
FAILED
(
hr
=
d2d_transform_graph_add_node
(
graph
,
object
)))
return
hr
;
node
=
d2d_transform_graph_get_node
(
graph
,
object
);
graph
->
output
=
node
;
input_count
=
ID2D1TransformNode_GetInputCount
(
object
);
if
(
graph
->
input_count
!=
input_count
)
return
E_INVALIDARG
;
for
(
i
=
0
;
i
<
graph
->
input_count
;
++
i
)
{
graph
->
inputs
[
i
].
node
=
node
;
graph
->
inputs
[
i
].
index
=
i
;
}
return
S_OK
;
}
}
static
HRESULT
STDMETHODCALLTYPE
d2d_transform_graph_AddNode
(
ID2D1TransformGraph
*
iface
,
static
HRESULT
STDMETHODCALLTYPE
d2d_transform_graph_AddNode
(
ID2D1TransformGraph
*
iface
,
...
...
dlls/d2d1/tests/d2d1.c
View file @
7c969b05
...
@@ -12731,6 +12731,18 @@ static void test_transform_graph(BOOL d3d11)
...
@@ -12731,6 +12731,18 @@ static void test_transform_graph(BOOL d3d11)
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_NOT_FOUND
),
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_NOT_FOUND
),
"Got unexpected hr %#lx.
\n
"
,
hr
);
hr
=
ID2D1TransformGraph_SetOutputNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
hr
=
ID2D1TransformGraph_SetOutputNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_NOT_FOUND
),
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
HRESULT_FROM_WIN32
(
ERROR_NOT_FOUND
),
"Got unexpected hr %#lx.
\n
"
,
hr
);
/* Single input effect, single input node. */
hr
=
ID2D1TransformGraph_SetSingleTransformNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
/* Single input effect, two-input node. */
hr
=
ID2D1TransformGraph_SetSingleTransformNode
(
graph
,
(
ID2D1TransformNode
*
)
blend_transform
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
hr
=
ID2D1TransformGraph_AddNode
(
graph
,
(
ID2D1TransformNode
*
)
blend_transform
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
ID2D1TransformGraph_Clear
(
graph
);
hr
=
ID2D1TransformGraph_AddNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
hr
=
ID2D1TransformGraph_AddNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
hr
=
ID2D1TransformGraph_AddNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
hr
=
ID2D1TransformGraph_AddNode
(
graph
,
(
ID2D1TransformNode
*
)
offset_transform
);
...
@@ -14507,13 +14519,7 @@ static void test_effect_custom_pixel_shader(BOOL d3d11)
...
@@ -14507,13 +14519,7 @@ static void test_effect_custom_pixel_shader(BOOL d3d11)
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
hr
=
ID2D1DeviceContext_CreateEffect
(
context
,
&
CLSID_TestEffect
,
&
effect
);
hr
=
ID2D1DeviceContext_CreateEffect
(
context
,
&
CLSID_TestEffect
,
&
effect
);
todo_wine
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#lx.
\n
"
,
hr
);
if
(
FAILED
(
hr
))
{
release_test_context
(
&
ctx
);
return
;
}
set_size_u
(
&
input_size
,
1
,
1
);
set_size_u
(
&
input_size
,
1
,
1
);
pixel
=
0xabcd00ff
;
pixel
=
0xabcd00ff
;
...
...
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