|
@@ -4,7 +4,7 @@
|
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
* @author Alexander Rose <alexander.rose@weirdbyte.de>
|
|
*/
|
|
*/
|
|
|
|
|
|
-import { ProgramProps, createProgram, Program, Programs } from './program';
|
|
|
|
|
|
+import { ProgramProps, createProgram, Program } from './program';
|
|
import { ShaderType, createShader, Shader, ShaderProps } from './shader';
|
|
import { ShaderType, createShader, Shader, ShaderProps } from './shader';
|
|
import { GLRenderingContext } from './compat';
|
|
import { GLRenderingContext } from './compat';
|
|
import { Framebuffer, createFramebuffer } from './framebuffer';
|
|
import { Framebuffer, createFramebuffer } from './framebuffer';
|
|
@@ -60,7 +60,7 @@ export interface WebGLResources {
|
|
shader: (type: ShaderType, source: string) => Shader
|
|
shader: (type: ShaderType, source: string) => Shader
|
|
texture: (kind: TextureKind, format: TextureFormat, type: TextureType, filter: TextureFilter) => Texture,
|
|
texture: (kind: TextureKind, format: TextureFormat, type: TextureType, filter: TextureFilter) => Texture,
|
|
cubeTexture: (faces: CubeFaces, mipmaps: boolean, onload?: () => void) => Texture,
|
|
cubeTexture: (faces: CubeFaces, mipmaps: boolean, onload?: () => void) => Texture,
|
|
- vertexArray: (programs: Programs, attributeBuffers: AttributeBuffers, elementsBuffer?: ElementsBuffer) => VertexArray,
|
|
|
|
|
|
+ vertexArray: (program: Program, attributeBuffers: AttributeBuffers, elementsBuffer?: ElementsBuffer) => VertexArray,
|
|
|
|
|
|
getByteCounts: () => ByteCounts
|
|
getByteCounts: () => ByteCounts
|
|
|
|
|
|
@@ -142,8 +142,8 @@ export function createResources(gl: GLRenderingContext, state: WebGLState, stats
|
|
cubeTexture: (faces: CubeFaces, mipmaps: boolean, onload?: () => void) => {
|
|
cubeTexture: (faces: CubeFaces, mipmaps: boolean, onload?: () => void) => {
|
|
return wrap('cubeTexture', createCubeTexture(gl, faces, mipmaps, onload));
|
|
return wrap('cubeTexture', createCubeTexture(gl, faces, mipmaps, onload));
|
|
},
|
|
},
|
|
- vertexArray: (programs: Programs, attributeBuffers: AttributeBuffers, elementsBuffer?: ElementsBuffer) => {
|
|
|
|
- return wrap('vertexArray', createVertexArray(gl, extensions, programs, attributeBuffers, elementsBuffer));
|
|
|
|
|
|
+ vertexArray: (program: Program, attributeBuffers: AttributeBuffers, elementsBuffer?: ElementsBuffer) => {
|
|
|
|
+ return wrap('vertexArray', createVertexArray(gl, extensions, program, attributeBuffers, elementsBuffer));
|
|
},
|
|
},
|
|
|
|
|
|
getByteCounts: () => {
|
|
getByteCounts: () => {
|