code: function rotatePixels(buffer, width, height, degrees) {
    let loops = degrees / 90
    while (loops > 0) {
      const newBuffer = Buffer.alloc(buffer.length)
      let newOffset = 0
      for (let x = 0; x < width; x += 1) {
        for (let y = height - 1; y >= 0; y -= 1) {
          const offset = (width * y + x) << 2
          const pixel = buffer.readUInt32BE(offset, true)
          newBuffer.writeUInt32BE(pixel, newOffset, true)
          newOffset += 4
        }
      }
      buffer = newBuffer
      const newHeight = width
      width = height
      height = newHeight
      loops -= 1
    }
    return buffer
  }
docs: Rotate a buffer (degrees must be a multiple of 90)
  Inspired from Jimp (https://github.com/oliver-moran/jimp)