Skip to content

Commit

Permalink
Release 1.0.27
Browse files Browse the repository at this point in the history
* Added +12 dB compensation on measurement of the spectrum to match the amplitude
  of the pure sine wave on the graph.
* Updated build scripts and dependencies.
  • Loading branch information
sadko4u committed Oct 8, 2024
2 parents 7a343eb + 3dbd516 commit 1c445b8
Show file tree
Hide file tree
Showing 22 changed files with 280 additions and 194 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,11 @@
* RECENT CHANGES
*******************************************************************************

=== 1.0.27 ===
* Added +12 dB compensation on measurement of the spectrum to match the amplitude
of the pure sine wave on the graph.
* Updated build scripts and dependencies.

=== 1.0.26 ===
* Updated build scripts and dependencies.

Expand Down
3 changes: 3 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -141,10 +141,13 @@ help:
echo "Available FEATURES:"
echo " clap CLAP plugin format binaries"
echo " doc Generate standalone HTML documentation"
echo " gst GStreamer plugins"
echo " jack Standalone JACK plugins"
echo " ladspa LADSPA plugins"
echo " lv2 LV2 plugins"
echo " ui Build plugins with UI"
echo " vst2 VST 2.x plugin binaries"
echo " vst3 VST 3.x plugin binaries"
echo " xdg Desktop integration icons"


3 changes: 2 additions & 1 deletion include/private/meta/spectrum_analyzer.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ namespace lsp

static constexpr float THRESH_HI_DB = 0.0f;
static constexpr float THRESH_LO_DB = -48.0f;
static constexpr float SPECTRALIZER_BOOST = 16.0f;
static constexpr float SPECTRALIZER_BOOST = GAIN_AMP_P_24_DB;
static constexpr float ANALYZER_BOOST = GAIN_AMP_P_12_DB;
static constexpr size_t MMESH_STEP = 16;
static constexpr size_t WND_DFL = dspu::windows::HANN;
static constexpr size_t ENV_DFL = dspu::envelope::PINK_NOISE;
Expand Down
18 changes: 16 additions & 2 deletions make/configure.mk
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,10 @@ define _modconfig =
$(if $($(name)_OBJ_TEST),, $(eval $(name)_OBJ_TEST := "$($(name)_BIN)/$($(name)_NAME)-test.o"))
$(if $($(name)_MFLAGS),, $(eval $(name)_MFLAGS := $(if $(publisher),,"-D$(name)_BUILTIN -fvisibility=hidden")))

$(if $(HOST_$(name)_NAME),, $(eval HOST_$(name)_NAME := $($(name)_NAME)))
$(if $(HOST_$(name)_DESC),, $(eval HOST_$(name)_DESC := $($(name)_DESC)))
$(if $(HOST_$(name)_URL),, $(eval HOST_$(name)_URL := $($(name)_URL$(X_URL_SUFFIX))))

$(if $(HOST_$(name)_PATH),, $(eval HOST_$(name)_PATH := $(MODULES)/$($(name)_NAME)))
$(if $(HOST_$(name)_INC),, $(eval HOST_$(name)_INC := $(HOST_$(name)_PATH)/include))
$(if $(HOST_$(name)_SRC),, $(eval HOST_$(name)_SRC := $(HOST_$(name)_PATH)/src))
Expand Down Expand Up @@ -164,6 +168,10 @@ define hdrconfig =
$(if $($(name)_TESTING),, $(eval $(name)_TESTING := 0))
$(if $($(name)_CFLAGS),, $(eval $(name)_CFLAGS := "$(if $($(name)_INC_OPT),$($(name)_INC_OPT) ,-I )\"$($(name)_INC)\""$(if $(publisher), "-D$(name)_PUBLISHER")))
$(if $($(name)_MFLAGS),, $(eval $(name)_MFLAGS := "-D$(name)_BUILTIN -fvisibility=hidden"))

$(if $(HOST_$(name)_NAME),, $(eval HOST_$(name)_NAME := $($(name)_NAME)))
$(if $(HOST_$(name)_DESC),, $(eval HOST_$(name)_DESC := $($(name)_DESC)))
$(if $(HOST_$(name)_URL),, $(eval HOST_$(name)_URL := $($(name)_URL$(X_URL_SUFFIX))))

$(if $(HOST_$(name)_PATH),, $(eval HOST_$(name)_PATH := $(MODULES)/$($(name)_NAME)))
$(if $(HOST_$(name)_INC),, $(eval HOST_$(name)_INC := $(HOST_$(name)_PATH)/include))
Expand Down Expand Up @@ -192,6 +200,9 @@ define plugconfig =
$(if $($(name)_OBJ_UI),, $(eval $(name)_OBJ_UI := "$($(name)_BIN)/$($(name)_NAME)-ui.o"))
$(if $($(name)_OBJ_TEST),, $(eval $(name)_OBJ_TEST := "$($(name)_BIN)/$($(name)_NAME)-test.o"))
$(if $($(name)_MFLAGS),, $(eval $(name)_MFLAGS := $(if $(publisher),,"-D$(name)_BUILTIN -fvisibility=hidden")))

