Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lorenzo Ferrillo
wine
Commits
6d238163
Commit
6d238163
authored
13 years ago
by
Jörg Höhle
Committed by
Alexandre Julliard
13 years ago
Browse files
Options
Downloads
Patches
Plain Diff
wineoss: GetStreamLatency is constant, SNDCTL_DSP_GETODELAY is dynamic.
parent
92d8e93a
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
dlls/wineoss.drv/mmdevdrv.c
+2
-19
2 additions, 19 deletions
dlls/wineoss.drv/mmdevdrv.c
with
2 additions
and
19 deletions
dlls/wineoss.drv/mmdevdrv.c
+
2
−
19
View file @
6d238163
...
...
@@ -1046,26 +1046,9 @@ static HRESULT WINAPI AudioClient_GetStreamLatency(IAudioClient *iface,
return
AUDCLNT_E_NOT_INITIALIZED
;
}
if
(
This
->
dataflow
==
eRender
){
int
delay_bytes
;
double
delay_s
;
if
(
ioctl
(
This
->
fd
,
SNDCTL_DSP_GETODELAY
,
&
delay_bytes
)
<
0
){
LeaveCriticalSection
(
&
This
->
lock
);
WARN
(
"GETODELAY failed: %d (%s)
\n
"
,
errno
,
strerror
(
errno
));
return
E_FAIL
;
}
delay_s
=
delay_bytes
/
(
double
)(
This
->
fmt
->
nSamplesPerSec
*
This
->
fmt
->
nBlockAlign
);
*
latency
=
delay_s
*
10000000
;
}
else
*
latency
=
10000
;
/* OSS doesn't provide input latency */
/* pretend we process audio in Period chunks, so max latency includes
* the period time */
*
latency
+
=
DefaultPeriod
;
* the period time
. Some native machines add .6666ms in shared mode.
*/
*
latency
=
This
->
period_us
*
10
+
6666
;
LeaveCriticalSection
(
&
This
->
lock
);
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment