Remove DISABLE_AUDIO

This commit is contained in:
Blaz Kristan 2022-09-05 00:43:26 +02:00
parent 787f5f06df
commit 2c27240da6
8 changed files with 1911 additions and 1983 deletions

View File

@ -5921,7 +5921,6 @@ static const char _data_FX_MODE_2DDRIFTROSE[] PROGMEM = "Drift Rose@Fade,Blur;;;
#endif // WLED_DISABLE_2D #endif // WLED_DISABLE_2D
#ifndef WLED_DISABLE_AUDIO
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
/******************** audio enhanced routines ************************/ /******************** audio enhanced routines ************************/
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
@ -6605,11 +6604,6 @@ uint16_t mode_puddles(void) { // Puddles. By Andrew Tuline.
static const char _data_FX_MODE_PUDDLES[] PROGMEM = "Puddles@Fade rate,Puddle size;!,!;!;mp12=0,ssim=0,1d,vo"; // Pixels, Beatsin static const char _data_FX_MODE_PUDDLES[] PROGMEM = "Puddles@Fade rate,Puddle size;!,!;!;mp12=0,ssim=0,1d,vo"; // Pixels, Beatsin
///////////////////////////////////////////////////////////////////////////////
/******************** audio only routines ************************/
///////////////////////////////////////////////////////////////////////////////
#ifdef USERMOD_AUDIOREACTIVE
////////////////////// //////////////////////
// * PIXELS // // * PIXELS //
////////////////////// //////////////////////
@ -7198,14 +7192,7 @@ uint16_t mode_2DFunkyPlank(void) { // Written by ??? Adapted by Wil
} // mode_2DFunkyPlank } // mode_2DFunkyPlank
static const char _data_FX_MODE_2DFUNKYPLANK[] PROGMEM = "Funky Plank@Scroll speed,,# of bands;;;ssim=0,2d,fr"; // Beatsin static const char _data_FX_MODE_2DFUNKYPLANK[] PROGMEM = "Funky Plank@Scroll speed,,# of bands;;;ssim=0,2d,fr"; // Beatsin
#endif // WLED_DISABLE_2D
//end audio only routines
#endif
#ifndef WLED_DISABLE_2D
///////////////////////// /////////////////////////
// 2D Akemi // // 2D Akemi //
///////////////////////// /////////////////////////
@ -7310,7 +7297,6 @@ uint16_t mode_2DAkemi(void) {
static const char _data_FX_MODE_2DAKEMI[] PROGMEM = "Akemi@Color speed,Dance;Head palette,Arms & Legs,Eyes & Mouth;Face palette;ssim=0,2d,fr"; //beatsin static const char _data_FX_MODE_2DAKEMI[] PROGMEM = "Akemi@Color speed,Dance;Head palette,Arms & Legs,Eyes & Mouth;Face palette;ssim=0,2d,fr"; //beatsin
#endif // WLED_DISABLE_2D #endif // WLED_DISABLE_2D
#endif // WLED_DISABLE_AUDIO
////////////////////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////////////////////
// mode data // mode data
@ -7492,16 +7478,14 @@ void WS2812FX::setupEffectData() {
addEffect(FX_MODE_2DMETABALLS, &mode_2Dmetaballs, _data_FX_MODE_2DMETABALLS); addEffect(FX_MODE_2DMETABALLS, &mode_2Dmetaballs, _data_FX_MODE_2DMETABALLS);
addEffect(FX_MODE_2DPULSER, &mode_2DPulser, _data_FX_MODE_2DPULSER); addEffect(FX_MODE_2DPULSER, &mode_2DPulser, _data_FX_MODE_2DPULSER);
addEffect(FX_MODE_2DDRIFT, &mode_2DDrift, _data_FX_MODE_2DDRIFT); addEffect(FX_MODE_2DDRIFT, &mode_2DDrift, _data_FX_MODE_2DDRIFT);
// --- 2D audio effects --- // --- 2D audio effects ---
#ifndef WLED_DISABLE_AUDIO
addEffect(FX_MODE_2DWAVERLY, &mode_2DWaverly, _data_FX_MODE_2DWAVERLY); addEffect(FX_MODE_2DWAVERLY, &mode_2DWaverly, _data_FX_MODE_2DWAVERLY);
addEffect(FX_MODE_2DSWIRL, &mode_2DSwirl, _data_FX_MODE_2DSWIRL); addEffect(FX_MODE_2DSWIRL, &mode_2DSwirl, _data_FX_MODE_2DSWIRL);
addEffect(FX_MODE_2DAKEMI, &mode_2DAkemi, _data_FX_MODE_2DAKEMI); addEffect(FX_MODE_2DAKEMI, &mode_2DAkemi, _data_FX_MODE_2DAKEMI);
#endif addEffect(FX_MODE_2DGEQ, &mode_2DGEQ, _data_FX_MODE_2DGEQ);
addEffect(FX_MODE_2DFUNKYPLANK, &mode_2DFunkyPlank, _data_FX_MODE_2DFUNKYPLANK);
#endif // WLED_DISABLE_2D #endif // WLED_DISABLE_2D
#ifndef WLED_DISABLE_AUDIO
// --- 1D audio effects --- // --- 1D audio effects ---
addEffect(FX_MODE_PIXELWAVE, &mode_pixelwave, _data_FX_MODE_PIXELWAVE); addEffect(FX_MODE_PIXELWAVE, &mode_pixelwave, _data_FX_MODE_PIXELWAVE);
addEffect(FX_MODE_JUGGLES, &mode_juggles, _data_FX_MODE_JUGGLES); addEffect(FX_MODE_JUGGLES, &mode_juggles, _data_FX_MODE_JUGGLES);
@ -7516,29 +7500,15 @@ void WS2812FX::setupEffectData() {
addEffect(FX_MODE_RIPPLEPEAK, &mode_ripplepeak, _data_FX_MODE_RIPPLEPEAK); addEffect(FX_MODE_RIPPLEPEAK, &mode_ripplepeak, _data_FX_MODE_RIPPLEPEAK);
addEffect(FX_MODE_GRAVCENTER, &mode_gravcenter, _data_FX_MODE_GRAVCENTER); addEffect(FX_MODE_GRAVCENTER, &mode_gravcenter, _data_FX_MODE_GRAVCENTER);
addEffect(FX_MODE_GRAVCENTRIC, &mode_gravcentric, _data_FX_MODE_GRAVCENTRIC); addEffect(FX_MODE_GRAVCENTRIC, &mode_gravcentric, _data_FX_MODE_GRAVCENTRIC);
#endif // WLED_DISABLE_AUDIO
#ifdef USERMOD_AUDIOREACTIVE
// --- WLED-SR audio reactive usermod only effects ---
#ifdef WLED_DISABLE_AUDIO
#error Incompatible options: WLED_DISABLE_AUDIO and USERMOD_AUDIOREACTIVE
#endif
#ifdef WLED_DISABLE_2D
#error AUDIOREACTIVE usermod requires 2D support.
#endif
addEffect(FX_MODE_PIXELS, &mode_pixels, _data_FX_MODE_PIXELS); addEffect(FX_MODE_PIXELS, &mode_pixels, _data_FX_MODE_PIXELS);
addEffect(FX_MODE_FREQWAVE, &mode_freqwave, _data_FX_MODE_FREQWAVE); addEffect(FX_MODE_FREQWAVE, &mode_freqwave, _data_FX_MODE_FREQWAVE);
addEffect(FX_MODE_FREQMATRIX, &mode_freqmatrix, _data_FX_MODE_FREQMATRIX); addEffect(FX_MODE_FREQMATRIX, &mode_freqmatrix, _data_FX_MODE_FREQMATRIX);
addEffect(FX_MODE_2DGEQ, &mode_2DGEQ, _data_FX_MODE_2DGEQ);
addEffect(FX_MODE_WATERFALL, &mode_waterfall, _data_FX_MODE_WATERFALL); addEffect(FX_MODE_WATERFALL, &mode_waterfall, _data_FX_MODE_WATERFALL);
addEffect(FX_MODE_FREQPIXELS, &mode_freqpixels, _data_FX_MODE_FREQPIXELS); addEffect(FX_MODE_FREQPIXELS, &mode_freqpixels, _data_FX_MODE_FREQPIXELS);
addEffect(FX_MODE_NOISEMOVE, &mode_noisemove, _data_FX_MODE_NOISEMOVE); addEffect(FX_MODE_NOISEMOVE, &mode_noisemove, _data_FX_MODE_NOISEMOVE);
addEffect(FX_MODE_FREQMAP, &mode_freqmap, _data_FX_MODE_FREQMAP); addEffect(FX_MODE_FREQMAP, &mode_freqmap, _data_FX_MODE_FREQMAP);
addEffect(FX_MODE_GRAVFREQ, &mode_gravfreq, _data_FX_MODE_GRAVFREQ); addEffect(FX_MODE_GRAVFREQ, &mode_gravfreq, _data_FX_MODE_GRAVFREQ);
addEffect(FX_MODE_DJLIGHT, &mode_DJLight, _data_FX_MODE_DJLIGHT); addEffect(FX_MODE_DJLIGHT, &mode_DJLight, _data_FX_MODE_DJLIGHT);
addEffect(FX_MODE_2DFUNKYPLANK, &mode_2DFunkyPlank, _data_FX_MODE_2DFUNKYPLANK);
addEffect(FX_MODE_BLURZ, &mode_blurz, _data_FX_MODE_BLURZ); addEffect(FX_MODE_BLURZ, &mode_blurz, _data_FX_MODE_BLURZ);
addEffect(FX_MODE_ROCKTAVES, &mode_rocktaves, _data_FX_MODE_ROCKTAVES); addEffect(FX_MODE_ROCKTAVES, &mode_rocktaves, _data_FX_MODE_ROCKTAVES);
//addEffect(FX_MODE_CUSTOMEFFECT, &mode_customEffect, _data_FX_MODE_CUSTOMEFFECT); //WLEDSR Custom Effects
#endif // USERMOD_AUDIOREACTIVE
} }

View File

@ -275,67 +275,39 @@
#define FX_MODE_2DMETABALLS 142 // non audio #define FX_MODE_2DMETABALLS 142 // non audio
#define FX_MODE_2DPULSER 143 // non audio #define FX_MODE_2DPULSER 143 // non audio
#define FX_MODE_2DDRIFT 144 // non audio #define FX_MODE_2DDRIFT 144 // non audio
#endif #define FX_MODE_2DWAVERLY 145 // audio enhanced
#ifndef WLED_DISABLE_AUDIO #define FX_MODE_2DSWIRL 146 // audio enhanced
#ifndef WLED_DISABLE_2D #define FX_MODE_2DAKEMI 147 // audio enhanced
#define FX_MODE_2DWAVERLY 145 // audio enhanced #define FX_MODE_2DGEQ 148 // audio enhanced
#define FX_MODE_2DSWIRL 146 // audio enhanced #define FX_MODE_2DFUNKYPLANK 149 // audio enhanced
#define FX_MODE_2DAKEMI 147 // audio enhanced #endif //WLED_DISABLE_2D
// 148 & 149 reserved #define FX_MODE_PIXELWAVE 150 // audio enhanced
#endif #define FX_MODE_JUGGLES 151 // audio enhanced
#define FX_MODE_PIXELWAVE 150 // audio enhanced #define FX_MODE_MATRIPIX 152 // audio enhanced
#define FX_MODE_JUGGLES 151 // audio enhanced #define FX_MODE_GRAVIMETER 153 // audio enhanced
#define FX_MODE_MATRIPIX 152 // audio enhanced #define FX_MODE_PLASMOID 154 // audio enhanced
#define FX_MODE_GRAVIMETER 153 // audio enhanced #define FX_MODE_PUDDLES 155 // audio enhanced
#define FX_MODE_PLASMOID 154 // audio enhanced #define FX_MODE_MIDNOISE 156 // audio enhanced
#define FX_MODE_PUDDLES 155 // audio enhanced #define FX_MODE_NOISEMETER 157 // audio enhanced
#define FX_MODE_MIDNOISE 156 // audio enhanced #define FX_MODE_NOISEFIRE 158 // audio enhanced
#define FX_MODE_NOISEMETER 157 // audio enhanced #define FX_MODE_PUDDLEPEAK 159 // audio enhanced
#define FX_MODE_NOISEFIRE 158 // audio enhanced #define FX_MODE_RIPPLEPEAK 160 // audio enhanced
#define FX_MODE_PUDDLEPEAK 159 // audio enhanced #define FX_MODE_GRAVCENTER 161 // audio enhanced
#define FX_MODE_RIPPLEPEAK 160 // audio enhanced #define FX_MODE_GRAVCENTRIC 162 // audio enhanced
#define FX_MODE_GRAVCENTER 161 // audio enhanced #define FX_MODE_PIXELS 163 // audio enhanced
#define FX_MODE_GRAVCENTRIC 162 // audio enhanced #define FX_MODE_FREQWAVE 164 // audio enhanced
#endif #define FX_MODE_FREQMATRIX 165 // audio enhanced
#define FX_MODE_WATERFALL 166 // audio enhanced
#define FX_MODE_FREQPIXELS 167 // audio enhanced
#define FX_MODE_BINMAP 168 // audio enhanced
#define FX_MODE_NOISEMOVE 169 // audio enhanced
#define FX_MODE_FREQMAP 170 // audio enhanced
#define FX_MODE_GRAVFREQ 171 // audio enhanced
#define FX_MODE_DJLIGHT 172 // audio enhanced
#define FX_MODE_BLURZ 173 // audio enhanced
#define FX_MODE_ROCKTAVES 174 // audio enhanced
#ifndef USERMOD_AUDIOREACTIVE #define MODE_COUNT 175
#ifndef WLED_DISABLE_AUDIO
#define MODE_COUNT 163
#else
#ifndef WLED_DISABLE_2D
#define MODE_COUNT 145
#else
#define MODE_COUNT 118
#endif
#endif
#else
#ifdef WLED_DISABLE_AUDIO
#error Incompatible options: WLED_DISABLE_AUDIO and USERMOD_AUDIOREACTIVE
#endif
#ifdef WLED_DISABLE_2D
#error AUDIOREACTIVE usermod requires 2D support.
#endif
#define FX_MODE_2DGEQ 148
#define FX_MODE_2DFUNKYPLANK 149
#define FX_MODE_PIXELS 163
#define FX_MODE_FREQWAVE 164
#define FX_MODE_FREQMATRIX 165
#define FX_MODE_WATERFALL 166
#define FX_MODE_FREQPIXELS 167
#define FX_MODE_BINMAP 168
#define FX_MODE_NOISEMOVE 169
#define FX_MODE_FREQMAP 170
#define FX_MODE_GRAVFREQ 171
#define FX_MODE_DJLIGHT 172
#define FX_MODE_BLURZ 173
#define FX_MODE_ROCKTAVES 174
//#define FX_MODE_CUSTOMEFFECT 175 //WLEDSR Custom Effects
#define MODE_COUNT 175
#endif
typedef enum mapping1D2D { typedef enum mapping1D2D {
M12_Pixels = 0, M12_Pixels = 0,

View File

@ -611,13 +611,13 @@ function parseInfo(i) {
//gId("filter2D").classList.add("hide"); //gId("filter2D").classList.add("hide");
hideModes("2D"); hideModes("2D");
} }
if (i.noaudio) { // if (i.noaudio) {
gId("filterVol").classList.add("hide"); // gId("filterVol").classList.add("hide");
gId("filterFreq").classList.add("hide"); // gId("filterFreq").classList.add("hide");
} // }
// if (!i.u || !i.u.AudioReactive) { // if (!i.u || !i.u.AudioReactive) {
//gId("filterVol").classList.add("hide"); hideModes(" ♪"); // hide volume reactive effects // gId("filterVol").classList.add("hide"); hideModes(" ♪"); // hide volume reactive effects
//gId("filterFreq").classList.add("hide"); hideModes(" ♫"); // hide frequency reactive effects // gId("filterFreq").classList.add("hide"); hideModes(" ♫"); // hide frequency reactive effects
// } // }
} }

File diff suppressed because it is too large Load Diff

View File

@ -614,10 +614,6 @@ void serializeInfo(JsonObject root)
leds[F("wv")] = totalLC & 0x02; // deprecated, true if white slider should be displayed for any segment leds[F("wv")] = totalLC & 0x02; // deprecated, true if white slider should be displayed for any segment
leds["cct"] = totalLC & 0x04; // deprecated, use info.leds.lc leds["cct"] = totalLC & 0x04; // deprecated, use info.leds.lc
#ifdef WLED_DISABLE_AUDIO
root[F("noaudio")] = true;
#endif
#ifdef WLED_DEBUG #ifdef WLED_DEBUG
JsonArray i2c = root.createNestedArray(F("i2c")); JsonArray i2c = root.createNestedArray(F("i2c"));
i2c.add(i2c_sda); i2c.add(i2c_sda);

View File

@ -133,9 +133,6 @@
#endif #endif
#ifdef USERMOD_AUDIOREACTIVE #ifdef USERMOD_AUDIOREACTIVE
#ifdef WLED_DISABLE_AUDIO
#error Incompatible options: WLED_DISABLE_AUDIO and USERMOD_AUDIOREACTIVE
#endif
#include "../usermods/audioreactive/audio_reactive.h" #include "../usermods/audioreactive/audio_reactive.h"
#endif #endif
@ -260,9 +257,6 @@ void registerUsermods()
#endif #endif
#ifdef USERMOD_AUDIOREACTIVE #ifdef USERMOD_AUDIOREACTIVE
#ifdef WLED_DISABLE_AUDIO
#error Incompatible options: WLED_DISABLE_AUDIO and USERMOD_AUDIOREACTIVE
#endif
usermods.add(new AudioReactive()); usermods.add(new AudioReactive());
#endif #endif
} }

