EpigraphTourApi

Constructors

Constructor

new EpigraphTourApi(appWcRef): EpigraphTourApi

Parameters

appWcRef

EpigraphThreedCore

Returns

EpigraphTourApi

Overrides

EpigraphViewerApi.constructor

Overrides

EpigraphViewerApi._appWcRef

Methods

addHotspot()

addHotspot(config): void

Adds a new hotspot to the scene.

Parameters

config

IHotspotConfig

The configuration for the new hotspot.

Returns

void

Implementation of

IFeatureHotspot.addHotspot


areDimensionsVisible()

areDimensionsVisible(): boolean

Checks if the dimensions are currently visible.

Returns

boolean

true if the dimensions are visible, otherwise false.

Implementation of

IFeatureDimensions.areDimensionsVisible

Inherited from

EpigraphViewerApi.areDimensionsVisible


areHotspotsVisible()

areHotspotsVisible(): boolean

Checks if hotspots are currently visible.

Returns

boolean

true if hotspots are visible, otherwise false.

Implementation of

IFeatureHotspot.areHotspotsVisible


canLaunchAR()

canLaunchAR(): boolean

Checks if the current device and browser support launching an AR session.

Returns

boolean

true if AR can be launched, otherwise false.

Implementation of

IFeatureViewInYourSpace.canLaunchAR

Inherited from

EpigraphViewerApi.canLaunchAR


closeActiveHotspot()

closeActiveHotspot(): void

Closes the currently active hotspot.

Returns

void

Implementation of

IFeatureHotspot.closeActiveHotspot


disableCameraZoomLimits()

disableCameraZoomLimits(): void

Disables the camera zoom limits, allowing for infinite zoom in and out.

Returns

void

Implementation of

IFeatureCameraControls.disableCameraZoomLimits

Inherited from

EpigraphViewerApi.disableCameraZoomLimits


enterDefaultState()

enterDefaultState(): void

Enters the default state, which may be picker or view state depending on configuration.

Returns

void

Implementation of

IFeatureHotspot.enterDefaultState


enterPickerState()

enterPickerState(): void

Enters the hotspot picker state, allowing the user to place hotspots.

Returns

void

Implementation of

IFeatureHotspot.enterPickerState


enterViewState()

enterViewState(): void

Enters the hotspot view state, where hotspots are visible and interactive.

Returns

void

Implementation of

IFeatureHotspot.enterViewState


getActiveHotspot()

getActiveHotspot(): EpgHotspot | undefined

Gets the currently active hotspot.

Returns

EpgHotspot | undefined

The active hotspot, or undefined if no hotspot is active.

Implementation of

IFeatureHotspot.getActiveHotspot


getAllHotspotIds()

getAllHotspotIds(): number[]

Gets the IDs of all hotspots in the scene.

Returns

number[]

An array of all hotspot IDs.

Implementation of

IFeatureHotspot.getAllHotspotIds


getAllHotspots()

getAllHotspots(): EpgHotspot[]

Gets all hotspots in the scene.

Returns

EpgHotspot[]

An array of all hotspots.

Implementation of

IFeatureHotspot.getAllHotspots


getCameraFocalLength()

getCameraFocalLength(): number

Gets the current camera focal length.

Returns

number

The current camera focal length.

Implementation of

IFeatureCameraControls.getCameraFocalLength

Inherited from

EpigraphViewerApi.getCameraFocalLength


getCameraRotation()

getCameraRotation(): ICameraRotationConfig

Gets the current camera rotation in terms of azimuth and polar angles.

Returns

ICameraRotationConfig

The current camera rotation.

Implementation of

IFeatureCameraControls.getCameraRotation

Inherited from

EpigraphViewerApi.getCameraRotation


getCameraTransforms()

getCameraTransforms(): ICameraStateConfig

Gets the current camera position and target.

Returns

ICameraStateConfig

The current camera transforms.

Implementation of

IFeatureCameraControls.getCameraTransforms

Inherited from

EpigraphViewerApi.getCameraTransforms


getDimensions()

getDimensions(): object

Gets the dimensions of the product.

Returns

object

