Versions in this module Expand all Collapse all v0 v0.2.1 Sep 18, 2023 Changes in this version + type AmbientLight struct + Position *Vector3 + func NewAmbientLight(color *Color, intensity float64) *AmbientLight + func (obj *AmbientLight) Add(m Object3D) + func (obj *AmbientLight) ApplyMatrix(matrix *Matrix4) + func (obj *AmbientLight) ToJSON() interface{} + type BasicGeometry struct + func NewBasicGeometry(params BasicGeometryParams) BasicGeometry + func (bg *BasicGeometry) AddFace(a, b, c int) + func (bg *BasicGeometry) AddVertice(x, y, z float64) + func (g BasicGeometry) ApplyMatrix(matrix *Matrix4) + func (g BasicGeometry) Center() + func (g BasicGeometry) ComputeBoundingBox() + func (g BasicGeometry) ComputeBoundingSphere() + func (g BasicGeometry) ComputeFaceNormals() + func (g BasicGeometry) ComputeFlatVertexNormals() + func (g BasicGeometry) ComputeLineDistances() + func (g BasicGeometry) ComputeMorphNormals() + func (g BasicGeometry) ComputeVertexNormals(areaWeighted bool) + func (g BasicGeometry) Copy(source Object3D, recursive bool) *BasicGeometry + func (g BasicGeometry) Dispose() + func (g BasicGeometry) FromBufferGeometry(geometry Geometry) + func (g BasicGeometry) LookAt() + func (g BasicGeometry) Merge(geometry Geometry, matrix Matrix4, materialIndexOffset float64) + func (g BasicGeometry) MergeMesh(mesh Mesh) + func (g BasicGeometry) MergeVertices() + func (g BasicGeometry) Normalize() BasicGeometry + func (g BasicGeometry) RotateX() + func (g BasicGeometry) RotateY() + func (g BasicGeometry) RotateZ() + func (g BasicGeometry) Scale() + func (g BasicGeometry) SortFacesByMaterialIndex() + func (g BasicGeometry) ToJSON() interface{} + func (g BasicGeometry) Translate() + type BasicGeometryParams struct + type BoxGeometry struct + Depth float64 + DepthSegments float64 + Height float64 + HeightSegments float64 + Width float64 + WidthSegments float64 + func NewBoxGeometry(params *BoxGeometryParameters) BoxGeometry + func (g BoxGeometry) ApplyMatrix(matrix *Matrix4) + func (g BoxGeometry) Center() + func (g BoxGeometry) ComputeBoundingBox() + func (g BoxGeometry) ComputeBoundingSphere() + func (g BoxGeometry) ComputeFaceNormals() + func (g BoxGeometry) ComputeFlatVertexNormals() + func (g BoxGeometry) ComputeLineDistances() + func (g BoxGeometry) ComputeMorphNormals() + func (g BoxGeometry) ComputeVertexNormals(areaWeighted bool) + func (g BoxGeometry) Copy(source Object3D, recursive bool) *BoxGeometry + func (g BoxGeometry) Dispose() + func (g BoxGeometry) FromBufferGeometry(geometry Geometry) + func (g BoxGeometry) LookAt() + func (g BoxGeometry) Merge(geometry Geometry, matrix Matrix4, materialIndexOffset float64) + func (g BoxGeometry) MergeMesh(mesh Mesh) + func (g BoxGeometry) MergeVertices() + func (g BoxGeometry) Normalize() BoxGeometry + func (g BoxGeometry) RotateX() + func (g BoxGeometry) RotateY() + func (g BoxGeometry) RotateZ() + func (g BoxGeometry) Scale() + func (g BoxGeometry) SortFacesByMaterialIndex() + func (g BoxGeometry) ToJSON() interface{} + func (g BoxGeometry) Translate() + type BoxGeometryParameters struct + Depth float64 + DepthSegments float64 + Height float64 + HeightSegments float64 + Width float64 + WidthSegments float64 + type Camera interface + GetJsObject func() *js.Object + type CircleGeometry struct + Radius float64 + Segments float64 + ThetaLength float64 + ThetaStart float64 + func NewCircleGeometry(params CircleGeometryParameters) CircleGeometry + func (g CircleGeometry) ApplyMatrix(matrix *Matrix4) + func (g CircleGeometry) Center() + func (g CircleGeometry) ComputeBoundingBox() + func (g CircleGeometry) ComputeBoundingSphere() + func (g CircleGeometry) ComputeFaceNormals() + func (g CircleGeometry) ComputeFlatVertexNormals() + func (g CircleGeometry) ComputeLineDistances() + func (g CircleGeometry) ComputeMorphNormals() + func (g CircleGeometry) ComputeVertexNormals(areaWeighted bool) + func (g CircleGeometry) Copy(source Object3D, recursive bool) *CircleGeometry + func (g CircleGeometry) Dispose() + func (g CircleGeometry) FromBufferGeometry(geometry Geometry) + func (g CircleGeometry) LookAt() + func (g CircleGeometry) Merge(geometry Geometry, matrix Matrix4, materialIndexOffset float64) + func (g CircleGeometry) MergeMesh(mesh Mesh) + func (g CircleGeometry) MergeVertices() + func (g CircleGeometry) Normalize() CircleGeometry + func (g CircleGeometry) RotateX() + func (g CircleGeometry) RotateY() + func (g CircleGeometry) RotateZ() + func (g CircleGeometry) Scale() + func (g CircleGeometry) SortFacesByMaterialIndex() + func (g CircleGeometry) ToJSON() interface{} + func (g CircleGeometry) Translate() + type CircleGeometryParameters struct + Radius float64 + Segments float64 + ThetaLength float64 + ThetaStart float64 + type Color struct + func NewColor(r, g, b float64) *Color + type DirectionalLight struct + Position *Vector3 + func NewDirectionalLight(color *Color, intensity float64) *DirectionalLight + func (obj *DirectionalLight) Add(m Object3D) + func (obj *DirectionalLight) ApplyMatrix(matrix *Matrix4) + func (obj *DirectionalLight) ToJSON() interface{} + type Euler struct + Order float64 + X float64 + Y float64 + Z float64 + func NewEuler(x, y, z, order float64) Euler + type Face3 struct + func NewFace3(a, b, c float64) Face3 + type Fog struct + Color string + Far float64 + Near float64 + func NewFog(color Color, near float64, far float64) Fog + func (obj *Fog) Add(m Object3D) + func (obj *Fog) ApplyMatrix(matrix *Matrix4) + func (obj *Fog) ToJSON() interface{} + type Geometry interface + ApplyMatrix func(matrix *Matrix4) + Center func() + ComputeBoundingBox func() + ComputeBoundingSphere func() + ComputeFaceNormals func() + ComputeFlatVertexNormals func() + ComputeLineDistances func() + ComputeMorphNormals func() + ComputeVertexNormals func(areaWeighted bool) + Dispose func() + FromBufferGeometry func(geometry Geometry) + LookAt func() + Merge func(geometry Geometry, matrix Matrix4, materialIndexOffset float64) + MergeMesh func(mesh Mesh) + MergeVertices func() + RotateX func() + RotateY func() + RotateZ func() + Scale func() + SortFacesByMaterialIndex func() + ToJSON func() interface{} + Translate func() + type Group struct + Position *Vector3 + Rotation *Euler + func NewGroup() *Group + func (obj *Group) Add(m Object3D) + func (obj *Group) ApplyMatrix(matrix *Matrix4) + func (obj *Group) ToJSON() interface{} + type Line struct + func NewLine(geom Geometry, material Material) *Line + func (obj *Line) Add(m Object3D) + func (obj *Line) ApplyMatrix(matrix *Matrix4) + func (obj *Line) ToJSON() interface{} + type LineBasicMaterial struct + func NewLineBasicMaterial(params *MaterialParameters) *LineBasicMaterial + func (m LineBasicMaterial) Clone() + func (m LineBasicMaterial) Copy(source Object3D) + func (m LineBasicMaterial) Dispose() + func (m LineBasicMaterial) OnBeforeCompile() + func (m LineBasicMaterial) SetValues(values MaterialParameters) + func (m LineBasicMaterial) ToJSON(meta interface{}) interface{} + type Material interface + Clone func() + Copy func(source Object3D) + Dispose func() + OnBeforeCompile func() + SetValues func(values MaterialParameters) + ToJSON func(meta interface{}) interface{} + type MaterialParameters struct + Color *Color + Shading Shading + Side Side + func NewMaterialParameters() *MaterialParameters + type Matrix4 struct + func NewMatrix4(x, y, z float64) Matrix4 + type Mesh struct + Position *Vector3 + Rotation *Euler + func NewMesh(geometry Geometry, material Material) *Mesh + func (m Mesh) RotateX() + func (m Mesh) SetRotationFromAxisAngle(axis string, angle float64) + func (obj *Mesh) Add(m Object3D) + func (obj *Mesh) ApplyMatrix(matrix *Matrix4) + func (obj *Mesh) ToJSON() interface{} + type MeshBasicMaterial struct + func NewMeshBasicMaterial(params *MaterialParameters) *MeshBasicMaterial + func (m MeshBasicMaterial) Clone() + func (m MeshBasicMaterial) Copy(source Object3D) + func (m MeshBasicMaterial) Dispose() + func (m MeshBasicMaterial) OnBeforeCompile() + func (m MeshBasicMaterial) SetValues(values MaterialParameters) + func (m MeshBasicMaterial) ToJSON(meta interface{}) interface{} + type MeshLambertMaterial struct + func NewMeshLambertMaterial(params *MaterialParameters) *MeshLambertMaterial + func (m MeshLambertMaterial) Clone() + func (m MeshLambertMaterial) Copy(source Object3D) + func (m MeshLambertMaterial) Dispose() + func (m MeshLambertMaterial) OnBeforeCompile() + func (m MeshLambertMaterial) SetValues(values MaterialParameters) + func (m MeshLambertMaterial) ToJSON(meta interface{}) interface{} + type MeshPhongMaterial struct + func NewMeshPhongMaterial(params *MaterialParameters) *MeshPhongMaterial + func (m MeshPhongMaterial) Clone() + func (m MeshPhongMaterial) Copy(source Object3D) + func (m MeshPhongMaterial) Dispose() + func (m MeshPhongMaterial) OnBeforeCompile() + func (m MeshPhongMaterial) SetValues(values MaterialParameters) + func (m MeshPhongMaterial) ToJSON(meta interface{}) interface{} + type Object3D interface + Add func(m Object3D) + ApplyMatrix func(matrix *Matrix4) + ToJSON func() interface{} + type OrthographicCamera struct + Aspect float64 + MatrixAutoUpdate bool + Position Vector3 + func NewOrthographicCamera(left, right, top, bottom, near, far float64) OrthographicCamera + func (c OrthographicCamera) ClearViewOffset() + func (c OrthographicCamera) Copy() OrthographicCamera + func (c OrthographicCamera) SetViewOffset(fullWidth, fullHeight, x, y, width, height float64) + func (c OrthographicCamera) ToJSON(meta interface{}) interface{} + func (c OrthographicCamera) UpdateProjectionMatrix() + func (o OrthographicCamera) GetJsObject() *js.Object + type OrthographicCameraPosition struct + Z int + type PerspectiveCamera struct + Position Vector3 + func NewPerspectiveCamera(fov, aspect, near, far float64) PerspectiveCamera + func (c PerspectiveCamera) ClearViewOffset() + func (c PerspectiveCamera) Copy() PerspectiveCamera + func (c PerspectiveCamera) GetEffectiveFOV() float64 + func (c PerspectiveCamera) GetFilmHeight() float64 + func (c PerspectiveCamera) GetFilmWidth() float64 + func (c PerspectiveCamera) GetFocalLength() float64 + func (c PerspectiveCamera) SetFocalLength(focalLength float64) + func (c PerspectiveCamera) SetViewOffset(fullWidth, fullHeight, x, y, width, height float64) + func (c PerspectiveCamera) ToJSON(meta interface{}) interface{} + func (c PerspectiveCamera) UpdateProjectionMatrix() + func (p PerspectiveCamera) GetJsObject() *js.Object + type PerspectiveCameraPosition struct + Z int + type Quaternion struct + func NewQuaternion() Quaternion + type Scene struct + func NewScene() *Scene + func (obj *Scene) Add(m Object3D) + func (obj *Scene) ApplyMatrix(matrix *Matrix4) + func (obj *Scene) ToJSON() interface{} + type Shading float64 + const FlatShading + const SmoothShading + type Side float64 + const BackSide + const DoubleSide + const FrontSide + type Vector3 struct + func NewVector3(x, y, z float64) Vector3 + func (v Vector3) Normalize() Vector3 + func (v Vector3) Set(x, y, z float64) Vector3 + type WebGLRenderer struct + func NewWebGLRenderer() WebGLRenderer + func (r WebGLRenderer) Render(scene *Scene, camera Camera) + func (r WebGLRenderer) SetPixelRatio(ratio float64) + func (r WebGLRenderer) SetSize(w float64, h float64, updateStyle bool)