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
828d5a0c
Commit
828d5a0c
authored
Apr 06, 2007
by
Chris Robinson
Committed by
Alexandre Julliard
Apr 07, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
quartz: Add a cleanup callback for parser filters to call on release.
parent
ea0d7f17
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
4 deletions
+10
-4
avisplit.c
dlls/quartz/avisplit.c
+1
-1
parser.c
dlls/quartz/parser.c
+5
-1
parser.h
dlls/quartz/parser.h
+3
-1
waveparser.c
dlls/quartz/waveparser.c
+1
-1
No files found.
dlls/quartz/avisplit.c
View file @
828d5a0c
...
...
@@ -594,7 +594,7 @@ HRESULT AVISplitter_create(IUnknown * pUnkOuter, LPVOID * ppv)
This
->
pCurrentSample
=
NULL
;
hr
=
Parser_Create
(
&
(
This
->
Parser
),
&
CLSID_AviSplitter
,
AVISplitter_Sample
,
AVISplitter_QueryAccept
,
AVISplitter_InputPin_PreConnect
);
hr
=
Parser_Create
(
&
(
This
->
Parser
),
&
CLSID_AviSplitter
,
AVISplitter_Sample
,
AVISplitter_QueryAccept
,
AVISplitter_InputPin_PreConnect
,
NULL
);
if
(
FAILED
(
hr
))
return
hr
;
...
...
dlls/quartz/parser.c
View file @
828d5a0c
...
...
@@ -60,7 +60,7 @@ static inline Parser_OutputPin *impl_from_IMediaSeeking( IMediaSeeking *iface )
}
HRESULT
Parser_Create
(
ParserImpl
*
pParser
,
const
CLSID
*
pClsid
,
PFN_PROCESS_SAMPLE
fnProcessSample
,
PFN_QUERY_ACCEPT
fnQueryAccept
,
PFN_PRE_CONNECT
fnPreConnect
)
HRESULT
Parser_Create
(
ParserImpl
*
pParser
,
const
CLSID
*
pClsid
,
PFN_PROCESS_SAMPLE
fnProcessSample
,
PFN_QUERY_ACCEPT
fnQueryAccept
,
PFN_PRE_CONNECT
fnPreConnect
,
PFN_CLEANUP
fnCleanup
)
{
HRESULT
hr
;
PIN_INFO
piInput
;
...
...
@@ -74,6 +74,7 @@ HRESULT Parser_Create(ParserImpl* pParser, const CLSID* pClsid, PFN_PROCESS_SAMP
pParser
->
csFilter
.
DebugInfo
->
Spare
[
0
]
=
(
DWORD_PTR
)(
__FILE__
": ParserImpl.csFilter"
);
pParser
->
state
=
State_Stopped
;
pParser
->
pClock
=
NULL
;
pParser
->
fnCleanup
=
fnCleanup
;
ZeroMemory
(
&
pParser
->
filterInfo
,
sizeof
(
FILTER_INFO
));
pParser
->
cStreams
=
0
;
...
...
@@ -187,6 +188,9 @@ static ULONG WINAPI Parser_Release(IBaseFilter * iface)
{
ULONG
i
;
if
(
This
->
fnCleanup
)
This
->
fnCleanup
(
This
);
if
(
This
->
pClock
)
IReferenceClock_Release
(
This
->
pClock
);
...
...
dlls/quartz/parser.h
View file @
828d5a0c
...
...
@@ -23,6 +23,7 @@ typedef struct ParserImpl ParserImpl;
typedef
HRESULT
(
*
PFN_PROCESS_SAMPLE
)
(
LPVOID
iface
,
IMediaSample
*
pSample
);
typedef
HRESULT
(
*
PFN_QUERY_ACCEPT
)
(
LPVOID
iface
,
const
AM_MEDIA_TYPE
*
pmt
);
typedef
HRESULT
(
*
PFN_PRE_CONNECT
)
(
IPin
*
iface
,
IPin
*
pConnectPin
);
typedef
HRESULT
(
*
PFN_CLEANUP
)
(
LPVOID
iface
);
struct
ParserImpl
{
...
...
@@ -33,6 +34,7 @@ struct ParserImpl
FILTER_STATE
state
;
REFERENCE_TIME
rtStreamStart
;
IReferenceClock
*
pClock
;
PFN_CLEANUP
fnCleanup
;
FILTER_INFO
filterInfo
;
CLSID
clsid
;
...
...
@@ -54,4 +56,4 @@ typedef struct Parser_OutputPin
}
Parser_OutputPin
;
HRESULT
Parser_AddPin
(
ParserImpl
*
This
,
PIN_INFO
*
piOutput
,
ALLOCATOR_PROPERTIES
*
props
,
AM_MEDIA_TYPE
*
amt
,
float
fSamplesPerSec
,
DWORD
dwSampleSize
,
DWORD
dwLength
);
HRESULT
Parser_Create
(
ParserImpl
*
,
const
CLSID
*
,
PFN_PROCESS_SAMPLE
,
PFN_QUERY_ACCEPT
,
PFN_PRE_CONNECT
);
HRESULT
Parser_Create
(
ParserImpl
*
,
const
CLSID
*
,
PFN_PROCESS_SAMPLE
,
PFN_QUERY_ACCEPT
,
PFN_PRE_CONNECT
,
PFN_CLEANUP
);
dlls/quartz/waveparser.c
View file @
828d5a0c
...
...
@@ -318,7 +318,7 @@ HRESULT WAVEParser_create(IUnknown * pUnkOuter, LPVOID * ppv)
This
->
pCurrentSample
=
NULL
;
hr
=
Parser_Create
(
&
(
This
->
Parser
),
&
CLSID_WAVEParser
,
WAVEParser_Sample
,
WAVEParser_QueryAccept
,
WAVEParser_InputPin_PreConnect
);
hr
=
Parser_Create
(
&
(
This
->
Parser
),
&
CLSID_WAVEParser
,
WAVEParser_Sample
,
WAVEParser_QueryAccept
,
WAVEParser_InputPin_PreConnect
,
NULL
);
if
(
FAILED
(
hr
))
return
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