Skip to content

jpreiss/quatcompress

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

quatcompress

Compress a normalized quaternion into 32 bits.

Single C header file with static inline functions.

On random quaternions, mean error is 0.08 degrees and worst-case error is 0.25 degrees.

Always returns a quaternion where the element of largest magnitude is positive. This saves 1 bit, but it creates the possibility that quaternion elements will flip signs when the underlying rotation only changes slightly. Since q and -q represent the same rotation, code that uses quaternions correctly should be able to handle sign flips without any problem.

About

Compress a unit quaternion into 32 bits

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages