Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Sphere

A MeshPrimitive prepopulated with sphere vertices and triangles

Hierarchy

  • MeshPrimitive
    • Sphere

Implements

Index

Constructors

Properties

Methods

Constructors

constructor

  • new Sphere(radius: number, longLines?: number, latLines?: number, material?: Material): Sphere
  • Generate a sphere mesh primitive

    Parameters

    • radius: number

      The radius of the generated sphere

    • Default value longLines: number = 12

      The number of polar vertex rings

    • Default value latLines: number = 8

      The number of equatorial vertex rings (not counting poles)

    • Default value material: Material = null

      An initial material to apply to the sphere

    Returns Sphere

Properties

material

material: Material

triangles

triangles: number[] = []

vertices

vertices: Vertex[] = []

Methods

getByteSize

  • getByteSize(scanId: number): number
  • Parameters

    • scanId: number

    Returns number

serialize