three-nebula API
    Preparing search index...

    Class BodySprite

    Sets the body property to be a THREE.Sprite on initialized particles.

    NOTE The texture map MUST be set on the SpriteMaterial in the TextureLoader.load callback. Not doing so will cause WebGL buffer errors.

    Hierarchy

    • default
      • BodySprite
    Index
    • Constructs a BodySprite initializer.

      Parameters

      • THREE: __module

        The Web GL API we are using eg., THREE

      • Optionaltexture: string

        The sprite texture

      • materialProperties: Record<string, unknown> = DEFAULT_MATERIAL_PROPERTIES

        The sprite material properties

      • isEnabled: boolean = true

      Returns BodySprite

      If the TextureLoader fails to load the supplied texture

    isEnabled: boolean
    material: SpriteMaterial
    materialProperties: Record<string, unknown>
    sprite: Sprite
    texture: Texture
    type: string
    • Creates a BodySprite initializer from JSON.

      Parameters

      • json: BodySpriteJSON

        The JSON to construct the instance from

      • THREE: __module

        The Web GL API we are using eg., THREE

      Returns BodySprite

    • Determines if the initializer requires a WebGL API to be provided to its constructor.

      Returns boolean