Package tvi.webrtc
Class GlRectDrawer
- java.lang.Object
-
- tvi.webrtc.GlRectDrawer
-
- All Implemented Interfaces:
RendererCommon.GlDrawer
public class GlRectDrawer extends java.lang.Object
Simplest possible GL shader that just draws frames as opaque quads.
-
-
Constructor Summary
Constructors Constructor Description GlRectDrawer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
drawOes(int oesTextureId, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw an OES texture frame with specified texture transformation matrix.void
drawRgb(int textureId, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw a RGB(A) texture frame with specified texture transformation matrix.void
drawYuv(int[] yuvTextures, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw a YUV frame with specified texture transformation matrix.void
release()
Release all GLES resources.
-
-
-
Method Detail
-
drawOes
public void drawOes(int oesTextureId, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw an OES texture frame with specified texture transformation matrix. Required resources are allocated at the first call to this function.- Specified by:
drawOes
in interfaceRendererCommon.GlDrawer
-
drawRgb
public void drawRgb(int textureId, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw a RGB(A) texture frame with specified texture transformation matrix. Required resources are allocated at the first call to this function.- Specified by:
drawRgb
in interfaceRendererCommon.GlDrawer
-
drawYuv
public void drawYuv(int[] yuvTextures, float[] texMatrix, int frameWidth, int frameHeight, int viewportX, int viewportY, int viewportWidth, int viewportHeight)
Draw a YUV frame with specified texture transformation matrix. Required resources are allocated at the first call to this function.- Specified by:
drawYuv
in interfaceRendererCommon.GlDrawer
-
release
public void release()
Release all GLES resources. This needs to be done manually, otherwise the resources are leaked.- Specified by:
release
in interfaceRendererCommon.GlDrawer
-
-