Skip to main content

Module: Core-API

Classes

Interfaces

Enumerations

Type aliases

HTMLElementEventMap2

Ƭ HTMLElementEventMap2: HTMLElementEventMap & { initialized: Event }

Defined in

webgi/examples/runtime/WebGiViewerElement.ts:320


TOrbitControlsEvents

Ƭ TOrbitControlsEvents: "change" | "end" | "start"

Defined in

webgi/src/core/threejs/CameraController.ts:26


TControlsCtor

Ƭ TControlsCtor: (camera: Camera, domElement: HTMLElement | Document) => TCameraControls

Type declaration

▸ (camera, domElement): TCameraControls

Parameters
NameType
cameraCamera
domElementHTMLElement | Document
Returns

TCameraControls

Defined in

webgi/src/core/threejs/CameraController.ts:27


TCameraControls

Ƭ TCameraControls: ICameraControls<"change" | string>

Defined in

webgi/src/core/threejs/CameraController.ts:37


Object3DModelOptions

Ƭ Object3DModelOptions: AddModelOptions & { pseudoCenter?: boolean ; autoCenter?: boolean ; license?: string }

Defined in

webgi/src/core/threejs/Object3DModel.ts:9


IMaterialGenerator

Ƭ IMaterialGenerator: (params: any, oldMaterial: any) => IMaterial

Type declaration

▸ (params, oldMaterial): IMaterial

Parameters
NameType
paramsany
oldMaterialany
Returns

IMaterial

Defined in

webgi/src/extras/asset_manager/AMaterialManager.ts:51


IAssetID

Ƭ IAssetID: string

Defined in

webgi/src/extras/asset_manager/AssetManager.ts:29


ExportFileOptions

Ƭ ExportFileOptions: { exportExt?: string ; viewerConfig?: boolean } & GLTFExporter2Options & AnyOptions

Defined in

webgi/src/extras/asset_manager/AssetManager.ts:58


ProcessImportedOptions

Ƭ ProcessImportedOptions: { processImported?: boolean ; forceImporterReprocess?: boolean ; rootPath?: string ; generateMipmaps?: boolean ; _testDataTextureComplete?: boolean } & Object3DModelOptions & AnyOptions

Defined in

webgi/src/extras/asset_manager/AssetManager.ts:75


ImportFilesOptions

Ƭ ImportFilesOptions: ProcessImportedOptions & ImportFileOptions & { allowedExtensions?: string[] }

Defined in

webgi/src/extras/asset_manager/AssetManager.ts:92


ImportAssetOptions

Ƭ ImportAssetOptions: { forceImport?: boolean ; reimportDisposed?: boolean ; pathOverride?: string ; importedFile?: IFile } & ProcessImportedOptions & ImportFileOptions & AnyOptions

Defined in

webgi/src/extras/asset_manager/AssetManager.ts:94


ImportAddOptions

Ƭ ImportAddOptions: ImportAssetOptions & AddModelOptions & AddObjectOptions

Defined in

webgi/src/extras/asset_manager/AssetManagerPlugin.ts:31


AddImportedOptions

Ƭ AddImportedOptions: ProcessImportedOptions & AddObjectOptions & AddModelOptions

Defined in

webgi/src/extras/asset_manager/AssetManagerPlugin.ts:32


AssetImportEventTypes

Ƭ AssetImportEventTypes: "onLoad" | "onProgress" | "onStop" | "onError" | "onStart" | "loaderCreate" | "importFile" | "importFiles" | "processFileStart" | "processFileEnd"

Defined in

webgi/src/extras/asset_manager/importer/threejs/AssetImporter.ts:43


TAssetTypes

Ƭ TAssetTypes: "model" | "texture" | "light" | "material"

Defined in

webgi/src/interfaces.ts:32


IFile

Ƭ IFile: Partial<File> & { name: string ; type: string ; objectUrl?: string ; importId?: string ; ext?: string }

Defined in

webgi/src/interfaces.ts:34


ISceneObject

