Diorama

Made for a big screen.

This site is one 3D scene, built for a computer: a wide window and a mouse. Open dioramajs.dev on a desktop or a laptop to see it.This site is one 3D scene, built for a wide window. Make this one wider, or open dioramajs.dev on a larger screen.

GitHub

DioramaDocs

applyShader function

Adds a shader to the surface from a custom effect's setup.

View as Markdown
import { applyShader } from '@dioramajs/diorama/glsl'

Call the result to remove it.

function applyShader<P extends ParamSpec>(
  ctx: EffectContext<P>,
  shader: GlslSource,
  options?: ApplyOptions,
): Off

Parameters

NameTypeDescription
ctxEffectContext<P>
shaderGlslSource
options?ApplyOptions

Default {}.

Also exported from @dioramajs/glsl.

Defined in packages/glsl/src/runtime.ts.