The dimensions of the product.

height

height: number = currentDimensions.height.distance

length

length: number = currentDimensions.length.distance

unit

unit: DistanceUnits = dimensionsUnit

width

width: number = currentDimensions.width.distance

Implementation of

IFeatureDimensions.getDimensions

Inherited from

EpigraphViewerApi.getDimensions


getHotspotById()

getHotspotById(id): EpgHotspot | undefined

Gets a hotspot by its ID.

Parameters

id

number

The ID of the hotspot to get.

Returns

EpgHotspot | undefined

The hotspot with the given ID, or undefined if not found.

Implementation of

IFeatureHotspot.getHotspotById


getIntersectionOnProductFromPoint()

getIntersectionOnProductFromPoint(clientX, clientY): IAssetInterrsectionDetails | null

Gets detailed information about the intersection of a ray cast from a screen point with the product.

Parameters

clientX

number

The x-coordinate of the point on the screen.

clientY

number

The y-coordinate of the point on the screen.

Returns

IAssetInterrsectionDetails | null

The intersection details, or null if there is no intersection.

Implementation of

IFeatureViewer.getIntersectionOnProductFromPoint

Inherited from

EpigraphViewerApi.getIntersectionOnProductFromPoint


getMinimumRequirementsString()

getMinimumRequirementsString(): string

Gets a string describing the minimum requirements for the AR feature.

Returns

string

A string with the minimum requirements.

Implementation of

IFeatureViewInYourSpace.getMinimumRequirementsString

Inherited from

EpigraphViewerApi.getMinimumRequirementsString


getPositionOnMeshFromPoint()

getPositionOnMeshFromPoint(clientX, clientY): Vector3 | null

Gets the 3D position on the mesh corresponding to a 2D point on the screen.

Parameters

clientX

number

The x-coordinate of the point on the screen.

clientY

number

The y-coordinate of the point on the screen.

Returns

Vector3 | null

The 3D position on the mesh, or null if there is no intersection.

Implementation of

IFeatureViewer.getPositionOnMeshFromPoint

Inherited from

EpigraphViewerApi.getPositionOnMeshFromPoint


getSceneAnimations()

getSceneAnimations(): ISceneAnimations

Gets the available animations for the scene.

Returns

ISceneAnimations

The available scene animations.

Implementation of

IFeatureAnimations.getSceneAnimations

Inherited from

EpigraphViewerApi.getSceneAnimations


getViewInYourSpaceQR()

getViewInYourSpaceQR(): Promise<string>

Beta

Gets the QR code for the "View in Your Space" feature.

Returns

Promise<string>

A promise that resolves with the QR code data. Currently returns an empty string.

Implementation of

IFeatureViewInYourSpace.getViewInYourSpaceQR

Inherited from

EpigraphViewerApi.getViewInYourSpaceQR


getViewInYourSpaceUrl()

getViewInYourSpaceUrl(): Promise<string>

Beta

Gets the URL for the "View in Your Space" feature.

Returns

Promise<string>

A promise that resolves with the URL string. Currently returns an empty string.

Implementation of

IFeatureViewInYourSpace.getViewInYourSpaceUrl

Inherited from

EpigraphViewerApi.getViewInYourSpaceUrl


hideDimensions()

hideDimensions(): void

Hides the dimensions of the product.

Returns

void

Implementation of

IFeatureDimensions.hideDimensions

Inherited from

EpigraphViewerApi.hideDimensions


hideHelp()

hideHelp(): void

Hides the help dialog.

Returns

void

Implementation of

IFeatureHelp.hideHelp

Inherited from

EpigraphViewerApi.hideHelp


hideHotspots()

hideHotspots(): void

Hides all hotspots.

Returns

void

Implementation of

IFeatureHotspot.hideHotspots


highlightEntityByAssetId()

highlightEntityByAssetId(assetId): void

Highlights an entity in the scene by its asset ID.

Parameters

assetId

number

The ID of the asset to highlight.

Returns

void

Implementation of

IFeatureViewer.highlightEntityByAssetId

Inherited from

EpigraphViewerApi.highlightEntityByAssetId


