Documentation ¶
Index ¶
- Constants
- func Build2DMipmaps(target gl.GLenum, internalFormat int, width, height int, format, typ gl.GLenum, ...) int
- func Cylinder(q unsafe.Pointer, base, top, height float32, slices, stacks int)
- func Disk(q unsafe.Pointer, inner, outer float32, slices, loops int)
- func ErrorString(error gl.GLenum) (string, error)
- func LookAt(eyeX, eyeY, eyeZ, centerX, centerY, centerZ, upX, upY, upZ float64)
- func NewQuadric() unsafe.Pointer
- func PartialDisk(q unsafe.Pointer, inner, outer float32, slices, loops int, ...)
- func Perspective(fovy, aspect, zNear, zFar float64)
- func Project(projX, projY, projZ float64, model, proj *[16]float64, view *[4]int32) (float64, float64, float64)
- func Sphere(q unsafe.Pointer, radius float32, slices, stacks int)
- func UnProject(winX, winY, winZ float64, model, proj *[16]float64, view *[4]int32) (float64, float64, float64)
- type TessBeginHandler
- type TessCombineHandler
- type TessEdgeFlagHandler
- type TessEndHandler
- type TessErrorHandler
- type TessVertexHandler
- type Tesselator
- func (tess *Tesselator) BeginContour()
- func (tess *Tesselator) BeginPolygon(data interface{})
- func (tess *Tesselator) Delete()
- func (tess *Tesselator) EndContour()
- func (tess *Tesselator) EndPolygon()
- func (tess *Tesselator) Normal(valueX, valueY, valueZ float64)
- func (tess *Tesselator) Property(which gl.GLenum, data float64)
- func (tess *Tesselator) SetBeginCallback(f TessBeginHandler)
- func (tess *Tesselator) SetCombineCallback(f TessCombineHandler)
- func (tess *Tesselator) SetEdgeFlagCallback(f TessEdgeFlagHandler)
- func (tess *Tesselator) SetEndCallback(f TessEndHandler)
- func (tess *Tesselator) SetErrorCallback(f TessErrorHandler)
- func (tess *Tesselator) SetVertexCallback(f TessVertexHandler)
- func (tess *Tesselator) Vertex(location [3]float64, data interface{})
Constants ¶
const ( // TessCallback TESS_BEGIN_DATA gl.GLenum = 100106 TESS_VERTEX_DATA = 100107 TESS_END_DATA = 100108 TESS_ERROR_DATA = 100109 TESS_EDGE_FLAG_DATA = 100110 TESS_COMBINE_DATA = 100111 // TessProperty TESS_WINDING_RULE = 100140 TESS_BOUNDARY_ONLY = 100141 TESS_TOLERANCE = 100142 // TessWinding TESS_WINDING_ODD = 100130 TESS_WINDING_NONZERO = 100131 TESS_WINDING_POSITIVE = 100132 TESS_WINDING_NEGATIVE = 100133 TESS_WINDING_ABS_GEQ_TWO = 100134 )
Variables ¶
This section is empty.
Functions ¶
func Build2DMipmaps ¶
func NewQuadric ¶
func PartialDisk ¶
func Perspective ¶
func Perspective(fovy, aspect, zNear, zFar float64)
Types ¶
type TessBeginHandler ¶
type TessCombineHandler ¶
type TessEdgeFlagHandler ¶
type TessEdgeFlagHandler func(flag bool, polygonData interface{})
type TessEndHandler ¶
type TessEndHandler func(polygonData interface{})
type TessErrorHandler ¶
type TessVertexHandler ¶
type TessVertexHandler func(vertexData interface{}, polygonData interface{})
type Tesselator ¶
type Tesselator struct {
// contains filtered or unexported fields
}
Opaque object used for book keeping on the go side.
func (*Tesselator) BeginContour ¶
func (tess *Tesselator) BeginContour()
Begin a contour within the polygon.
func (*Tesselator) BeginPolygon ¶
func (tess *Tesselator) BeginPolygon(data interface{})
Begin the drawing of the polygon, with the data parameter that will be provided to callbacks.
func (*Tesselator) Delete ¶
func (tess *Tesselator) Delete()
Clean up resources held by the tesselator. Go's garbage collector cannot do this automatically.
func (*Tesselator) EndContour ¶
func (tess *Tesselator) EndContour()
End a contour within the polygon.
func (*Tesselator) EndPolygon ¶
func (tess *Tesselator) EndPolygon()
End the drawing of the polygon.
func (*Tesselator) Normal ¶
func (tess *Tesselator) Normal(valueX, valueY, valueZ float64)
Set the normal of the plane onto which points are projected onto before tesselation.
func (*Tesselator) Property ¶
func (tess *Tesselator) Property(which gl.GLenum, data float64)
Set a property of the tesselator.
func (*Tesselator) SetBeginCallback ¶
func (tess *Tesselator) SetBeginCallback(f TessBeginHandler)
Sets the callback for TESS_BEGIN_DATA.
func (*Tesselator) SetCombineCallback ¶
func (tess *Tesselator) SetCombineCallback(f TessCombineHandler)
Sets the callback for TESS_COMBINE_DATA.
func (*Tesselator) SetEdgeFlagCallback ¶
func (tess *Tesselator) SetEdgeFlagCallback(f TessEdgeFlagHandler)
Sets the callback for TESS_EDGE_FLAG_DATA.
func (*Tesselator) SetEndCallback ¶
func (tess *Tesselator) SetEndCallback(f TessEndHandler)
Sets the callback for TESS_END_DATA.
func (*Tesselator) SetErrorCallback ¶
func (tess *Tesselator) SetErrorCallback(f TessErrorHandler)
Sets the callback for TESS_ERROR_DATA.
func (*Tesselator) SetVertexCallback ¶
func (tess *Tesselator) SetVertexCallback(f TessVertexHandler)
Sets the callback for TESS_VERTEX_DATA.
func (*Tesselator) Vertex ¶
func (tess *Tesselator) Vertex(location [3]float64, data interface{})
Add a vertex to the polygon, with the data parameter that will be provided to callbacks.