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
c3cca0d2
Commit
c3cca0d2
authored
Oct 02, 2022
by
Anton Baskanov
Committed by
Alexandre Julliard
Nov 15, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winegstreamer: Set allocator properties for MPEG layer-3 decoder source.
Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=18773
Signed-off-by:
Anton Baskanov
<
baskanov@gmail.com
>
parent
d9b9af96
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
8 deletions
+14
-8
mpeglayer3.c
dlls/quartz/tests/mpeglayer3.c
+7
-7
quartz_transform.c
dlls/winegstreamer/quartz_transform.c
+7
-1
No files found.
dlls/quartz/tests/mpeglayer3.c
View file @
c3cca0d2
...
@@ -921,9 +921,9 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
...
@@ -921,9 +921,9 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
/* Earlier versions used 16 buffers of lSampleSize bytes,
/* Earlier versions used 16 buffers of lSampleSize bytes,
* later versions use 8 buffers of lSampleSize * 4 bytes. */
* later versions use 8 buffers of lSampleSize * 4 bytes. */
todo_wine
ok
(
props
.
cBuffers
==
16
||
props
.
cBuffers
==
8
,
"Got %ld buffers.
\n
"
,
props
.
cBuffers
);
ok
(
props
.
cBuffers
==
16
||
props
.
cBuffers
==
8
,
"Got %ld buffers.
\n
"
,
props
.
cBuffers
);
todo_wine
ok
(
props
.
cbBuffer
==
2222
||
props
.
cbBuffer
==
8888
,
"Got size %ld.
\n
"
,
props
.
cbBuffer
);
ok
(
props
.
cbBuffer
==
2222
||
props
.
cbBuffer
==
8888
,
"Got size %ld.
\n
"
,
props
.
cbBuffer
);
todo_wine
ok
(
props
.
cbAlign
==
1
,
"Got alignment %ld.
\n
"
,
props
.
cbAlign
);
ok
(
props
.
cbAlign
==
1
,
"Got alignment %ld.
\n
"
,
props
.
cbAlign
);
ok
(
!
props
.
cbPrefix
,
"Got prefix %ld.
\n
"
,
props
.
cbPrefix
);
ok
(
!
props
.
cbPrefix
,
"Got prefix %ld.
\n
"
,
props
.
cbPrefix
);
hr
=
IMemAllocator_GetBuffer
(
testsink
->
sink
.
pAllocator
,
&
sample
,
NULL
,
NULL
,
0
);
hr
=
IMemAllocator_GetBuffer
(
testsink
->
sink
.
pAllocator
,
&
sample
,
NULL
,
NULL
,
0
);
...
@@ -933,7 +933,7 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
...
@@ -933,7 +933,7 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
hr
=
IMemAllocator_GetBuffer
(
testsink
->
sink
.
pAllocator
,
&
sample
,
NULL
,
NULL
,
0
);
hr
=
IMemAllocator_GetBuffer
(
testsink
->
sink
.
pAllocator
,
&
sample
,
NULL
,
NULL
,
0
);
todo_wine
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
if
(
hr
==
S_OK
)
if
(
hr
==
S_OK
)
IMediaSample_Release
(
sample
);
IMediaSample_Release
(
sample
);
...
@@ -963,9 +963,9 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
...
@@ -963,9 +963,9 @@ static void test_source_allocator(IFilterGraph2 *graph, IMediaControl *control,
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
ok
(
hr
==
S_OK
,
"Got hr %#lx.
\n
"
,
hr
);
/* Earlier versions used 16 buffers of lSampleSize bytes,
/* Earlier versions used 16 buffers of lSampleSize bytes,
* later versions use 8 buffers of lSampleSize * 4 bytes. */
* later versions use 8 buffers of lSampleSize * 4 bytes. */
todo_wine
ok
(
props
.
cBuffers
==
16
||
props
.
cBuffers
==
8
,
"Got %ld buffers.
\n
"
,
props
.
cBuffers
);
ok
(
props
.
cBuffers
==
16
||
props
.
cBuffers
==
8
,
"Got %ld buffers.
\n
"
,
props
.
cBuffers
);
todo_wine
ok
(
props
.
cbBuffer
==
2222
||
props
.
cbBuffer
==
8888
,
"Got size %ld.
\n
"
,
props
.
cbBuffer
);
ok
(
props
.
cbBuffer
==
2222
||
props
.
cbBuffer
==
8888
,
"Got size %ld.
\n
"
,
props
.
cbBuffer
);
todo_wine
ok
(
props
.
cbAlign
==
1
,
"Got alignment %ld.
\n
"
,
props
.
cbAlign
);
ok
(
props
.
cbAlign
==
1
,
"Got alignment %ld.
\n
"
,
props
.
cbAlign
);
ok
(
!
props
.
cbPrefix
,
"Got prefix %ld.
\n
"
,
props
.
cbPrefix
);
ok
(
!
props
.
cbPrefix
,
"Got prefix %ld.
\n
"
,
props
.
cbPrefix
);
IFilterGraph2_Disconnect
(
graph
,
source
);
IFilterGraph2_Disconnect
(
graph
,
source
);
...
...
dlls/winegstreamer/quartz_transform.c
View file @
c3cca0d2
...
@@ -803,7 +803,13 @@ static HRESULT mpeg_layer3_decoder_source_get_media_type(struct transform *filte
...
@@ -803,7 +803,13 @@ static HRESULT mpeg_layer3_decoder_source_get_media_type(struct transform *filte
static
HRESULT
mpeg_layer3_decoder_source_decide_buffer_size
(
struct
transform
*
filter
,
IMemAllocator
*
allocator
,
ALLOCATOR_PROPERTIES
*
props
)
static
HRESULT
mpeg_layer3_decoder_source_decide_buffer_size
(
struct
transform
*
filter
,
IMemAllocator
*
allocator
,
ALLOCATOR_PROPERTIES
*
props
)
{
{
return
S_OK
;
ALLOCATOR_PROPERTIES
ret_props
;
props
->
cBuffers
=
max
(
props
->
cBuffers
,
8
);
props
->
cbBuffer
=
max
(
props
->
cbBuffer
,
filter
->
source
.
pin
.
mt
.
lSampleSize
*
4
);
props
->
cbAlign
=
max
(
props
->
cbAlign
,
1
);
return
IMemAllocator_SetProperties
(
allocator
,
props
,
&
ret_props
);
}
}
static
const
struct
transform_ops
mpeg_layer3_decoder_transform_ops
=
static
const
struct
transform_ops
mpeg_layer3_decoder_transform_ops
=
...
...
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