Ƭ ISceneObject<T>: IModel<T> | ILight<T> | ITexture<T> | IMaterial<T> & IUiConfigContainer

Type parameters

NameType
Tany

Defined in

webgi/src/interfaces.ts:51


TSceneEvents

Ƭ TSceneEvents: "sceneUpdate" | "addSceneObject" | "update" | "textureAdded" | "activeCameraChange" | "textureUpdate" | "renderCameraChange" | "activeCameraUpdate" | "sceneMaterialUpdate" | "environmentChanged" | "select" | "objectUpdate" | "materialUpdate" | "materialChanged" | "setView" | "activateMain" | "backgroundChanged"

Defined in

webgi/src/interfaces.ts:66


TCameraControlsMode

Ƭ TCameraControlsMode: "" | "orbit" | "deviceOrientation" | "firstPerson" | "pointerLock" | string

Defined in

webgi/src/interfaces.ts:217


IGeometry

Ƭ IGeometry: any

Others

Defined in

webgi/src/interfaces.ts:302


IShader

Ƭ IShader: IEventDispatcher<string>

Defined in

webgi/src/interfaces.ts:362


IPassID

Ƭ IPassID: string

Defined in

webgi/src/interfaces.ts:364


TUiRefreshModes

Ƭ TUiRefreshModes: "preRender" | "postRender" | "preFrame" | "postFrame"

UI

Defined in

webgi/src/interfaces.ts:547


UiObjectType

Ƭ UiObjectType: string

Defined in

webgi/src/interfaces.ts:548


TViewerScreenShaderFrag

Ƭ TViewerScreenShaderFrag: string | [string, string] | { pars?: string ; main: string }

Defined in

webgi/src/viewer/ViewerApp.ts:70


TViewerScreenShader

Ƭ TViewerScreenShader: TViewerScreenShaderFrag | ShaderPass2

Defined in

webgi/src/viewer/ViewerApp.ts:71


EnvMapBackground

Ƭ EnvMapBackground: "envMapBackground"

Type for {@see envMapBackground}

deprecated will be removed

Defined in

webgi/src/viewer/ViewerApp.ts:1186

Functions

makeFilter

makeFilter<Tid, TPass>(viewer, filter, updaters?): IFilter<TPass, Tid>

Type parameters

NameType
Tidextends string
TPassextends IPass<TPass>

Parameters

NameType
viewerIViewerApp
filterPartialPick<IFilter<TPass, Tid>, "passId" | "passObject">
updaters?(undefined | IShaderPropertiesUpdater)[] | () => (undefined | IShaderPropertiesUpdater)[]

Returns

IFilter<TPass, Tid>

Defined in

webgi/src/core/AViewerPlugin.ts:114


createRenderTargetKey

createRenderTargetKey(op?): string

Parameters

NameType
opCreateRenderTargetOptions

Returns

string

Defined in

webgi/src/core/threejs/BaseRenderer.ts:767


setupObject3dModel

setupObject3dModel(obj, modelProcessor): IModel<Object3D<Event, string>>

Setup an Object3DModel with a model processor

Parameters

NameType
objIModel<Object3D<Event, string>>
modelProcessor(m: IModel<any>) => undefined | IModel<any>

Returns

IModel<Object3D<Event, string>>

Defined in

webgi/src/core/threejs/Object3DModel.ts:226


setupIModel

setupIModel(object, parent?, modelProcessor?): IModel & Object3D

Converts three.js Object3D to IModel, setup object events, adds utility methods, and runs model processor.

Parameters

NameType
objectObject3D<Event, string> & IModel<any>
parent?IModel<any>
modelProcessor?(m: IModel<any>) => undefined | IModel<any>

Returns

IModel & Object3D

Defined in

webgi/src/core/threejs/iModelSetup.ts:12


setMeshMaterial

setMeshMaterial(mesh, material): IMaterial[]

Parameters

