[Bf-blender-cvs] [fe891d581df] master: Audaspace: update from upstream

Jörg Müller noreply at git.blender.org
Sun May 3 15:31:09 CEST 2020


Commit: fe891d581dfece13b42414ba1d8fec6063290a31
Author: Jörg Müller
Date:   Sun May 3 15:25:52 2020 +0200
Branches: master
https://developer.blender.org/rBfe891d581dfece13b42414ba1d8fec6063290a31

Audaspace: update from upstream

- Changing API for time values from float to double for better precision.
- Fixing minor mistakes in the documentation.
- Fixing minor unnecessary large memory allocation.

===================================================================

M	extern/audaspace/bindings/C/AUD_Device.cpp
M	extern/audaspace/bindings/C/AUD_Device.h
M	extern/audaspace/bindings/C/AUD_DynamicMusic.cpp
M	extern/audaspace/bindings/C/AUD_DynamicMusic.h
M	extern/audaspace/bindings/C/AUD_Handle.cpp
M	extern/audaspace/bindings/C/AUD_Handle.h
M	extern/audaspace/bindings/C/AUD_Sequence.cpp
M	extern/audaspace/bindings/C/AUD_Sequence.h
M	extern/audaspace/bindings/C/AUD_Special.cpp
M	extern/audaspace/bindings/C/AUD_Special.h
M	extern/audaspace/bindings/doc/device.rst
M	extern/audaspace/bindings/doc/handle.rst
M	extern/audaspace/bindings/doc/index.rst
M	extern/audaspace/bindings/doc/sequence.rst
M	extern/audaspace/bindings/doc/sequence_entry.rst
M	extern/audaspace/bindings/doc/sound.rst
M	extern/audaspace/bindings/doc/tutorials.rst
M	extern/audaspace/bindings/python/PyDynamicMusic.cpp
M	extern/audaspace/bindings/python/PyHandle.cpp
M	extern/audaspace/bindings/python/PySequence.cpp
M	extern/audaspace/bindings/python/PySequenceEntry.cpp
M	extern/audaspace/bindings/python/PySound.cpp
M	extern/audaspace/include/devices/DefaultSynchronizer.h
M	extern/audaspace/include/devices/IDeviceFactory.h
M	extern/audaspace/include/devices/IHandle.h
M	extern/audaspace/include/devices/ISynchronizer.h
M	extern/audaspace/include/devices/NULLDevice.h
M	extern/audaspace/include/devices/SoftwareDevice.h
M	extern/audaspace/include/file/IFileInput.h
M	extern/audaspace/include/fx/Delay.h
M	extern/audaspace/include/fx/DelayReader.h
M	extern/audaspace/include/fx/DynamicMusic.h
M	extern/audaspace/include/fx/Fader.h
M	extern/audaspace/include/fx/FaderReader.h
M	extern/audaspace/include/fx/Limiter.h
M	extern/audaspace/include/fx/LimiterReader.h
M	extern/audaspace/include/sequence/Sequence.h
M	extern/audaspace/include/sequence/SequenceData.h
M	extern/audaspace/include/sequence/SequenceEntry.h
M	extern/audaspace/plugins/jack/JackDevice.cpp
M	extern/audaspace/plugins/jack/JackDevice.h
M	extern/audaspace/plugins/jack/JackSynchronizer.cpp
M	extern/audaspace/plugins/jack/JackSynchronizer.h
M	extern/audaspace/plugins/openal/OpenALDevice.cpp
M	extern/audaspace/plugins/openal/OpenALDevice.h
M	extern/audaspace/src/devices/DefaultSynchronizer.cpp
M	extern/audaspace/src/devices/NULLDevice.cpp
M	extern/audaspace/src/devices/SoftwareDevice.cpp
M	extern/audaspace/src/fx/Delay.cpp
M	extern/audaspace/src/fx/DelayReader.cpp
M	extern/audaspace/src/fx/DynamicMusic.cpp
M	extern/audaspace/src/fx/Fader.cpp
M	extern/audaspace/src/fx/FaderReader.cpp
M	extern/audaspace/src/fx/Limiter.cpp
M	extern/audaspace/src/fx/LimiterReader.cpp
M	extern/audaspace/src/respec/ChannelMapperReader.cpp
M	extern/audaspace/src/respec/Mixer.cpp
M	extern/audaspace/src/sequence/Sequence.cpp
M	extern/audaspace/src/sequence/SequenceData.cpp
M	extern/audaspace/src/sequence/SequenceEntry.cpp
M	extern/audaspace/src/sequence/SequenceHandle.cpp
M	extern/audaspace/src/sequence/SequenceHandle.h
M	extern/audaspace/src/sequence/SequenceReader.cpp
M	source/blender/blenkernel/BKE_sound.h
M	source/blender/blenkernel/intern/sound.c
M	source/blender/editors/screen/screen_ops.c
M	source/blender/windowmanager/intern/wm_event_system.c
M	source/blender/windowmanager/intern/wm_init_exit.c

