Modifying camera output using SurfaceTexture and OpenGL
mDirectVideo = new DirectVideo(texture); texture = createTexture(); should be texture = createTexture(); mDirectVideo = new DirectVideo(texture); Shader private final String vertexShaderCode = “attribute vec4 position;” + “attribute vec2 inputTextureCoordinate;” + “varying vec2 textureCoordinate;” + “void main()” + “{“+ “gl_Position = position;”+ “textureCoordinate = inputTextureCoordinate;” + “}”; private final String fragmentShaderCode = “#extension GL_OES_EGL_image_external : require\n”+ … Read more