public void setProgramConstantsFromMatrix(string programType, int firstRegister, Matrix3D matrix, bool transposedMatrix = false) { throw new NotImplementedException(); }
public void setProgramConstantsFromMatrix (string programType, int firstRegister, Matrix3D matrix, bool transposedMatrix = false) { // GLES does not support transposed uniform setting so do it manually if (transposedMatrix) { // 0 1 2 3 // 4 5 6 7 // 8 9 10 11 // 12 13 14 15 double[] source = matrix.mData; mTemp[0] = (float)source[0]; mTemp[1] = (float)source[4]; mTemp[2] = (float)source[8]; mTemp[3] = (float)source[12]; mTemp[4] = (float)source[1]; mTemp[5] = (float)source[5]; mTemp[6] = (float)source[9]; mTemp[7] = (float)source[13]; mTemp[8] = (float)source[2]; mTemp[9] = (float)source[6]; mTemp[10]= (float)source[10]; mTemp[11]= (float)source[14]; mTemp[12]= (float)source[3]; mTemp[13]= (float)source[7]; mTemp[14]= (float)source[11]; mTemp[15]= (float)source[15]; } else { // convert double->float convertDoubleToFloat (mTemp, matrix.mData, 16); } bool isVertex = (programType == "vertex"); // set uniform registers Program3D.Uniform uniform =mProgram.getUniform(isVertex, firstRegister); if (uniform != null) { GL.UniformMatrix4(uniform.Location, 1, false, mTemp); } else { if (enableErrorChecking) { Console.WriteLine ("warning: program register not found: {0}", firstRegister); } } }
public void append(Matrix3D lhs) { }
public void interpolateTo(Matrix3D toMat, float percent) { }
public static Matrix3D interpolate(Matrix3D thisMat, Matrix3D toMat, float percent) { return thisMat; }