gophysx

package module
v0.0.0-...-5184657 Latest Latest
Warning

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

Go to latest
Published: Jan 29, 2018 License: MIT Imports: 3 Imported by: 0

README

go-physx

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrCreateSceneFail = errors.New("create scene fail.")
View Source
var ErrNeedInitSDK = errors.New("physx sdk is not init.")

Functions

func ReleasePhysxSDK

func ReleasePhysxSDK()

Types

type PxScene

type PxScene struct {
	// contains filtered or unexported fields
}

func NewScene

func NewScene(path string) (*PxScene, error)

func (*PxScene) AddForce

func (this *PxScene) AddForce(id uint64, force Vector3)

func (*PxScene) ClearForce

func (this *PxScene) ClearForce(id uint64)

func (*PxScene) CreateBoxDynamic

func (this *PxScene) CreateBoxDynamic(pos Vector3, halfExtents Vector3) (id uint64)

func (*PxScene) CreateBoxKinematic

func (this *PxScene) CreateBoxKinematic(pos Vector3, halfExtents Vector3) (id uint64)

func (*PxScene) CreateBoxStatic

func (this *PxScene) CreateBoxStatic(pos Vector3, halfExtents Vector3) (id uint64)

func (*PxScene) CreateCapsuleDynamic

func (this *PxScene) CreateCapsuleDynamic(pos Vector3, radius, halfHeight float32) (id uint64)

func (*PxScene) CreateCapsuleKinematic

func (this *PxScene) CreateCapsuleKinematic(pos Vector3, radius, halfHeight float32) (id uint64)

func (*PxScene) CreateCapsuleStatic

func (this *PxScene) CreateCapsuleStatic(pos Vector3, radius, halfHeight float32) (id uint64)

func (*PxScene) CreatePlane

func (this *PxScene) CreatePlane(yAxis float32) (id uint64)

func (*PxScene) CreateSphereDynamic

func (this *PxScene) CreateSphereDynamic(pos Vector3, radius float32) (id uint64)

func (*PxScene) CreateSphereKinematic

func (this *PxScene) CreateSphereKinematic(pos Vector3, radius float32) (id uint64)

func (*PxScene) CreateSphereStatic

func (this *PxScene) CreateSphereStatic(pos Vector3, radius float32) (id uint64)

func (*PxScene) GetGlobalPostion

func (this *PxScene) GetGlobalPostion(id uint64) (outPostionX, outPostionY, outPostionZ float32)

func (*PxScene) GetGlobalRotate

func (this *PxScene) GetGlobalRotate(id uint64) (outRotateX, outRotateY, outRotateZ, outRotateW float32)

func (*PxScene) IsDynamicObj

func (this *PxScene) IsDynamicObj(id uint64) (ok bool)

func (*PxScene) IsStaticObj

func (this *PxScene) IsStaticObj(id uint64) (ok bool)

func (*PxScene) Release

func (this *PxScene) Release()

func (*PxScene) RemoveActor

func (this *PxScene) RemoveActor(id uint64)

func (*PxScene) SetCurrentAngularDamping

func (this *PxScene) SetCurrentAngularDamping(value float32)

func (*PxScene) SetCurrentMaterial

func (this *PxScene) SetCurrentMaterial(staticFriction, dynamicFriction, restitution float32)

func (*PxScene) SetGlobalPostion

func (this *PxScene) SetGlobalPostion(id uint64, pos Vector3)

func (*PxScene) SetGlobalRotate

func (this *PxScene) SetGlobalRotate(id uint64, rotate Quat)

func (*PxScene) SetLinearVelocity

func (this *PxScene) SetLinearVelocity(id uint64, velocity Vector3)

func (*PxScene) Update

func (this *PxScene) Update(elapsedTime float32)

type Quat

type Quat struct {
	X float32
	Y float32
	Z float32
	W float32
}

type Vector3

type Vector3 struct {
	X float32
	Y float32
	Z float32
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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