| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
It's true that ALSA uses alloca() in some of its API functions, but
since this is hidden behind macros in the ALSA headers, we have no
reason to include alloca.h ourselves.
Might help with portability (FreeBSD).
|
| |
|
|
|
|
|
|
|
|
| |
At least not with ffmpeg.
Honestly, I have no idea how little endian AC3 works at all, since
ao_pcm doesn't do anything special about it, and treats it like s16le.
Maybe it's broken and ffmpeg has special logic to detect it.
|
|
|
|
|
|
|
|
|
| |
Was disabled by default, was never used, internal support was
inconsistent and poor, and there has been virtually no interest in
creating translations.
And I don't even think that a terminal program should be translated.
This is something for (hypothetical) GUIs.
|
|
|
|
|
|
|
|
| |
Output silence to the output buffer during underruns. This removes small
occasional glitches that happen before the AUHAL is actually paused from the
`audio_pause` call.
Fixes #269
|
|
|
|
| |
Based on an earlier patch for mplayer by Alexandre Ratchov <alex@caoua.org>
|
|
|
|
|
| |
The previous code fetched the device name regardless of log level and then
only printed it if log level was verbose.
|
|
|
|
|
|
|
|
| |
Trying to connect multiple mpv clients to JACK with the
JackUseExactName option would fail unless the user manually
specifies a unique client name. This changes the behavior
to automatically generate a unique name if the requested
one is already in use.
|
|
|
|
|
| |
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: wm4 <wm4@nowhere>
|
| |
|
| |
|
|
|
|
| |
Also remove stray include statements from ao_alsa and ao_oss.
|
|
|
|
|
| |
Also add a note to mp_msg.h, since it might be not clear which of the
two mechanisms is preferred.
|
|
|
|
|
|
|
| |
Use the new MP_ macros for some AOs instead of mp_msg.
Not all AOs are converted, and some only partially. In some cases, some
additional cosmetic changes are made.
|
| |
|
|
|
|
| |
Followup commit. Fixes all the files references.
|
|\
| |
| | |
WASAPI stops working after pause
|
| | |
|
| | |
|
| |
| |
| |
| | |
They are already defined in the header file
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| | |
Using the default output audio unit should provide a much better user
exeperience since it changes automatically the output device based on which
becomes the default one.
|
| |
| |
| |
| |
| |
| | |
This was removed in d427b4fd. I now found a sample that causes underruns when
moving to a chapter and apparently this is also a problem when taking
screenshots.
|
|/
|
|
|
|
|
|
|
|
|
|
| |
Reverts one of the changes from 18777ecf. `kAudioObjectPropertyScopeOutput`
was introduced in the 10.8 SDK while `kAudioDevicePropertyScopeOutput` was
moved to `AudioHardwareDeprecated.h`. Since the deprecation is silent for now
(no warnings), just use the old constant.
Either way, they both evaluate to 'outp', and in the 10.8 SDK the deprecated
constant is defined in terms of the non-deprecated one.
Fixes #155
|
|
|
|
| |
Same as with VOs in the previous commit.
|
|
|
|
| |
Finally not used by anything anymore. Farewell.
|
|
|
|
|
| |
The big endian case was not covered. Doesn't make much difference since mpv
runs on Macs with x86 only, but for the sake of correctness.
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
This is not done automatically by CoreAudio. I am told that it would a PITA
to have to switch back the format manually on the device (especially if the
same device is used for lpcm output).
|
|
|
|
|
|
| |
b2f9e0610 introduced this functionality with code that was quite 'monolithic'.
Split the functionality over several functions and ose the new macros to get
array properties.
|
|
|
|
|
|
|
|
| |
Introduce some macros to deal with properties. These allow to work around the
limitation of CoreAudio's API being `void **` based. The macros allow to keep
their client's code DRY, by not asking size and other details which can be
derived by the macro itself. I have no idea why Apple didn't design their API
like this in the first place.
|
| |
|
|
|
|
|
|
|
|
|
| |
* ao_coreaudio_utils: contains several utility function
* ao_coreaudio_properties: contains functions to set and get audio object
properties.
Conflicts:
audio/out/ao_coreaudio.c
|
|
|
|
|
| |
Previous code needlessly stored the input asbd before actually testing it's
support against the hardware.
|
| |
|
|
|
|
| |
this is a wip
|
|
|
|
|
|
| |
The condition was checked wrongly on asbd which is the input format
description. This lead to the condition always being true, thus selecting lpcm
streams for digital input.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
kHALOutputParam_Volume is the linear gain so it should be at maximum 1 to
keep the audio quality good. No idea why it was more than that.
|
|
|
|
| |
Also extract this functionality inside a function in coreaudio_common
|
| |
|
|
|
|
|
| |
Luckily they all were inside for loops so the functionality does not actually
change.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The initialization is split more clearly between compressed and lpcm case.
For the compressed case, format selection is simplified a lot and negotiation
removed. The way it was written it just passed back to the core the original
requested format, not what was found available on hardware.
Since this is most likely useless for the compressed case, I didn't bother
with this. In the future I'd like to split this AO in two one that only uses
the AUHAL and the other with direct access to the hardware so that even
passthrough of lcpm can be possible. This would decrease the latency,
audiophiles would like that.
|
| |
|
|
|
|
|
|
|
| |
Split out some utility functions that use the CoreAudio API but are not related
the main task of the AOs (which is to move data correctly to the ringbuffer).
These are mainly need for the verbosity of the CoreAudio API and are just
obscuring the 'real' code.
|
|
|
|
| |
property_address -> p_addr
|
|
|
|
| |
WIP
|
|
|
|
|
| |
Change the ca_msg macro to pass along MSGT_AO automatically. Also use it for
every output for consistency.
|
|
|
|
|
| |
It was reported that it also works by not setting the read size in the
AudioBuffer (now idea how, but I will discover it later).
|
| |
|
|
|
|
|
|
|
| |
Read only the requested amount by the AUHAL (instead of all the buffered data).
No idea what the deal is with pausing the audio units if there is no audio to
play, maybe to avoid underruns of some sort. Anyway from my tests this
condition never occurred so I'm removing it all.
|
|
|
|
| |
Ahead of OSS because cygwin provides OSS.
|
|
|
|
|
|
|
|
|
|
| |
MSDN tells me to multiply the samplerates by 4 (for setting up the S/PDIF
signal frequency), but doesn't mention that I'm only supposed to do it
on the new, NT6.1+ IEC 61937 structs. Works on my Realtek Digital Output,
but as I can't connect any hardware to it I can't hear the result.
Also, always ask for little-endian AC3. I'm not sure if this is supposed
to be LE or NE, but Windows is LE on all platforms, so we go with LE.
|
| |
|
|
|
|
| |
That's the sample format ad_spdif uses when the source is MP3.
|
|
|
|
|
|
|
| |
Entirely untested as this troper has no S/PDIF hardware.
Refuses trying any other format if we can't use passthrough, or we would
end up sending white noise at the user.
|
|
|
|
|
| |
Caused by incorrect conversion to the m_option API: since we don't allocate
the state ourselves, we also don't free it ourselves.
|
|
|
|
|
|
|
|
|
| |
Do an strstr match against the device description and, if we have only
a single match, take it. This works as long as the devices in the system
don't change, but it's not supposed to be reliable; if one wants
reliability, one uses the device ID string.
Formatting.
|
|
|
|
|
|
|
|
|
|
|
| |
This could turn valid parameters into syntax errors by the mere presence
or abscence of a device (e.g. USB audio devices), so don't do that.
We do validate that, if the parameter is an integer, it is not negative.
We also respond to the "help" parameter, which does the same as the "list"
suboption but exits after listing.
Demote the validation logging to MSGL_DBG2.
|
|
|
|
| |
Add semicolons where they were missing.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Validates by trying to pick the device using the device enumerator and
aborting with out of range on failure.
Refactors find_and_load_device to not use the wasapi_state; it might be
called during validation. Adds missing CoInitialize/CoUninitialize calls.
Remove unused variables (the SAFE_RELEASE macros keep them referenced so
compiler warnings don't help finding them...).
Remove the IMMDeviceEnu |