diff --git a/src/sound/CMakeLists.txt b/src/sound/CMakeLists.txt index 1da1a5dfc..faef42193 100644 --- a/src/sound/CMakeLists.txt +++ b/src/sound/CMakeLists.txt @@ -8,19 +8,6 @@ add_library(sound SHARED codecs/opusdecoder.h codecs/opusencoder.cpp codecs/opusencoder.h - dsp/SimpleComp.cpp - dsp/SimpleComp.h - dsp/SimpleCompProcess.inl - dsp/SimpleEnvelope.cpp - dsp/SimpleEnvelope.h - dsp/SimpleGain.h - dsp/SimpleGate.cpp - dsp/SimpleGate.h - dsp/SimpleGateProcess.inl - dsp/SimpleHeader.h - dsp/SimpleLimit.cpp - dsp/SimpleLimit.h - dsp/SimpleLimitProcess.inl dsp/biquadfilter.cpp dsp/biquadfilter.h notificationplayer.cpp @@ -76,6 +63,7 @@ target_link_libraries(sound Qt::Multimedia misc Opus::opus + ChunkwareDsp ) install(TARGETS sound diff --git a/src/sound/sampleprovider/simplecompressoreffect.h b/src/sound/sampleprovider/simplecompressoreffect.h index 879a9e180..f84dd55ca 100644 --- a/src/sound/sampleprovider/simplecompressoreffect.h +++ b/src/sound/sampleprovider/simplecompressoreffect.h @@ -9,7 +9,8 @@ #include #include -#include "sound/dsp/SimpleComp.h" +#include "chunkware_dsp/SimpleComp.h" + #include "sound/sampleprovider/sampleprovider.h" #include "sound/swiftsoundexport.h" diff --git a/third_party/CMakeLists.txt b/third_party/CMakeLists.txt index 122731948..922a90fd4 100644 --- a/third_party/CMakeLists.txt +++ b/third_party/CMakeLists.txt @@ -1,6 +1,7 @@ # SPDX-FileCopyrightText: Copyright (C) swift Project Community / Contributors # SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1 +add_subdirectory(chunkware_dsp) add_subdirectory(simplecrypt) add_subdirectory(qjsonwebtoken) add_subdirectory(cmake/msgpack EXCLUDE_FROM_ALL SYSTEM) diff --git a/third_party/chunkware_dsp/CMakeLists.txt b/third_party/chunkware_dsp/CMakeLists.txt new file mode 100644 index 000000000..df73961b2 --- /dev/null +++ b/third_party/chunkware_dsp/CMakeLists.txt @@ -0,0 +1,29 @@ +# SPDX-FileCopyrightText: Copyright (C) swift Project Community / Contributors +# SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1 + +add_library(ChunkwareDsp STATIC) +target_sources(ChunkwareDsp + PRIVATE + SimpleComp.cpp + SimpleComp.h + SimpleCompProcess.inl + SimpleEnvelope.cpp + SimpleEnvelope.h + SimpleGain.h + SimpleGate.cpp + SimpleGate.h + SimpleGateProcess.inl + SimpleHeader.h + SimpleLimit.cpp + SimpleLimit.h + SimpleLimitProcess.inl +) +target_include_directories(ChunkwareDsp + PUBLIC + ${PROJECT_SOURCE_DIR}/third_party +) +set_property(TARGET ChunkwareDsp PROPERTY POSITION_INDEPENDENT_CODE ON) +set_source_files_properties(SimpleComp.cpp PROPERTIES SKIP_LINTING ON) +set_source_files_properties(SimpleEnvelope.cpp PROPERTIES SKIP_LINTING ON) +set_source_files_properties(SimpleGate.cpp PROPERTIES SKIP_LINTING ON) +set_source_files_properties(SimpleLimit.cpp PROPERTIES SKIP_LINTING ON) diff --git a/src/sound/dsp/SimpleComp.cpp b/third_party/chunkware_dsp/SimpleComp.cpp similarity index 100% rename from src/sound/dsp/SimpleComp.cpp rename to third_party/chunkware_dsp/SimpleComp.cpp diff --git a/src/sound/dsp/SimpleComp.cpp.license b/third_party/chunkware_dsp/SimpleComp.cpp.license similarity index 100% rename from src/sound/dsp/SimpleComp.cpp.license rename to third_party/chunkware_dsp/SimpleComp.cpp.license diff --git a/src/sound/dsp/SimpleComp.h b/third_party/chunkware_dsp/SimpleComp.h similarity index 95% rename from src/sound/dsp/SimpleComp.h rename to third_party/chunkware_dsp/SimpleComp.h index 078b91202..30c5bb4b0 100644 --- a/src/sound/dsp/SimpleComp.h +++ b/third_party/chunkware_dsp/SimpleComp.h @@ -30,9 +30,9 @@ #ifndef chunkware_simple_SIMPLE_COMP_H #define chunkware_simple_SIMPLE_COMP_H -#include "SimpleHeader.h" // common header -#include "SimpleEnvelope.h" // for base class -#include "SimpleGain.h" // for gain functions +#include "chunkware_dsp/SimpleEnvelope.h" +#include "chunkware_dsp/SimpleGain.h" +#include "chunkware_dsp/SimpleHeader.h" namespace chunkware_simple { diff --git a/src/sound/dsp/SimpleComp.h.license b/third_party/chunkware_dsp/SimpleComp.h.license similarity index 100% rename from src/sound/dsp/SimpleComp.h.license rename to third_party/chunkware_dsp/SimpleComp.h.license diff --git a/src/sound/dsp/SimpleCompProcess.inl b/third_party/chunkware_dsp/SimpleCompProcess.inl similarity index 100% rename from src/sound/dsp/SimpleCompProcess.inl rename to third_party/chunkware_dsp/SimpleCompProcess.inl diff --git a/src/sound/dsp/SimpleCompProcess.inl.license b/third_party/chunkware_dsp/SimpleCompProcess.inl.license similarity index 100% rename from src/sound/dsp/SimpleCompProcess.inl.license rename to third_party/chunkware_dsp/SimpleCompProcess.inl.license diff --git a/src/sound/dsp/SimpleEnvelope.cpp b/third_party/chunkware_dsp/SimpleEnvelope.cpp similarity index 100% rename from src/sound/dsp/SimpleEnvelope.cpp rename to third_party/chunkware_dsp/SimpleEnvelope.cpp diff --git a/src/sound/dsp/SimpleEnvelope.cpp.license b/third_party/chunkware_dsp/SimpleEnvelope.cpp.license similarity index 100% rename from src/sound/dsp/SimpleEnvelope.cpp.license rename to third_party/chunkware_dsp/SimpleEnvelope.cpp.license diff --git a/src/sound/dsp/SimpleEnvelope.h b/third_party/chunkware_dsp/SimpleEnvelope.h similarity index 98% rename from src/sound/dsp/SimpleEnvelope.h rename to third_party/chunkware_dsp/SimpleEnvelope.h index ee11cb0e2..d0c014395 100644 --- a/src/sound/dsp/SimpleEnvelope.h +++ b/third_party/chunkware_dsp/SimpleEnvelope.h @@ -31,7 +31,7 @@ #ifndef __SIMPLE_ENVELOPE_H__ #define __SIMPLE_ENVELOPE_H__ -#include "SimpleHeader.h" // common header +#include "SimpleHeader.h" namespace chunkware_simple { diff --git a/src/sound/dsp/SimpleEnvelope.h.license b/third_party/chunkware_dsp/SimpleEnvelope.h.license similarity index 100% rename from src/sound/dsp/SimpleEnvelope.h.license rename to third_party/chunkware_dsp/SimpleEnvelope.h.license diff --git a/src/sound/dsp/SimpleGain.h b/third_party/chunkware_dsp/SimpleGain.h similarity index 100% rename from src/sound/dsp/SimpleGain.h rename to third_party/chunkware_dsp/SimpleGain.h diff --git a/src/sound/dsp/SimpleGain.h.license b/third_party/chunkware_dsp/SimpleGain.h.license similarity index 100% rename from src/sound/dsp/SimpleGain.h.license rename to third_party/chunkware_dsp/SimpleGain.h.license diff --git a/src/sound/dsp/SimpleGate.cpp b/third_party/chunkware_dsp/SimpleGate.cpp similarity index 100% rename from src/sound/dsp/SimpleGate.cpp rename to third_party/chunkware_dsp/SimpleGate.cpp diff --git a/src/sound/dsp/SimpleGate.cpp.license b/third_party/chunkware_dsp/SimpleGate.cpp.license similarity index 100% rename from src/sound/dsp/SimpleGate.cpp.license rename to third_party/chunkware_dsp/SimpleGate.cpp.license diff --git a/src/sound/dsp/SimpleGate.h b/third_party/chunkware_dsp/SimpleGate.h similarity index 95% rename from src/sound/dsp/SimpleGate.h rename to third_party/chunkware_dsp/SimpleGate.h index a469dfc5c..1a4844b67 100644 --- a/src/sound/dsp/SimpleGate.h +++ b/third_party/chunkware_dsp/SimpleGate.h @@ -31,9 +31,9 @@ #ifndef chunkware__SIMPLE_GATE_H #define chunkware__SIMPLE_GATE_H -#include "SimpleHeader.h" // common header -#include "SimpleEnvelope.h" // for base class -#include "SimpleGain.h" // for gain functions +#include "chunkware_dsp/SimpleEnvelope.h" +#include "chunkware_dsp/SimpleGain.h" // for gain functions +#include "chunkware_dsp/SimpleHeader.h" // common header namespace chunkware_simple { diff --git a/src/sound/dsp/SimpleGate.h.license b/third_party/chunkware_dsp/SimpleGate.h.license similarity index 100% rename from src/sound/dsp/SimpleGate.h.license rename to third_party/chunkware_dsp/SimpleGate.h.license diff --git a/src/sound/dsp/SimpleGateProcess.inl b/third_party/chunkware_dsp/SimpleGateProcess.inl similarity index 100% rename from src/sound/dsp/SimpleGateProcess.inl rename to third_party/chunkware_dsp/SimpleGateProcess.inl diff --git a/src/sound/dsp/SimpleGateProcess.inl.license b/third_party/chunkware_dsp/SimpleGateProcess.inl.license similarity index 100% rename from src/sound/dsp/SimpleGateProcess.inl.license rename to third_party/chunkware_dsp/SimpleGateProcess.inl.license diff --git a/src/sound/dsp/SimpleHeader.h b/third_party/chunkware_dsp/SimpleHeader.h similarity index 100% rename from src/sound/dsp/SimpleHeader.h rename to third_party/chunkware_dsp/SimpleHeader.h diff --git a/src/sound/dsp/SimpleHeader.h.license b/third_party/chunkware_dsp/SimpleHeader.h.license similarity index 100% rename from src/sound/dsp/SimpleHeader.h.license rename to third_party/chunkware_dsp/SimpleHeader.h.license diff --git a/src/sound/dsp/SimpleLimit.cpp b/third_party/chunkware_dsp/SimpleLimit.cpp similarity index 100% rename from src/sound/dsp/SimpleLimit.cpp rename to third_party/chunkware_dsp/SimpleLimit.cpp diff --git a/src/sound/dsp/SimpleLimit.cpp.license b/third_party/chunkware_dsp/SimpleLimit.cpp.license similarity index 100% rename from src/sound/dsp/SimpleLimit.cpp.license rename to third_party/chunkware_dsp/SimpleLimit.cpp.license diff --git a/src/sound/dsp/SimpleLimit.h b/third_party/chunkware_dsp/SimpleLimit.h similarity index 95% rename from src/sound/dsp/SimpleLimit.h rename to third_party/chunkware_dsp/SimpleLimit.h index 65320cc11..4a839d2fe 100644 --- a/src/sound/dsp/SimpleLimit.h +++ b/third_party/chunkware_dsp/SimpleLimit.h @@ -31,9 +31,9 @@ #ifndef chunkware_SIMPLE_LIMIT_H #define chunkware_SIMPLE_LIMIT_H -#include "SimpleHeader.h" // common header -#include "SimpleEnvelope.h" // for base class of FastEnvelope -#include "SimpleGain.h" // for gain functions +#include "chunkware_dsp/SimpleHeader.h" // common header +#include "chunkware_dsp/SimpleEnvelope.h" // for base class of FastEnvelope +#include "chunkware_dsp/SimpleGain.h" // for gain functions #include namespace chunkware_simple diff --git a/src/sound/dsp/SimpleLimit.h.license b/third_party/chunkware_dsp/SimpleLimit.h.license similarity index 100% rename from src/sound/dsp/SimpleLimit.h.license rename to third_party/chunkware_dsp/SimpleLimit.h.license diff --git a/src/sound/dsp/SimpleLimitProcess.inl b/third_party/chunkware_dsp/SimpleLimitProcess.inl similarity index 100% rename from src/sound/dsp/SimpleLimitProcess.inl rename to third_party/chunkware_dsp/SimpleLimitProcess.inl diff --git a/src/sound/dsp/SimpleLimitProcess.inl.license b/third_party/chunkware_dsp/SimpleLimitProcess.inl.license similarity index 100% rename from src/sound/dsp/SimpleLimitProcess.inl.license rename to third_party/chunkware_dsp/SimpleLimitProcess.inl.license