Class: Arrow

ROS3D. Arrow

new Arrow(options)

A Arrow is a THREE object that can be used to display an arrow model.

Parameters:
Name Type Description
options

object with following keys:

  • origin (optional) - the origin of the arrow
  • direction (optional) - the direction vector of the arrow
  • length (optional) - the length of the arrow
  • headLength (optional) - the head length of the arrow
  • shaftDiameter (optional) - the shaft diameter of the arrow
  • headDiameter (optional) - the head diameter of the arrow
  • material (optional) - the material to use for this arrow
Source:
  • models/Arrow.js, line 19

Methods

setColor(hex)

Set the color of this arrow to the given hex value.

Parameters:
Name Type Description
hex

the hex value of the color to use

Source:
  • models/Arrow.js, line 79

setDirection(direction)

Set the direction of this arrow to that of the given vector.

Parameters:
Name Type Description
direction

the direction to set this arrow

Source:
  • models/Arrow.js, line 58

setLength(length)

Set this arrow to be the given length.

Parameters:
Name Type Description
length

the new length of the arrow

Source:
  • models/Arrow.js, line 70