API ReferenceGlobalsRoomleGLBViewer

# Class: RoomleGLBViewer

# Hierarchy

  • RoomleGLBViewer

# Implements

# Index

# Constructors

# Properties

# Accessors

# Methods

# Constructors

# constructor

+ new RoomleGLBViewer(creator: string): RoomleGLBViewer

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:62

Parameters:

Name Type
creator string

Returns: RoomleGLBViewer

# Properties

# creator

creator: string

_Implementation of Context.creator_

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:37

# Accessors

# callbacks

get callbacks(): object

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:231

Returns: object

# Methods

# clearScene

clearScene(): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:120

Remove the current glb from the scene if it exists

Returns: void


# enableHD

enableHD(): Promise‹void›

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:102

Returns: Promise‹void›


# getCameraOffset

getCameraOffset(): CanvasOffset

Implementation of GlobalAPI

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:72

Returns: CanvasOffset


# getCurrentId

getCurrentId(): string

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:150

Returns the current item id or url of the loaded object

Returns: string


# getScene

getScene(): Scene

Implementation of GlobalAPI

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:235

Returns: Scene


# init

init(element: HTMLElement, initData?: InitDataDefinition): Promise‹void›

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:76

Parameters:

Name Type
element HTMLElement
initData? InitDataDefinition

Returns: Promise‹void›


# loadGLB

loadGLB(url: string, scaling: number, callback?: function): Promise‹void›

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:130

Loads the GLB from the given URL Param

Parameters:

url: string

Default value scaling: number= 1

defaults to 1

Optional callback: function

loading percent between 0 and 1

▸ (percent: number): void

Parameters:

Name Type
percent number

Returns: Promise‹void›


# loadQualitySetting

loadQualitySetting(qualitySetting: QualitySetting): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:167

Loads a QualitySetting object (see QualitySetting).

Parameters:

Name Type Description
qualitySetting QualitySetting

Returns: void


# loadSceneSetting

loadSceneSetting(sceneSettings: SceneSettings): Promise‹void›

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:159

Loads a SceneSettings object, currently it can can contain a light setting definition (see loadDynamicLightSetting) and an environment definition (see EnvironmentSetting).

Parameters:

Name Type Description
sceneSettings SceneSettings

Returns: Promise‹void›


# loadStaticItem

loadStaticItem(staticItemId: string, callback?: function): Promise‹void›

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:141

Loads the glb asset from the static item

Parameters:

staticItemId: string

Optional callback: function

loading percent between 0 and 1

▸ (percent: number): void

Parameters:

Name Type
percent number

Returns: Promise‹void›


# pauseTest

pauseTest(): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:223

Returns: void


# preparePerspectiveImage

preparePerspectiveImage(): Promise‹Base64Image

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:171

Returns: Promise‹Base64Image


# processRenderList

processRenderList(jsonString: string, width: number, height: number): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:175

Parameters:

Name Type Default
jsonString string -
width number 320
height number 320

Returns: void


# resumeTest

resumeTest(element: HTMLElement): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:218

Parameters:

Name Type
element HTMLElement

Returns: void


# setCameraOffset

setCameraOffset(offset: CanvasOffset): void

Implementation of GlobalAPI

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:68

Parameters:

Name Type
offset CanvasOffset

Returns: void


# setOverrides

setOverrides(initData: InitDataDefinition & GlobalInitDataDefinition): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:196

Parameters:

Name Type
initData InitDataDefinition & GlobalInitDataDefinition

Returns: void


# showGUI

showGUI(): void

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:227

Returns: void


# updateScene

updateScene(): void

Implementation of GlobalAPI

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:239

Returns: void


# updateSize

updateSize(): void

Implementation of GlobalAPI

Defined in packages/glb-viewer-core/src/roomle-glb-viewer.ts:204

Returns: void