$(if $(HOST_$(name)_NAME),, $(eval HOST_$(name)_NAME := $($(name)_NAME)))
$(if $(HOST_$(name)_DESC),, $(eval HOST_$(name)_DESC := $($(name)_DESC)))

$(if $(HOST_$(name)_PATH),, $(eval HOST_$(name)_PATH := $(MODULES)/$($(name)_NAME)))
$(if $(HOST_$(name)_INC),, $(eval HOST_$(name)_INC := $(HOST_$(name)_PATH)/include))
Expand Down Expand Up @@ -277,6 +288,8 @@ CONFIG_VARS = \
$(name)_OBJ_UI \
$(name)_OBJ_TEST \
\
HOST_$(name)_NAME \
HOST_$(name)_DESC \
HOST_$(name)_PATH \
HOST_$(name)_INC \
HOST_$(name)_SRC \
Expand Down Expand Up @@ -305,8 +318,9 @@ $(CONFIG_VARS): prepare
echo "$(@)=$($(@))" >> "$(CONFIG)"

config: $(CONFIG_VARS)
echo "Architecture: $(ARCHITECTURE_FAMILY)/$(ARCHITECTURE) ($(ARCHITECTURE_CFLAGS))"
echo "Features: $(FEATURES)"
echo "Host architecture: $(HOST_ARCHITECTURE_FAMILY)/$(HOST_ARCHITECTURE) ($(HOST_ARCHITECTURE_CFLAGS))"
echo "Architecture: $(ARCHITECTURE_FAMILY)/$(ARCHITECTURE) ($(ARCHITECTURE_CFLAGS))"
echo "Features: $(FEATURES)"
echo "Configured OK"

