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
76d69cdb
Commit
76d69cdb
authored
Mar 27, 2012
by
Christian Costa
Committed by
Alexandre Julliard
Mar 28, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
amstream: Implement AddMediaStream and GetMediaStream in media stream filter.
parent
82290556
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
5 deletions
+38
-5
mediastreamfilter.c
dlls/amstream/mediastreamfilter.c
+38
-5
No files found.
dlls/amstream/mediastreamfilter.c
View file @
76d69cdb
...
...
@@ -37,7 +37,8 @@ WINE_DEFAULT_DEBUG_CHANNEL(amstream);
typedef
struct
{
BaseFilter
filter
;
ULONG
nb_streams
;
IMediaStream
**
streams
;
}
IMediaStreamFilterImpl
;
static
inline
IMediaStreamFilterImpl
*
impl_from_IMediaStreamFilter
(
IMediaStreamFilter
*
iface
)
...
...
@@ -89,7 +90,12 @@ static ULONG WINAPI MediaStreamFilterImpl_Release(IMediaStreamFilter *iface)
TRACE
(
"(%p)->() Release from %d
\n
"
,
iface
,
refCount
+
1
);
if
(
!
refCount
)
{
int
i
;
for
(
i
=
0
;
i
<
This
->
nb_streams
;
i
++
)
IMediaStream_Release
(
This
->
streams
[
i
]);
HeapFree
(
GetProcessHeap
(),
0
,
This
);
}
return
refCount
;
}
...
...
@@ -170,16 +176,43 @@ static HRESULT WINAPI MediaStreamFilterImpl_QueryVendorInfo(IMediaStreamFilter *
static
HRESULT
WINAPI
MediaStreamFilterImpl_AddMediaStream
(
IMediaStreamFilter
*
iface
,
IAMMediaStream
*
pAMMediaStream
)
{
FIXME
(
"(%p)->(%p): Stub!
\n
"
,
iface
,
pAMMediaStream
);
IMediaStreamFilterImpl
*
This
=
impl_from_IMediaStreamFilter
(
iface
);
IMediaStream
**
streams
;
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%p)
\n
"
,
iface
,
pAMMediaStream
);
streams
=
CoTaskMemRealloc
(
This
->
streams
,
(
This
->
nb_streams
+
1
)
*
sizeof
(
IMediaStream
*
));
if
(
!
streams
)
return
E_OUTOFMEMORY
;
This
->
streams
=
streams
;
This
->
streams
[
This
->
nb_streams
]
=
(
IMediaStream
*
)
pAMMediaStream
;
This
->
nb_streams
++
;
IMediaStream_AddRef
((
IMediaStream
*
)
pAMMediaStream
);
return
S_OK
;
}
static
HRESULT
WINAPI
MediaStreamFilterImpl_GetMediaStream
(
IMediaStreamFilter
*
iface
,
REFMSPID
idPurpose
,
IMediaStream
**
ppMediaStream
)
{
FIXME
(
"(%p)->(%s,%p): Stub!
\n
"
,
iface
,
debugstr_guid
(
idPurpose
),
ppMediaStream
);
IMediaStreamFilterImpl
*
This
=
impl_from_IMediaStreamFilter
(
iface
);
MSPID
purpose_id
;
unsigned
int
i
;
return
E_NOTIMPL
;
TRACE
(
"(%p)->(%s,%p)
\n
"
,
iface
,
debugstr_guid
(
idPurpose
),
ppMediaStream
);
for
(
i
=
0
;
i
<
This
->
nb_streams
;
i
++
)
{
IMediaStream_GetInformation
(
This
->
streams
[
i
],
&
purpose_id
,
NULL
);
if
(
IsEqualIID
(
&
purpose_id
,
idPurpose
))
{
*
ppMediaStream
=
This
->
streams
[
i
];
IMediaStream_AddRef
(
*
ppMediaStream
);
return
S_OK
;
}
}
return
MS_E_NOSTREAM
;
}
static
HRESULT
WINAPI
MediaStreamFilterImpl_EnumMediaStreams
(
IMediaStreamFilter
*
iface
,
LONG
Index
,
IMediaStream
**
ppMediaStream
)
...
...
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