UX improvement: don't blur GIF images by default

solves a problem when activating images from PixelForge: in case users had "don't load defaults" set, images were always loaded with a strong blur.
This commit is contained in:
Frank
2026-01-09 21:29:21 +01:00
parent 6af7ee9df8
commit 7e104ba414

View File

@@ -336,7 +336,10 @@ bool deserializeSegment(JsonObject elem, byte it, byte presetId)
// end fix // end fix
if (getVal(elem["fx"], &fx, 0, last)) { //load effect ('r' random, '~' inc/dec, 0-255 exact value, 5~10r pick random between 5 & 10) if (getVal(elem["fx"], &fx, 0, last)) { //load effect ('r' random, '~' inc/dec, 0-255 exact value, 5~10r pick random between 5 & 10)
if (!presetId && currentPlaylist>=0) unloadPlaylist(); if (!presetId && currentPlaylist>=0) unloadPlaylist();
if (fx != seg.mode) seg.setMode(fx, elem[F("fxdef")], elem[F("fxdef2")]); // WLEDMM fxdef2 added bool doLoadDefault = elem[F("fxdef")] == true;
if (fx == FX_MODE_IMAGE) doLoadDefault = true; // WLEDMM quick fix: when called from PixelForge, images were always shown with blur
if (fx == FX_MODE_2DSCROLLTEXT) doLoadDefault = true; // same hack for scrolling text
if (fx != seg.mode) seg.setMode(fx, doLoadDefault, elem[F("fxdef2")]); // WLEDMM fxdef2 added
} }
//getVal also supports inc/decrementing and random //getVal also supports inc/decrementing and random