NameType
meshMesh<BufferGeometry<NormalBufferAttributes, Event, string>, Material<Event, string> | Material<Event, string>[]> & IModel<any> & Line<BufferGeometry<NormalBufferAttributes, Event, string>, Material<Event, string> | Material<Event, string>[]> & IModel<any>
materialundefined | null | IMaterial<any> | IMaterial<any>[]

Returns

IMaterial[]

Defined in

webgi/src/core/threejs/iModelSetup.ts:247


setMeshGeometry

setMeshGeometry(mesh, geometry, force?): BufferGeometry | undefined

Parameters

NameTypeDefault value
meshMesh<BufferGeometry<NormalBufferAttributes, Event, string>, Material<Event, string> | Material<Event, string>[]> & IModel<any> & Line<BufferGeometry<NormalBufferAttributes, Event, string>, Material<Event, string> | Material<Event, string>[]> & IModel<any>undefined
geometryundefined | null | BufferGeometry<NormalBufferAttributes, Event, string>undefined
forcebooleanfalse

Returns

BufferGeometry | undefined

Defined in

webgi/src/core/threejs/iModelSetup.ts:292


copyObject3DUserData

copyObject3DUserData(dest, source): any

Parameters

NameType
destany
sourceany

Returns

any

Defined in

webgi/src/core/threejs/iModelSetup.ts:324


getTextureDataType

getTextureDataType(renderer?): TextureDataType

Parameters

NameType
renderer?WebGLRenderer

Returns

TextureDataType

Defined in

webgi/src/extras/asset_manager/importer/threejs/AssetImporter.ts:632


makeSamplerUi

makeSamplerUi<T>(mat, map): UiObjectConfig<any, string>

Type parameters

NameType
Textends IMaterial<any, T> & { map: null | Texture }

Parameters

NameType
matT
mapkeyof T

Returns

UiObjectConfig<any, string>

Defined in

webgi/src/extras/asset_manager/threejs/materialUtils.ts:20


copyMaterialUserData

copyMaterialUserData(dest, source, isRoot?): any

Parameters

NameTypeDefault value
destanyundefined
sourceanyundefined
isRootbooleantrue

Returns

any

Defined in

webgi/src/extras/asset_manager/threejs/materialUtils.ts:198


copyTextureUserData

copyTextureUserData(dest, source): any

Parameters

NameType
destany
sourceany

Returns

any

Defined in

webgi/src/extras/asset_manager/threejs/materialUtils.ts:218


uiConfig

uiConfig(uiType?, params?): PropertyDecorator

Parameters

NameType
uiType?string
params?AnyOptions

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:7


uiToggle

