public abstract class

GLUtils.Program2D

extends java.lang.Object

 java.lang.Object

↳androidx.camera.core.processing.util.GLUtils.Program2D

Subclasses:

GLUtils.SamplerShaderProgram, GLUtils.BlankShaderProgram

Summary

Fields
protected intmAlphaScaleLoc

protected intmPositionLoc

protected intmProgramHandle

protected intmTransMatrixLoc

Constructors
protectedProgram2D(java.lang.String vertexShaderSource, java.lang.String fragmentShaderSource)

Methods
public voiddelete()

Delete the shader program

public voidupdateAlpha(float alpha)

Updates the alpha of the drawn frame

public voidupdateTransformMatrix(float[] transformMat[])

Updates the global transform matrix

public voiduse()

Use this shader program

from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Fields

protected int mProgramHandle

protected int mTransMatrixLoc

protected int mAlphaScaleLoc

protected int mPositionLoc

Constructors

protected Program2D(java.lang.String vertexShaderSource, java.lang.String fragmentShaderSource)

Methods

public void use()

Use this shader program

public void updateTransformMatrix(float[] transformMat[])

Updates the global transform matrix

public void updateAlpha(float alpha)

Updates the alpha of the drawn frame

public void delete()

Delete the shader program

Once called, this program should no longer be used.