Gjsify LogoGjsify Logo

A 3D box, described as the volume between a minimum and a maximum vertices.

record

Hierarchy

  • Box

Index

Constructors

Properties

name: string

Methods

  • Checks whether the #graphene_box_t a contains the given #graphene_box_t b.

    Parameters

    Returns boolean

  • containsPoint(point: Point3D): boolean
  • Checks whether box contains the given point.

    Parameters

    • point: Point3D

      the coordinates to check

    Returns boolean

  • Expands the dimensions of box by the given scalar value.

    If scalar is positive, the #graphene_box_t will grow; if scalar is negative, the #graphene_box_t will shrink.

    Parameters

    • scalar: number

      a scalar value

    Returns Graphene.Box

  • Expands the dimensions of box to include the coordinates of the given vector.

    Parameters

    • vec: Graphene.Vec3

      the coordinates of the point to include, as a #graphene_vec3_t

    Returns Graphene.Box

  • free(): void
  • Computes the bounding #graphene_sphere_t capable of containing the given #graphene_box_t.

    Returns Sphere

  • getDepth(): number
  • getHeight(): number
  • getWidth(): number
  • Initializes the given #graphene_box_t with the given array of vertices.

    If n_points is 0, the returned box is initialized with graphene_box_empty().

    Parameters

    • points: Point3D[]

      an array of #graphene_point3d_t

    Returns Graphene.Box

  • Initializes the given #graphene_box_t with the given array of vertices.

    If n_vectors is 0, the returned box is initialized with graphene_box_empty().

    Parameters

    Returns Graphene.Box

  • Intersects the two given #graphene_box_t.

    If the two boxes do not intersect, res will contain a degenerate box initialized with graphene_box_empty().

    Parameters

    Returns [boolean, Graphene.Box]

  • A degenerate #graphene_box_t that can only be expanded.

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

  • A degenerate #graphene_box_t that cannot be expanded.

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

  • A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the maximum vertex set at (0, 0, 0).

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

  • A #graphene_box_t with the minimum vertex set at (0, 0, 0) and the maximum vertex set at (1, 1, 1).

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

  • A #graphene_box_t with the minimum vertex set at (-1, -1, -1) and the maximum vertex set at (1, 1, 1).

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

  • A #graphene_box_t with both the minimum and maximum vertices set at (0, 0, 0).

    The returned value is owned by Graphene and should not be modified or freed.

    Returns Graphene.Box

Legend

  • Module
  • Object literal
  • Variable
  • Function
  • Function with type parameter
  • Index signature
  • Type alias
  • Type alias with type parameter
  • Enumeration
  • Enumeration member
  • Property
  • Method
  • Interface
  • Interface with type parameter
  • Constructor
  • Property
  • Method
  • Index signature
  • Class
  • Class with type parameter
  • Constructor
  • Property
  • Method
  • Accessor
  • Index signature
  • Inherited constructor
  • Inherited property
  • Inherited method
  • Inherited accessor
  • Protected property
  • Protected method
  • Protected accessor
  • Private property
  • Private method
  • Private accessor
  • Static property
  • Static method