-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Updated build scripts and dependencies.
- Loading branch information
Showing
22 changed files
with
592 additions
and
244 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
/* | ||
* Copyright (C) 2021 Linux Studio Plugins Project <https://lsp-plug.in/> | ||
* (C) 2021 Vladimir Sadovnikov <[email protected]> | ||
* Copyright (C) 2024 Linux Studio Plugins Project <https://lsp-plug.in/> | ||
* (C) 2024 Vladimir Sadovnikov <[email protected]> | ||
* | ||
* This file is part of lsp-plugins-spectrum-analyzer | ||
* Created on: 22 июн. 2021 г. | ||
|
@@ -38,11 +38,12 @@ namespace lsp | |
static constexpr float FREQ_MIN = SPEC_FREQ_MIN; | ||
static constexpr float FREQ_DFL = 1000.0f; | ||
static constexpr float FREQ_MAX = SPEC_FREQ_MAX; | ||
static constexpr float CORR_PERIOD = 100.0f; | ||
|
||
static constexpr size_t PORTS_PER_INPUT = 6; | ||
static constexpr size_t RANK_MIN = 10; | ||
static constexpr size_t RANK_DFL = 12; | ||
static constexpr size_t RANK_MAX = 14; | ||
static constexpr size_t RANK_MAX = 15; | ||
static constexpr size_t MESH_POINTS = 640; | ||
|
||
static constexpr float THRESH_HI_DB = 0.0f; | ||
|
@@ -64,6 +65,11 @@ namespace lsp | |
static constexpr float SELECTOR_MAX = SPEC_FREQ_MAX; | ||
static constexpr float SELECTOR_STEP = 0.005f; | ||
|
||
static constexpr float CORRELATION_MIN = -100.0f; | ||
static constexpr float CORRELATION_MAX = 100.0f; | ||
static constexpr float CORRELATION_DFL = 0.0f; | ||
static constexpr float CORRELATION_STEP = 0.1f; | ||
|
||
static constexpr float HLINE_MIN = GAIN_AMP_M_72_DB; | ||
static constexpr float HLINE_DFL = GAIN_AMP_0_DB; | ||
static constexpr float HLINE_MAX = GAIN_AMP_P_24_DB; | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
/* | ||
* Copyright (C) 2023 Linux Studio Plugins Project <https://lsp-plug.in/> | ||
* (C) 2023 Vladimir Sadovnikov <[email protected]> | ||
* Copyright (C) 2024 Linux Studio Plugins Project <https://lsp-plug.in/> | ||
* (C) 2024 Vladimir Sadovnikov <[email protected]> | ||
* | ||
* This file is part of lsp-plugins-spectrum-analyzer | ||
* Created on: 22 июн. 2021 г. | ||
|
@@ -23,6 +23,7 @@ | |
#define PRIVATE_PLUGINS_SPECTRUM_ANALYZER_H_ | ||
|
||
#include <lsp-plug.in/dsp-units/ctl/Counter.h> | ||
#include <lsp-plug.in/dsp-units/meters/Correlometer.h> | ||
#include <lsp-plug.in/dsp-units/util/Analyzer.h> | ||
#include <lsp-plug.in/plug-fw/plug.h> | ||
#include <lsp-plug.in/plug-fw/core/IDBuffer.h> | ||
|
@@ -62,13 +63,20 @@ namespace lsp | |
|
||
typedef struct sa_spectralizer_t | ||
{ | ||
ssize_t nPortId; // Last port identifier | ||
ssize_t nChannelId; // Channel identifier | ||
int32_t nPortId; // Last port identifier | ||
int32_t nChannelId; // Channel identifier | ||
|
||
plug::IPort *pPortId; // Port identifier | ||
plug::IPort *pFBuffer; // Frame buffer port | ||
} sa_spectralizer_t; | ||
|
||
typedef struct sa_correlometer_t | ||
{ | ||
dspu::Correlometer sCorr; // Correlometer | ||
float fCorrelation; // Measured correlation value | ||
plug::IPort *pCorrelometer; // Correlometer output value | ||
} sa_correlometer_t; | ||
|
||
enum mode_t | ||
{ | ||
SA_ANALYZER, | ||
|
@@ -90,8 +98,10 @@ namespace lsp | |
protected: | ||
dspu::Analyzer sAnalyzer; | ||
dspu::Counter sCounter; | ||
size_t nChannels; | ||
uint32_t nChannels; | ||
uint32_t nCorrelometers; | ||
sa_channel_t *vChannels; | ||
sa_correlometer_t *vCorrelometers; // Available correlometers | ||
float **vAnalyze; // Analysis buffers | ||
float *vFrequences; | ||
float *vMaxValues; // Maximum value tracking | ||
|
@@ -152,6 +162,7 @@ namespace lsp | |
void process_multiple(); | ||
void process_spectralizer(); | ||
void get_spectrum(float *dst, size_t channel, size_t flags); | ||
void measure_correlation(size_t count); | ||
void prepare_buffers(size_t count); | ||
|
||
public: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -19,93 +19,93 @@ | |
# | ||
|
||
# Variables that describe dependencies | ||
LSP_3RD_PARTY_VERSION := 1.0.15 | ||
LSP_3RD_PARTY_VERSION := 1.0.16 | ||
LSP_3RD_PARTY_NAME := lsp-3rd-party | ||
LSP_3RD_PARTY_TYPE := hdr | ||
LSP_3RD_PARTY_INC_OPT := -idirafter | ||
LSP_3RD_PARTY_URL_RO := https://github.com/lsp-plugins/$(LSP_3RD_PARTY_NAME).git | ||
LSP_3RD_PARTY_URL_RW := [email protected]:lsp-plugins/$(LSP_3RD_PARTY_NAME).git | ||
|
||
LSP_COMMON_LIB_VERSION := 1.0.34 | ||
LSP_COMMON_LIB_VERSION := 1.0.36 | ||
LSP_COMMON_LIB_NAME := lsp-common-lib | ||
LSP_COMMON_LIB_TYPE := src | ||
LSP_COMMON_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_COMMON_LIB_NAME).git | ||
LSP_COMMON_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_COMMON_LIB_NAME).git | ||
|
||
LSP_DSP_LIB_VERSION := 1.0.21 | ||
LSP_DSP_LIB_VERSION := 1.0.23 | ||
LSP_DSP_LIB_NAME := lsp-dsp-lib | ||
LSP_DSP_LIB_TYPE := src | ||
LSP_DSP_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_DSP_LIB_NAME).git | ||
LSP_DSP_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_DSP_LIB_NAME).git | ||
|
||
LSP_DSP_UNITS_VERSION := 1.0.20 | ||
LSP_DSP_UNITS_VERSION := 1.0.22 | ||
LSP_DSP_UNITS_NAME := lsp-dsp-units | ||
LSP_DSP_UNITS_TYPE := src | ||
LSP_DSP_UNITS_URL_RO := https://github.com/lsp-plugins/$(LSP_DSP_UNITS_NAME).git | ||
LSP_DSP_UNITS_URL_RW := [email protected]:lsp-plugins/$(LSP_DSP_UNITS_NAME).git | ||
|
||
LSP_LLTL_LIB_VERSION := 1.0.17 | ||
LSP_LLTL_LIB_VERSION := 1.0.19 | ||
LSP_LLTL_LIB_NAME := lsp-lltl-lib | ||
LSP_LLTL_LIB_TYPE := src | ||
LSP_LLTL_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_LLTL_LIB_NAME).git | ||
LSP_LLTL_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_LLTL_LIB_NAME).git | ||
|
||
LSP_R3D_BASE_LIB_VERSION := 1.0.17 | ||
LSP_R3D_BASE_LIB_VERSION := 1.0.18 | ||
LSP_R3D_BASE_LIB_NAME := lsp-r3d-base-lib | ||
LSP_R3D_BASE_LIB_TYPE := src | ||
LSP_R3D_BASE_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_BASE_LIB_NAME).git | ||
LSP_R3D_BASE_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_R3D_BASE_LIB_NAME).git | ||
|
||
LSP_R3D_IFACE_VERSION := 1.0.17 | ||
LSP_R3D_IFACE_VERSION := 1.0.18 | ||
LSP_R3D_IFACE_NAME := lsp-r3d-iface | ||
LSP_R3D_IFACE_TYPE := src | ||
LSP_R3D_IFACE_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_IFACE_NAME).git | ||
LSP_R3D_IFACE_URL_RW := [email protected]:lsp-plugins/$(LSP_R3D_IFACE_NAME).git | ||
|
||
LSP_R3D_GLX_LIB_VERSION := 1.0.17 | ||
LSP_R3D_GLX_LIB_VERSION := 1.0.18 | ||
LSP_R3D_GLX_LIB_NAME := lsp-r3d-glx-lib | ||
LSP_R3D_GLX_LIB_TYPE := bin | ||
LSP_R3D_GLX_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_GLX_LIB_NAME).git | ||
LSP_R3D_GLX_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_R3D_GLX_LIB_NAME).git | ||
|
||
LSP_R3D_WGL_LIB_VERSION := 1.0.12 | ||
LSP_R3D_WGL_LIB_VERSION := 1.0.13 | ||
LSP_R3D_WGL_LIB_NAME := lsp-r3d-wgl-lib | ||
LSP_R3D_WGL_LIB_TYPE := bin | ||
LSP_R3D_WGL_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_R3D_WGL_LIB_NAME).git | ||
LSP_R3D_WGL_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_R3D_WGL_LIB_NAME).git | ||
|
||
LSP_RUNTIME_LIB_VERSION := 1.0.20 | ||
LSP_RUNTIME_LIB_VERSION := 1.0.22 | ||
LSP_RUNTIME_LIB_NAME := lsp-runtime-lib | ||
LSP_RUNTIME_LIB_TYPE := src | ||
LSP_RUNTIME_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_RUNTIME_LIB_NAME).git | ||
LSP_RUNTIME_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_RUNTIME_LIB_NAME).git | ||
|
||
LSP_TEST_FW_VERSION := 1.0.24 | ||
LSP_TEST_FW_VERSION := 1.0.25 | ||
LSP_TEST_FW_NAME := lsp-test-fw | ||
LSP_TEST_FW_TYPE := src | ||
LSP_TEST_FW_URL_RO := https://github.com/lsp-plugins/$(LSP_TEST_FW_NAME).git | ||
LSP_TEST_FW_URL_RW := [email protected]:lsp-plugins/$(LSP_TEST_FW_NAME).git | ||
|
||
LSP_TK_LIB_VERSION := 1.0.20 | ||
LSP_TK_LIB_VERSION := 1.0.21 | ||
LSP_TK_LIB_NAME := lsp-tk-lib | ||
LSP_TK_LIB_TYPE := src | ||
LSP_TK_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_TK_LIB_NAME).git | ||
LSP_TK_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_TK_LIB_NAME).git | ||
|
||
LSP_WS_LIB_VERSION := 1.0.20 | ||
LSP_WS_LIB_VERSION := 1.0.21 | ||
LSP_WS_LIB_NAME := lsp-ws-lib | ||
LSP_WS_LIB_TYPE := src | ||
LSP_WS_LIB_URL_RO := https://github.com/lsp-plugins/$(LSP_WS_LIB_NAME).git | ||
LSP_WS_LIB_URL_RW := [email protected]:lsp-plugins/$(LSP_WS_LIB_NAME).git | ||
|
||
# Plugin-related module dependencies | ||
LSP_PLUGIN_FW_VERSION := 1.0.22 | ||
LSP_PLUGIN_FW_VERSION := 1.0.23 | ||
LSP_PLUGIN_FW_NAME := lsp-plugin-fw | ||
LSP_PLUGIN_FW_TYPE := src | ||
LSP_PLUGIN_FW_URL_RO := https://github.com/lsp-plugins/$(LSP_PLUGIN_FW_NAME).git | ||
LSP_PLUGIN_FW_URL_RW := [email protected]:lsp-plugins/$(LSP_PLUGIN_FW_NAME).git | ||
|
||
LSP_PLUGINS_SHARED_VERSION := 1.0.21 | ||
LSP_PLUGINS_SHARED_VERSION := 1.0.22 | ||
LSP_PLUGINS_SHARED_NAME := lsp-plugins-shared | ||
LSP_PLUGINS_SHARED_TYPE := src | ||
LSP_PLUGINS_SHARED_URL_RO := https://github.com/lsp-plugins/$(LSP_PLUGINS_SHARED_NAME).git | ||
|
@@ -154,15 +154,15 @@ LIBICONV_NAME := libiconv | |
LIBICONV_TYPE := opt | ||
LIBICONV_LDFLAGS := -liconv | ||
|
||
LIBJACK_VERSION := system | ||
LIBJACK_NAME := jack | ||
LIBJACK_TYPE := pkg | ||
|
||
LIBMPR_VERSION := system | ||
LIBMPR_NAME := libmpr | ||
LIBMPR_TYPE := opt | ||
LIBMPR_LDFLAGS := -lmpr | ||
|
||
LIBJACK_VERSION := system | ||
LIBJACK_NAME := jack | ||
LIBJACK_TYPE := pkg | ||
|
||
LIBMSACM_VERSION := system | ||
LIBMSACM_NAME := libmsacm | ||
LIBMSACM_TYPE := opt | ||
|
@@ -183,6 +183,11 @@ LIBPTHREAD_NAME := libpthread | |
LIBPTHREAD_TYPE := opt | ||
LIBPTHREAD_LDFLAGS := -lpthread | ||
|
||
LIBRT_VERSION := system | ||
LIBRT_NAME := librt | ||
LIBRT_TYPE := opt | ||
LIBRT_LDFLAGS := -lrt | ||
|
||
LIBSNDFILE_VERSION := system | ||
LIBSNDFILE_NAME := sndfile | ||
LIBSNDFILE_TYPE := pkg | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.