help: | pathvars toolvars sysvars
Expand Down
8 changes: 7 additions & 1 deletion make/modules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,15 @@ UNIQ_ALL_DEPENDENCIES := $(filter-out $(ARTIFACT_ID),$(call uniq, $(ALL_DEP
MODULES ?= $(BASEDIR)/modules
GIT ?= git

ifeq ($(DEVEL),1)
X_URL_SUFFIX = _RW
else
X_URL_SUFFIX = _RO
endif

ifeq ($(TREE),1)
$(foreach dep,$(UNIQ_ALL_DEPENDENCIES), \
$(eval $(dep)_URL=$($(dep)_URL_RO)) \
$(eval $(dep)_URL=$($(dep)_URL$(X_URL_SUFFIX))) \
)

ifeq ($(findstring -devel,$(ARTIFACT_VERSION)),-devel)
Expand Down
17 changes: 16 additions & 1 deletion make/paths.mk
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,8 @@
ifndef PREFIX
ifeq ($(PLATFORM),Windows)
PREFIX := $(BASEDIR)/INSTALL
else ifeq ($(CROSS_COMPILE),1)
PREFIX := $(BASEDIR)/INSTALL
else
PREFIX := /usr/local
endif
Expand All @@ -42,7 +44,11 @@ SHAREDDIR := $(PREFIX)/share
INCDIR := $(PREFIX)/include
BUILDDIR := $(BASEDIR)/.build
TARGET_BUILDDIR := $(BUILDDIR)/target
HOST_BUILDDIR := $(BUILDDIR)/host
ifeq ($(CROSS_COMPILE),1)
HOST_BUILDDIR := $(BUILDDIR)/host
else
HOST_BUILDDIR := $(TARGET_BUILDDIR)
endif
MODULES := $(BASEDIR)/modules
CONFIG := $(BASEDIR)/.config.mk

Expand All @@ -61,6 +67,15 @@ ifndef INCDIR
INCDIR := $(PREFIX)/include
endif

# Shared resources
ifndef SHAREDDIR
ifeq ($(PLATFORM),Haiku)
SHAREDDIR := $(PREFIX)/data
else
SHAREDDIR := $(PREFIX)/share
endif
endif

# Temporary directory
ifndef TEMPDIR
ifeq ($(PLATFORM),Windows)
Expand Down
194 changes: 105 additions & 89 deletions make/system.mk
Original file line number Diff line number Diff line change
Expand Up @@ -38,108 +38,119 @@ ifndef PLATFORM
PLATFORM := Linux
else ifeq ($(findstring SunOS,$(BUILD_SYSTEM)),SunOS)
PLATFORM := Solaris
else ifeq ($(findstring Darwin,$(BUILD_SYSTEM)),Darwin)
PLATFORM := MacOS
else ifeq ($(findstring Haiku,$(BUILD_SYSTEM)),Haiku)
PLATFORM := Haiku
endif
endif

# Detect system processor architecture
ifndef ARCHITECTURE
ifeq ($(PLATFORM),Windows)
BUILD_ARCH := $(PROCESSOR_ARCHITECTURE)
else
BUILD_ARCH := $(shell uname -m)
endif
ifeq ($(PLATFORM),Windows)
HOST_BUILD_ARCH := $(PROCESSOR_ARCHITECTURE)
else
BUILD_ARCH := $(ARCHITECTURE)
HOST_BUILD_ARCH := $(shell uname -m)
endif
BUILD_ARCH := $(if $(ARCHITECTURE),$(ARCHITECTURE),$(HOST_BUILD_ARCH))

# Set actual architecture
# Set actual architecture for HOST and TARGET builds
# The current architecture can be obtained by: gcc -Q --help=target
ifeq ($(BUILD_ARCH),armel)
override ARCHITECTURE = $(BUILD_ARCH)
ARCHITECTURE_FAMILY = generic
ARCHITECTURE_CFLAGS :=
else ifeq ($(BUILD_ARCH),armhf)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv7-a+fp -marm
else ifeq ($(patsubst armv6%,armv6,$(BUILD_ARCH)),armv6)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv6 -marm
else ifeq ($(patsubst armv7ve%,armv7ve,$(BUILD_ARCH)),armv7ve)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv7ve -marm
else ifeq ($(patsubst armv7%,armv7,$(BUILD_ARCH)),armv7)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv7-a -marm
else ifeq ($(patsubst armv8%,armv8,$(BUILD_ARCH)),armv8)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv7-a -marm
else ifeq ($(patsubst aarch64%,aarch64,$(BUILD_ARCH)),aarch64)
override ARCHITECTURE = aarch64
ARCHITECTURE_FAMILY = aarch64
ARCHITECTURE_CFLAGS := -march=armv8-a
else ifeq ($(BUILD_ARCH),arm64)
override ARCHITECTURE = aarch64
ARCHITECTURE_FAMILY = aarch64
ARCHITECTURE_CFLAGS := -march=armv8-a
else ifeq ($(BUILD_ARCH),arm32)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv6 -marm
else ifeq ($(BUILD_ARCH),arm)
override ARCHITECTURE = arm32
ARCHITECTURE_FAMILY = arm32
ARCHITECTURE_CFLAGS := -march=armv6 -marm
else ifeq ($(patsubst %x86_64%,x86_64,$(BUILD_ARCH)),x86_64)
override ARCHITECTURE = x86_64
ARCHITECTURE_FAMILY = x86_64
ARCHITECTURE_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %amd64%,amd64,$(BUILD_ARCH)),amd64)
override ARCHITECTURE = x86_64
ARCHITECTURE_FAMILY = x86_64
ARCHITECTURE_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %AMD64%,AMD64,$(BUILD_ARCH)),AMD64)
override ARCHITECTURE = x86_64
ARCHITECTURE_FAMILY = x86_64
ARCHITECTURE_CFLAGS := -march=x86-64 -m64
else ifeq ($(BUILD_ARCH),i86pc)
override ARCHITECTURE = x86_64
ARCHITECTURE_FAMILY = x86_64
ARCHITECTURE_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %i686%,i686,$(BUILD_ARCH)),i686)
override ARCHITECTURE = i686
ARCHITECTURE_FAMILY = ia32
ARCHITECTURE_CFLAGS := -march=i686 -m32
else ifeq ($(patsubst i%86,i586,$(BUILD_ARCH)),i586)
override ARCHITECTURE = i586
ARCHITECTURE_FAMILY = ia32
ARCHITECTURE_CFLAGS := -march=i586 -m32
else ifeq ($(BUILD_ARCH),x86)
override ARCHITECTURE = i686
ARCHITECTURE_FAMILY = ia32
ARCHITECTURE_CFLAGS := -march=i686 -m32
else ifeq ($(BUILD_ARCH),riscv32)
override ARCHITECTURE = riscv32
ARCHITECTURE_FAMILY = riscv32
ARCHITECTURE_CFLAGS := -march=rv32imafdc -mabi=lp32d
else ifeq ($(BUILD_ARCH),riscv64)
override ARCHITECTURE = riscv64
ARCHITECTURE_FAMILY = riscv64
ARCHITECTURE_CFLAGS := -march=rv64imafdc -mabi=lp64d
else
override ARCHITECTURE = $(BUILD_ARCH)
ARCHITECTURE_FAMILY = generic
ARCHITECTURE_CFLAGS :=
endif
define detect_architecture =
ifeq ($(1),armel)
$(2)_NAME = $(1)
$(2)_FAMILY = generic
$(2)_CFLAGS :=
else ifeq ($(1),armhf)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv7-a+fp -marm
else ifeq ($(patsubst armv6%,armv6,$(1)),armv6)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv6 -marm
else ifeq ($(patsubst armv7ve%,armv7ve,$(1)),armv7ve)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv7ve -marm
else ifeq ($(patsubst armv7%,armv7,$(1)),armv7)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv7-a -marm
else ifeq ($(patsubst armv8%,armv8,$(1)),armv8)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv7-a -marm
else ifeq ($(patsubst aarch64%,aarch64,$(1)),aarch64)
$(2)_NAME = aarch64
$(2)_FAMILY = aarch64
$(2)_CFLAGS := -march=armv8-a
else ifeq ($(1),arm64)
$(2)_NAME = aarch64
$(2)_FAMILY = aarch64
$(2)_CFLAGS := -march=armv8-a
else ifeq ($(1),arm32)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv6 -marm
else ifeq ($(1),arm)
$(2)_NAME = arm32
$(2)_FAMILY = arm32
$(2)_CFLAGS := -march=armv6 -marm
else ifeq ($(patsubst %x86_64%,x86_64,$(1)),x86_64)
$(2)_NAME = x86_64
$(2)_FAMILY = x86_64
$(2)_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %amd64%,amd64,$(1)),amd64)
$(2)_NAME = x86_64
$(2)_FAMILY = x86_64
$(2)_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %AMD64%,AMD64,$(1)),AMD64)
$(2)_NAME = x86_64
$(2)_FAMILY = x86_64
$(2)_CFLAGS := -march=x86-64 -m64
else ifeq ($(1),i86pc)
$(2)_NAME = x86_64
$(2)_FAMILY = x86_64
$(2)_CFLAGS := -march=x86-64 -m64
else ifeq ($(patsubst %i686%,i686,$(1)),i686)
$(2)_NAME = i686
$(2)_FAMILY = ia32
$(2)_CFLAGS := -march=i686 -m32
else ifeq ($(patsubst i%86,i586,$(1)),i586)
$(2)_NAME = i586
$(2)_FAMILY = ia32
$(2)_CFLAGS := -march=i586 -m32
else ifeq ($(1),x86)
$(2)_NAME = i686
$(2)_FAMILY = ia32
$(2)_CFLAGS := -march=i686 -m32
else ifeq ($(1),riscv32)
$(2)_NAME = riscv32
$(2)_FAMILY = riscv32
$(2)_CFLAGS := -march=rv32imafdc -mabi=lp32d
else ifeq ($(1),riscv64)
$(2)_NAME = riscv64
$(2)_FAMILY = riscv64
$(2)_CFLAGS := -march=rv64imafdc -mabi=lp64d
else
$(2)_NAME = $(1)
$(2)_FAMILY = generic
$(2)_CFLAGS :=
endif
endef

