Skip to content

Intermact API Reference / @intermact/core / RendererFactory

Interface: RendererFactory<TBackend, TOptions>

Defined in: packages/core/src/extend/types.ts:51

Describes a renderer backend factory (e.g. a WebGPU backend). Kept abstract in core (which is renderer-free): create returns a TBackend the host renderer adapter understands. Selecting a backend = looking its factory up by name in Registries.renderers.

Type Parameters

TBackend

TBackend = unknown

TOptions

TOptions = unknown

Properties

description?

readonly optional description?: string

Defined in: packages/core/src/extend/types.ts:55

Optional human-readable summary for tooling.


name

readonly name: string

Defined in: packages/core/src/extend/types.ts:53

Registry key, e.g. "webgl" or "webgpu".

Methods

create()

create(options): TBackend

Defined in: packages/core/src/extend/types.ts:62

Construct the backend from host-supplied options.

Parameters

options

TOptions

Returns

TBackend


isSupported()?

optional isSupported(): boolean

Defined in: packages/core/src/extend/types.ts:60

Whether this backend can run in the current environment (e.g. feature-detect navigator.gpu). Defaults to always-available when omitted.

Returns

boolean

Intermact v1.0 — 文档覆盖 Phase-1 / Phase-2 / Phase-3(全阶段)