Package com.banuba.sdk.internal.gl
Class GLFrameSurfaceHandler
java.lang.Object
com.banuba.sdk.internal.gl.GLFrameSurfaceHandler
- All Implemented Interfaces:
IOrientable
,Closeable
,AutoCloseable
- Direct Known Subclasses:
GLFramePixelBufferRenderer
,GLOrientableTextureReader
Rectangular drawing plane. Responsible for creating the geometry of the square to draw and for
drawing that square with the texture applied. The texture will be rendered with the specific
rotation and mirroring.
IMPORTANT: The shader program (vertex shader) that will use this class must start with:
"#version 300 es"
"layout (location = 0) in vec3 aPosition;"
"layout (location = 1) in vec2 aTextureCoord;"
Or you can use a SIMPLE_VERTEX_SHADER_PROGRAM which is designed to work in conjunction with
this class.
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
The fragment shader must contain an input texture coordinate variable: "in vec2 vTexCoord;" -
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
void
void
setOrientation
(Orientation orientation, boolean mirroring)
-
Field Details
-
SIMPLE_VERTEX_SHADER_PROGRAM
The fragment shader must contain an input texture coordinate variable: "in vec2 vTexCoord;"- See Also:
-
-
Constructor Details
-
GLFrameSurfaceHandler
public GLFrameSurfaceHandler()
-
-
Method Details
-
setOrientation
- Specified by:
setOrientation
in interfaceIOrientable
-
drawSurface
@CallSuper public void drawSurface() -
close
@CallSuper public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
-