-#define SMARTMATRIX_ENABLED   1
+/*
+  Demo intended to compare APA102 refreshing using Temporal Dithering, no Dithering, and SmartMatrix with Dynamic Global Brightness Control
+  Set MODE and BRIGHTNESS defines at the top to reproduce the results in the demo video (MODE_SMARTMATRIX_COLORCORRECTION wasn't used in the video)
+
+  Connect APA102 Data Pin to D2
+  Connect APA102 Clock Pin to D4
+*/
+
+#define MODE_SMARTMATRIX_NOCOLORCORRECTION   0
+#define MODE_SMARTMATRIX_COLORCORRECTION     1
+#define MODE_FASTLED_DITHERING               2
+#define MODE_FASTLED_NODITHERING             3
+
+// SET SKETCH OPTIONS HERE:
+#define MODE MODE_SMARTMATRIX_NOCOLORCORRECTION
+#define BRIGHTNESS 255
 
 #include "application.h"
 
-#if (SMARTMATRIX_ENABLED == 1)
+#if (MODE == MODE_SMARTMATRIX_NOCOLORCORRECTION || MODE == MODE_SMARTMATRIX_COLORCORRECTION)
   #include "SmartMatrix3/SmartMatrix3.h"
 #endif
 
 #include "FastLEDSmartMatrix/FastLEDSmartMatrix.h"
 FASTLED_USING_NAMESPACE;
 
-#if (SMARTMATRIX_ENABLED == 1)
+#if (MODE == MODE_SMARTMATRIX_NOCOLORCORRECTION || MODE == MODE_SMARTMATRIX_COLORCORRECTION)
   #define COLOR_DEPTH 24                  // known working: 24, 48 - If the sketch uses type `rgb24` directly, COLOR_DEPTH must be 24
   const uint8_t kMatrixWidth = 16;        // known working: 16, 32, 48, 64
   const uint8_t kMatrixHeight = 16;       // known working: 32, 64, 96, 128

  }
#endif

#if (SMARTMATRIX_ENABLED == 1)
  // scale the brightness of all pixels down
  void dimAll(byte value)
  {


const uint8_t scale = 256 / kMatrixWidth;

#if (MODE == MODE_SMARTMATRIX_NOCOLORCORRECTION || MODE == MODE_SMARTMATRIX_COLORCORRECTION)
  uint16_t XY(uint8_t x, uint8_t y) {
    return kMatrixWidth * y + x;
  }
