CullFace

View source

Selects which polygon faces WebGL should cull.

Pass Front, Back, or Both to WebGLRenderingContext#cullFace after enabling face culling on the context. None represents disabled face culling in engine configuration; disable the WebGL cull-face capability separately when applying that choice.

Examples

import { CullFace } from '@wimaengine/render-webgl'

gl.enable(gl.CULL_FACE)
gl.cullFace(CullFace.Back)

Variants


None

View source

Represents no face culling in engine configuration (0).

Both

View source

Culls both front-facing and back-facing polygons (0x0408).