• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #pragma once
2 
3 #include "FrameBuffer.h"
4 #include "Renderer.h"
5 
6 #include <GLES2/gl2.h>
7 
8 #include <stdint.h>
9 #include <stdio.h>
10 #include <stdlib.h>
11 
12 class YVURenderer: public Renderer {
13   public:
14     YVURenderer();
15     virtual ~YVURenderer();
16 
17     // Initialize OpenGL resources
18     // @return true if successful
19     bool InitializeGLProgram();
20 
21     bool DrawTexture();
22 
23  private:
24     // Source code for shaders.
25     const char* VertexShaderSource() const;
26     const char* FragmentShaderSource() const;
27 
28     // Attribute locations
29     GLint  mPositionLoc;
30     GLint  mTexCoordLoc;
31 
32     // Sampler location
33     GLint mSamplerLoc;
34 };
35 
36