#ifndef PIXELSTREAM_H
#define PIXELSTREAM_H

#include <pico/stdlib.h>

namespace lib
{

class Display;

class PixelStream
{
  friend Display;

public:
  PixelStream(const PixelStream&) = delete;
  PixelStream& operator=(const PixelStream&) = delete;
  ~PixelStream();

  // prefer other overload when possible
  void write(uint8_t data);
  void write(uint8_t red, uint8_t green, uint8_t blue);

  // use for large transfers
  void write(const uint8_t* data, size_t datalen);

private:
  PixelStream(Display&);

  Display& display;
};

}

#endif // PIXELSTREAM_H
