NGL@1.0.0-beta.7 Home Manual Reference Source Gallery
import ArrowBuffer from 'ngl/src/buffer/arrow-buffer.js'
public class | source

ArrowBuffer

Implements:

Arrow buffer. Draws arrows made from a cylinder and a cone.

Example:

var arrowBuffer = new ArrowBuffer( {
    position1: new Float32Array( [ 0, 0, 0 ] ),
    position2: new Float32Array( [ 10, 1, 1 ] ),
    color: new Float32Array( [ 1, 0, 0 ] ),
    radius: new Float32Array( [ 1 ] )
} );

Constructor Summary

Public Constructor
public

Member Summary

Public Members
public
public
public
public
public
public
public set
public get
public get
public
public
public
public
public

Method Summary

Public Methods
public
public
public
public
public
public
public

Set buffer parameters

public

Public Constructors

public constructor(data: Object, params: BufferParameters) source

Params:

NameTypeAttributeDescription
data Object

buffer data

data.position1 Float32Array

from positions

data.position2 Float32Array

to positions

data.color Float32Array

colors

data.radius Float32Array

radii

data.picking Picker
  • optional

picking ids

params BufferParameters
  • optional

parameters object

Public Members

public aspectRatio source

public coneBuffer source

public cylinderBuffer source

public cylinderRadius source

public geometry source

public group source

public set matrix source

public get matrix source

public get pickable source

public picking source

public pickingGroup source

public splitPosition source

public wireframe source

public wireframeGroup source

Public Methods

public dispose() source

public getMesh() source

public getPickingMesh() source

public getWireframeMesh() source

public makeAttributes() source

public setAttributes() source

public setParameters(params: BufferParameters): undefined source

Set buffer parameters

Params:

NameTypeAttributeDescription
params BufferParameters

buffer parameters object

Return:

undefined

public setVisibility() source