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
d5b79e6a
Commit
d5b79e6a
authored
Oct 08, 2019
by
Nikolay Sivov
Committed by
Alexandre Julliard
Oct 08, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
mf: Adjust sample grabber sink flags in rateless mode.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
c1c77f22
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
0 deletions
+28
-0
samplegrabber.c
dlls/mf/samplegrabber.c
+2
-0
mf.c
dlls/mf/tests/mf.c
+26
-0
No files found.
dlls/mf/samplegrabber.c
View file @
d5b79e6a
...
...
@@ -862,6 +862,8 @@ static HRESULT WINAPI sample_grabber_sink_GetCharacteristics(IMFMediaSink *iface
return
MF_E_SHUTDOWN
;
*
flags
=
MEDIASINK_FIXED_STREAMS
;
if
(
grabber
->
ignore_clock
)
*
flags
|=
MEDIASINK_RATELESS
;
return
S_OK
;
}
...
...
dlls/mf/tests/mf.c
View file @
d5b79e6a
...
...
@@ -2166,6 +2166,32 @@ todo_wine
refcount
=
IMFActivate_Release
(
activate
);
ok
(
!
refcount
,
"Unexpected refcount %u.
\n
"
,
refcount
);
/* Rateless mode with MF_SAMPLEGRABBERSINK_IGNORE_CLOCK. */
hr
=
MFCreateMediaType
(
&
media_type
);
ok
(
hr
==
S_OK
,
"Failed to create media type, hr %#x.
\n
"
,
hr
);
hr
=
IMFMediaType_SetGUID
(
media_type
,
&
MF_MT_MAJOR_TYPE
,
&
MFMediaType_Audio
);
ok
(
hr
==
S_OK
,
"Failed to set attribute, hr %#x.
\n
"
,
hr
);
hr
=
IMFMediaType_SetGUID
(
media_type
,
&
MF_MT_SUBTYPE
,
&
MFAudioFormat_PCM
);
ok
(
hr
==
S_OK
,
"Failed to set attribute, hr %#x.
\n
"
,
hr
);
hr
=
MFCreateSampleGrabberSinkActivate
(
media_type
,
&
grabber_callback
,
&
activate
);
ok
(
hr
==
S_OK
,
"Failed to create grabber activate, hr %#x.
\n
"
,
hr
);
hr
=
IMFActivate_SetUINT32
(
activate
,
&
MF_SAMPLEGRABBERSINK_IGNORE_CLOCK
,
1
);
ok
(
hr
==
S_OK
,
"Failed to set attribute, hr %#x.
\n
"
,
hr
);
hr
=
IMFActivate_ActivateObject
(
activate
,
&
IID_IMFMediaSink
,
(
void
**
)
&
sink
);
ok
(
hr
==
S_OK
,
"Failed to activate object, hr %#x.
\n
"
,
hr
);
hr
=
IMFMediaSink_GetCharacteristics
(
sink
,
&
flags
);
ok
(
hr
==
S_OK
,
"Failed to get sink flags, hr %#x.
\n
"
,
hr
);
ok
(
flags
&
MEDIASINK_RATELESS
,
"Unexpected flags %#x.
\n
"
,
flags
);
IMFMediaSink_Release
(
sink
);
IMFActivate_Release
(
activate
);
IMFMediaType_Release
(
media_type
);
hr
=
MFShutdown
();
ok
(
hr
==
S_OK
,
"Failed to shut down, hr %#x.
\n
"
,
hr
);
}
...
...
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