openMSX
Scaler2.hh
Go to the documentation of this file.
1#ifndef SCALER2_HH
2#define SCALER2_HH
3
4#include "Scaler.hh"
5#include "PixelOperations.hh"
6
7namespace openmsx {
8
11template<std::unsigned_integral Pixel> class Scaler2 : public Scaler<Pixel>
12{
13public:
14 void scaleImage(FrameSource& src, const RawFrame* superImpose,
15 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
16 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY) override;
17
18protected:
20
21 void dispatchScale(FrameSource& src,
22 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
23 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
24 virtual void scaleBlank1to2(
25 FrameSource& src, unsigned srcStartY, unsigned srcEndY,
26 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
27 virtual void scaleBlank1to1(
28 FrameSource& src, unsigned srcStartY, unsigned srcEndY,
29 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
30 virtual void scale1x1to3x2(FrameSource& src,
31 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
32 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
33 virtual void scale1x1to3x1(FrameSource& src,
34 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
35 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
36 virtual void scale1x1to2x2(FrameSource& src,
37 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
38 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
39 virtual void scale1x1to2x1(FrameSource& src,
40 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
41 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
42 virtual void scale2x1to3x2(FrameSource& src,
43 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
44 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
45 virtual void scale2x1to3x1(FrameSource& src,
46 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
47 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
48 virtual void scale1x1to1x2(FrameSource& src,
49 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
50 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
51 virtual void scale1x1to1x1(FrameSource& src,
52 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
53 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
54 virtual void scale4x1to3x2(FrameSource& src,
55 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
56 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
57 virtual void scale4x1to3x1(FrameSource& src,
58 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
59 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
60 virtual void scale2x1to1x2(FrameSource& src,
61 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
62 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
63 virtual void scale2x1to1x1(FrameSource& src,
64 unsigned srcStartY, unsigned srcEndY, unsigned srcWidth,
65 ScalerOutput<Pixel>& dst, unsigned dstStartY, unsigned dstEndY);
66
67protected:
69};
70
71} // namespace openmsx
72
73#endif
Interface for getting lines from a video frame.
Definition: FrameSource.hh:20
A video frame as output by the VDP scanline conversion unit, before any postprocessing filters are ap...
Definition: RawFrame.hh:15
Base class for 2x scalers.
Definition: Scaler2.hh:12
virtual void scale1x1to1x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:166
virtual void scale1x1to2x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:107
virtual void scale1x1to3x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:91
void dispatchScale(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:223
virtual void scale4x1to3x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:193
virtual void scaleBlank1to2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:20
virtual void scale1x1to3x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:81
const PixelOperations< Pixel > pixelOps
Definition: Scaler2.hh:68
virtual void scale2x1to3x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:127
virtual void scale1x1to2x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:117
virtual void scaleBlank1to1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:33
Scaler2(const PixelOperations< Pixel > &pixelOps)
Definition: Scaler2.cc:14
virtual void scale4x1to3x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:183
void scaleImage(FrameSource &src, const RawFrame *superImpose, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY) override
Scales the image in the given area, which must consist of lines which are all equally wide.
Definition: Scaler2.cc:298
virtual void scale1x1to1x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:147
virtual void scale2x1to3x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:137
virtual void scale2x1to1x2(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:203
virtual void scale2x1to1x1(FrameSource &src, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, ScalerOutput< Pixel > &dst, unsigned dstStartY, unsigned dstEndY)
Definition: Scaler2.cc:213
Abstract base class for scalers.
Definition: Scaler.hh:16
This file implemented 3 utility functions:
Definition: Autofire.cc:9