Skip to main content

Libary for creating spatial space hierarchies

Project description

spatial-transform

Libary for creating spatial space hierarchies, like game engines and renderes would do, to have diffrent rotations, scale and positions which can also rely on their parent.

This package was created for my master thesis and only aims about integrety but not performance. For the most of the calculations the package PyGLM is used.

Features

  • Transforms as stackable in form of trees.
  • Transforms reactor to attaching and detaching.
  • Support Translation, Rotation and Scale.
  • Includes a static class for euler angle conversions.
  • Space is defined as: Y+ is Up and right handed like openGL

Examples

Create and stack transforms

import spatial-transform as st

root = st.Transform('root')
child1 = st.Transform('child1')

root.append(child1)

Change properties

import spatial-transform as st

root = st.Transform('root')
root.Position = (1,2,3)
root.SetEuler(0, 45, 0)
root.Scale = (10, 10, 10)

Convert between spaced

import spatial-transform as st

root = st.Transform('root')
root.pointToWorld(1,1,1)
root.directionToLocal(1,1,1)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

spatial_transform-1.0.1.tar.gz (4.9 kB view hashes)

Uploaded Source

Built Distribution

spatial_transform-1.0.1-py3-none-any.whl (5.9 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page