Packages

class Vector3D extends AnyRef

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Vector3D
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new Vector3D(from: Coordinate, to: Coordinate)

    Creates a vector with the direction and magnitude of the difference between the to and from {link Coordinate}s.

    Creates a vector with the direction and magnitude of the difference between the to and from {link Coordinate}s.

    from

    the origin Coordinate

    to

    the destination Coordinate return a new vector

  2. new Vector3D(v: Coordinate)

    Creates a new 3D vector from a {link Coordinate}.

    Creates a new 3D vector from a {link Coordinate}. The coordinate should have the X,Y and Z ordinates specified.

  3. new Vector3D(x: Double = 0, y: Double = 0, z: Double = 0)

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. def add(v: Vector3D): Vector3D

    Computes a vector which is the sum of this vector and the given vector.

    Computes a vector which is the sum of this vector and the given vector.

    v

    the vector to add return the sum of this and v

  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  7. def divide(d: Double): Vector3D

    Creates a new vector which has the same direction and with length equals to the length of this vector divided by the scalar value d.

    Creates a new vector which has the same direction and with length equals to the length of this vector divided by the scalar value d.

    d

    the scalar divisor return a new vector with divided length

  8. def dot(v: Vector3D): Double

    Computes the dot-product of two vectors

    Computes the dot-product of two vectors

    v

    a vector return the dot product of the vectors

  9. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  10. def equals(o: Any): Boolean

    Tests if a vector o has the same values for the components.

    Tests if a vector o has the same values for the components.

    o

    a Vector3D with which to do the comparison. return true if other is a Vector3D with the same values for the x and y components.

    Definition Classes
    Vector3D → AnyRef → Any
  11. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  12. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  13. def getX: Double

    Gets the X component of this vector.

    Gets the X component of this vector.

    return the value of the X component

  14. def getY: Double

    Gets the Y component of this vector.

    Gets the Y component of this vector.

    return the value of the Y component

  15. def getZ: Double

    Gets the Z component of this vector.

    Gets the Z component of this vector.

    return the value of the Z component

  16. def hashCode(): Int

    Gets a hashcode for this vector.

    Gets a hashcode for this vector.

    return a hashcode for this vector

    Definition Classes
    Vector3D → AnyRef → Any
  17. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  18. def length: Double

    Computes the length of this vector.

    Computes the length of this vector.

    return the length of the vector

  19. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  20. def normalize: Vector3D

    Computes a vector having identical direction but normalized to have length 1.

    Computes a vector having identical direction but normalized to have length 1.

    return a new normalized vector

  21. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  23. def subtract(v: Vector3D): Vector3D

    Computes a vector which is the difference of this vector and the given vector.

    Computes a vector which is the difference of this vector and the given vector.

    v

    the vector to subtract return the difference of this and v

  24. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  25. def toString(): String

    Gets a string representation of this vector

    Gets a string representation of this vector

    return a string representing this vector

    Definition Classes
    Vector3D → AnyRef → Any
  26. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  27. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  28. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  29. val x: Double
    Attributes
    protected
  30. val y: Double
    Attributes
    protected
  31. val z: Double
    Attributes
    protected

Inherited from AnyRef

Inherited from Any

Ungrouped