/// <summary>
        /// </summary>
        /// <param name="uniformName"></param>
        /// <param name="m"></param>
        internal int glUniform(string uniformName, mat2 m)
        {
            int location = GetUniformLocation(uniformName);

            if (location >= 0)
            {
                if (glUniformMatrix2fv == null)
                {
                    glUniformMatrix2fv = GL.Instance.GetDelegateFor("glUniformMatrix2fv", GLDelegates.typeof_void_int_int_bool_floatN) as GLDelegates.void_int_int_bool_floatN;
                }
                float[] array = m.ToArray();
                glUniformMatrix2fv(location, 1, false, array);
            }
            return(location);
        }
Esempio n. 2
0
        /// <summary>
        /// </summary>
        /// <param name="uniformName"></param>
        /// <param name="m"></param>
        public int glUniform(string uniformName, mat2 m)
        {
            int location = GetUniformLocation(uniformName);

            if (location >= 0)
            {
                if (glUniformMatrix2fv == null)
                {
                    glUniformMatrix2fv = OpenGL.GetDelegateFor <OpenGL.glUniformMatrix2fv>();
                }
                float[] array = m.ToArray();
                glUniformMatrix2fv(location, 1, false, array);
            }
            return(location);
        }