Vector1

public typealias Vector1 = Scalar
  • Creates a vector for which all components are equal to the given scalar.

    Declaration

    Swift

    public init(scalar: Scalar)
  • The empty vector (all scalar components are equal to 0.0).

    Declaration

    Swift

    public static var zero: Vector1 { get }
  • The number of scalar components in this vector type.

    Declaration

    Swift

    public static var length: Int { get }
  • Declaration

    Swift

    public subscript(index: Int) -> Scalar { get set }
  • Interpolate between the given values.

    Declaration

    Swift

    public func interpolated(to otherValue: Vector1, alpha: Scalar) -> Vector1
  • Interpolate between the given values.

    Declaration

    Swift

    public mutating func interpolate(to otherValue: Vector1, alpha: Scalar)
  • Declaration

    Swift

    public func clamped(min: Vector1, max: Vector1) -> Vector1