$(eval $(call detect_architecture,$(BUILD_ARCH),ARCHITECTURE))
$(eval $(call detect_architecture,$(HOST_BUILD_ARCH),HOST_ARCHITECTURE))

override ARCHITECTURE = $(ARCHITECTURE_NAME)
override HOST_ARCHITECTURE = $(HOST_ARCHITECTURE_NAME)

# Extension of libraries
ifndef LIBRARY_EXT
ifeq ($(PLATFORM),Windows)
LIBRARY_EXT := .dll
else ifeq ($(PLATFORM),MacOS)
LIBRARY_EXT := .dylib
else
LIBRARY_EXT := .so
endif
Expand Down Expand Up @@ -180,10 +191,14 @@ COMMON_VARS = \
ARCHITECTURE \
ARCHITECTURE_FAMILY \
ARCHITECTURE_CFLAGS \
CROSS_COMPILE \
DEBUG \
EXECUTABLE_EXT \
EXPORT_SYMBOLS \
FEATURES \
HOST_ARCHITECTURE \
HOST_ARCHITECTURE_FAMILY \
HOST_ARCHITECTURE_CFLAGS \
INSTALL_HEADERS \
LIBRARY_EXT \
LIBRARY_PREFIX \
Expand All @@ -205,6 +220,7 @@ sysvars:
echo " ARCHITECTURE_CFLAGS compiler flags to specify architecture"
echo " ARCHITECTURE_FAMILY compiler flags to specify architecture family"
echo " ARCHITECTURE_LDFLAGS linker flags to specify architecture"
echo " CROSS_COMPILE enable/disable cross-compilation"
echo " DEBUG build with debug options"
echo " DEVEL build with modules checked out for read/write URL"
echo " EXECUTABLE_EXT file extension for executable files"
Expand Down
Loading

0 comments on commit 1c445b8

Please sign in to comment.