Taos API Reference
    Preparing search index...

    Class DofPass

    Two-stage depth-of-field post-process (render-graph version).

    Half-resolution prefilter writes scene color and signed circle-of-confusion into the alpha channel; then a full-resolution composite blurs the half-res buffer and blends with the sharp source.

    Hierarchy (View Summary)

    • Pass<DofDeps, DofOutputs>
      • DofPass
    Index

    Properties

    name: "DofPass" = 'DofPass'

    Human-readable identifier used in graph node labels and error messages.

    Methods

    • Parameters

      • ctx: RenderContext
      • focusDistance: number = 30.0
      • focusRange: number = 60.0
      • bokehRadius: number = 6.0
      • near: number = 0.1
      • far: number = 1000.0
      • blurScale: number = 1.0
      • skyInFocus: boolean = false

      Returns void

    • Insert the pass into graph for one frame. Implementations call graph.addPass(name, type, b => { ... }) exactly once and use the supplied PassBuilder to declare reads, writes, transient resources, and the execute callback.

      Parameters

      • graph: RenderGraph

        Graph being built this frame.

      • deps: DofDeps

        Pass-specific dependency record (handles, scene data, etc.).

      Returns DofOutputs

      Pass-specific output record (typically a set of handles downstream passes will consume).

    • Release every long-lived GPU resource owned by the pass (pipelines, persistent uniform buffers, samplers, BGLs). Called by the factory or application during teardown. Default implementation is a no-op.

      Returns void