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
cc395ce8
Commit
cc395ce8
authored
Mar 05, 2024
by
Rémi Bernon
Committed by
Alexandre Julliard
Apr 29, 2024
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winegstreamer: Introduce a new wg_transform_create_quartz helper.
parent
0567f993
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
10 deletions
+20
-10
gst_private.h
dlls/winegstreamer/gst_private.h
+2
-0
main.c
dlls/winegstreamer/main.c
+15
-0
quartz_transform.c
dlls/winegstreamer/quartz_transform.c
+3
-10
No files found.
dlls/winegstreamer/gst_private.h
View file @
cc395ce8
...
@@ -83,6 +83,8 @@ void wg_parser_stream_seek(wg_parser_stream_t stream, double rate,
...
@@ -83,6 +83,8 @@ void wg_parser_stream_seek(wg_parser_stream_t stream, double rate,
wg_transform_t
wg_transform_create
(
const
struct
wg_format
*
input_format
,
wg_transform_t
wg_transform_create
(
const
struct
wg_format
*
input_format
,
const
struct
wg_format
*
output_format
,
const
struct
wg_transform_attrs
*
attrs
);
const
struct
wg_format
*
output_format
,
const
struct
wg_transform_attrs
*
attrs
);
HRESULT
wg_transform_create_quartz
(
const
AM_MEDIA_TYPE
*
input_format
,
const
AM_MEDIA_TYPE
*
output_format
,
const
struct
wg_transform_attrs
*
attrs
,
wg_transform_t
*
transform
);
void
wg_transform_destroy
(
wg_transform_t
transform
);
void
wg_transform_destroy
(
wg_transform_t
transform
);
bool
wg_transform_set_output_format
(
wg_transform_t
transform
,
struct
wg_format
*
format
);
bool
wg_transform_set_output_format
(
wg_transform_t
transform
,
struct
wg_format
*
format
);
bool
wg_transform_get_status
(
wg_transform_t
transform
,
bool
*
accepts_input
);
bool
wg_transform_get_status
(
wg_transform_t
transform
,
bool
*
accepts_input
);
...
...
dlls/winegstreamer/main.c
View file @
cc395ce8
...
@@ -357,6 +357,21 @@ wg_transform_t wg_transform_create(const struct wg_format *input_format,
...
@@ -357,6 +357,21 @@ wg_transform_t wg_transform_create(const struct wg_format *input_format,
return
params
.
transform
;
return
params
.
transform
;
}
}
HRESULT
wg_transform_create_quartz
(
const
AM_MEDIA_TYPE
*
input_type
,
const
AM_MEDIA_TYPE
*
output_type
,
const
struct
wg_transform_attrs
*
attrs
,
wg_transform_t
*
transform
)
{
struct
wg_format
input_format
,
output_format
;
if
(
!
amt_to_wg_format
(
input_type
,
&
input_format
))
return
E_FAIL
;
if
(
!
amt_to_wg_format
(
output_type
,
&
output_format
))
return
E_FAIL
;
if
(
!
(
*
transform
=
wg_transform_create
(
&
input_format
,
&
output_format
,
attrs
)))
return
E_FAIL
;
return
S_OK
;
}
void
wg_transform_destroy
(
wg_transform_t
transform
)
void
wg_transform_destroy
(
wg_transform_t
transform
)
{
{
TRACE
(
"transform %#I64x.
\n
"
,
transform
);
TRACE
(
"transform %#I64x.
\n
"
,
transform
);
...
...
dlls/winegstreamer/quartz_transform.c
View file @
cc395ce8
...
@@ -98,26 +98,19 @@ static HRESULT transform_query_interface(struct strmbase_filter *iface, REFIID i
...
@@ -98,26 +98,19 @@ static HRESULT transform_query_interface(struct strmbase_filter *iface, REFIID i
static
HRESULT
transform_init_stream
(
struct
strmbase_filter
*
iface
)
static
HRESULT
transform_init_stream
(
struct
strmbase_filter
*
iface
)
{
{
struct
transform
*
filter
=
impl_from_strmbase_filter
(
iface
);
struct
transform
*
filter
=
impl_from_strmbase_filter
(
iface
);
struct
wg_format
input_format
,
output_format
;
struct
wg_transform_attrs
attrs
=
{
0
};
struct
wg_transform_attrs
attrs
=
{
0
};
HRESULT
hr
;
HRESULT
hr
;
if
(
filter
->
source
.
pin
.
peer
)
if
(
filter
->
source
.
pin
.
peer
)
{
{
if
(
!
amt_to_wg_format
(
&
filter
->
sink
.
pin
.
mt
,
&
input_format
))
return
E_FAIL
;
if
(
!
amt_to_wg_format
(
&
filter
->
source
.
pin
.
mt
,
&
output_format
))
return
E_FAIL
;
if
(
FAILED
(
hr
=
wg_sample_queue_create
(
&
filter
->
sample_queue
)))
if
(
FAILED
(
hr
=
wg_sample_queue_create
(
&
filter
->
sample_queue
)))
return
hr
;
return
hr
;
filter
->
transform
=
wg_transform_create
(
&
input_format
,
&
output_format
,
&
attrs
);
if
(
FAILED
(
hr
=
wg_transform_create_quartz
(
&
filter
->
sink
.
pin
.
mt
,
&
filter
->
source
.
pin
.
mt
,
if
(
!
filter
->
transform
)
&
attrs
,
&
filter
->
transform
))
)
{
{
wg_sample_queue_destroy
(
filter
->
sample_queue
);
wg_sample_queue_destroy
(
filter
->
sample_queue
);
return
E_FAIL
;
return
hr
;
}
}
hr
=
IMemAllocator_Commit
(
filter
->
source
.
pAllocator
);
hr
=
IMemAllocator_Commit
(
filter
->
source
.
pAllocator
);
...
...
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