infinitecylinder

package
v0.0.0-...-77601ef Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 18, 2020 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type InfiniteCylinder

type InfiniteCylinder struct {
	Ray                geometry.Ray `json:"ray"`
	Radius             float64      `json:"radius"`
	HasInvertedNormals bool         `json:"has_inverted_normals"`
	// contains filtered or unexported fields
}

InfiniteCylinder represents an infinitely long cylinder

func Unit

func Unit(xOffset, yOffset, zOffset float64) *InfiniteCylinder

Unit returns a unit infinite cylinder

func (*InfiniteCylinder) BoundingBox

func (ic *InfiniteCylinder) BoundingBox(t0, t1 float64) (*aabb.AABB, bool)

BoundingBox returns an AABB of this object

func (*InfiniteCylinder) Copy

Copy returns a shallow copy of this object

func (*InfiniteCylinder) Intersection

func (ic *InfiniteCylinder) Intersection(ray geometry.Ray, tMin, tMax float64, rng *rand.Rand) (*material.RayHit, bool)

Intersection computer the intersection of this object and a given ray if it exists

func (*InfiniteCylinder) IsClosed

func (ic *InfiniteCylinder) IsClosed() bool

IsClosed returns whether this object is closed

func (*InfiniteCylinder) IsInfinite

func (ic *InfiniteCylinder) IsInfinite() bool

IsInfinite returns whether this object is infinite

func (*InfiniteCylinder) SetMaterial

func (ic *InfiniteCylinder) SetMaterial(m material.Material)

SetMaterial sets this object's material

func (*InfiniteCylinder) Setup

func (ic *InfiniteCylinder) Setup() (*InfiniteCylinder, error)

Setup sets up an infinite cylinder

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL