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
31639627
Commit
31639627
authored
Nov 15, 2020
by
Zebediah Figura
Committed by
Alexandre Julliard
Nov 16, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
quartz/tests: Store a testfilter pointer inside the testpin structure.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d19aac6e
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
38 additions
and
41 deletions
+38
-41
filtergraph.c
dlls/quartz/tests/filtergraph.c
+38
-41
No files found.
dlls/quartz/tests/filtergraph.c
View file @
31639627
...
...
@@ -789,7 +789,7 @@ struct testpin
IPin
IPin_iface
;
LONG
ref
;
PIN_DIRECTION
dir
;
IBaseF
ilter
*
filter
;
struct
testf
ilter
*
filter
;
IPin
*
peer
;
AM_MEDIA_TYPE
*
mt
;
WCHAR
name
[
10
];
...
...
@@ -806,6 +806,40 @@ struct testpin
HRESULT
QueryInternalConnections_hr
;
};
struct
testfilter
{
IBaseFilter
IBaseFilter_iface
;
LONG
ref
;
IFilterGraph
*
graph
;
WCHAR
*
name
;
IReferenceClock
*
clock
;
IEnumPins
IEnumPins_iface
;
struct
testpin
*
pins
;
unsigned
int
pin_count
,
enum_idx
;
FILTER_STATE
state
;
REFERENCE_TIME
start_time
;
HRESULT
state_hr
,
GetState_hr
,
seek_hr
;
FILTER_STATE
expect_stop_prev
,
expect_run_prev
;
IAMFilterMiscFlags
IAMFilterMiscFlags_iface
;
ULONG
misc_flags
;
IMediaSeeking
IMediaSeeking_iface
;
LONG
seeking_ref
;
DWORD
seek_caps
;
BOOL
support_testguid
,
support_media_time
;
GUID
time_format
;
LONGLONG
seek_duration
,
seek_current
,
seek_stop
;
double
seek_rate
;
IReferenceClock
IReferenceClock_iface
;
IFileSourceFilter
IFileSourceFilter_iface
;
WCHAR
filename
[
MAX_PATH
];
};
static
inline
struct
testpin
*
impl_from_IEnumMediaTypes
(
IEnumMediaTypes
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
struct
testpin
,
IEnumMediaTypes_iface
);
...
...
@@ -954,8 +988,8 @@ static HRESULT WINAPI testpin_QueryPinInfo(IPin *iface, PIN_INFO *info)
struct
testpin
*
pin
=
impl_from_IPin
(
iface
);
if
(
winetest_debug
>
1
)
trace
(
"%p->QueryPinInfo()
\n
"
,
pin
);
info
->
pFilter
=
pin
->
filter
;
IBaseFilter_AddRef
(
pin
->
f
ilter
);
info
->
pFilter
=
&
pin
->
filter
->
IBaseFilter_iface
;
IBaseFilter_AddRef
(
info
->
pF
ilter
);
info
->
dir
=
pin
->
dir
;
wcscpy
(
info
->
achName
,
pin
->
name
);
return
S_OK
;
...
...
@@ -1158,40 +1192,6 @@ static void testsource_init(struct testpin *pin, const AM_MEDIA_TYPE *types, int
pin
->
type_count
=
type_count
;
}
struct
testfilter
{
IBaseFilter
IBaseFilter_iface
;
LONG
ref
;
IFilterGraph
*
graph
;
WCHAR
*
name
;
IReferenceClock
*
clock
;
IEnumPins
IEnumPins_iface
;
struct
testpin
*
pins
;
unsigned
int
pin_count
,
enum_idx
;
FILTER_STATE
state
;
REFERENCE_TIME
start_time
;
HRESULT
state_hr
,
GetState_hr
,
seek_hr
;
FILTER_STATE
expect_stop_prev
,
expect_run_prev
;
IAMFilterMiscFlags
IAMFilterMiscFlags_iface
;
ULONG
misc_flags
;
IMediaSeeking
IMediaSeeking_iface
;
LONG
seeking_ref
;
DWORD
seek_caps
;
BOOL
support_testguid
,
support_media_time
;
GUID
time_format
;
LONGLONG
seek_duration
,
seek_current
,
seek_stop
;
double
seek_rate
;
IReferenceClock
IReferenceClock_iface
;
IFileSourceFilter
IFileSourceFilter_iface
;
WCHAR
filename
[
MAX_PATH
];
};
static
inline
struct
testfilter
*
impl_from_IEnumPins
(
IEnumPins
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
struct
testfilter
,
IEnumPins_iface
);
...
...
@@ -1842,7 +1842,7 @@ static void testfilter_init(struct testfilter *filter, struct testpin *pins, int
filter
->
pins
=
pins
;
filter
->
pin_count
=
pin_count
;
for
(
i
=
0
;
i
<
pin_count
;
i
++
)
pins
[
i
].
filter
=
&
filter
->
IBaseFilter_iface
;
pins
[
i
].
filter
=
filter
;
filter
->
state
=
State_Stopped
;
filter
->
expect_stop_prev
=
filter
->
expect_run_prev
=
State_Paused
;
...
...
@@ -3232,9 +3232,6 @@ static void test_filter_state(void)
IFilterGraph2_QueryInterface
(
graph
,
&
IID_IMediaFilter
,
(
void
**
)
&
filter
);
IFilterGraph2_QueryInterface
(
graph
,
&
IID_IMediaControl
,
(
void
**
)
&
control
);
source_pin
.
filter
=
&
source
.
IBaseFilter_iface
;
sink_pin
.
filter
=
&
sink
.
IBaseFilter_iface
;
IFilterGraph2_AddFilter
(
graph
,
&
source
.
IBaseFilter_iface
,
NULL
);
IFilterGraph2_AddFilter
(
graph
,
&
sink
.
IBaseFilter_iface
,
NULL
);
IFilterGraph2_AddFilter
(
graph
,
&
dummy
.
IBaseFilter_iface
,
NULL
);
...
...
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