bitbybit.dev v1.0.0-rc.1
    Preparing search index...

    Class Transforms

    Index

    Constructors

    identity

    • Creates identity transformation matrix (no transformation - leaves objects unchanged). Returns 4×4 matrix: [1,0,0,0, 0,1,0,0, 0,0,1,0, 0,0,0,1]

      Returns TransformMatrix

      transformation

      identity

      false

    rotation

    • Creates rotation transformations around a center point and custom axis. Combines translation to origin, axis rotation, then translation back. Example: center=[5,0,0], axis=[0,1,0], angle=90° → rotates around vertical axis through point [5,0,0]

      Parameters

      Returns TransformMatrixes

      array of transformations

      center axis

      false

    • Creates rotation transformations around a center point along the X axis. Example: center=[5,5,5], angle=90° → rotates 90° around X axis through point [5,5,5]

      Parameters

      Returns TransformMatrixes

      array of transformations

      center x

      false

    • Creates rotation transformations around a center point along the Y axis. Example: center=[0,0,0], angle=45° → rotates 45° around Y axis through origin

      Parameters

      Returns TransformMatrixes

      array of transformations

      center y

      false

    • Creates rotation transformations around a center point along the Z axis. Example: center=[10,10,0], angle=180° → rotates 180° around Z axis through point [10,10,0]

      Parameters

      Returns TransformMatrixes

      array of transformations

      center z

      false

    • Creates rotation transformations using yaw-pitch-roll (Euler angles) around a center point. Yaw → Y axis rotation, Pitch → X axis rotation, Roll → Z axis rotation. Example: center=[0,0,0], yaw=90°, pitch=0°, roll=0° → rotates 90° around Y axis

      Parameters

      Returns TransformMatrixes

      array of transformations

      yaw pitch roll

      false

    scale

    • Creates non-uniform scale transformation around a center point (different scale per axis). Example: center=[5,5,5], scaleXyz=[2,1,0.5] → doubles X, keeps Y, halves Z around point [5,5,5]

      Parameters

      Returns TransformMatrixes

      array of transformations

      center xyz

      false

    • Creates non-uniform scale transformation from origin (different scale per axis). Example: scaleXyz=[2,3,1] → doubles X, triples Y, keeps Z unchanged

      Parameters

      Returns TransformMatrixes

      transformation

      xyz

      false

    • Creates directional stretch transformation that scales along a specific direction from a center point. Points move only along the direction vector; perpendicular plane remains unchanged. Example: center=[0,0,0], direction=[1,0,0], scale=2 → stretches 2× along X axis only

      Parameters

      Returns TransformMatrixes

      Array of transformations: [Translate To Origin, Stretch, Translate Back].

      stretch dir center

      false

    • Creates uniform scale transformation from origin (same scale on all axes). Example: scale=2 → doubles size in all directions (X, Y, Z)

      Parameters

      Returns TransformMatrixes

      transformation

      uniform

      false

    • Creates uniform scale transformation around a center point (same scale on all axes). Example: center=[5,5,5], scale=0.5 → halves size in all directions around point [5,5,5]

      Parameters

      Returns TransformMatrixes

      array of transformations

      uniform from center

      false

    translation

    • Creates translation transformation (moves objects in space). Example: translation=[10,5,0] → moves object 10 units in X, 5 in Y, 0 in Z

      Parameters

      Returns TransformMatrixes

      transformation

      xyz

      false

    translations *

    • Creates multiple translation transformations (batch move operations). Example: translations=[[1,0,0], [0,2,0]] → generates two transforms: move +X, move +Y

      Parameters

      Returns TransformMatrixes[]

      transformation *

      xyz *

      false