40 lines
808 B
Plaintext
40 lines
808 B
Plaintext
/**
|
|
* @module {{{module}}}/Locations
|
|
*/
|
|
// This file is automatically generated, do not edit
|
|
// Run `make shaders` to generate, and commit the result.
|
|
|
|
import {DEBUG as DEBUG_WEBGL} from '../../../../webgl.js';
|
|
|
|
/**
|
|
* @constructor
|
|
* @param {WebGLRenderingContext} gl GL.
|
|
* @param {WebGLProgram} program Program.
|
|
* @struct
|
|
*/
|
|
class Locations {
|
|
|
|
constructor(gl, program) {
|
|
{{#uniforms}}
|
|
|
|
/**
|
|
* @type {WebGLUniformLocation}
|
|
*/
|
|
this.{{originalName}} = gl.getUniformLocation(
|
|
program, DEBUG_WEBGL ? '{{originalName}}' : '{{shortName}}');
|
|
{{/uniforms}}
|
|
{{#attributes}}
|
|
|
|
/**
|
|
* @type {number}
|
|
*/
|
|
this.{{originalName}} = gl.getAttribLocation(
|
|
program, DEBUG_WEBGL ? '{{originalName}}' : '{{shortName}}');
|
|
{{/attributes}}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
export default Locations;
|