Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJörg Müller <nexyon@gmail.com>2021-03-14 14:46:47 +0300
committerJörg Müller <nexyon@gmail.com>2021-03-17 01:21:45 +0300
commit12c08ceee3b034e360824969ea4e1aaed4be2daf (patch)
tree022c4bd87118b19af6e8477593466a3e7c25d2a4 /source
parentbc5798530663a9b3fec8df60feba510bd681c5ad (diff)
Audaspace: add support for CoreAudio on macOS
This adds CoreAudio as audio backend on macOS. CoreAudio is the standard audio API on macOS. Ref T86590
Diffstat (limited to 'source')
-rw-r--r--source/blender/makesrna/intern/CMakeLists.txt4
-rw-r--r--source/blender/python/intern/CMakeLists.txt4
-rw-r--r--source/blender/python/intern/bpy_app_build_options.c7
-rw-r--r--source/creator/creator_args.c2
4 files changed, 16 insertions, 1 deletions
diff --git a/source/blender/makesrna/intern/CMakeLists.txt b/source/blender/makesrna/intern/CMakeLists.txt
index 3069928cea7..4fafa356879 100644
--- a/source/blender/makesrna/intern/CMakeLists.txt
+++ b/source/blender/makesrna/intern/CMakeLists.txt
@@ -298,6 +298,10 @@ if(WITH_OPENAL)
add_definitions(-DWITH_OPENAL)
endif()
+if(WITH_COREAUDIO)
+ add_definitions(-DWITH_COREAUDIO)
+endif()
+
if(WITH_JACK)
add_definitions(-DWITH_JACK)
endif()
diff --git a/source/blender/python/intern/CMakeLists.txt b/source/blender/python/intern/CMakeLists.txt
index 298491327e0..c7816aed3c1 100644
--- a/source/blender/python/intern/CMakeLists.txt
+++ b/source/blender/python/intern/CMakeLists.txt
@@ -280,6 +280,10 @@ if(WITH_JACK)
add_definitions(-DWITH_JACK)
endif()
+if(WITH_COREAUDIO)
+ add_definitions(-DWITH_COREAUDIO)
+endif()
+
if(WITH_LIBMV)
add_definitions(-DWITH_LIBMV)
endif()
diff --git a/source/blender/python/intern/bpy_app_build_options.c b/source/blender/python/intern/bpy_app_build_options.c
index da5f46b9986..f7b71c769d1 100644
--- a/source/blender/python/intern/bpy_app_build_options.c
+++ b/source/blender/python/intern/bpy_app_build_options.c
@@ -49,6 +49,7 @@ static PyStructSequence_Field app_builtopts_info_fields[] = {
{"opensubdiv", NULL},
{"sdl", NULL},
{"sdl_dynload", NULL},
+ {"coreaudio", NULL},
{"jack", NULL},
{"pulseaudio", NULL},
{"wasapi", NULL},
@@ -213,6 +214,12 @@ static PyObject *make_builtopts_info(void)
SetObjIncref(Py_False);
#endif
+#ifdef WITH_COREAUDIO
+ SetObjIncref(Py_True);
+#else
+ SetObjIncref(Py_False);
+#endif
+
#ifdef WITH_JACK
SetObjIncref(Py_True);
#else
diff --git a/source/creator/creator_args.c b/source/creator/creator_args.c
index 562739642dd..5189af3ee85 100644
--- a/source/creator/creator_args.c
+++ b/source/creator/creator_args.c
@@ -1330,7 +1330,7 @@ static const char arg_handle_audio_set_doc[] =
"\n\t"
"Force sound system to a specific device."
"\n\t"
- "'None' 'SDL' 'OpenAL' 'JACK' 'PulseAudio' 'WASAPI'.";
+ "'None' 'SDL' 'OpenAL' 'CoreAudio' 'JACK' 'PulseAudio' 'WASAPI'.";
static int arg_handle_audio_set(int argc, const char **argv, void *UNUSED(data))
{
if (argc < 1) {