Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
getModel(gl) {
return new Model({
gl,
id: this.props.id,
...assembleShaders(gl, {
vs: VERTEX_SHADER,
fs: FRAGMENT_SHADER
}),
geometry: new Geometry({
drawMode: GL.TRIANGLE_FAN,
positions: this.getPositions()
}),
isInstanced: true
});
}
getModel(gl) {
return new Model(gl, Object.assign({}, this.getShaders(), {
id: this.props.id,
geometry: new Geometry({
drawMode: this.props.drawContour ? GL.LINES : GL.TRIANGLES
}),
vertexCount: 0,
isIndexed: true,
shaderCache: this.context.shaderCache
}));
}
_getModel(gl) {
return new Model(
gl,
Object.assign({}, this.getShaders(), {
id: this.props.id,
geometry: new Geometry({
drawMode: GL.TRIANGLE_FAN,
attributes: {
vertices: new Float32Array([0, 0, 0, 1, 0, 0, 1, 1, 0, 0, 1, 0])
}
}),
isInstanced: true,
shaderCache: this.context.shaderCache
})
);
}
getModel(gl) {
return new Model({
gl,
id: this.props.id,
...assembleShaders(gl, {
vs: VERTEX_SHADER,
fs: FRAGMENT_SHADER
}),
geometry: new Geometry({drawMode: GL.POINTS})
});
}
getModel(gl) {
return new Model({
gl,
id: this.props.id,
...assembleShaders(gl, {
vs: glslify('./reflection-layer-vertex.glsl'),
fs: glslify('./reflection-layer-fragment.glsl')
}),
geometry: new Geometry({
drawMode: this.props.drawContour ? GL.LINES : GL.TRIANGLES
}),
vertexCount: 0,
isIndexed: true
});
}