Skip to content
Snippets Groups Projects
Commit c4bbc536 authored by 관우 안's avatar 관우 안
Browse files

3.5.1 revert

parent 32a3c89a
No related branches found
No related tags found
No related merge requests found
Showing
with 72 additions and 134 deletions
...@@ -2,8 +2,8 @@ ...@@ -2,8 +2,8 @@
## Prerequisites ## Prerequisites
* **python3** >= 3.8 (you can find an official download here: https://www.python.org/downloads/) * **python3** >= 3.8
* **cmake** >= 3.16 (you can find an official download here: https://cmake.org/download/) * **cmake** >= 3.16
* A working C++ 17 compiler * A working C++ 17 compiler
* Graphviz (optional) * Graphviz (optional)
......
...@@ -31,8 +31,8 @@ endif() ...@@ -31,8 +31,8 @@ endif()
# Increment as appropriate after release of a new version, and set back # Increment as appropriate after release of a new version, and set back
# AUDACITY_BUILD_LEVEL to 0 # AUDACITY_BUILD_LEVEL to 0
set( AUDACITY_VERSION 3 ) set( AUDACITY_VERSION 3 )
set( AUDACITY_RELEASE 6 ) set( AUDACITY_RELEASE 5 )
set( AUDACITY_REVISION 0 ) set( AUDACITY_REVISION 1 )
set( AUDACITY_MODLEVEL 0 ) set( AUDACITY_MODLEVEL 0 )
string( TIMESTAMP __TDATE__ "%Y%m%d" ) string( TIMESTAMP __TDATE__ "%Y%m%d" )
...@@ -678,8 +678,7 @@ string( JOIN "\n" GRAPH_EDGES ${GRAPH_EDGES} ) ...@@ -678,8 +678,7 @@ string( JOIN "\n" GRAPH_EDGES ${GRAPH_EDGES} )
# Choose edge attributes making it easy to hover at either end of edge # Choose edge attributes making it easy to hover at either end of edge
# and see a tooltip describing the edge, in svg image # and see a tooltip describing the edge, in svg image
file( WRITE "${CMAKE_CURRENT_BINARY_DIR}/modules.dot" "digraph { file( WRITE "${CMAKE_CURRENT_BINARY_DIR}/modules.dot" "digraph {
graph [rankdir=LR newrank=true] edge [dir=both,arrowtail=inv] \n" graph [rankdir=LR] edge [dir=both,arrowtail=inv] \n"
"${GRAPH_SUBGRAPHS}\n"
"${GRAPH_EDGES}" "${GRAPH_EDGES}"
"\n}\n" "\n}\n"
) )
......
...@@ -29,7 +29,7 @@ See [our translators page](https://www.audacityteam.org/community/translators/) ...@@ -29,7 +29,7 @@ See [our translators page](https://www.audacityteam.org/community/translators/)
## Feedback & Feature requests ## Feedback & Feature requests
If you have anything you think Audacity can do better, you can voice it in [the relevant section in the forum](https://forum.audacityteam.org/c/feedback-and-discussion-forum/adding-features-to-audacity/22). If you have a very concrete idea something in the code which should be added or changed, you can also [make an enhancement request in the issue tracker](https://github.com/audacity/audacity/issues/new/choose). If you have anything you thing Audacity can do better, you can voice it in [the relevant section in the forum](https://forum.audacityteam.org/c/feedback-and-discussion-forum/adding-features-to-audacity/22). If you have a very concrete idea something in the code which should be added or changed, you can also [make an enhancement request in the issue tracker](https://github.com/audacity/audacity/issues/new/choose).
## Supporting Users ## Supporting Users
......
...@@ -27,6 +27,3 @@ Additional development resources may be found [here](https://audacity.gitbook.io ...@@ -27,6 +27,3 @@ Additional development resources may be found [here](https://audacity.gitbook.io
## License ## License
Audacity is open source software licensed GPLv3. Most code files are GPLv2-or-later, with the notable exceptions being /lib-src (which contains third party libraries), as well as VST3-related code. Documentation is licensed CC-by 3.0 unless otherwise noted. Details can be found in the [license file](LICENSE.txt). Audacity is open source software licensed GPLv3. Most code files are GPLv2-or-later, with the notable exceptions being /lib-src (which contains third party libraries), as well as VST3-related code. Documentation is licensed CC-by 3.0 unless otherwise noted. Details can be found in the [license file](LICENSE.txt).
...@@ -356,7 +356,7 @@ endfunction() ...@@ -356,7 +356,7 @@ endfunction()
# shorten a target name for purposes of generating a dependency graph picture # shorten a target name for purposes of generating a dependency graph picture
function( canonicalize_node_name var node ) function( canonicalize_node_name var node )
# strip generator expressions # strip generator expressions
string( REGEX REPLACE ".*>:(.*)>" "\\1" node "${node}" ) string( REGEX REPLACE ".*>.*:(.*)>" "\\1" node "${node}" )
# omit the "-interface" for alias targets to modules # omit the "-interface" for alias targets to modules
string( REGEX REPLACE "-interface\$" "" node "${node}" ) string( REGEX REPLACE "-interface\$" "" node "${node}" )
# shorten names of standard libraries or Apple frameworks # shorten names of standard libraries or Apple frameworks
...@@ -848,57 +848,3 @@ function(fix_bundle target_name) ...@@ -848,57 +848,3 @@ function(fix_bundle target_name)
-config=$<CONFIG> -config=$<CONFIG>
) )
endfunction() endfunction()
# The list of modules is ordered so that each module occurs after any others
# that it depends on
macro( audacity_module_subdirectory modules )
# Make a graphviz cluster of module nodes and maybe some 3p libraries
set( subgraph )
get_filename_component( name "${CMAKE_CURRENT_SOURCE_DIR}" NAME_WE )
string( APPEND subgraph
# name must begin with "cluster" to get graphviz to draw a box
"subgraph \"cluster${name}\" { "
# style attributes and visible name
"style=bold color=blue labeljust=r labelloc=b label=\"${name}\" "
)
set( nodes )
set( EXCLUDE_LIST
Audacity
PRIVATE
PUBLIC
INTERFACE
)
# Visit each module, and may collect some clustered node names
foreach( MODULE ${MODULES} )
set( EXTRA_CLUSTER_NODES ) # a variable that the subdirectory may change
add_subdirectory( "${MODULE}" )
foreach( NODE ${EXTRA_CLUSTER_NODES} )
# This processing of NODE makes it easy for the module simply to
# designate all of its libraries as extra cluster nodes, when they
# (besides the executable itself) are not used anywhere else
if ( NODE IN_LIST EXCLUDE_LIST )
continue()
endif()
canonicalize_node_name( NODE "${NODE}" )
string( APPEND nodes "\"${NODE}\"\n" )
endforeach()
endforeach()
# complete the cluster description
foreach( MODULE ${MODULES} )
string( APPEND nodes "\"${MODULE}\"\n" )
endforeach()
string( APPEND subgraph
# names of nodes to be grouped
"\n${nodes}"
"}\n"
)
# propagate collected edges and subgraphs up to root CMakeLists.txt
set( GRAPH_EDGES "${GRAPH_EDGES}" PARENT_SCOPE )
set( GRAPH_SUBGRAPHS "${GRAPH_SUBGRAPHS}${subgraph}" PARENT_SCOPE )
endmacro()
...@@ -3,7 +3,7 @@ add_library( ${TARGET} STATIC ) ...@@ -3,7 +3,7 @@ add_library( ${TARGET} STATIC )
def_vars() def_vars()
set( SOURCES list( APPEND SOURCES
PRIVATE PRIVATE
${TARGET_ROOT}/audioreader.cpp ${TARGET_ROOT}/audioreader.cpp
${TARGET_ROOT}/comp_chroma.cpp ${TARGET_ROOT}/comp_chroma.cpp
...@@ -16,7 +16,7 @@ set( SOURCES ...@@ -16,7 +16,7 @@ set( SOURCES
${TARGET_ROOT}/fft3/FFT3.cpp ${TARGET_ROOT}/fft3/FFT3.cpp
) )
set( INCLUDES list( APPEND INCLUDES
PUBLIC PUBLIC
${TARGET_ROOT} ${TARGET_ROOT}
) )
......
...@@ -5,7 +5,7 @@ def_vars() ...@@ -5,7 +5,7 @@ def_vars()
set(CMAKE_MODULE_PATH ${TARGET_ROOT}/cmake/Modules ) set(CMAKE_MODULE_PATH ${TARGET_ROOT}/cmake/Modules )
set( SOURCES list( APPEND SOURCES
PRIVATE PRIVATE
${TARGET_ROOT}/src/cr.c ${TARGET_ROOT}/src/cr.c
${TARGET_ROOT}/src/cr32.c ${TARGET_ROOT}/src/cr32.c
...@@ -23,21 +23,21 @@ set( SOURCES ...@@ -23,21 +23,21 @@ set( SOURCES
${TARGET_ROOT}/src/vr32.c ${TARGET_ROOT}/src/vr32.c
) )
set( INCLUDES list( APPEND INCLUDES
PRIVATE PRIVATE
${_PRVDIR} ${_PRVDIR}
PUBLIC PUBLIC
${TARGET_ROOT}/src ${TARGET_ROOT}/src
) )
set( DEFINES list( APPEND DEFINES
PRIVATE PRIVATE
_USE_MATH_DEFINES _USE_MATH_DEFINES
_CRT_SECURE_NO_WARNINGS _CRT_SECURE_NO_WARNINGS
SOXR_LIB SOXR_LIB
) )
set( OPTIONS list( APPEND OPTIONS
PRIVATE PRIVATE
$<$<C_COMPILER_ID:AppleClang,Clang,GNU>: $<$<C_COMPILER_ID:AppleClang,Clang,GNU>:
-Wconversion -Wconversion
......
...@@ -8,7 +8,7 @@ def_vars() ...@@ -8,7 +8,7 @@ def_vars()
# This isn't really a target... # This isn't really a target...
set( PIXMAPS list( APPEND PIXMAPS
${_SRCDIR}/gnome-mime-application-x-audacity-project.xpm ${_SRCDIR}/gnome-mime-application-x-audacity-project.xpm
${_SRCDIR}/icons/16x16/audacity16.xpm ${_SRCDIR}/icons/16x16/audacity16.xpm
${_SRCDIR}/icons/32x32/audacity32.xpm ${_SRCDIR}/icons/32x32/audacity32.xpm
......
...@@ -4,7 +4,7 @@ add_library( ${TARGET} STATIC ) ...@@ -4,7 +4,7 @@ add_library( ${TARGET} STATIC )
def_vars() def_vars()
set( SOURCES list( APPEND SOURCES
PRIVATE PRIVATE
# libnyquist # libnyquist
...@@ -263,7 +263,7 @@ set( SOURCES ...@@ -263,7 +263,7 @@ set( SOURCES
nyquist/xlisp/xlsys.c nyquist/xlisp/xlsys.c
) )
set( INCLUDES list( APPEND INCLUDES
PRIVATE PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/nyquist/cmt ${CMAKE_CURRENT_SOURCE_DIR}/nyquist/cmt
${CMAKE_CURRENT_SOURCE_DIR}/nyquist/cmupv/src ${CMAKE_CURRENT_SOURCE_DIR}/nyquist/cmupv/src
...@@ -279,7 +279,7 @@ set( INCLUDES ...@@ -279,7 +279,7 @@ set( INCLUDES
${CMAKE_CURRENT_SOURCE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}
) )
set( DEFINES list( APPEND DEFINES
PUBLIC PUBLIC
USE_NYQUIST=1 USE_NYQUIST=1
PRIVATE PRIVATE
...@@ -288,12 +288,12 @@ set( DEFINES ...@@ -288,12 +288,12 @@ set( DEFINES
$<$<PLATFORM_ID:Windows>:WIN32> $<$<PLATFORM_ID:Windows>:WIN32>
) )
set( OPTIONS list( APPEND OPTIONS
PRIVATE PRIVATE
$<$<PLATFORM_ID:Darwin>:-fno-common> $<$<PLATFORM_ID:Darwin>:-fno-common>
) )
set( LIBRARIES list( APPEND LIBRARIES
PRIVATE PRIVATE
portaudio::portaudio portaudio::portaudio
SndFile::sndfile SndFile::sndfile
......
...@@ -38,7 +38,7 @@ elseif( WIN32 ) ...@@ -38,7 +38,7 @@ elseif( WIN32 )
) )
endif() endif()
set( SOURCES list( APPEND SOURCES
PRIVATE PRIVATE
include/portmixer.h include/portmixer.h
...@@ -71,14 +71,14 @@ set( SOURCES ...@@ -71,14 +71,14 @@ set( SOURCES
> >
) )
set( INCLUDES list( APPEND INCLUDES
PRIVATE PRIVATE
src src
PUBLIC PUBLIC
include include
) )
set( DEFINES list( APPEND DEFINES
PUBLIC PUBLIC
USE_PORTMIXER=1 USE_PORTMIXER=1
PRIVATE PRIVATE
...@@ -109,7 +109,7 @@ set( DEFINES ...@@ -109,7 +109,7 @@ set( DEFINES
> >
) )
set( LIBRARIES list( APPEND LIBRARIES
PRIVATE PRIVATE
portaudio::portaudio portaudio::portaudio
) )
......
#[[
A directory containing library targets
]]
# Include the libraries that we'll build # Include the libraries that we'll build
# The list of modules is ordered so that each library occurs after any others # The list of modules is ordered so that each library occurs after any others
...@@ -41,7 +37,6 @@ set( LIBRARIES ...@@ -41,7 +37,6 @@ set( LIBRARIES
lib-realtime-effects lib-realtime-effects
lib-audio-io lib-audio-io
lib-wave-track lib-wave-track
lib-wave-track-paint
lib-track-selection lib-track-selection
lib-project-file-io lib-project-file-io
lib-command-parameters lib-command-parameters
...@@ -70,7 +65,6 @@ set( LIBRARIES ...@@ -70,7 +65,6 @@ set( LIBRARIES
lib-fft lib-fft
lib-concurrency lib-concurrency
lib-sqlite-helpers lib-sqlite-helpers
lib-preference-pages
) )
if ( ${_OPT}use_lv2 ) if ( ${_OPT}use_lv2 )
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
A small program that is run at build time of the application. For each built-in A small program that is run at build time of the application. For each built-in
theme it generates a header file from image files. The images are part of the theme it generates a header file from image files. The images are part of the
source code tree but not deployed with the program. source code tree but not deployed with the program.
]] ]]#
if( NOT IMAGE_COMPILER_EXECUTABLE ) if( NOT IMAGE_COMPILER_EXECUTABLE )
add_executable( image-compiler imageCompilerMain.cpp ) add_executable( image-compiler imageCompilerMain.cpp )
......
...@@ -76,6 +76,8 @@ bool App::OnInit() ...@@ -76,6 +76,8 @@ bool App::OnInit()
{ {
// Leave no persistent side-effect on preferences // Leave no persistent side-effect on preferences
SettingScope scope; SettingScope scope;
// Don't blend colors
GUIBlendThemes.Write(false);
// So that the program can interpret PNG // So that the program can interpret PNG
wxInitAllImageHandlers(); wxInitAllImageHandlers();
......
...@@ -8,7 +8,7 @@ Also abstract class Meter for communicating buffers of samples for display ...@@ -8,7 +8,7 @@ Also abstract class Meter for communicating buffers of samples for display
purposes. purposes.
Does not contain an audio engine. Does not contain an audio engine.
]] ]]#
set( SOURCES set( SOURCES
AudioIOBase.cpp AudioIOBase.cpp
......
...@@ -275,6 +275,12 @@ void DeviceManager::Rescan() ...@@ -275,6 +275,12 @@ void DeviceManager::Rescan()
} }
if (info->maxInputChannels > 0) { if (info->maxInputChannels > 0) {
#ifdef __WXMSW__
#if !defined(EXPERIMENTAL_FULL_WASAPI)
if (Pa_GetHostApiInfo(info->hostApi)->type != paWASAPI ||
PaWasapi_IsLoopback(i) > 0)
#endif
#endif
AddSources(i, info->defaultSampleRate, &mInputDeviceSourceMaps, 1); AddSources(i, info->defaultSampleRate, &mInputDeviceSourceMaps, 1);
} }
} }
......
...@@ -141,10 +141,10 @@ struct AudioIoCallback::TransportState { ...@@ -141,10 +141,10 @@ struct AudioIoCallback::TransportState {
move(wOwningProject), sampleRate, numPlaybackChannels); move(wOwningProject), sampleRate, numPlaybackChannels);
// The following adds a new effect processor for each logical sequence. // The following adds a new effect processor for each logical sequence.
for (size_t i = 0, cnt = playbackSequences.size(); i < cnt; ++i) { for (size_t i = 0, cnt = playbackSequences.size(); i < cnt; ++i) {
// An array only of non-null pointers should be given to us // An array only of non-null leaders should be given to us
const auto vt = playbackSequences[i].get(); const auto vt = playbackSequences[i].get();
const auto pGroup = vt ? vt->FindChannelGroup() : nullptr; const auto pGroup = vt ? vt->FindChannelGroup() : nullptr;
if (!pGroup) { if (!(pGroup && pGroup->IsLeader())) {
assert(false); assert(false);
continue; continue;
} }
...@@ -347,6 +347,7 @@ std::shared_ptr<RealtimeEffectState> ...@@ -347,6 +347,7 @@ std::shared_ptr<RealtimeEffectState>
AudioIO::AddState(AudacityProject &project, AudioIO::AddState(AudacityProject &project,
ChannelGroup *pGroup, const PluginID & id) ChannelGroup *pGroup, const PluginID & id)
{ {
assert(!pGroup || pGroup->IsLeader());
RealtimeEffects::InitializationScope *pInit = nullptr; RealtimeEffects::InitializationScope *pInit = nullptr;
if (mpTransportState && mpTransportState->mpRealtimeInitialization) if (mpTransportState && mpTransportState->mpRealtimeInitialization)
if (auto pProject = GetOwningProject(); pProject.get() == &project) if (auto pProject = GetOwningProject(); pProject.get() == &project)
...@@ -358,6 +359,7 @@ std::shared_ptr<RealtimeEffectState> ...@@ -358,6 +359,7 @@ std::shared_ptr<RealtimeEffectState>
AudioIO::ReplaceState(AudacityProject &project, AudioIO::ReplaceState(AudacityProject &project,
ChannelGroup *pGroup, size_t index, const PluginID & id) ChannelGroup *pGroup, size_t index, const PluginID & id)
{ {
assert(!pGroup || pGroup->IsLeader());
RealtimeEffects::InitializationScope *pInit = nullptr; RealtimeEffects::InitializationScope *pInit = nullptr;
if (mpTransportState && mpTransportState->mpRealtimeInitialization) if (mpTransportState && mpTransportState->mpRealtimeInitialization)
if (auto pProject = GetOwningProject(); pProject.get() == &project) if (auto pProject = GetOwningProject(); pProject.get() == &project)
...@@ -832,7 +834,7 @@ int AudioIO::StartStream(const TransportSequences &sequences, ...@@ -832,7 +834,7 @@ int AudioIO::StartStream(const TransportSequences &sequences,
[](const auto &pSequence){ [](const auto &pSequence){
const auto pGroup = const auto pGroup =
pSequence ? pSequence->FindChannelGroup() : nullptr; pSequence ? pSequence->FindChannelGroup() : nullptr;
return pGroup; } return pGroup && pGroup->IsLeader(); }
)); ));
const auto &pStartTime = options.pStartTime; const auto &pStartTime = options.pStartTime;
...@@ -982,6 +984,7 @@ int AudioIO::StartStream(const TransportSequences &sequences, ...@@ -982,6 +984,7 @@ int AudioIO::StartStream(const TransportSequences &sequences,
// previous call. // previous call.
mPlaybackSchedule.GetPolicy().Initialize( mPlaybackSchedule, mRate ); mPlaybackSchedule.GetPolicy().Initialize( mPlaybackSchedule, mRate );
#ifdef EXPERIMENTAL_MIDI_OUT
auto range = Extensions(); auto range = Extensions();
successAudio = successAudio && successAudio = successAudio &&
std::all_of(range.begin(), range.end(), std::all_of(range.begin(), range.end(),
...@@ -990,6 +993,7 @@ int AudioIO::StartStream(const TransportSequences &sequences, ...@@ -990,6 +993,7 @@ int AudioIO::StartStream(const TransportSequences &sequences,
(mPortStreamV19 != NULL && mLastPaError == paNoError) (mPortStreamV19 != NULL && mLastPaError == paNoError)
? Pa_GetStreamInfo(mPortStreamV19) : nullptr, ? Pa_GetStreamInfo(mPortStreamV19) : nullptr,
t0, mRate ); }); t0, mRate ); });
#endif
if (!successAudio) { if (!successAudio) {
if (pListener && numCaptureChannels > 0) if (pListener && numCaptureChannels > 0)
...@@ -1286,6 +1290,7 @@ bool AudioIO::AllocateBuffers( ...@@ -1286,6 +1290,7 @@ bool AudioIO::AllocateBuffers(
// By the precondition of StartStream which is sole caller of // By the precondition of StartStream which is sole caller of
// this function: // this function:
assert(pSequence->FindChannelGroup()); assert(pSequence->FindChannelGroup());
assert(pSequence->FindChannelGroup()->IsLeader());
// use sequence time for the end time, not real time! // use sequence time for the end time, not real time!
double startTime, endTime; double startTime, endTime;
if (!sequences.prerollSequences.empty()) if (!sequences.prerollSequences.empty())
...@@ -2137,8 +2142,6 @@ void AudioIO::DrainRecordBuffers() ...@@ -2137,8 +2142,6 @@ void AudioIO::DrainRecordBuffers()
// boxes. // boxes.
StopStream(); StopStream();
DefaultDelayedHandlerAction( pException ); DefaultDelayedHandlerAction( pException );
for (auto &pSequence: mCaptureSequences)
pSequence->RepairChannels();
}; };
GuardedCall( [&] { GuardedCall( [&] {
...@@ -2183,9 +2186,9 @@ void AudioIO::DrainRecordBuffers() ...@@ -2183,9 +2186,9 @@ void AudioIO::DrainRecordBuffers()
size_t size = floor( correction * mRate * mFactor); size_t size = floor( correction * mRate * mFactor);
SampleBuffer temp(size, mCaptureFormat); SampleBuffer temp(size, mCaptureFormat);
ClearSamples(temp.ptr(), mCaptureFormat, 0, size); ClearSamples(temp.ptr(), mCaptureFormat, 0, size);
(*iter)->Append(iChannel, temp.ptr(), mCaptureFormat, size, 1, (*iter)->Append(temp.ptr(), mCaptureFormat, size, 1,
// Do not dither recordings // Do not dither recordings
narrowestSampleFormat); narrowestSampleFormat, iChannel);
} }
else { else {
// Leftward shift // Leftward shift
...@@ -2288,10 +2291,10 @@ void AudioIO::DrainRecordBuffers() ...@@ -2288,10 +2291,10 @@ void AudioIO::DrainRecordBuffers()
// Now append // Now append
// see comment in second handler about guarantee // see comment in second handler about guarantee
newBlocks = (*iter)->Append(iChannel, newBlocks = (*iter)->Append(
temp.ptr(), format, size, 1, temp.ptr(), format, size, 1,
// Do not dither recordings // Do not dither recordings
narrowestSampleFormat narrowestSampleFormat, iChannel
) || newBlocks; ) || newBlocks;
} // end loop over capture channels } // end loop over capture channels
......
...@@ -433,6 +433,7 @@ public: ...@@ -433,6 +433,7 @@ public:
//! Forwards to RealtimeEffectManager::AddState with proper init scope //! Forwards to RealtimeEffectManager::AddState with proper init scope
/*! /*!
@pre `!pGroup || pGroup->IsLeader()`
@post result: `!result || result->GetEffect() != nullptr` @post result: `!result || result->GetEffect() != nullptr`
*/ */
std::shared_ptr<RealtimeEffectState> std::shared_ptr<RealtimeEffectState>
...@@ -441,6 +442,7 @@ public: ...@@ -441,6 +442,7 @@ public:
//! Forwards to RealtimeEffectManager::ReplaceState with proper init scope //! Forwards to RealtimeEffectManager::ReplaceState with proper init scope
/*! /*!
@pre `!pGroup || pGroup->IsLeader()`
@post result: `!result || result->GetEffect() != nullptr` @post result: `!result || result->GetEffect() != nullptr`
*/ */
std::shared_ptr<RealtimeEffectState> std::shared_ptr<RealtimeEffectState>
...@@ -468,9 +470,10 @@ public: ...@@ -468,9 +470,10 @@ public:
* If successful, returns a token identifying this particular stream * If successful, returns a token identifying this particular stream
* instance. For use with IsStreamActive() * instance. For use with IsStreamActive()
* *
* @pre `p && p->FindChannelGroup()` for all pointers `p` in * @pre `p && p->FindChannelGroup() &&
* p->FindChannelGroup()->IsLeader()` for all pointers `p` in
* `sequences.playbackSequences` * `sequences.playbackSequences`
* @pre `p != nullptr` for all pointers `p` in * @pre `p && p->IsLeader()` for all pointers `p` in
* `sequences.captureSequences` * `sequences.captureSequences`
*/ */
......
...@@ -31,21 +31,16 @@ class EffectSettings; ...@@ -31,21 +31,16 @@ class EffectSettings;
class TranslatableString; class TranslatableString;
class AudioUnitWrapper; class AudioUnitWrapper;
/** //! This works as a cached copy of state stored in an AudioUnit, but can also
* @struct AudioUnitEffectSettings //! outlive it
* @brief Represents a cached copy of the state stored in an AudioUnit, but can outlive the original AudioUnit.
*
* This structure handles the storage and management of settings and state information for AudioUnit effects.
* It provides mechanisms for sharing settings between different instances and managing preset configurations.
*/
struct AudioUnitEffectSettings { struct AudioUnitEffectSettings {
/** //! The effect object and all Settings objects coming from it share this
* @brief Shared set of strings to optimize memory usage by avoiding repeated allocations. //! set of strings, which allows Pair below to copy without allocations.
* /*!
* All instances of AudioUnitEffectSettings share this set to reduce memory overhead and ensure consistency. Note that names associated with parameter IDs are not invariant metadata
* The effect object and all Settings objects coming from it share this set of strings. of an AudioUnit effect! The names can themselves depend on the current
* Note: The names associated with parameter IDs are not invariant metadata of an AudioUnit effect. values. Example: AUGraphicEQ changes names of slider parameters when you
* For example, AUGraphicEQ changes names of slider parameters when you switch between 10 and 31 bands. change the switch between 10 and 31 bands.
*/ */
using StringSet = std::set<wxString>; using StringSet = std::set<wxString>;
const std::shared_ptr<StringSet> mSharedNames{ const std::shared_ptr<StringSet> mSharedNames{
...@@ -80,12 +75,10 @@ struct AudioUnitEffectSettings { ...@@ -80,12 +75,10 @@ struct AudioUnitEffectSettings {
} }
}; };
/** //! Common base class for AudioUnitEffect and its Instance
* @class AudioUnitWrapper /*!
* @brief Manages and interacts with an AudioUnit, providing operations on audio effects. Maintains a smart handle to an AudioUnit (also called AudioComponentInstance)
* in the SDK and defines some utility functions
* This class hosts the functionality for managing AudioUnit settings, presets, and parameters,
* allowing manipulation of audio processing units.
*/ */
struct AudioUnitWrapper struct AudioUnitWrapper
{ {
...@@ -199,10 +192,6 @@ protected: ...@@ -199,10 +192,6 @@ protected:
unsigned mAudioOuts{ 2 }; unsigned mAudioOuts{ 2 };
}; };
/**
* @class AudioUnitWrapper::ParameterInfo
* @brief Encapsulates parameter information for an AudioUnit.
* */
class AudioUnitWrapper::ParameterInfo final class AudioUnitWrapper::ParameterInfo final
{ {
public: public:
......
#[[ #[[
AudioUnit effect processing logic, minus user interface AudioUnit effect processing logic, minus user interface
]] ]]#
if (USE_AUDIO_UNITS) if (USE_AUDIO_UNITS)
......
...@@ -12,11 +12,9 @@ Paul Licameli ...@@ -12,11 +12,9 @@ Paul Licameli
#include <mutex> #include <mutex>
#include <vector> #include <vector>
#if (defined(__linux__) && !defined(__ANDROID__)) || defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) #define HAS_XDG_OPEN_HELPER (defined(__linux__) && !defined __ANDROID__) || defined (__FreeBSD__) || defined (__NetBSD__) || defined(__OpenBSD__)
#define HAS_XDG_OPEN_HELPER
#endif
#if defined(HAS_XDG_OPEN_HELPER) #if HAS_XDG_OPEN_HELPER
#include <sys/types.h> #include <sys/types.h>
#include <sys/wait.h> #include <sys/wait.h>
...@@ -31,10 +29,11 @@ Paul Licameli ...@@ -31,10 +29,11 @@ Paul Licameli
#include <string> #include <string>
#if defined(__FreeBSD__) || defined(__OpenBSD__) #ifdef __FreeBSD__
extern char** environ; extern char** environ;
#endif #endif
namespace namespace
{ {
...@@ -245,7 +244,7 @@ void Yield() ...@@ -245,7 +244,7 @@ void Yield()
bool OpenInDefaultBrowser(const wxString &url) bool OpenInDefaultBrowser(const wxString &url)
{ {
#if defined(HAS_XDG_OPEN_HELPER) #if HAS_XDG_OPEN_HELPER
if (RunXDGOpen(url.ToStdString())) if (RunXDGOpen(url.ToStdString()))
return true; return true;
#endif #endif
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment