You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
35 lines
737 B
35 lines
737 B
/*
|
|
* Copyright (c) Hisilicon Technologies Co., Ltd. 2019-2020. All rights reserved.
|
|
* Description: Crop or move source FBO rect to destination FBO rect
|
|
* Author:
|
|
* Create: 2019-08-26
|
|
*/
|
|
|
|
#ifndef OSD_BLIT_H
|
|
#define OSD_BLIT_H
|
|
|
|
#include <memory>
|
|
#include "Common.h"
|
|
#include "ShaderProgram.h"
|
|
|
|
namespace dolgles {
|
|
using std::unique_ptr;
|
|
|
|
class OSDBlit {
|
|
public:
|
|
OSDBlit();
|
|
~OSDBlit();
|
|
EGL_S32 Init();
|
|
void Blit(const GLBlitInfo &blitInfo) const;
|
|
private:
|
|
void BlitByDrawing(const GLRectInfo &srcRect, const GLRectInfo &dstRect) const;
|
|
|
|
unique_ptr<ShaderProgram> shaderProgram;
|
|
GLuint program;
|
|
GLuint vbo;
|
|
GLint uniformTex;
|
|
GLint attribCoord;
|
|
};
|
|
}; // namespace dolgles
|
|
|
|
#endif // end OSD_BLIT_H
|