Class: Renderer

PSV.services~Renderer

new Renderer (psv)

Viewer and renderer

Name Type Description
psv PSV.Viewer

Extends

Members

camera external:THREE.PerspectiveCamera protectedreadonly

canvasContainer HTMLElement protectedreadonly

config PSV.Options readonly inherited overrides

Configuration holder

mesh external:THREE.Mesh protectedreadonly

prop Object readonly inherited overrides

Properties holder

Reference to main controller

raycaster external:THREE.Raycaster protectedreadonly

renderer external:THREE.WebGLRenderer protectedreadonly

scene external:THREE.Scene protectedreadonly

Methods

__renderLoop (timestamp) package

Main event loop, calls render if prop.needsUpdate is true

Name Type Description
timestamp number
Fires:
  • PSV.event:before-render

destroy () inherited overrides

Destroys the service

hide ()

Hides the viewer

render ()

Performs a render

Do not call this method directly, instead call PSV.Viewer#needsUpdate on PSV.event:before-render.

Fires:
  • PSV.event:render

setSphereCorrection (sphereCorrection, mesh) package

Apply a SphereCorrection to a Mesh

Name Type Default Description
sphereCorrection PSV.SphereCorrection
mesh external:THREE.Mesh this.mesh optional

setTexture (textureData) package

Applies the texture to the scene, creates the scene if needed

Name Type Description
textureData PSV.TextureData
Fires:
  • PSV.event:panorama-loaded

show ()

Shows the viewer

transition (textureData, options)PSV.Animation package

Performs transition between the current and a new texture

Name Type Description
textureData PSV.TextureData
options PSV.PanoramaOptions
Returns:
Type Description
PSV.Animation