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
8e343024
Commit
8e343024
authored
Jul 15, 2020
by
Nikolay Sivov
Committed by
Alexandre Julliard
Jul 15, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mf/topoloader: Switch to public interface for initial topology validation.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
04d53626
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
11 deletions
+23
-11
topology.c
dlls/mf/topology.c
+23
-11
No files found.
dlls/mf/topology.c
View file @
8e343024
...
...
@@ -1936,38 +1936,50 @@ static ULONG WINAPI topology_loader_Release(IMFTopoLoader *iface)
static
HRESULT
WINAPI
topology_loader_Load
(
IMFTopoLoader
*
iface
,
IMFTopology
*
input_topology
,
IMFTopology
**
output_topology
,
IMFTopology
*
current_topology
)
{
struct
topology
*
topology
=
unsafe_impl_from_IMFTopology
(
input_topology
);
MF_TOPOLOGY_TYPE
node_type
;
IMFTopologyNode
*
node
;
unsigned
short
i
=
0
;
IMFStreamSink
*
sink
;
HRESULT
hr
;
size_t
i
;
IUnknown
*
object
;
HRESULT
hr
=
E_FAIL
;
FIXME
(
"%p, %p, %p, %p.
\n
"
,
iface
,
input_topology
,
output_topology
,
current_topology
);
if
(
current_topology
)
FIXME
(
"Current topology instance is ignored.
\n
"
);
for
(
i
=
0
;
i
<
topology
->
nodes
.
count
;
++
i
)
/* Basic sanity checks for input topology:
- source nodes must have stream descriptor set;
- sink nodes must be resolved to stream sink objects;
*/
while
(
SUCCEEDED
(
IMFTopology_GetNode
(
input_topology
,
i
++
,
&
node
)))
{
struct
topology_node
*
node
=
topology
->
nodes
.
nodes
[
i
]
;
IMFTopologyNode_GetNodeType
(
node
,
&
node_type
)
;
switch
(
node
->
node
_type
)
switch
(
node_type
)
{
case
MF_TOPOLOGY_OUTPUT_NODE
:
if
(
node
->
object
)
if
(
SUCCEEDED
(
hr
=
IMFTopologyNode_GetObject
(
node
,
&
object
))
)
{
/* Sinks must be bound beforehand. */
if
(
FAILED
(
IUnknown_QueryInterface
(
node
->
object
,
&
IID_IMFStreamSink
,
(
void
**
)
&
sink
)))
return
MF_E_TOPO_SINK_ACTIVATES_UNSUPPORTED
;
if
(
FAILED
(
IUnknown_QueryInterface
(
object
,
&
IID_IMFStreamSink
,
(
void
**
)
&
sink
)))
hr
=
MF_E_TOPO_SINK_ACTIVATES_UNSUPPORTED
;
else
if
(
sink
)
IMFStreamSink_Release
(
sink
);
IUnknown_Release
(
object
);
}
break
;
case
MF_TOPOLOGY_SOURCESTREAM_NODE
:
if
(
FAILED
(
hr
=
IMFAttributes_GetItem
(
node
->
attributes
,
&
MF_TOPONODE_STREAM_DESCRIPTOR
,
NULL
)))
return
hr
;
hr
=
IMFTopologyNode_GetItem
(
node
,
&
MF_TOPONODE_STREAM_DESCRIPTOR
,
NULL
);
break
;
default:
;
}
IMFTopologyNode_Release
(
node
);
if
(
FAILED
(
hr
))
return
hr
;
}
if
(
FAILED
(
hr
=
MFCreateTopology
(
output_topology
)))
...
...
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