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
bd83b11a
Commit
bd83b11a
authored
Nov 22, 2019
by
Zebediah Figura
Committed by
Alexandre Julliard
Nov 25, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
strmbase: Return a strmbase_pin pointer from the filter_get_pin() callback.
Signed-off-by:
Zebediah Figura
<
z.figura12@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
ad96d919
Show whitespace changes
Inline
Side-by-side
Showing
17 changed files
with
45 additions
and
55 deletions
+45
-55
audiorecord.c
dlls/qcap/audiorecord.c
+1
-1
avico.c
dlls/qcap/avico.c
+3
-3
avimux.c
dlls/qcap/avimux.c
+3
-3
smartteefilter.c
dlls/qcap/smartteefilter.c
+4
-4
vfwcapture.c
dlls/qcap/vfwcapture.c
+2
-2
samplegrabber.c
dlls/qedit/samplegrabber.c
+3
-3
filesource.c
dlls/quartz/filesource.c
+2
-2
videorenderer.c
dlls/quartz/tests/videorenderer.c
+2
-2
vmr7.c
dlls/quartz/tests/vmr7.c
+2
-2
vmr9.c
dlls/quartz/tests/vmr9.c
+2
-2
enumpins.c
dlls/strmbase/enumpins.c
+4
-6
filter.c
dlls/strmbase/filter.c
+3
-11
renderer.c
dlls/strmbase/renderer.c
+2
-2
transform.c
dlls/strmbase/transform.c
+3
-3
gstdemux.c
dlls/winegstreamer/gstdemux.c
+3
-3
qtsplitter.c
dlls/wineqtdecoder/qtsplitter.c
+5
-5
strmbase.h
include/wine/strmbase.h
+1
-1
No files found.
dlls/qcap/audiorecord.c
View file @
bd83b11a
...
...
@@ -67,7 +67,7 @@ static const IBaseFilterVtbl AudioRecordVtbl = {
BaseFilterImpl_QueryVendorInfo
};
static
IP
in
*
audio_record_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
audio_record_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
FIXME
(
"iface %p, index %u, stub!
\n
"
,
iface
,
index
);
return
NULL
;
...
...
dlls/qcap/avico.c
View file @
bd83b11a
...
...
@@ -178,14 +178,14 @@ static const IBaseFilterVtbl AVICompressorVtbl = {
BaseFilterImpl_QueryVendorInfo
,
};
static
IP
in
*
avi_compressor_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
avi_compressor_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
AVICompressor
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
index
==
0
)
return
&
filter
->
sink
.
pin
.
IPin_iface
;
return
&
filter
->
sink
.
pin
;
else
if
(
index
==
1
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/qcap/avimux.c
View file @
bd83b11a
...
...
@@ -113,14 +113,14 @@ static inline AviMux* impl_from_strmbase_filter(struct strmbase_filter *filter)
return
CONTAINING_RECORD
(
filter
,
AviMux
,
filter
);
}
static
IP
in
*
avi_mux_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
avi_mux_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
AviMux
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
!
index
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
else
if
(
index
<=
filter
->
input_pin_no
)
return
&
filter
->
in
[
index
-
1
]
->
pin
.
pin
.
IPin_iface
;
return
&
filter
->
in
[
index
-
1
]
->
pin
.
pin
;
return
NULL
;
}
...
...
dlls/qcap/smartteefilter.c
View file @
bd83b11a
...
...
@@ -69,16 +69,16 @@ static const IBaseFilterVtbl SmartTeeFilterVtbl = {
BaseFilterImpl_QueryVendorInfo
};
static
IP
in
*
smart_tee_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
smart_tee_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
SmartTeeFilter
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
index
==
0
)
return
&
filter
->
sink
.
pin
.
IPin_iface
;
return
&
filter
->
sink
.
pin
;
else
if
(
index
==
1
)
return
&
filter
->
capture
.
pin
.
IPin_iface
;
return
&
filter
->
capture
.
pin
;
else
if
(
index
==
2
)
return
&
filter
->
preview
.
pin
.
IPin_iface
;
return
&
filter
->
preview
.
pin
;
return
NULL
;
}
...
...
dlls/qcap/vfwcapture.c
View file @
bd83b11a
...
...
@@ -82,14 +82,14 @@ static inline VfwCapture *impl_from_IPersistPropertyBag(IPersistPropertyBag *ifa
return
CONTAINING_RECORD
(
iface
,
VfwCapture
,
IPersistPropertyBag_iface
);
}
static
IP
in
*
vfw_capture_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
vfw_capture_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
VfwCapture
*
This
=
impl_from_strmbase_filter
(
iface
);
if
(
index
>=
1
)
return
NULL
;
return
&
This
->
source
.
pin
.
IPin_iface
;
return
&
This
->
source
.
pin
;
}
static
void
vfw_capture_destroy
(
struct
strmbase_filter
*
iface
)
...
...
dlls/qedit/samplegrabber.c
View file @
bd83b11a
...
...
@@ -100,14 +100,14 @@ static void SampleGrabber_cleanup(SG_Impl *This)
IUnknown_Release
(
This
->
seekthru_unk
);
}
static
IP
in
*
sample_grabber_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
sample_grabber_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
SG_Impl
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
index
==
0
)
return
&
filter
->
sink
.
pin
.
IPin_iface
;
return
&
filter
->
sink
.
pin
;
else
if
(
index
==
1
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/quartz/filesource.c
View file @
bd83b11a
...
...
@@ -341,12 +341,12 @@ BOOL get_media_type(const WCHAR *filename, GUID *majortype, GUID *subtype, GUID
return
FALSE
;
}
static
IP
in
*
async_reader_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
async_reader_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
AsyncReader
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
!
index
&&
filter
->
pszFileName
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/quartz/tests/videorenderer.c
View file @
bd83b11a
...
...
@@ -519,11 +519,11 @@ static inline struct testfilter *impl_from_BaseFilter(struct strmbase_filter *if
return
CONTAINING_RECORD
(
iface
,
struct
testfilter
,
filter
);
}
static
IP
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
struct
testfilter
*
filter
=
impl_from_BaseFilter
(
iface
);
if
(
!
index
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/quartz/tests/vmr7.c
View file @
bd83b11a
...
...
@@ -879,11 +879,11 @@ static inline struct testfilter *impl_from_strmbase_filter(struct strmbase_filte
return
CONTAINING_RECORD
(
iface
,
struct
testfilter
,
filter
);
}
static
IP
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
struct
testfilter
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
!
index
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/quartz/tests/vmr9.c
View file @
bd83b11a
...
...
@@ -883,11 +883,11 @@ static inline struct testfilter *impl_from_strmbase_filter(struct strmbase_filte
return
CONTAINING_RECORD
(
iface
,
struct
testfilter
,
filter
);
}
static
IP
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
testfilter_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
struct
testfilter
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
!
index
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/strmbase/enumpins.c
View file @
bd83b11a
...
...
@@ -42,7 +42,6 @@ static const struct IEnumPinsVtbl IEnumPinsImpl_Vtbl;
HRESULT
enum_pins_create
(
struct
strmbase_filter
*
base
,
IEnumPins
**
out
)
{
IEnumPinsImpl
*
object
;
IPin
*
pin
;
if
(
!
out
)
return
E_POINTER
;
...
...
@@ -59,7 +58,7 @@ HRESULT enum_pins_create(struct strmbase_filter *base, IEnumPins **out)
IBaseFilter_AddRef
(
&
base
->
IBaseFilter_iface
);
object
->
Version
=
base
->
pin_version
;
while
(
(
pin
=
base
->
ops
->
filter_get_pin
(
base
,
object
->
count
)
))
while
(
base
->
ops
->
filter_get_pin
(
base
,
object
->
count
))
++
object
->
count
;
TRACE
(
"Created enumerator %p.
\n
"
,
object
);
...
...
@@ -137,12 +136,12 @@ static HRESULT WINAPI IEnumPinsImpl_Next(IEnumPins * iface, ULONG cPins, IPin **
for
(
i
=
0
;
i
<
cPins
;
++
i
)
{
IP
in
*
pin
=
This
->
base
->
ops
->
filter_get_pin
(
This
->
base
,
This
->
uIndex
+
i
);
struct
strmbase_p
in
*
pin
=
This
->
base
->
ops
->
filter_get_pin
(
This
->
base
,
This
->
uIndex
+
i
);
if
(
!
pin
)
break
;
IPin_AddRef
(
ppPins
[
i
]
=
pin
);
IPin_AddRef
(
ppPins
[
i
]
=
&
pin
->
IPin_iface
);
}
if
(
pcFetched
)
...
...
@@ -173,14 +172,13 @@ static HRESULT WINAPI IEnumPinsImpl_Skip(IEnumPins *iface, ULONG count)
static
HRESULT
WINAPI
IEnumPinsImpl_Reset
(
IEnumPins
*
iface
)
{
IEnumPinsImpl
*
enum_pins
=
impl_from_IEnumPins
(
iface
);
IPin
*
pin
;
TRACE
(
"iface %p.
\n
"
,
iface
);
if
(
enum_pins
->
Version
!=
enum_pins
->
base
->
pin_version
)
{
enum_pins
->
count
=
0
;
while
(
(
pin
=
enum_pins
->
base
->
ops
->
filter_get_pin
(
enum_pins
->
base
,
enum_pins
->
count
)
))
while
(
enum_pins
->
base
->
ops
->
filter_get_pin
(
enum_pins
->
base
,
enum_pins
->
count
))
++
enum_pins
->
count
;
}
...
...
dlls/strmbase/filter.c
View file @
bd83b11a
...
...
@@ -250,24 +250,16 @@ HRESULT WINAPI BaseFilterImpl_EnumPins(IBaseFilter *iface, IEnumPins **enum_pins
HRESULT
WINAPI
BaseFilterImpl_FindPin
(
IBaseFilter
*
iface
,
const
WCHAR
*
id
,
IPin
**
ret
)
{
struct
strmbase_filter
*
This
=
impl_from_IBaseFilter
(
iface
);
struct
strmbase_pin
*
pin
;
unsigned
int
i
;
PIN_INFO
info
;
HRESULT
hr
;
IPin
*
pin
;
TRACE
(
"(%p)->(%s, %p)
\n
"
,
This
,
debugstr_w
(
id
),
ret
);
for
(
i
=
0
;
(
pin
=
This
->
ops
->
filter_get_pin
(
This
,
i
));
++
i
)
{
hr
=
IPin_QueryPinInfo
(
pin
,
&
info
);
if
(
FAILED
(
hr
))
return
hr
;
if
(
info
.
pFilter
)
IBaseFilter_Release
(
info
.
pFilter
);
if
(
!
lstrcmpW
(
id
,
info
.
achName
))
if
(
!
lstrcmpW
(
id
,
pin
->
name
))
{
IPin_AddRef
(
*
ret
=
pin
);
IPin_AddRef
(
*
ret
=
&
pin
->
IPin_iface
);
return
S_OK
;
}
}
...
...
dlls/strmbase/renderer.c
View file @
bd83b11a
...
...
@@ -163,12 +163,12 @@ static const IPinVtbl BaseRenderer_InputPin_Vtbl =
BaseInputPinImpl_NewSegment
};
static
IP
in
*
renderer_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
renderer_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
struct
strmbase_renderer
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
index
==
0
)
return
&
filter
->
sink
.
pin
.
IPin_iface
;
return
&
filter
->
sink
.
pin
;
return
NULL
;
}
...
...
dlls/strmbase/transform.c
View file @
bd83b11a
...
...
@@ -114,14 +114,14 @@ static HRESULT source_get_media_type(struct strmbase_pin *This, unsigned int iPo
return
S_OK
;
}
static
IP
in
*
transform_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
transform_get_pin
(
struct
strmbase_filter
*
iface
,
unsigned
int
index
)
{
TransformFilter
*
filter
=
impl_from_strmbase_filter
(
iface
);
if
(
index
==
0
)
return
&
filter
->
sink
.
pin
.
IPin_iface
;
return
&
filter
->
sink
.
pin
;
else
if
(
index
==
1
)
return
&
filter
->
source
.
pin
.
IPin_iface
;
return
&
filter
->
source
.
pin
;
return
NULL
;
}
...
...
dlls/winegstreamer/gstdemux.c
View file @
bd83b11a
...
...
@@ -1188,14 +1188,14 @@ static inline struct gstdemux_source *impl_from_IMediaSeeking(IMediaSeeking *ifa
return
CONTAINING_RECORD
(
iface
,
struct
gstdemux_source
,
seek
.
IMediaSeeking_iface
);
}
static
IP
in
*
gstdemux_get_pin
(
struct
strmbase_filter
*
base
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
gstdemux_get_pin
(
struct
strmbase_filter
*
base
,
unsigned
int
index
)
{
struct
gstdemux
*
filter
=
impl_from_strmbase_filter
(
base
);
if
(
!
index
)
return
&
filter
->
sink
.
IPin_iface
;
return
&
filter
->
sink
;
else
if
(
index
<=
filter
->
cStreams
)
return
&
filter
->
ppPins
[
index
-
1
]
->
pin
.
pin
.
IPin_iface
;
return
&
filter
->
ppPins
[
index
-
1
]
->
pin
.
pin
;
return
NULL
;
}
...
...
dlls/wineqtdecoder/qtsplitter.c
View file @
bd83b11a
...
...
@@ -208,21 +208,21 @@ static inline QTInPin *impl_from_IPin(IPin *iface)
* Base Filter
*/
static
IP
in
*
qt_splitter_get_pin
(
struct
strmbase_filter
*
base
,
unsigned
int
index
)
static
struct
strmbase_p
in
*
qt_splitter_get_pin
(
struct
strmbase_filter
*
base
,
unsigned
int
index
)
{
QTSplitter
*
filter
=
impl_from_strmbase_filter
(
base
);
if
(
index
==
0
)
return
&
filter
->
pInputPin
.
pin
.
IPin_iface
;
return
&
filter
->
pInputPin
.
pin
;
else
if
(
index
==
1
)
{
if
(
filter
->
pVideo_Pin
)
return
&
filter
->
pVideo_Pin
->
pin
.
pin
.
IPin_iface
;
return
&
filter
->
pVideo_Pin
->
pin
.
pin
;
else
if
(
filter
->
pAudio_Pin
)
return
&
filter
->
pAudio_Pin
->
pin
.
pin
.
IPin_iface
;
return
&
filter
->
pAudio_Pin
->
pin
.
pin
;
}
else
if
(
index
==
2
&&
filter
->
pVideo_Pin
&&
filter
->
pAudio_Pin
)
return
&
filter
->
pAudio_Pin
->
pin
.
pin
.
IPin_iface
;
return
&
filter
->
pAudio_Pin
->
pin
.
pin
;
return
NULL
;
}
...
...
include/wine/strmbase.h
View file @
bd83b11a
...
...
@@ -166,7 +166,7 @@ struct strmbase_filter
struct
strmbase_filter_ops
{
IP
in
*
(
*
filter_get_pin
)(
struct
strmbase_filter
*
iface
,
unsigned
int
index
);
struct
strmbase_p
in
*
(
*
filter_get_pin
)(
struct
strmbase_filter
*
iface
,
unsigned
int
index
);
void
(
*
filter_destroy
)(
struct
strmbase_filter
*
iface
);
HRESULT
(
*
filter_query_interface
)(
struct
strmbase_filter
*
iface
,
REFIID
iid
,
void
**
out
);
...
...
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