isARSessionActive()

isARSessionActive(): boolean

Checks if an AR session is currently active.

Returns

boolean

true if an AR session is active, otherwise false.

Implementation of

IFeatureViewInYourSpace.isARSessionActive

Inherited from

EpigraphViewerApi.isARSessionActive


isHelpVisible()

isHelpVisible(): boolean

Checks if the help dialog is currently visible.

Returns

boolean

true if the help dialog is visible, otherwise false.

Implementation of

IFeatureHelp.isHelpVisible

Inherited from

EpigraphViewerApi.isHelpVisible


launchAR()

launchAR(): Promise<boolean | undefined>

Launches the Augmented Reality (AR) experience.

Returns

Promise<boolean | undefined>

A promise that resolves when the AR session is launched.

Implementation of

IFeatureViewInYourSpace.launchAR

Inherited from

EpigraphViewerApi.launchAR


nextHotspot()

nextHotspot(): EpgHotspot | undefined

Navigates to the next hotspot in the tour.

Returns

EpgHotspot | undefined

The next hotspot, or undefined if there is no next hotspot.

Implementation of

IFeatureHotspot.nextHotspot


openHotspot()

openHotspot(options): void

Opens a hotspot and sets its state.

Parameters

options

The options for opening the hotspot.

hotspotId

number

The ID of the hotspot to open.

skipHotspotOpenEvent?

boolean = false

Whether to skip firing the hotspot open event.

state?

HOTSPOT_STATES

The state to set the hotspot to.

Returns

void

Implementation of

IFeatureHotspot.openHotspot


pauseActiveAnimations()

pauseActiveAnimations(time?): void

Pauses all active animations.

Parameters

time?

number

The time at which to pause the animations.

Returns

void

Implementation of

IFeatureAnimations.pauseActiveAnimations

Inherited from

EpigraphViewerApi.pauseActiveAnimations


playAnimationByNameAndId()

playAnimationByNameAndId(options): void

Plays an animation by name and asset ID.

Parameters

options

IAnimationPlaybackOptions

The options for playing the animation.

Returns

void

Implementation of

IFeatureAnimations.playAnimationByNameAndId

Inherited from

EpigraphViewerApi.playAnimationByNameAndId


previousHotspot()

previousHotspot(): EpgHotspot | undefined

Navigates to the previous hotspot in the tour.

Returns

EpgHotspot | undefined

The previous hotspot, or undefined if there is no previous hotspot.

Implementation of

IFeatureHotspot.previousHotspot


removeHotspot()

removeHotspot(id): void

Removes a hotspot from the scene.

Parameters

id

number

The ID of the hotspot to remove.

Returns

void

Implementation of

IFeatureHotspot.removeHotspot


resumeActiveAnimations()

resumeActiveAnimations(): void

Resumes all paused animations.

Returns

void

Implementation of

IFeatureAnimations.resumeActiveAnimations

Inherited from

EpigraphViewerApi.resumeActiveAnimations


selectFinishForAsset()

selectFinishForAsset(finishId, assetName): Promise<boolean>

Selects a finish for a specific asset in the scene.

Parameters

finishId

string

The ID of the finish to apply.

assetName

string

The name of the asset to apply the finish to.

Returns

Promise<boolean>

A promise that resolves to true if the finish was applied successfully, otherwise false.

Inherited from

EpigraphViewerApi.selectFinishForAsset


setActiveHotspotState()

setActiveHotspotState(state): void

Sets the state of the currently active hotspot.

Parameters

state

HOTSPOT_STATES

The new state for the active hotspot.

Returns

void

Implementation of

IFeatureHotspot.setActiveHotspotState


setCameraFocalLength()

setCameraFocalLength(focalLength): void

Sets the camera focal length.

Parameters

focalLength

number

The new focal length.

Returns

void

Implementation of

IFeatureCameraControls.setCameraFocalLength

Inherited from

EpigraphViewerApi.setCameraFocalLength


setCameraRotation()

setCameraRotation(rotationConfig, transition?): Promise<void>

Rotates the camera to a new location.

Parameters

rotationConfig

ICameraRotationConfig