View File

@ -390,7 +390,6 @@ uint16_t crc16(const unsigned char* data_p, size_t length) {
} }
#ifndef WLED_DISABLE_AUDIO
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
// Begin simulateSound (to enable audio enhanced effects to display something) // Begin simulateSound (to enable audio enhanced effects to display something)
/////////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////////
@ -402,7 +401,6 @@ typedef enum UM_SoundSimulations {
UMS_14_3 UMS_14_3
} um_soundSimulations_t; } um_soundSimulations_t;
// this is still work in progress
um_data_t* simulateSound(uint8_t simulationId) um_data_t* simulateSound(uint8_t simulationId)
{ {
static uint8_t samplePeak; static uint8_t samplePeak;
@ -507,7 +505,6 @@ um_data_t* simulateSound(uint8_t simulationId)
return um_data; return um_data;
} }
#endif
void enumerateLedmaps() { void enumerateLedmaps() {

View File

@ -8,7 +8,7 @@
*/ */
// version code in format yymmddb (b = daily build) // version code in format yymmddb (b = daily build)
#define VERSION 2208311 #define VERSION 2209051
//uncomment this if you have a "my_config.h" file you'd like to use //uncomment this if you have a "my_config.h" file you'd like to use
//#define WLED_USE_MY_CONFIG //#define WLED_USE_MY_CONFIG