Class type AbstractRenderer-PIXI._t
inherit PIXI.EventEmitter._t
method autoDensity#=: Js.Internal.meth([ `Arity_1(bool) ], unit)Whether CSS dimensions of canvas view should be resized to screen dimensions automatically
method autoDensity: boolWhether CSS dimensions of canvas view should be resized to screen dimensions automatically
method backgroundColor#=: Js.Internal.meth([ `Arity_1(int) ], unit)The background color to fill if not transparent
method cleanBeforeRender#=: Js.Internal.meth([ `Arity_1(bool) ], unit)This sets if the CanvasRenderer will clear the canvas or not before the new render pass. If the scene is NOT transparent PixiJS will use a canvas sized fillRect operation every frame to set the canvas background color. If the scene is transparent PixiJS will use clearRect to clear the canvas every frame. Disable this by setting this to false. For example, if your game has a canvas filling background image you often don't need this set.
method cleanBeforeRender: boolThis sets if the CanvasRenderer will clear the canvas or not before the new render pass. If the scene is NOT transparent PixiJS will use a canvas sized fillRect operation every frame to set the canvas background color. If the scene is transparent PixiJS will use clearRect to clear the canvas every frame. Disable this by setting this to false. For example, if your game has a canvas filling background image you often don't need this set.
method plugins: rendererPluginsCollection of plugins
method preserveDrawingBuffer#=: Js.Internal.meth([ `Arity_1(bool) ], unit)method preserveDrawingBuffer: boolmethod resolution#=: Js.Internal.meth([ `Arity_1(float) ], unit)The resolution / device pixel ratio of the renderer.
method screen#=: Js.Internal.meth([ `Arity_1(PIXI.Rectangle.t) ], unit)Measurements of the screen. (0, 0, screenWidth, screenHeight). Its safe to use as filterArea or hitArea for the whole stage
method screen: PIXI.Rectangle.tMeasurements of the screen. (0, 0, screenWidth, screenHeight). Its safe to use as filterArea or hitArea for the whole stage
method transparent#=: Js.Internal.meth([ `Arity_1(bool) ], unit)Whether the render view is transparent
method view#=: Js.Internal.meth([ `Arity_1(Dom.element) ], unit)The canvas element that everything is drawn to
method destroy: Js.Internal.meth([ `Arity_1(bool) ], unit)Removes everything from the renderer and optionally removes the Canvas DOM element.
- parameter removeView
removes the Canvas element from the DOM
method generateTexture: Js.Internal.meth([ `Arity_4((displayObjectOpaque, int, float, Js.Undefined.t(PIXI.Rectangle.t))) ], renderTextureOpaque)Useful function that returns a texture of the display object that can then be used to create sprites This can be quite useful if your displayObject is complicated and needs to be reused multiple times
- deprecated
Consider using AbstractRenderer.generateTexture
- see /bs-pixi/PIXI/AbstractRenderer-PIXI/#val-generateTexture
AbstractRederer.generateTexture
- parameter displayObject
The displayObject the object will be generated from
- parameter scaleMode
Should be one of the scaleMode consts
- parameter resolution
The resolution / device pixel ratio of the texture being generated
- parameter region
(optional) The region of the displayObject, that shall be rendered, if no region is specified, defaults to the local bounds of the displayObject
- returns
A texture of the graphics object