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
74df86d8
Commit
74df86d8
authored
Dec 04, 2019
by
Zebediah Figura
Committed by
Alexandre Julliard
Dec 05, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qcap/avimux: Use strmbase filter state change methods.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
f8156266
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
16 additions
and
42 deletions
+16
-42
avimux.c
dlls/qcap/avimux.c
+16
-42
No files found.
dlls/qcap/avimux.c
View file @
74df86d8
...
...
@@ -167,19 +167,6 @@ static HRESULT avi_mux_query_interface(struct strmbase_filter *iface, REFIID iid
return
S_OK
;
}
static
const
struct
strmbase_filter_ops
filter_ops
=
{
.
filter_get_pin
=
avi_mux_get_pin
,
.
filter_destroy
=
avi_mux_destroy
,
.
filter_query_interface
=
avi_mux_query_interface
,
};
static
inline
AviMux
*
impl_from_IBaseFilter
(
IBaseFilter
*
iface
)
{
struct
strmbase_filter
*
filter
=
CONTAINING_RECORD
(
iface
,
struct
strmbase_filter
,
IBaseFilter_iface
);
return
impl_from_strmbase_filter
(
filter
);
}
static
HRESULT
out_flush
(
AviMux
*
This
)
{
ULONG
written
;
...
...
@@ -420,17 +407,12 @@ static HRESULT queue_sample(AviMux *avimux, AviMuxIn *avimuxin, IMediaSample *sa
return
flush_queue
(
avimux
,
avimuxin
,
FALSE
);
}
static
HRESULT
WINAPI
AviMux_Stop
(
IBaseF
ilter
*
iface
)
static
HRESULT
avi_mux_cleanup_stream
(
struct
strmbase_f
ilter
*
iface
)
{
AviMux
*
This
=
impl_from_
IBaseF
ilter
(
iface
);
AviMux
*
This
=
impl_from_
strmbase_f
ilter
(
iface
);
HRESULT
hr
;
int
i
;
TRACE
(
"(%p)
\n
"
,
This
);
if
(
This
->
filter
.
state
==
State_Stopped
)
return
S_OK
;
if
(
This
->
stream
)
{
AVIEXTHEADER
dmlh
;
...
...
@@ -559,36 +541,20 @@ static HRESULT WINAPI AviMux_Stop(IBaseFilter *iface)
This
->
stream
=
NULL
;
}
This
->
filter
.
state
=
State_Stopped
;
return
S_OK
;
}
static
HRESULT
WINAPI
AviMux_Pause
(
IBaseF
ilter
*
iface
)
static
HRESULT
avi_mux_init_stream
(
struct
strmbase_f
ilter
*
iface
)
{
AviMux
*
This
=
impl_from_IBaseFilter
(
iface
);
FIXME
(
"(%p)
\n
"
,
This
);
return
E_NOTIMPL
;
}
static
HRESULT
WINAPI
AviMux_Run
(
IBaseFilter
*
iface
,
REFERENCE_TIME
tStart
)
{
AviMux
*
This
=
impl_from_IBaseFilter
(
iface
);
AviMux
*
This
=
impl_from_strmbase_filter
(
iface
);
HRESULT
hr
;
int
i
,
stream_id
;
TRACE
(
"(%p)->(%s)
\n
"
,
This
,
wine_dbgstr_longlong
(
tStart
));
if
(
This
->
filter
.
state
==
State_Running
)
return
S_OK
;
if
(
This
->
mode
!=
INTERLEAVE_FULL
)
{
FIXME
(
"mode not supported (%d)
\n
"
,
This
->
mode
);
return
E_NOTIMPL
;
}
if
(
tStart
)
FIXME
(
"tStart parameter ignored
\n
"
);
for
(
i
=
0
;
i
<
This
->
input_pin_no
;
i
++
)
{
IMediaSeeking
*
ms
;
LONGLONG
cur
,
stop
;
...
...
@@ -694,18 +660,26 @@ static HRESULT WINAPI AviMux_Run(IBaseFilter *iface, REFERENCE_TIME tStart)
This
->
avih
.
dwWidth
=
((
BITMAPINFOHEADER
*
)
This
->
in
[
0
]
->
strf
->
data
)
->
biWidth
;
This
->
avih
.
dwHeight
=
((
BITMAPINFOHEADER
*
)
This
->
in
[
0
]
->
strf
->
data
)
->
biHeight
;
This
->
filter
.
state
=
State_Running
;
return
S_OK
;
}
static
const
struct
strmbase_filter_ops
filter_ops
=
{
.
filter_get_pin
=
avi_mux_get_pin
,
.
filter_destroy
=
avi_mux_destroy
,
.
filter_query_interface
=
avi_mux_query_interface
,
.
filter_init_stream
=
avi_mux_init_stream
,
.
filter_cleanup_stream
=
avi_mux_cleanup_stream
,
};
static
const
IBaseFilterVtbl
AviMuxVtbl
=
{
BaseFilterImpl_QueryInterface
,
BaseFilterImpl_AddRef
,
BaseFilterImpl_Release
,
BaseFilterImpl_GetClassID
,
AviMux
_Stop
,
AviMux
_Pause
,
AviMux
_Run
,
BaseFilterImpl
_Stop
,
BaseFilterImpl
_Pause
,
BaseFilterImpl
_Run
,
BaseFilterImpl_GetState
,
BaseFilterImpl_SetSyncSource
,
BaseFilterImpl_GetSyncSource
,
...
...
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