From 80b987d5d8b82d14e0d960a461849204bc7526fc Mon Sep 17 00:00:00 2001 From: Dan Date: Sat, 9 Dec 2023 00:02:34 -0800 Subject: [PATCH] some fixes --- VortexEngine/src/Menus/MenuList/Randomizer.cpp | 6 +++--- VortexEngine/src/Menus/MenuList/Randomizer.h | 4 +--- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/VortexEngine/src/Menus/MenuList/Randomizer.cpp b/VortexEngine/src/Menus/MenuList/Randomizer.cpp index 4ad8de38d3..efaa3ac8d0 100644 --- a/VortexEngine/src/Menus/MenuList/Randomizer.cpp +++ b/VortexEngine/src/Menus/MenuList/Randomizer.cpp @@ -235,19 +235,19 @@ bool Randomizer::splitMultiRandomize() // apply pattern1 and colorset1 to the bitmap PatternID pat1 = rollSingleLedPatternID(m_multiRandCtx); Colorset set1 = rollColorset(m_multiRandCtx); - if (!applyPatternAndColorsetToMap(m_multiRandCtx, randomMap, pat1, set1)) { + if (!applyPatternAndColorsetToMap(randomMap, pat1, set1)) { return false; } // apply pattern2 and colorset2 to the inverse bitmap PatternID pat2 = rollSingleLedPatternID(m_multiRandCtx); Colorset set2 = rollColorset(m_multiRandCtx); - if (!applyPatternAndColorsetToMap(m_multiRandCtx, MAP_INVERSE(randomMap), pat2, set2)) { + if (!applyPatternAndColorsetToMap(MAP_INVERSE(randomMap), pat2, set2)) { return false; } return true; } -bool Randomizer::applyPatternAndColorsetToMap(Random &ctx, LedMap map, PatternID pattern, const Colorset &colorset) +bool Randomizer::applyPatternAndColorsetToMap(LedMap map, PatternID pattern, const Colorset &colorset) { MAP_FOREACH_LED(map) { if (!m_previewMode.setPattern(pattern, pos) || !m_previewMode.setColorset(colorset, pos)) { diff --git a/VortexEngine/src/Menus/MenuList/Randomizer.h b/VortexEngine/src/Menus/MenuList/Randomizer.h index e252bf12b5..a6efbf699f 100644 --- a/VortexEngine/src/Menus/MenuList/Randomizer.h +++ b/VortexEngine/src/Menus/MenuList/Randomizer.h @@ -31,9 +31,7 @@ class Randomizer : public Menu bool reRollSingles(); bool reRollForContext(Random &ctx, LedPos pos); bool splitMultiRandomize(); - bool rollPatternForPosition(Random &ctx, LedPos pos); - bool rollColorsetForPosition(Random &ctx, LedPos pos); - bool applyPatternAndColorsetToMap(Random &ctx, LedMap map, PatternID pattern, const Colorset &colorset); + bool applyPatternAndColorsetToMap(LedMap map, PatternID pattern, const Colorset &colorset); PatternID rollSingleLedPatternID(Random &ctx); PatternID rollMultiLedPatternID(Random &ctx); Colorset rollColorset(Random &ctx);