Bug 1846158 - Reapply patch on top of libcubeb. r=cubeb-reviewers,kinetik

Depends on D184920

Differential Revision: https://phabricator.services.mozilla.com/D184921
This commit is contained in:
Paul Adenot 2023-08-01 07:07:08 +00:00
Родитель 92ee586b0d
Коммит c1119ffcc8
1 изменённых файлов: 4 добавлений и 0 удалений

Просмотреть файл

@ -11,6 +11,7 @@
#include "cubeb_resampler.h"
#include "cubeb_triple_buffer.h"
#include <aaudio/AAudio.h>
#include <android/api-level.h>
#include <atomic>
#include <cassert>
#include <chrono>
@ -1704,6 +1705,9 @@ const static struct cubeb_ops aaudio_ops = {
extern "C" /*static*/ int
aaudio_init(cubeb ** context, char const * /* context_name */)
{
if (android_get_device_api_level() <= 30) {
return CUBEB_ERROR;
}
// load api
void * libaaudio = nullptr;
#ifndef DISABLE_LIBAAUDIO_DLOPEN