Bug 65122 - Audio doesn't work on OSX due to bugs in the coreaudio implementation
Summary: Audio doesn't work on OSX due to bugs in the coreaudio implementation
Status: RESOLVED FIXED
Alias: None
Product: PulseAudio
Classification: Unclassified
Component: modules (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Mac OS X (All)
: high blocker
Assignee: pulseaudio-bugs
QA Contact: pulseaudio-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-29 10:17 UTC by Vadim Troshchinskiy
Modified: 2013-05-29 11:10 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Fix bugs in coreaudio latency calculation code (3.01 KB, text/plain)
2013-05-29 10:17 UTC, Vadim Troshchinskiy
Details

Description Vadim Troshchinskiy 2013-05-29 10:17:03 UTC
Created attachment 79947 [details]
Fix bugs in coreaudio latency calculation code

Pulseaudio on OSX sometimes works and sometimes doesn't. When it works it usually takes a while before sound starts playing. A sound file might start playing after being stuck for a few minutes.

I tracked this down to a bug in the coreaudio implementation: the get_latency_us function is buggy and uses an uninitialized variable as part of the calculation. Sometimes the resulting latency turns out low enough for it to play, sometimes not.

The attached patch fixes the issue. It also fixes AudioObjectGetPropertyData calls that weren't working due to the wrong mScope and adds error logging.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.