src_legacy/2017/ImageCache.cpp
// shifts values from a position to one higher position ending at position shiftRegisterLength
// if cyclic is true, then value at shiftRegisterLength is shifted back to position 0
shifts values from a position to one higher position ending at position shiftRegisterLength
if cyclic is true, then value at shiftRegisterLength is shifted back to position 0
shifts values from a position to one higher position ending at position shiftRegisterLength if cyclic is true then value at shiftRegisterLength is shifted back to position 0
void ImageCache::shiftRegister(uint8_t registerId1, uint8_t shiftRegisterLength, bool cyclic) {
  rgbVal valLast = _pixelRegister[registerId1][shiftRegisterLength-1];
  for (int j=shiftRegisterLength-1; j>0; j--){
    _pixelRegister[registerId1][j] = _pixelRegister[registerId1][j-1];
  }
  _pixelRegister[registerId1][0] = cyclic ? valLast : makeRGBValue(BLACK, 0);
}
void ImageCache :: shiftRegister ( uint8_t registerId1 , uint8_t shiftRegisterLength , bool cyclic ) { rgbVal valLast = _pixelRegister [ registerId1 ] [ shiftRegisterLength - 1 ] ; for ( int j = shiftRegisterLength - 1 ; j > 0 ; j -- ) { _pixelRegister [ registerId1 ] [ j ] = _pixelRegister [ registerId1 ] [ j - 1 ] ; } _pixelRegister [ registerId1 ] [ 0 ] = cyclic ? valLast : makeRGBValue ( BLACK , 0 ) ; }
shifts values from a position to one higher position ending at position shiftRegisterLength
if cyclic is true, then value at shiftRegisterLength is shifted back to position 0
shifts values from a position to one higher position ending at position shiftRegisterLength if cyclic is true then value at shiftRegisterLength is shifted back to position 0