uiToggle(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:28


uiMonitor

uiMonitor(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:31


uiSlider

uiSlider(label?, bounds?, stepSize?, params?): PropertyDecorator

Parameters

NameType
label?string
bounds?[number, number]
stepSize?number
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:34


uiVector

uiVector(label?, bounds?, stepSize?, params?): PropertyDecorator

Parameters

NameType
label?string
bounds?[number, number]
stepSize?number
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:37


uiDropdown

uiDropdown(label?, children?, params?): PropertyDecorator

Parameters

NameType
label?string
children?ValOrFunc<UiObjectConfig<any, string>[], any[]>
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:40


uiButton

uiButton(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:44


uiInput

uiInput(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:47


uiColor

uiColor(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:50


uiImage

uiImage(label?, params?): PropertyDecorator

Parameters

NameType
label?string
params?any

Returns

PropertyDecorator

Defined in

webgi/src/ui/uiConfigDecorators.ts:53


generateUiConfig

generateUiConfig(obj): UiObjectConfig[]

Parameters

NameType
objany

Returns

UiObjectConfig[]

Defined in

webgi/src/ui/uiConfigDecorators.ts:57


generateUiFolder

generateUiFolder(label, obj, params?, type?): UiObjectConfig

Parameters

NameTypeDefault value
labelstringundefined
objanyundefined
paramsany{}
typestring'folder'

Returns

UiObjectConfig

Defined in

webgi/src/ui/uiConfigDecorators.ts:145


uiFolder

uiFolder(label, params?, type?): <T>(constructor: T) => { prototype: __class<any> } & T

Parameters

NameTypeDefault value
labelstringundefined
params?anyundefined
typestring'folder'

Returns

fn

▸ <T>(constructor): { prototype: __class<any> } & T

Type parameters
NameType
Textends (...args: any[]) => any
Parameters
NameType
constructorT
Returns

{ prototype: __class<any> } & T

Defined in

webgi/src/ui/uiConfigDecorators.ts:155


uiPanel

uiPanel(label, params?): <T>(constructor: T) => { prototype: __class<any> } & T

Parameters

NameType
labelstring
params?any

Returns

fn

▸ <T>(constructor): { prototype: __class<any> } & T

Type parameters
NameType
Textends (...args: any[]) => any
Parameters
NameType
constructorT
Returns

{ prototype: __class<any> } & T

Defined in

webgi/src/ui/uiConfigDecorators.ts:163


valueToUiType

valueToUiType(val): null | "input" | "button" | "folder" | "checkbox" | "number" | "vec" | "color" | "image"

Parameters

NameType
valany

Returns

null | "input" | "button" | "folder" | "checkbox" | "number" | "vec" | "color" | "image"

Defined in

webgi/src/ui/uiConfigDecorators.ts:167

Variables

iGeometryIgnoredUserData

Const iGeometryIgnoredUserData: string[]

Defined in

webgi/src/core/threejs/iModelSetup.ts:322


iModelIgnoredUserData

Const iModelIgnoredUserData: string[]

Defined in

webgi/src/core/threejs/iModelSetup.ts:323


basicMaterialPropList

Const basicMaterialPropList: Object

Type declaration

NameType
namestring
blending1
side0
vertexColorsboolean
opacitynumber
transparentboolean
blendSrc204
blendDst205
blendEquation100
blendSrcAlphanull
blendDstAlphanull
blendEquationAlphanull
depthFunc3
depthTestboolean
depthWriteboolean
stencilWriteMasknumber
stencilFunc519
stencilRefnumber
stencilFuncMasknumber
stencilFail7680
stencilZFail7680
stencilZPass7680
stencilWriteboolean
clippingPlanesnull
clipIntersectionboolean
clipShadowsboolean
shadowSidenull
colorWriteboolean
precisionnull
polygonOffsetboolean
polygonOffsetFactornumber
polygonOffsetUnitsnumber
ditheringboolean
alphaToCoverageboolean
premultipliedAlphaboolean
forceSinglePassboolean
visibleboolean
toneMappedboolean
userData{}
alphaTestnumber
colorstring
mapnull
lightMapnull
lightMapIntensitynumber
aoMapnull
aoMapIntensitynumber
specularMapnull
alphaMapnull
envMapnull
combine0
reflectivitynumber
refractionRationumber
wireframeboolean
wireframeLinewidthnumber
wireframeLinecapstring
wireframeLinejoinstring
skinningboolean
fogboolean

Defined in

webgi/src/extras/asset_manager/threejs/MeshBasicMaterial2.ts:34


standardMaterialPropList

Const standardMaterialPropList: Object

Type declaration

NameType
namestring
blending1
side0
vertexColorsboolean
opacitynumber
transparentboolean
blendSrc204
blendDst205
blendEquation100
blendSrcAlphanull
blendDstAlphanull
blendEquationAlphanull
depthFunc3
depthTestboolean
depthWriteboolean
stencilWriteMasknumber
stencilFunc519
stencilRefnumber
stencilFuncMasknumber
stencilFail7680
stencilZFail7680
stencilZPass7680
stencilWriteboolean
clippingPlanesnull
clipIntersectionboolean
clipShadowsboolean
shadowSidenull
colorWriteboolean
precisionnull
polygonOffsetboolean
polygonOffsetFactornumber
polygonOffsetUnitsnumber
ditheringboolean
alphaToCoverageboolean
premultipliedAlphaboolean
forceSinglePassboolean
visibleboolean
toneMappedboolean
userData{}
alphaTestnumber
colorstring
roughnessnumber
metalnessnumber
mapnull
lightMapnull
lightMapIntensitynumber
aoMapnull
aoMapIntensitynumber
emissivestring
emissiveIntensitynumber
emissiveMapnull
bumpMapnull
bumpScalenumber
normalMapnull
normalMapType0
normalScaleVector2
displacementMapnull
displacementScalenumber
displacementBiasnumber
roughnessMapnull
metalnessMapnull
alphaMapnull
envMapnull
envMapIntensitynumber
wireframeboolean
wireframeLinewidthnumber
wireframeLinecapstring
wireframeLinejoinstring
flatShadingboolean
fogboolean

Defined in

webgi/src/extras/asset_manager/threejs/MeshStandardMaterial2.ts:52


physicalMaterialPropList

Const physicalMaterialPropList: Object

Type declaration

NameType
namestring
blending1
side0
vertexColorsboolean
opacitynumber
transparentboolean
blendSrc204
blendDst205
blendEquation100
blendSrcAlphanull
blendDstAlphanull
blendEquationAlphanull
depthFunc3
depthTestboolean
depthWriteboolean
stencilWriteMasknumber
stencilFunc519
stencilRefnumber
stencilFuncMasknumber
stencilFail7680
stencilZFail7680
stencilZPass7680
stencilWriteboolean
clippingPlanesnull
clipIntersectionboolean
clipShadowsboolean
shadowSidenull
colorWriteboolean
precisionnull
polygonOffsetboolean
polygonOffsetFactornumber
polygonOffsetUnitsnumber
ditheringboolean
alphaToCoverageboolean
premultipliedAlphaboolean
forceSinglePassboolean
visibleboolean
toneMappedboolean
userData{}
alphaTestnumber
colorstring
roughnessnumber
metalnessnumber
mapnull
lightMapnull
lightMapIntensitynumber
aoMapnull
aoMapIntensitynumber
emissivestring
emissiveIntensitynumber
emissiveMapnull
bumpMapnull
bumpScalenumber
normalMapnull
normalMapType0
normalScaleVector2
displacementMapnull
displacementScalenumber
displacementBiasnumber
roughnessMapnull
metalnessMapnull
alphaMapnull
envMapnull
envMapIntensitynumber
wireframeboolean
wireframeLinewidthnumber
wireframeLinecapstring
wireframeLinejoinstring
flatShadingboolean
fogboolean
clearcoatnumber
clearcoatMapnull
clearcoatRoughnessnumber
clearcoatRoughnessMapnull
clearcoatNormalScaleVector2
clearcoatNormalMapnull
reflectivitynumber
iridescencenumber
iridescenceMapnull
iridescenceIORnumber
iridescenceThicknessRangenumber[]
iridescenceThicknessMapnull
sheennumber
sheenColorColor
sheenColorMapnull
sheenRoughnessnumber
sheenRoughnessMapnull
transmissionnumber
transmissionMapnull
thicknessnumber
thicknessMapnull
attenuationDistancenumber
attenuationColorColor
specularIntensitynumber
specularIntensityMapnull
specularColorColor
specularColorMapnull

Defined in

webgi/src/extras/asset_manager/threejs/MeshStandardMaterial2.ts:105


iMaterialIgnoredUserData

Const iMaterialIgnoredUserData: string[]

Defined in

webgi/src/extras/asset_manager/threejs/materialUtils.ts:196


iTextureIgnoredUserData

Const iTextureIgnoredUserData: string[]

Defined in

webgi/src/extras/asset_manager/threejs/materialUtils.ts:217


envMapBackground

Const envMapBackground: EnvMapBackground = 'envMapBackground'

Special value for background to use the environment map.

deprecated will be removed, use 'environment' instead by passing into {@see RootScene.setBackground}

Defined in

webgi/src/viewer/ViewerApp.ts:1192