Class

io.scalajs.dom.html.pixijs

CanvasRenderer

Related Doc: package pixijs

Permalink

class CanvasRenderer extends Object with AbstractRenderer

The CanvasRenderer draws the scene and all its content onto a 2d canvas. This renderer should be used for browsers that do not support webGL. Don't forget to add the CanvasRenderer.view to your DOM or you will not see anything :)

Annotations
@RawJSType() @native() @JSName( "CanvasRenderer" )
Linear Supertypes
AbstractRenderer, Object, Any, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. CanvasRenderer
  2. AbstractRenderer
  3. Object
  4. Any
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new CanvasRenderer(width: Double = js.native, height: Double = js.native, options: |[CanvasRendererOptions, RawOptions] = js.native)

    Permalink

    width

    the width of the canvas view

    height

    the height of the canvas view

    options

    The optional renderer parameters

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  5. var autoResize: Boolean

    Permalink

    Whether the render view should be resized automatically

  6. var backgroundColor: Color

    Permalink

    The background color to fill if not transparent

  7. var blendModes: Any

    Permalink

    Tracks the blend modes useful for this renderer.

  8. var clearBeforeRender: Boolean

    Permalink

    This sets if the CanvasRenderer will clear the canvas or not before the new render pass.

    This sets if the CanvasRenderer will clear the canvas or not before the new render pass. If the scene is NOT transparent Pixi will use a canvas sized fillRect operation every frame to set the canvas background color. If the scene is transparent Pixi 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.

  9. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  10. var context: CanvasRenderingContext2D

    Permalink

    The canvas 2d context that everything is drawn with.

  11. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  12. def equals(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  13. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  14. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  15. def hasOwnProperty(v: String): Boolean

    Permalink
    Definition Classes
    Object
  16. def hashCode(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  17. var height: Double

    Permalink

    the height of the canvas view

  18. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  19. def isPrototypeOf(v: Object): Boolean

    Permalink
    Definition Classes
    Object
  20. var maskManager: CanvasMaskManager

    Permalink

    Instance of a CanvasMaskManager, handles masking when using the canvas renderer.

  21. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  22. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  23. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  24. var options: |[CanvasRendererOptions, RawOptions]

    Permalink

    The optional renderer parameters

  25. var preserveDrawingBuffer: Boolean

    Permalink

    The value of the preserveDrawingBuffer flag affects whether or not the contents of the stencil buffer is retained after rendering.

  26. def propertyIsEnumerable(v: String): Boolean

    Permalink
    Definition Classes
    Object
  27. var refresh: Boolean

    Permalink

    Boolean flag controlling canvas refresh.

  28. var resolution: Resolution

    Permalink

    The resolution of the renderer

  29. var roundPixels: Double

    Permalink

    If true Pixi will Math.floor() x/y values when rendering, stopping pixel interpolation.

    If true Pixi will Math.floor() x/y values when rendering, stopping pixel interpolation. Handy for crisp pixel art and speed on legacy devices.

  30. var smoothProperty: String

    Permalink

    The canvas property used to set the canvas smoothing property.

  31. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  32. def toLocaleString(): String

    Permalink
    Definition Classes
    Object
  33. def toString(): String

    Permalink
    Definition Classes
    AnyRef → Any
  34. var transparent: Boolean

    Permalink

    Whether the render view is transparent

  35. var type: Int

    Permalink

    The type of the renderer.

    The type of the renderer. Default: PIXI.RENDERER_TYPE.UNKNOWN

  36. def valueOf(): Any

    Permalink
    Definition Classes
    Object
  37. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  38. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  39. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  40. var width: Double

    Permalink

    the width of the canvas view

Inherited from AbstractRenderer

Inherited from Object

Inherited from Any

Inherited from AnyRef

Inherited from Any

Ungrouped