openMSX
ScalerOutput.hh
Go to the documentation of this file.
1 #ifndef SCALEROUTPUT_HH
2 #define SCALEROUTPUT_HH
3 
4 namespace openmsx {
5 
6 template<typename Pixel> class ScalerOutput
7 {
8 public:
9  virtual ~ScalerOutput() = default;
10 
11  [[nodiscard]] virtual unsigned getWidth() const = 0;
12  [[nodiscard]] virtual unsigned getHeight() const = 0;
13 
14  [[nodiscard]] virtual Pixel* acquireLine(unsigned y) = 0;
15  virtual void releaseLine(unsigned y, Pixel* buf) = 0;
16  virtual void fillLine (unsigned y, Pixel color) = 0;
17  // TODO add copyLine() optimization
18 
19 protected:
20  ScalerOutput() = default;
21 };
22 
23 } // namespace openmsx
24 
25 #endif
virtual Pixel * acquireLine(unsigned y)=0
virtual unsigned getWidth() const =0
virtual unsigned getHeight() const =0
virtual void fillLine(unsigned y, Pixel color)=0
virtual void releaseLine(unsigned y, Pixel *buf)=0
virtual ~ScalerOutput()=default
This file implemented 3 utility functions:
Definition: Autofire.cc:9
uint32_t Pixel