2
0
mirror of https://github.com/rehlds/revoice.git synced 2025-03-03 17:15:25 +03:00

Add option ENABLE_VORBIS_PSY

Enable Vorbis psychoacoustic model for the Speex codec.
This is an experimental feature in the Speex codec that improves sound quality.
It allows the Speex codec to use the Vorbis psychoacoustic model for better speech compression,
especially at higher bitrates.
This model helps identify which parts of the sound are less noticeable to the human ear
and compresses them more, while preserving overall quality.
This commit is contained in:
the_hunter 2025-02-24 10:43:38 +02:00
parent 0095b8b5ad
commit 19e2898a0d
2 changed files with 3 additions and 3 deletions

View File

@ -25,6 +25,7 @@ option(ENABLE_EXCEPTIONS "Enable support for exception handling"
option(ENABLE_ASAN "Enable AddressSanitizer" OFF) option(ENABLE_ASAN "Enable AddressSanitizer" OFF)
option(ENABLE_UBSAN "Enable UndefinedBehaviorSanitizer" OFF) option(ENABLE_UBSAN "Enable UndefinedBehaviorSanitizer" OFF)
option(ENABLE_LINK_TRACE "Enable linker trace flag (detailed output of the linking process)" OFF) option(ENABLE_LINK_TRACE "Enable linker trace flag (detailed output of the linking process)" OFF)
option(ENABLE_SPEEX_VORBIS_PSY "Enable Vorbis psychoacoustic model in the Speex codec" OFF)
option(OPTIMIZE_FOR_CURRENT_CPU "Generate code optimized for the current (native) processor" OFF) option(OPTIMIZE_FOR_CURRENT_CPU "Generate code optimized for the current (native) processor" OFF)
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------

View File

@ -13,7 +13,6 @@ project( "Speex"
# Options # Options
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
option(SPEEX_ENABLE_VORBIS_PSY "Enable Vorbis psychoacoustic model" OFF)
option(SPEEX_USE_KISS_FFT "Use KISS Fast Fourier Transform (otherwise OggVorbis)" OFF) option(SPEEX_USE_KISS_FFT "Use KISS Fast Fourier Transform (otherwise OggVorbis)" OFF)
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
@ -117,7 +116,7 @@ target_sources("${TARGET_NAME}"
"src/smallft.h" "src/smallft.h"
> >
$<$<BOOL:${SPEEX_ENABLE_VORBIS_PSY}>: $<$<BOOL:${ENABLE_SPEEX_VORBIS_PSY}>:
"src/vorbis_psy.c" "src/vorbis_psy.c"
"src/vorbis_psy.h" "src/vorbis_psy.h"
> >
@ -166,7 +165,7 @@ target_compile_definitions("${TARGET_NAME}"
EXPORT=__attribute__\(\(visibility\(\"default\"\)\)\) EXPORT=__attribute__\(\(visibility\(\"default\"\)\)\)
> >
$<$<BOOL:${SPEEX_ENABLE_VORBIS_PSY}>:VORBIS_PSYCHO> $<$<BOOL:${ENABLE_SPEEX_VORBIS_PSY}>:VORBIS_PSYCHO>
$<IF:$<BOOL:${SPEEX_USE_KISS_FFT}>,USE_KISS_FFT,USE_SMALLFT> $<IF:$<BOOL:${SPEEX_USE_KISS_FFT}>,USE_KISS_FFT,USE_SMALLFT>
) )