Options
All
  • Public
  • Public/Protected
  • All
Menu

Represents a custom Model loaded from a JSON file as specified in the documentation.

Hierarchy

  • Model

Implements

Index

Constructors

constructor

  • Parameters

    Returns Model

Properties

Private colorbuffer

colorbuffer: WebGLBuffer

The buffer containing the box's colors

data

Imported Data

Private elements

elements: number

The amount of indices

Private gl

gl: WebGL2RenderingContext

Private indexbuffer

indexbuffer: WebGLBuffer

The indices describing which vertices form a triangle

Private normalbuffer

normalbuffer: WebGLBuffer

The buffer containing the box's normals

Readonly shader

shader: string = "pvmcolor"

Key of the corresponding Shader in the Shadermanager.

Private vertexbuffer

vertexbuffer: WebGLBuffer

The buffer containing the box's vertices

Methods

intersect

  • Used for drawing with the raytracer.

    Ignored by the Raytracer

    Parameters

    • ray: Ray

      Ray to intersect with.

    • transformation: Matrix4

      Transformation of the object into worldspace.

    Returns Intersection

render

  • render(shader: Shader): void
  • Method to used for drawing with rasterizer.

    Parameters

    • shader: Shader

      Shader used for rendering.

    Returns void

Generated using TypeDoc