===================================================================

diff --git a/extern/audaspace/bindings/C/AUD_Device.cpp b/extern/audaspace/bindings/C/AUD_Device.cpp
index 441f228deac..d4643094bc2 100644
--- a/extern/audaspace/bindings/C/AUD_Device.cpp
+++ b/extern/audaspace/bindings/C/AUD_Device.cpp
@@ -290,14 +290,14 @@ AUD_API AUD_Device* AUD_Device_getCurrent()
 	return new AUD_Device(device);
 }
 
-AUD_API void AUD_seekSynchronizer(AUD_Handle* handle, float time)
+AUD_API void AUD_seekSynchronizer(AUD_Handle* handle, double time)
 {
 	auto synchronizer = DeviceManager::getDevice()->getSynchronizer();
 	if(synchronizer)
 		synchronizer->seek(*reinterpret_cast<std::shared_ptr<IHandle>*>(handle), time);
 }
 
-AUD_API float AUD_getSynchronizerPosition(AUD_Handle* handle)
+AUD_API double AUD_getSynchronizerPosition(AUD_Handle* handle)
 {
 	auto synchronizer = DeviceManager::getDevice()->getSynchronizer();
 	if(synchronizer)
diff --git a/extern/audaspace/bindings/C/AUD_Device.h b/extern/audaspace/bindings/C/AUD_Device.h
index 0dfa21f0660..05e004a17db 100644
--- a/extern/audaspace/bindings/C/AUD_Device.h
+++ b/extern/audaspace/bindings/C/AUD_Device.h
@@ -221,14 +221,14 @@ extern AUD_API AUD_Device* AUD_Device_getCurrent();
  * \param handle Playback handle.
  * \param time Time in seconds to seek to.
  */
-extern AUD_API void AUD_seekSynchronizer(AUD_Handle* handle, float time);
+extern AUD_API void AUD_seekSynchronizer(AUD_Handle* handle, double time);
 
 /**
  * Returns the current sound scene playback time.
  * \param handle Playback handle.
  * \return The playback time in seconds.
  */
-extern AUD_API float AUD_getSynchronizerPosition(AUD_Handle* handle);
+extern AUD_API double AUD_getSynchronizerPosition(AUD_Handle* handle);
 
 /**
  * Starts the playback of jack transport if possible.
diff --git a/extern/audaspace/bindings/C/AUD_DynamicMusic.cpp b/extern/audaspace/bindings/C/AUD_DynamicMusic.cpp
index bb7a129dde3..62e626cdc6c 100644
--- a/extern/audaspace/bindings/C/AUD_DynamicMusic.cpp
+++ b/extern/audaspace/bindings/C/AUD_DynamicMusic.cpp
@@ -101,14 +101,14 @@ AUD_API int AUD_DynamicMusic_pause(AUD_DynamicMusic* player)
 	return (*player)->pause();
 }
 
-AUD_API int AUD_DynamicMusic_seek(AUD_DynamicMusic* player, float position)
+AUD_API int AUD_DynamicMusic_seek(AUD_DynamicMusic* player, double position)
 {
 	assert(player);
 
 	return (*player)->seek(position);
 }
 
-AUD_API float AUD_DynamicMusic_getPosition(AUD_DynamicMusic* player)
+AUD_API double AUD_DynamicMusic_getPosition(AUD_DynamicMusic* player)
 {
 	assert(player);
 
@@ -141,4 +141,4 @@ AUD_API int AUD_DynamicMusic_stop(AUD_DynamicMusic* player)
 	assert(player);
 
 	return (*player)->stop();
-}
\ No newline at end of file
+}
diff --git a/extern/audaspace/bindings/C/AUD_DynamicMusic.h b/extern/audaspace/bindings/C/AUD_DynamicMusic.h
index c362479591e..b8b78e57b55 100644
--- a/extern/audaspace/bindings/C/AUD_DynamicMusic.h
+++ b/extern/audaspace/bindings/C/AUD_DynamicMusic.h
@@ -103,14 +103,14 @@ extern AUD_API int AUD_DynamicMusic_pause(AUD_DynamicMusic* player);
 * \param position The new position from which to play back, in seconds.
 * \return 0 if the seeking wasn't possible.
 */
-extern AUD_API int AUD_DynamicMusic_seek(AUD_DynamicMusic* player, float position);
+extern AUD_API int AUD_DynamicMusic_seek(AUD_DynamicMusic* player, double position);
 
 /**
 * Retrieves the position of the current scene of a dynamic music player.
 * \param player The DynamicMusic object.
 * \return The position of the current playing scene.
 */
-extern AUD_API float AUD_DynamicMusic_getPosition(AUD_DynamicMusic* player);
+extern AUD_API double AUD_DynamicMusic_getPosition(AUD_DynamicMusic* player);
 
 /**
 * Retrieves the volume of the current scene of a dynamic music player.
@@ -142,4 +142,4 @@ extern AUD_API int AUD_DynamicMusic_stop(AUD_DynamicMusic* player);
 
 #ifdef __cplusplus
 }
-#endif
\ No newline at end of file
+#endif
diff --git a/extern/audaspace/bindings/C/AUD_Handle.cpp b/extern/audaspace/bindings/C/AUD_Handle.cpp
index 265c7bf08d2..88d46d635e3 100644
--- a/extern/audaspace/bindings/C/AUD_Handle.cpp
+++ b/extern/audaspace/bindings/C/AUD_Handle.cpp
@@ -259,13 +259,13 @@ AUD_API int AUD_Handle_setPitch(AUD_Handle* handle, float value)
 	return (*handle)->setPitch(value);
 }
 
-AUD_API float AUD_Handle_getPosition(AUD_Handle* handle)
+AUD_API double AUD_Handle_getPosition(AUD_Handle* handle)
 {
 	assert(handle);
 	return (*handle)->getPosition();
 }
 
-AUD_API int AUD_Handle_setPosition(AUD_Handle* handle, float value)
+AUD_API int AUD_Handle_setPosition(AUD_Handle* handle, double value)
 {
 	assert(handle);
 	return (*handle)->seek(value);
diff --git a/extern/audaspace/bindings/C/AUD_Handle.h b/extern/audaspace/bindings/C/AUD_Handle.h
index 27cbd251de5..2182346c451 100644
--- a/extern/audaspace/bindings/C/AUD_Handle.h
+++ b/extern/audaspace/bindings/C/AUD_Handle.h
@@ -211,14 +211,14 @@ extern AUD_API int AUD_Handle_setPitch(AUD_Handle* handle, float value);
  * param handle The handle to get the position from.
  * return The position of the handle.
  */
-extern AUD_API float AUD_Handle_getPosition(AUD_Handle* handle);
+extern AUD_API double AUD_Handle_getPosition(AUD_Handle* handle);
 
 /**
  * Sets the position of a handle.
  * param handle The handle to set the position from.
  * param value The new position to set.
  */
-extern AUD_API int AUD_Handle_setPosition(AUD_Handle* handle, float value);
+extern AUD_API int AUD_Handle_setPosition(AUD_Handle* handle, double value);
 
 /**
  * Retrieves the relative of a handle.
diff --git a/extern/audaspace/bindings/C/AUD_Sequence.cpp b/extern/audaspace/bindings/C/AUD_Sequence.cpp
index d278cb148a1..e3f88629657 100644
--- a/extern/audaspace/bindings/C/AUD_Sequence.cpp
+++ b/extern/audaspace/bindings/C/AUD_Sequence.cpp
@@ -41,7 +41,7 @@ AUD_API void AUD_Sequence_free(AUD_Sound* sequence)
 	delete sequence;
 }
 
-AUD_API AUD_SequenceEntry* AUD_Sequence_add(AUD_Sound* sequence, AUD_Sound* sound, float begin, float end, float skip)
+AUD_API AUD_SequenceEntry* AUD_Sequence_add(AUD_Sound* sequence, AUD_Sound* sound, double begin, double end, double skip)
 {
 	if(!sound)
 		return new AUD_SequenceEntry(((Sequence *)sequence->get())->add(AUD_Sound(), begin, end, skip));
@@ -160,7 +160,7 @@ AUD_API void AUD_Sequence_setSpeedOfSound(AUD_Sound* sequence, float value)
 
 
 
-AUD_API void AUD_SequenceEntry_move(AUD_SequenceEntry* entry, float begin, float end, float skip)
+AUD_API void AUD_SequenceEntry_move(AUD_SequenceEntry* entry, double begin, double end, double skip)
 {
 	(*entry)->move(begin, end, skip);
 }
diff --git a/extern/audaspace/bindings/C/AUD_Sequence.h b/extern/audaspace/bindings/C/AUD_Sequence.h
index 668960c7d50..bdf1a61a2de 100644
--- a/extern/audaspace/bindings/C/AUD_Sequence.h
+++ b/extern/audaspace/bindings/C/AUD_Sequence.h
@@ -55,7 +55,7 @@ extern AUD_API void AUD_Sequence_free(AUD_Sound* sequence);
  * \param skip How much seconds should be skipped at the beginning.
  * \return The entry added.
  */
-extern AUD_API AUD_SequenceEntry* AUD_Sequence_add(AUD_Sound* sequence, AUD_Sound* sound, float begin, float end, float skip);
+extern AUD_API AUD_SequenceEntry* AUD_Sequence_add(AUD_Sound* sequence, AUD_Sound* sound, double begin, double end, double skip);
 
 /**
  * Removes an entry from the scene.
@@ -167,7 +167,7 @@ extern AUD_API void AUD_Sequence_setSpeedOfSound(AUD_Sound* sequence, float valu
  * \param end The new end time or a negative value if unknown.
  * \param skip How many seconds to skip at the beginning.
  */
-extern AUD_API void AUD_SequenceEntry_move(AUD_SequenceEntry* entry, float begin, float end, float skip);
+extern AUD_API void AUD_SequenceEntry_move(AUD_SequenceEntry* entry, double begin, double end, double skip);
 
 /**
  * Writes animation data to a sequenced entry.
diff --git a/extern/audaspace/bindings/C/AUD_Special.cpp b/extern/audaspace/bindings/C/AUD_Special.cpp
index 30148fa1487..c7155276a30 100644
--- a/extern/audaspace/bindings/C/AUD_Special.cpp
+++ b/extern/audaspace/bindings/C/AUD_Special.cpp
@@ -175,7 +175,7 @@ static void pauseSound(AUD_Handle* handle)
 	(*handle)->pause();
 }
 
-AUD_API AUD_Handle* AUD_pauseAfter(AUD_Handle* handle, float seconds)
+AUD_API AUD_Handle* AUD_pauseAfter(AUD_Handle* handle, double seconds)
 {
 	auto device = DeviceManager::getDevice();
 
@@ -336,7 +336,7 @@ AUD_API const char* AUD_mixdown_per_channel(AUD_Sound* sound, unsigned int start
 	}
 }
 
-AUD_API AUD_Device* AUD_openMixdownDevice(AUD_DeviceSpecs specs, AUD_Sound* sequencer, float volume, float start)
+AUD_API AUD_Device* AUD_openMixdownDevice(AUD_DeviceSpecs specs, AUD_Sound* sequencer, float volume, double start)
 {
 	try
 	{
diff --git a/extern/audaspace/bindings/C/AUD_Special.h b/extern/audaspace/bindings/C/AUD_Special.h
index ab79ae915a2..9faf9e4ee74 100644
--- a/extern/audaspace/bindings/C/AUD_Special.h
+++ b/extern/audaspace/bindings/C/AUD_Special.h
@@ -45,7 +45,7 @@ extern AUD_API float* AUD_readSoundBuffer(const char* filename, float low, float
  * \param seconds The time in seconds.
  * \return The silence handle.
  */
-extern AUD_API AUD_Handle* AUD_pauseAfter(AUD_Handle* handle, float seconds);
+extern AUD_API AUD_Handle* AUD_pauseAfter(AUD_Handle* handle, double seconds);
 
 /**
  * Reads a sound into a buffer for drawing at a specific sampling rate.
@@ -101,7 +101,7 @@ extern AUD_API const char* AUD_mixdown_per_channel(AUD_Sound* sound, unsigned in
  * \param start The start time of the mixdown in the sound scene.
  * \return The read device for the mixdown.
  */
-extern AUD_API AUD_Device* AUD_openMixdownDevice(AUD_DeviceSpecs specs, AUD_Sound* sequencer, float volume, float start);
+extern AUD_API AUD_Device* AUD_openMixdownDevice(AUD_DeviceSpecs specs, AUD_Sound* sequencer, float volume, double start);
 
 /**
  * Initializes audio routines (FFMPEG/JACK if it is enabled).
diff --git a/extern/audaspace/bindings/doc/device.rst b/extern/audaspace/bindings/doc/device.rst
index fd6b334022c..d6f49bd7407 100644
--- a/extern/audaspace/bindings/doc/device.rst
+++ b/extern/audaspace/bindings/doc/device.rst
@@ -4,4 +4,5 @@ Device
 .. currentmodule:: aud
 .. autoclass:: Device
    :members:
+   :noindex:
 
diff --git a/extern/audaspace/bindings/doc/handle.rst b/exte

@@ Diff output truncated at 10240 characters. @@



More information about the Bf-blender-cvs mailing list