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
1a580f93
Commit
1a580f93
authored
May 20, 2022
by
Rémi Bernon
Committed by
Alexandre Julliard
Aug 09, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
qasf: Implement ASF Reader filter pin DecideBufferSize.
parent
80004974
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
2 deletions
+23
-2
asfreader.c
dlls/qasf/asfreader.c
+23
-2
No files found.
dlls/qasf/asfreader.c
View file @
1a580f93
...
...
@@ -198,8 +198,29 @@ static const struct strmbase_filter_ops filter_ops =
static
HRESULT
WINAPI
asf_reader_DecideBufferSize
(
struct
strmbase_source
*
iface
,
IMemAllocator
*
allocator
,
ALLOCATOR_PROPERTIES
*
req_props
)
{
FIXME
(
"iface %p, allocator %p, req_props %p stub!
\n
"
,
iface
,
allocator
,
req_props
);
return
E_NOTIMPL
;
struct
asf_stream
*
stream
=
impl_from_strmbase_pin
(
&
iface
->
pin
);
unsigned
int
buffer_size
=
16384
;
ALLOCATOR_PROPERTIES
ret_props
;
TRACE
(
"iface %p, allocator %p, req_props %p.
\n
"
,
iface
,
allocator
,
req_props
);
if
(
IsEqualGUID
(
&
stream
->
source
.
pin
.
mt
.
formattype
,
&
FORMAT_VideoInfo
))
{
VIDEOINFOHEADER
*
format
=
(
VIDEOINFOHEADER
*
)
stream
->
source
.
pin
.
mt
.
pbFormat
;
buffer_size
=
format
->
bmiHeader
.
biSizeImage
;
}
else
if
(
IsEqualGUID
(
&
stream
->
source
.
pin
.
mt
.
formattype
,
&
FORMAT_WaveFormatEx
)
&&
(
IsEqualGUID
(
&
stream
->
source
.
pin
.
mt
.
subtype
,
&
MEDIASUBTYPE_PCM
)
||
IsEqualGUID
(
&
stream
->
source
.
pin
.
mt
.
subtype
,
&
MEDIASUBTYPE_IEEE_FLOAT
)))
{
WAVEFORMATEX
*
format
=
(
WAVEFORMATEX
*
)
stream
->
source
.
pin
.
mt
.
pbFormat
;
buffer_size
=
format
->
nAvgBytesPerSec
;
}
req_props
->
cBuffers
=
max
(
req_props
->
cBuffers
,
1
);
req_props
->
cbBuffer
=
max
(
req_props
->
cbBuffer
,
buffer_size
);
req_props
->
cbAlign
=
max
(
req_props
->
cbAlign
,
1
);
return
IMemAllocator_SetProperties
(
allocator
,
req_props
,
&
ret_props
);
}
static
const
struct
strmbase_source_ops
source_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