geo

package
v0.1.0-alpha Latest Latest
Warning

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

Go to latest
Published: Aug 5, 2024 License: MIT Imports: 0 Imported by: 0

Documentation

Overview

Package geo .

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Vec3Int

type Vec3Int []int32

Vec3Int represents a 3-dimensional vector with integer components.

func NewVec3Int

func NewVec3Int(x, y, z int32) Vec3Int

NewVec3Int creates a new Vec3Int instance.

Parameters: - x: The x-coordinate. - y: The y-coordinate. - z: The z-coordinate.

Returns: - A new Vec3Int instance. if it's 2d, you can only use x and z (v.X(), v.Z())

func (Vec3Int) ToFloat32

func (v Vec3Int) ToFloat32() []float32

ToFloat32 converts the vector to a float32 slice.

func (Vec3Int) ToFloat64

func (v Vec3Int) ToFloat64() []float64

ToFloat64 converts the vector to a float64 slice.

func (Vec3Int) X

func (v Vec3Int) X() int32

X returns the x-coordinate of the vector.

Returns: - The x-coordinate.

func (Vec3Int) Y

func (v Vec3Int) Y() int32

Y returns the y-coordinate of the vector.

Returns: - The y-coordinate.

func (Vec3Int) Z

func (v Vec3Int) Z() int32

Z returns the z-coordinate of the vector.

Returns: - The z-coordinate.

Jump to

Keyboard shortcuts

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