Home Reference Source
public class | source

PolarVelocity

Extends:

InitializerVelocity → PolarVelocity

Sets the velocity property on initialized particles.

Static Method Summary

Static Public Methods
public static

Creates a PolarVelocity initializer from JSON.

Constructor Summary

Public Constructor
public

constructor(polar3d: Polar3D, theta: number): *

Constructs a PolarVelocity initializer.

Member Summary

Public Members
public

Directional vector

public

Theta.

Private Members
private

Determines whether to use the directional vector or not.

Inherited Summary

From class Initializer
public static abstract

Returns a new instance of the initializer from the JSON object passed.

public static

Determines if the initializer requires a Web GL API to be provided to its constructor.

public
public

type: *

public

init(emitter: Emitter, particle: Particle): *

Initializes the property on the emitter or particle.

public abstract

initialize(target: object)

Place custom property initialization code in this method in the subclass.

public abstract

reset()

From class Velocity
public

Directional vector

public

normalize(vr: *): *

Static Public Methods

public static fromJSON(json: object): PolarVelocity source

Creates a PolarVelocity initializer from JSON.

Override:

Initializer#fromJSON

Params:

NameTypeAttributeDescription
json object

The JSON to construct the instance from.

json.polarRadius number

The Polar3D radius

json.polarTheta number

The Polar3D theta

json.polarPhi number

The Polar3D phi

json.velocityTheta number

The velocity theta

Return:

PolarVelocity

Public Constructors

public constructor(polar3d: Polar3D, theta: number): * source

Constructs a PolarVelocity initializer.

Override:

Velocity#constructor

Params:

NameTypeAttributeDescription
polar3d Polar3D

The polar vector for the velocity

theta number

The theta angle to use

Return:

*

void

Public Members

public dirVec: Vector3D source

Directional vector

Override:

Velocity#dirVec

public tha: number source

Theta.

Private Members

private _useV: boolean source

Determines whether to use the directional vector or not.