Search Results for

    Show / Hide Table of Contents

    Class ExMV3

    Functions that return V3.

    Inheritance
    System.Object
    ExMV3
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Danmokou.DMath.Functions
    Assembly: cs.temp.dll.dll
    Syntax
    public static class ExMV3

    Methods

    CylinderWrap(tfloat, tfloat, tfloat, tfloat, tv2)

    Wrap a position equation around a cylinder.

    Declaration
    public static tv3 CylinderWrap(tfloat radius, tfloat ang0, tfloat maxWrap, tfloat axisOff, tv2 position)
    Parameters
    Type Name Description
    tfloat radius

    Radius of the cylinder

    tfloat ang0

    Starting angle offset (radians) on the cylinder. 0 = z-axis

    tfloat maxWrap

    Maximum angle value (radians) of the wrap. After this, the function will continue along the tangent. Starting offset not included. Absolute value tested.

    tfloat axisOff

    Offset angle (radians) of the axis of the cylinder from the y-axis

    tv2 position

    Position equation

    Returns
    Type Description
    tv3

    MultiplyX(tfloat, tv3)

    Multiply the x-component of a parametric equation by a function of input.

    Declaration
    public static tv3 MultiplyX(tfloat f, tv3 tp)
    Parameters
    Type Name Description
    tfloat f

    Function of input

    tv3 tp

    Parametric equation

    Returns
    Type Description
    tv3

    MultiplyY(tfloat, tv3)

    Multiply the y-component of a parametric equation by a function of input.

    Declaration
    public static tv3 MultiplyY(tfloat f, tv3 tp)
    Parameters
    Type Name Description
    tfloat f

    Function of input

    tv3 tp

    Parametric equation

    Returns
    Type Description
    tv3

    MultiplyZ(tfloat, tv3)

    Multiply the z-component of a parametric equation by a function of input.

    Declaration
    public static tv3 MultiplyZ(tfloat f, tv3 tp)
    Parameters
    Type Name Description
    tfloat f

    Function of input

    tv3 tp

    Parametric equation

    Returns
    Type Description
    tv3

    PX(tfloat)

    Derive a Vector3 from one floats.

    Declaration
    public static tv3 PX(tfloat x)
    Parameters
    Type Name Description
    tfloat x

    Float assigned to X-component

    Returns
    Type Description
    tv3

    PXY0(tfloat, tfloat)

    Derive a Vector3 from two floats.

    Declaration
    public static tv3 PXY0(tfloat x, tfloat y)
    Parameters
    Type Name Description
    tfloat x

    Float assigned to X-component

    tfloat y

    Float assigned to Y-component

    Returns
    Type Description
    tv3

    PXYZ(tfloat, tfloat, tfloat)

    Derive a Vector3 from three floats.

    Declaration
    public static tv3 PXYZ(tfloat x, tfloat y, tfloat z)
    Parameters
    Type Name Description
    tfloat x

    Float assigned to X-component

    tfloat y

    Float assigned to Y-component

    tfloat z

    Float assigned to Z-component

    Returns
    Type Description
    tv3

    PY(tfloat)

    Derive a Vector3 from one float.

    Declaration
    public static tv3 PY(tfloat y)
    Parameters
    Type Name Description
    tfloat y

    Float assigned to Y-component

    Returns
    Type Description
    tv3

    PZ(tfloat)

    Derive a Vector3 from one float.

    Declaration
    public static tv3 PZ(tfloat z)
    Parameters
    Type Name Description
    tfloat z

    Float assigned to Z-component

    Returns
    Type Description
    tv3

    QRotate(tv3, tv3)

    Rotate a Vector3 by a quaternion. In Unity the rotation order is ZXY. The z-axis is mapped to IN.

    Declaration
    public static tv3 QRotate(tv3 rotateBy, tv3 target)
    Parameters
    Type Name Description
    tv3 rotateBy

    Euler rotation, in degrees, xyz. Transformed to a quaternion.

    tv3 target

    Target Vector3

    Returns
    Type Description
    tv3

    TP3(tv2)

    Derive a Vector3 from a Vector2 (Z is set to zero)

    Declaration
    public static tv3 TP3(tv2 tp)
    Parameters
    Type Name Description
    tv2 tp

    Parametric function to assign to x,y components

    Returns
    Type Description
    tv3

    V3Rotate(tv3, tv3)

    Rotate a v3 by a direction vector.

    Declaration
    public static tv3 V3Rotate(tv3 rotateBy, tv3 target)
    Parameters
    Type Name Description
    tv3 rotateBy

    Direction vector (Normalization not required)

    tv3 target

    Target v3

    Returns
    Type Description
    tv3

    WithZ(tv2, tfloat)

    Derive a Vector3 from an XY (Vector2) and a Z-component.

    Declaration
    public static tv3 WithZ(tv2 xy, tfloat z)
    Parameters
    Type Name Description
    tv2 xy
    tfloat z
    Returns
    Type Description
    tv3

    XYrZ(tfloat, tfloat, tfloat, tfloat)

    Create a cylindrical equation along the Z-axis.

    Declaration
    public static tv3 XYrZ(tfloat period, tfloat radius, tfloat time, tfloat h)
    Parameters
    Type Name Description
    tfloat period

    Period of rotation in the XY-plane

    tfloat radius

    Radius of function

    tfloat time

    Time of rotation (t=0 -> X-axis)

    tfloat h

    Height (Z-axis)

    Returns
    Type Description
    tv3

    XZrY(tfloat, tfloat, tfloat, tfloat)

    Create a cylindrical equation along the Y-axis.

    Declaration
    public static tv3 XZrY(tfloat period, tfloat radius, tfloat time, tfloat h)
    Parameters
    Type Name Description
    tfloat period

    Period of rotation in the XZ-plane

    tfloat radius

    Radius of function

    tfloat time

    Time of rotation (t=0 -> X-axis)

    tfloat h

    Height (X-axis)

    Returns
    Type Description
    tv3

    YZrX(tfloat, tfloat, tfloat, tfloat)

    Create a cylindrical equation along the X-axis.

    Declaration
    public static tv3 YZrX(tfloat period, tfloat radius, tfloat time, tfloat h)
    Parameters
    Type Name Description
    tfloat period

    Period of rotation in the YZ-plane

    tfloat radius

    Radius of function

    tfloat time

    Time of rotation (t=0 -> Y-axis)

    tfloat h

    Height (X-axis)

    Returns
    Type Description
    tv3

    Zero()

    The zero vector.

    Declaration
    public static tv3 Zero()
    Returns
    Type Description
    tv3
    In This Article
    Back to top Generated by DocFX