24 void setup(
bool superImpose);
44 unsigned srcStartY,
unsigned srcEndY,
unsigned srcWidth,
45 unsigned dstStartY,
unsigned dstEndY,
unsigned dstWidth,
46 unsigned logSrcHeight) = 0;
49 unsigned srcStartY,
unsigned srcEndY,
53 explicit GLScaler(
const std::string& progName);
78 unsigned srcStartY,
unsigned srcEndY,
unsigned srcWidth,
79 unsigned dstStartY,
unsigned dstEndY,
unsigned dstWidth,
80 unsigned logSrcHeight,
81 bool textureFromZero =
false);
84 std::array<gl::BufferObject, 2>
vbo;
Interface for getting lines from a video frame.
Abstract base class for OpenGL scalers.
void setup(bool superImpose)
Setup scaler.
std::array< gl::ShaderProgram, 2 > program
std::array< GLint, 2 > unifTexSize
std::array< GLint, 2 > unifMvpMatrix
std::array< gl::BufferObject, 2 > vbo
void execute(const gl::ColorTexture &src, const gl::ColorTexture *superImpose, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, unsigned dstStartY, unsigned dstEndY, unsigned dstWidth, unsigned logSrcHeight, bool textureFromZero=false)
Helper method to draw a rectangle with multiple texture coordinates.
virtual ~GLScaler()=default
virtual void scaleImage(gl::ColorTexture &src, gl::ColorTexture *superImpose, unsigned srcStartY, unsigned srcEndY, unsigned srcWidth, unsigned dstStartY, unsigned dstEndY, unsigned dstWidth, unsigned logSrcHeight)=0
Scales the image in the given area, which must consist of lines which are all equally wide.
virtual void uploadBlock(unsigned srcStartY, unsigned srcEndY, unsigned lineWidth, FrameSource &paintFrame)
This file implemented 3 utility functions: