ivec2

package
v0.0.0-...-535787f Latest Latest
Warning

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

Go to latest
Published: Sep 16, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Package ivec2 provides GPU operations on two-component signed integer vectors.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BitsToFloat

func BitsToFloat(a XY) gpu.Vec2

func Equal

func Equal(a, b XY) gpu.Vec2b

func GreaterThan

func GreaterThan(a, b XY) gpu.Vec2b

func GreaterThanEqual

func GreaterThanEqual(a, b XY) gpu.Vec2b

func LessThan

func LessThan(a, b XY) gpu.Vec2b

func LessThanEqual

func LessThanEqual(a, b XY) gpu.Vec2b

func NotEqual

func NotEqual(a, b XY) gpu.Vec2b

Types

type XY

type XY gpu.Vec2i

XY is a two-component vector of signed integers on the GPU.

func Abs

func Abs(a XY) XY

func Add

func Add[T gpu.AnyInt | XY](a XY, b T) XY

func Clamp

func Clamp[T XY | gpu.AnyInt](a XY, min, max T) XY

func Div

func Div[T gpu.AnyInt | XY](a XY, b T) XY

func Max

func Max[T gpu.AnyInt | XY](a XY, b T) XY

func Min

func Min[B gpu.AnyInt | XY](a XY, b B) XY

func Mul

func Mul[T gpu.AnyInt | XY](a XY, b T) XY

func Neg

func Neg(a XY) XY

func New

func New[X, Y gpu.AnyInt](x X, y Y) XY

New creates a new XY value from two integers.

func Sign

func Sign(a XY) XY

func Sub

func Sub[T gpu.AnyInt | XY](a XY, b T) XY

Jump to

Keyboard shortcuts

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