Name Description Size
android 4
cubeb_aaudio.cpp Note: Must match cubeb_stream layout in cubeb.c. 51175
cubeb_alsa.c snd_pcm_hw_params_alloca is actually a macro 40108
cubeb_android.h 440
cubeb_array_queue.h 1888
cubeb_assert.h Forward fatal asserts to MOZ_RELEASE_ASSERT when built inside Gecko. 573
cubeb_audiounit.cpp Testing empirically, some headsets report a minimal latency that is very low, but this does not work in practice. Lie and say the minimum is 256 frames. 122075
cubeb_jack.cpp static 36278
cubeb_log.cpp The maximum size of a log message, after having been formatted. 3714
cubeb_log.h Asynchronous verbose logging, to log in real-time callbacks. 2184
cubeb_mixer.cpp 1/sqrt(2) 20511
cubeb_mixer.h 961
cubeb_opensl.c Note: Must match cubeb_stream layout in cubeb.c. 56290
cubeb_oss.c Supported well by most hardware. 33306
cubeb_osx_run_loop.c 429
cubeb_osx_run_loop.h On OSX 10.6 and after, the notification callbacks from the audio hardware are called on the main thread. Setting the kAudioHardwarePropertyRunLoop property to null tells the OSX to use a separate thread for that. This has to be called only once per process, so it is in a separate header for easy integration in other code bases. 646
cubeb_panner.cpp We use a cos/sin law. 1324
cubeb_panner.h Pan an integer or an float stereo buffer according to a cos/sin pan law @param buf the buffer to pan @param frames the number of frames in `buf` @param pan a float in [-1.0; 1.0] 652
cubeb_resampler_internal.h This header file contains the internal C++ API of the resamplers, for testing. 22789
cubeb_resampler.cpp 13190
cubeb_resampler.h Create a resampler to adapt the requested sample rate into something that is accepted by the audio backend. @param stream A cubeb_stream instance supplied to the data callback. @param input_params Used to calculate bytes per frame and buffer size for resampling of the input side of the stream. NULL if input should not be resampled. @param output_params Used to calculate bytes per frame and buffer size for resampling of the output side of the stream. NULL if output should not be resampled. @param target_rate The sampling rate after resampling for the input side of the stream, and/or the sampling rate prior to resampling of the output side of the stream. @param callback A callback to request data for resampling. @param user_ptr User data supplied to the data callback. @param quality Quality of the resampler. @retval A non-null pointer if success. 2883
cubeb_ring_array.h Ring array of pointers is used to hold buffers. In case that asynchronous producer/consumer callbacks do not arrive in a repeated order the ring array stores the buffers and fetch them in the correct order. 4235
cubeb_ringbuffer.h Single producer single consumer lock-free and wait-free ring buffer. This data structure allows producing data from one thread, and consuming it on another thread, safely and without explicit synchronization. If used on two threads, this data structure uses atomics for thread safety. It is possible to disable the use of atomics at compile time and only use this data structure on one thread. The role for the producer and the consumer must be constant, i.e., the producer should always be on one thread and the consumer should always be on another thread. Some words about the inner workings of this class: - Capacity is fixed. Only one allocation is performed, in the constructor. When reading and writing, the return value of the method allows checking if the ring buffer is empty or full. - We always keep the read index at least one element ahead of the write index, so we can distinguish between an empty and a full ring buffer: an empty ring buffer is when the write index is at the same position as the read index. A full buffer is when the write index is exactly one position before the read index. - We synchronize updates to the read index after having read the data, and the write index after having written the data. This means that the each thread can only touch a portion of the buffer that is not touched by the other thread. - Callers are expected to provide buffers. When writing to the queue, elements are copied into the internal storage from the buffer passed in. When reading from the queue, the user is expected to provide a buffer. Because this is a ring buffer, data might not be contiguous in memory, providing an external buffer to copy into is an easy way to have linear data for further processing. 15215
cubeb_sndio.c Note: Must match cubeb_stream layout in cubeb.c. 18273
cubeb_strings.c Look for string in string storage. @param strings Opaque pointer to interned string storage. @param s String to look up. @retval Read-only string or NULL if not found. 2859
cubeb_strings.h Opaque handle referencing interned string storage. 1271
cubeb_sun.c Default to 4 + 1 for the default device. 19043
cubeb_utils_unix.h This wraps a critical section to track the owner in debug mode. 1678
cubeb_utils_win.h This wraps a critical section to track the owner in debug mode, adapted from NSPR and http://blogs.msdn.com/b/oldnewthing/archive/2013/07/12/10433554.aspx 1674
cubeb_utils.cpp 544
cubeb_utils.h Similar to memcpy, but accounts for the size of an element. 7959
cubeb_wasapi.cpp [annotation][in] 106674
cubeb_winmm.c clang-format off 33445
cubeb-internal.h CUBEB_INTERNAL_0eb56756_4e20_4404_a76d_42bf88cd15a5 3082
cubeb-jni-instances.h The methods in this file offer a way to pass in the required JNI instances in the cubeb library. By default they return NULL. In this case part of the cubeb API that depends on JNI will return CUBEB_ERROR_NOT_SUPPORTED. Currently only one method depends on that: cubeb_stream_get_position() Users that want to use that cubeb API method must "override" the methods bellow to return a valid instance of JavaVM and application's Context object. 895
cubeb-jni.cpp 2658
cubeb-jni.h 254
cubeb-sles.h Only synchronous operation is supported, as if the second parameter was FALSE. 770
cubeb-speex-resampler.h 35
cubeb.c Note: All implementations of cubeb_stream must keep the following layout. 17739
moz.build 2452