Class: ResolutionPlugin

PSV.plugins.ResolutionPlugin

new PSV.plugins.ResolutionPlugin (psv, options)

Adds a setting to choose between multiple resolutions of the panorama.

Name Type Description
psv PSV.Viewer
options PSV.plugins.ResolutionPlugin.Options

Extends

Members

PSV.plugins.ResolutionPlugin.EVENTS string staticconstant

Available events

id string readonly inherited overrides

Unique identifier of the plugin

Reference to main controller

Available resolutions

Methods

destroy () package overrides

getResolution ()string

Returns the current resolution

Returns:
Type Description
string

init () package overrides

setResolution (id)

Changes the current resolution

Name Type Description
id string
Throws:

if the resolution does not exist

Type
PSVError

setResolutions (resolutions, defaultResolution)

Changes the available resolutions

Name Type Description
resolutions Array.<PSV.plugins.ResolutionPlugin.Resolution>
defaultResolution string optional

if not provided, the current panorama is kept

Type Definitions

PSV.plugins.ResolutionPlugin.Options Object

Properties:
Name Type Argument Default Description
resolutions Array.<PSV.plugins.ResolutionPlugin.Resolution>

list of available resolutions

defaultResolution string <optional>

the default resolution if no panorama is configured on the viewer

showBadge boolean <optional>
true

show the resolution id as a badge on the settings button

PSV.plugins.ResolutionPlugin.Resolution Object

Properties:
Name Type Description
id string
label string
panorama *

Events

PSV.plugins.ResolutionPlugin.event:resolution-changed

Triggered when the resolution is changed

Name Type Description
resolutionId string