OpenXRHand

package
v0.0.0-...-a66c66c Latest Latest
Warning

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

Go to latest
Published: Sep 12, 2025 License: MIT Imports: 24 Imported by: 0

Documentation

Overview

Package OpenXRHand provides methods for working with OpenXRHand object instances.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Advanced

type Advanced = class

Advanced exposes a 1:1 low-level instance of the class, undocumented, for those who know what they are doing.

type Any

type Any interface {
	gd.IsClass
	AsOpenXRHand() Instance
}

type BoneUpdate

type BoneUpdate int //gd:OpenXRHand.BoneUpdate
const (
	/*The skeletons bones are fully updated (both position and rotation) to match the tracked bones.*/
	BoneUpdateFull BoneUpdate = 0
	/*The skeletons bones are only rotated to align with the tracked bones, preserving bone length.*/
	BoneUpdateRotationOnly BoneUpdate = 1
	/*Maximum supported bone update mode.*/
	BoneUpdateMax BoneUpdate = 2
)

type Extension

type Extension[T gdclass.Interface] struct{ gdclass.Extension[T, Instance] }

Extension can be embedded in a new struct to create an extension of this class. T should be the type that is embedding this Extension

func (*Extension[T]) AsNode

func (self *Extension[T]) AsNode() Node.Instance

func (*Extension[T]) AsNode3D

func (self *Extension[T]) AsNode3D() Node3D.Instance

func (*Extension[T]) AsObject

func (self *Extension[T]) AsObject() [1]gd.Object

func (*Extension[T]) AsOpenXRHand

func (self *Extension[T]) AsOpenXRHand() Instance

type Hands

type Hands int //gd:OpenXRHand.Hands
const (
	/*Tracking the player's left hand.*/
	HandLeft Hands = 0
	/*Tracking the player's right hand.*/
	HandRight Hands = 1
	/*Maximum supported hands.*/
	HandMax Hands = 2
)

type ID

type ID Object.ID

ID is a typed object ID (reference) to an instance of this class, use it to store references to objects with unknown lifetimes, as an ID will not panic on use if the underlying object has been destroyed.

func (ID) Instance

func (id ID) Instance() (Instance, bool)

type Instance

type Instance [1]gdclass.OpenXRHand

This node enables OpenXR's hand tracking functionality. The node should be a child node of an [XROrigin3D] node, tracking will update its position to the player's tracked hand Palm joint location (the center of the middle finger's metacarpal bone). This node also updates the skeleton of a properly skinned hand or avatar model. If the skeleton is a hand (one of the hand bones is the root node of the skeleton), then the skeleton will be placed relative to the hand palm location and the hand mesh and skeleton should be children of the OpenXRHand node. If the hand bones are part of a full skeleton, then the root of the hand will keep its location with the assumption that IK is used to position the hand and arm. By default the skeleton hand bones are repositioned to match the size of the tracked hand. To preserve the modeled bone sizes change [member bone_update] to apply rotation only.

var Nil Instance

Nil is a nil/null instance of the class. Equivalent to the zero value.

func New

func New() Instance

func (Instance) AsNode

func (self Instance) AsNode() Node.Instance

func (Instance) AsNode3D

func (self Instance) AsNode3D() Node3D.Instance

func (Instance) AsObject

func (self Instance) AsObject() [1]gd.Object

func (Instance) AsOpenXRHand

func (self Instance) AsOpenXRHand() Instance

func (Instance) BoneUpdate

func (self Instance) BoneUpdate() BoneUpdate

func (Instance) Hand

func (self Instance) Hand() Hands

func (Instance) HandSkeleton

func (self Instance) HandSkeleton() string

func (Instance) ID

func (self Instance) ID() ID

func (Instance) MotionRange

func (self Instance) MotionRange() MotionRange

func (Instance) SetBoneUpdate

func (self Instance) SetBoneUpdate(value BoneUpdate)

func (Instance) SetHand

func (self Instance) SetHand(value Hands)

func (Instance) SetHandSkeleton

func (self Instance) SetHandSkeleton(value string)

func (Instance) SetMotionRange

func (self Instance) SetMotionRange(value MotionRange)

func (*Instance) SetObject

func (self *Instance) SetObject(obj [1]gd.Object) bool

func (Instance) SetSkeletonRig

func (self Instance) SetSkeletonRig(value SkeletonRig)

func (Instance) SkeletonRig

func (self Instance) SkeletonRig() SkeletonRig

func (Instance) Virtual

func (self Instance) Virtual(name string) reflect.Value

type MotionRange

type MotionRange int //gd:OpenXRHand.MotionRange
const (
	/*When player grips, hand skeleton will form a full fist.*/
	MotionRangeUnobstructed MotionRange = 0
	/*When player grips, hand skeleton conforms to the controller the player is holding.*/
	MotionRangeConformToController MotionRange = 1
	/*Maximum supported motion ranges.*/
	MotionRangeMax MotionRange = 2
)

type SkeletonRig

type SkeletonRig int //gd:OpenXRHand.SkeletonRig
const (
	/*An OpenXR compliant skeleton.*/
	SkeletonRigOpenxr SkeletonRig = 0
	/*A [SkeletonProfileHumanoid] compliant skeleton.*/
	SkeletonRigHumanoid SkeletonRig = 1
	/*Maximum supported hands.*/
	SkeletonRigMax SkeletonRig = 2
)

Jump to

Keyboard shortcuts

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