A set of blur filter instances which are modified by the zoom level and the "soft shadows" setting
A reference to the MouseInteractionManager that is currently controlling pointer-based interaction, or null.
Configure options passed to the texture loaded for the Scene. This object can be configured during the canvasInit hook before textures have been loaded.
Configure options used by the visibility framework for special effects This object can be configured during the canvasInit hook before visibility is initialized.
Configure options passed to initialize blur for the Scene and override normal behavior. This object can be configured during the canvasInit hook before blur is initialized.
Configure the Textures to apply to the Scene. Textures registered here will be automatically loaded as part of the TextureLoader.loadSceneTextures workflow. Textures which need to be loaded should be configured during the "canvasInit" hook.
Record framerate performance data.
The singleton interaction manager instance which handles mouse interaction on the Canvas.
Configured performance settings which affect the behavior of the Canvas and its renderer.
A list of supported webGL capabilities and limitations.
Is the photosensitive mode enabled?
The renderer screen dimensions.
A flag to indicate whether a new Scene is currently being drawn.
A promise that resolves when the canvas is first initialized and ready.
The singleton PIXI.Application instance rendered on the Canvas.
The primary stage container of the PIXI.Application.
The rendered canvas group which render the environment canvas group and the interface canvas group.
A singleton CanvasEdges instance.
The singleton FogManager instance.
A perception manager interface for batching lighting, sight, and sound updates.
The environment canvas group which render the primary canvas group and the effects canvas group.
The primary Canvas group which generally contains tangible physical objects which exist within the Scene. This group is a CachedContainer which is rendered to the Scene as a SpriteMesh. This allows the rendered result of the Primary Canvas Group to be affected by a BaseSamplerShader.
The effects Canvas group which modifies the result of the PrimaryCanvasGroup by adding special effects. This includes lighting, vision, fog of war and related animations.
The visibility Canvas group which handles the fog of war overlay by consolidating multiple render textures, and applying a filter with special effects and blur.
The interface Canvas group which is rendered above other groups and contains all interactive elements. The various InteractionLayer instances of the interface group provide different control sets for interacting with different types of Documents which can be represented on the Canvas.
The overlay Canvas group which is rendered above other groups and contains elements not bound to stage transform.
The singleton HeadsUpDisplay container which overlays HTML rendering on top of this Canvas.
Position of the mouse on stage.
Force snapping to grid vertices?
Track objects which have pending render flags.
Private
#throttleA throttled function that handles mouse moves.
Private
#drawingAn internal reference to a Promise in-progress to draw the canvas.
Private
#dragThe DragDrop instance which handles interactivity resulting from DragTransfer events.
Private
#reloadAn object of data which caches data which should be persisted across re-draws of the game canvas.
Private
_panTrack the last automatic pan time to throttle
Private
#tickerCached references to bound ticker functions which can be removed later.
A flag for whether the game Canvas is fully initialized and ready for additional content to be drawn.
A SceneManager instance which adds behaviors to this Scene, or null if there is no manager.
The current pixel dimensions of the displayed Scene, or null if the Canvas is blank.
A reference to the grid of the currently displayed Scene document, or null if the Canvas is currently blank.
A flag for whether the game Canvas is ready to be used. False if the canvas is not yet drawn, true otherwise.
Shortcut to get the masks container from HiddenCanvasGroup.
The id of the currently displayed Scene.
An Array of all CanvasLayer instances which are active on the Canvas board
Return a reference to the active Canvas Layer
The currently displayed darkness level, which may override the saved Scene value.
Static
layersA mapping of named CanvasLayer classes which defines the layers which comprise the Scene.
Internal
Configure performance settings for hte canvas application based on the selected performance mode.
Given an embedded object name, get the canvas layer for that object
Get the InteractionLayer of the canvas which manages Documents of a certain collection within the Scene.
The collection name
The canvas layer
Pan the canvas to a certain {x,y} coordinate and a certain zoom level
The canvas position to pan to
Animate panning the canvas to a certain destination coordinate and zoom scale Customize the animation speed with additional options Returns a Promise which is resolved once the animation has completed
The desired view parameters
A Promise which resolves once the animation has been completed
Recenter the canvas with a pan animation that ends in the center of the canvas rectangle.
A desired initial position from which to begin the animation
A Promise which resolves once the animation has been completed
Displays a Ping both locally and on other connected client, following these rules:
Point to display Ping at
Optional
options: PingOptionsAdditional options to configure how the ping is drawn.
Internal
Get the constrained zoom scale parameter which is allowed by the maxZoom parameter
The unconstrained position
The constrained position
Create a BlurFilter instance and register it to the array for updates when the zoom level changes.
The desired blur strength to use for this filter
The desired quality to use for this filter
Private
#initializePrivate
#createPrivate
#attachPrivate
#mapPrivate
#mapPrivate
#createPrivate
_initializePrivate
#drawDraw the game canvas. This method is wrapped by a promise that enqueues multiple draw requests.
Optional
scene: SceneA specific Scene document to render on the Canvas
Private
#handlePrivate
#drawPrivate
#initializePrivate
#initializePrivate
#initializePrivate
#callPrivate
#measureFPSPrivate
updatePrivate
#addPrivate
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#canDoes the User have permission to left-click drag on the Canvas?
The User performing the action.
The event object.
Private
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#onPrivate
#onPrivate
_onPrivate
_onPrivate
_onPrivate
#activatePrivate
#deactivatePrivate
#applyPrivate
#testTest support for some GPU capabilities and update the supported property.
Static
getInternal
Create a SceneManager instance used for this Scene, if any.
Static
clearRemove all children of the display object and call one cleaning method: clean first, then tearDown, and destroy if no cleaning method is found.
The display object to clean.
If textures should be destroyed.
Static
getGet a texture with the required configuration and clear color.
The clear color to use for this texture. Transparent by default.
The render texture configuration.
Static
Private
#configureStatic
Private
#createHTMLCanvasStatic
Private
#configure
The virtual tabletop environment is implemented using a WebGL powered HTML 5 canvas using the powerful PIXI.js library. The canvas is comprised by an ordered sequence of layers which define rendering groups and collections of objects that are drawn on the canvas itself.
Hook Events
hookEvents.canvasConfig hookEvents.canvasInit hookEvents.canvasReady hookEvents.canvasPan hookEvents.canvasTearDown
Example: Canvas State
Example: Canvas Methods