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

Appropriate multiplication of matrices for rotation/translation

It looks like the problem is: Matrix.multiplyMV(GLES20Renderer._uBodyCentreMatrix, 0, GLES20Renderer._ModelMatrixBody, 0, GLES20Renderer._uBodyCentre, 0); Matrix.multiplyMV is a method to multiply a 4 element vector by a 4×4 matrix and store the result in a 4 element column vector. In matrix notation: result = lhs x rhs. The resultVector element values are undefined if the resultVector elements overlap … Read more