The new rotation configuration.

transition?

boolean

Whether to animate the camera movement.

Returns

Promise<void>

A promise that resolves when the camera has finished rotating.

Implementation of

IFeatureCameraControls.setCameraRotation

Inherited from

EpigraphViewerApi.setCameraRotation


setCameraTransforms()

setCameraTransforms(newCameraTransformsConfig): void

Moves the camera to a new position and target.

Parameters

newCameraTransformsConfig

ICameraStateConfig

The new camera transforms.

Returns

void

Implementation of

IFeatureCameraControls.setCameraTransforms

Inherited from

EpigraphViewerApi.setCameraTransforms


setCameraZoomLimits()

setCameraZoomLimits(limits): void

Sets the minimum and maximum zoom distance for the camera.

Parameters

limits

An object containing the minimum and maximum distance.

maxDistance?

number

The maximum zoom distance.

minDistance?

number

The minimum zoom distance.

Returns

void

Implementation of

IFeatureCameraControls.setCameraZoomLimits

Inherited from

EpigraphViewerApi.setCameraZoomLimits


showDimensions()

showDimensions(): void

Shows the dimensions of the product.

Returns

void

Implementation of

IFeatureDimensions.showDimensions

Inherited from

EpigraphViewerApi.showDimensions


showHelp()

showHelp(): void

Shows the help dialog.

Returns

void

Implementation of

IFeatureHelp.showHelp

Inherited from

EpigraphViewerApi.showHelp


showHotspots()

showHotspots(): void

Shows all hotspots.

Returns

void

Implementation of

IFeatureHotspot.showHotspots


stopAllAnimations()

stopAllAnimations(): void

Stops all animations.

Returns

void

Implementation of

IFeatureAnimations.stopAllAnimations

Inherited from

EpigraphViewerApi.stopAllAnimations


stopAnimationByNameAndAssetId()

stopAnimationByNameAndAssetId(animationName, assetId): void

Stops an animation by name and asset ID.

Parameters

animationName

string

The name of the animation to stop.

assetId

number

The ID of the asset whose animation should be stopped.

Returns

void

Implementation of

IFeatureAnimations.stopAnimationByNameAndAssetId

Inherited from

EpigraphViewerApi.stopAnimationByNameAndAssetId


toggleDimensions()

toggleDimensions(): void

Toggles the visibility of the dimensions.

Returns

void

Todo

Implement the logic for this method.

Implementation of

IFeatureDimensions.toggleDimensions

Inherited from

EpigraphViewerApi.toggleDimensions


toggleHelp()

toggleHelp(): void

Toggles the visibility of the help dialog.

Returns

void

Implementation of

IFeatureHelp.toggleHelp

Inherited from

EpigraphViewerApi.toggleHelp


toggleHotspots()

toggleHotspots(): void

Toggles the visibility of all hotspots.

Returns

void

Implementation of

IFeatureHotspot.toggleHotspots


unhighlightAllEntities()

unhighlightAllEntities(): void

Removes all highlights from entities in the scene.

Returns

void

Implementation of

IFeatureViewer.unhighlightAllEntities

Inherited from

EpigraphViewerApi.unhighlightAllEntities


updateHotspot()

updateHotspot(id, config): void

Updates an existing hotspot.

Parameters

id

number

The ID of the hotspot to update.

config

IHotspotConfig

The new configuration for the hotspot.

Returns

void

Implementation of

IFeatureHotspot.updateHotspot


updateHotspotsOrder()

updateHotspotsOrder(newOrder): void

Updates the order of the hotspots.

Parameters

newOrder

number[]

An array of hotspot IDs in the new order.

Returns

void

Implementation of

IFeatureHotspot.updateHotspotsOrder


viewInYourSpace()

viewInYourSpace(): Promise<boolean | undefined>

An alias for the launchAR method. Launches the "View in Your Space" (AR) experience.

Returns

Promise<boolean | undefined>

A promise that resolves when the AR session is launched.

Implementation of

IFeatureViewInYourSpace.viewInYourSpace

Inherited from

EpigraphViewerApi.viewInYourSpace