Options
All
  • Public
  • Public/Protected
  • All
Menu

Class KeplerParticles

An efficient way to render many objects in space with Kepler orbits. Primarily used by Simulation to render all non-static objects.

see

Simulation

Hierarchy

  • KeplerParticles

Index

Constructors

constructor

Properties

Private addedToScene

addedToScene: boolean

Private attributes

attributes: ShaderAttributes

Private context

Private elements

elements: Ephem[]

Private geometry

geometry: BufferGeometry

Private id

id: string

Private options

options: KeplerParticlesOptions

Private particleCount

particleCount: number

Private particleSystem

particleSystem: Points<BufferGeometry, Material | Material[]>

Private shaderMaterial

shaderMaterial: ShaderMaterial

Private simulation

simulation: Simulation

Private uniforms

uniforms: { texture: { value: Texture } }

Type declaration

  • texture: { value: Texture }
    • value: Texture

Static instanceCount

instanceCount: number

Methods

addParticle

  • addParticle(ephem: Ephem, options?: KeplerParticleOptions): number
  • Add a particle to this particle system.

    Parameters

    • ephem: Ephem

      Kepler ephemeris

    • options: KeplerParticleOptions = {}

      Options container

    Returns number

    The index of this article in the attribute list.

get3jsObjects

  • get3jsObjects(): Object3D[]
  • Get THREE.js objects that comprise this point cloud

    Returns Object3D[]

    List of objects to add to THREE.js scene

getId

  • getId(): string

hideParticle

  • hideParticle(offset: number): void
  • Hides the particle at the given offset so it is no longer drawn. The particle still takes up space in the array though.

    Parameters

    • offset: number

    Returns void

setParticleOrigin

  • setParticleOrigin(offset: number, newOrigin: Coordinate3d): void
  • Change the origin attribute of a particle.

    Parameters

    • offset: number

      The location of this particle in the attributes * array.

    • newOrigin: Coordinate3d

      The new XYZ coordinates of the body that this particle orbits.

    Returns void

update

  • update(jd: number): void
  • Update the position for all particles

    Parameters

    • jd: number

      JD date

    Returns void

Generated using TypeDoc