portal

package module
v0.0.0-...-d85d5bc Latest Latest
Warning

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

Go to latest
Published: Oct 12, 2013 License: GPL-2.0 Imports: 4 Imported by: 2 modules, 1 package

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

portal

A Portal inspired game

Documentation

Index

Constants

This section is empty.

Variables

View Source
var QuadElements = map[gl.Enum][]int16{
	gl.TRIANGLE_STRIP: []int16{0, 1, 2, 3},
	gl.LINES:          []int16{0, 1, 1, 3, 3, 2, 2, 0, 0, 3, 1, 2, 4, 5},
}

Functions

func Cross3D

func Cross3D(a, b glm.Vec4d) glm.Vec3d

func Cross3Dv

func Cross3Dv(a, b glm.Vec4d) glm.Vec4d

func NearZero

func NearZero(v glm.Vec3d) bool

func PortalTransform

func PortalTransform(a, b Quad) (glm.Mat4d, glm.Mat4d, glm.Mat4d, glm.Mat4d)

func RotationBetweenNormals

func RotationBetweenNormals(n1, n2 glm.Vec4d) glm.Mat4d

Types

type Portal

type Portal struct {
	EventHorizon Quad
	Transform    glm.Mat4d
	Portalview   glm.Mat4d
}

type Quad

type Quad struct {
	Center glm.Vec4d
	Normal glm.Vec4d
	PlaneV glm.Vec4d
	Scale  glm.Vec4d
}

func (*Quad) Apply

func (q *Quad) Apply(t glm.Mat4d) Quad

func (*Quad) Mesh

func (q *Quad) Mesh() ([]float64, []float64)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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