This is a library for character animation with no GUI (console-mode). For rendering, please use libcalab_ogre3d (ogre-next) or GitHub:taesoobear/libcalab_examples (ogre-python) instead.
Project description
example code 1 (fbx loading).
import os,sys,pdb,math
from libcalab import *
this=RE.createMainWin() # this is necessary before using libcalab
skelFile='../../Mixamo/fbx_withSkin/bigvegas_Walking.fbx'
skinScale=1
fbx=RE.FBXloader(skelFile, skinScale=skinScale, useTexture=True, simplifyMesh=False)
loader=fbx.loader
motion=fbx.loader.mMotion
print(loader)
lua.out(loader) # print skeleton using lua (see console).
pdb.set_trace()
example code 2 (bvh loading).
import os, sys, pdb, math, random
from libcalab import *
import numpy as np
import copy
this=RE.createMainWin(sys.argv)
loader1=RE.createMotionLoaderExt('../Resource/motion/woody/wd2_2foot_walk_turn2.bvh')
mMotion=loader1.mMotion
# pose editing using quaternions
lua.out(loader1) # print skeleton using lua (see console).
ri1=loader1.getRotJointIndexByName('LeftForeArm')
pose1.rotations(ri1).setRotation(m.vector3(0,1,0), math.radians(-90))
# pose editing using euler angles
loader1.setPose(pose2)
dof2=loader1.getPoseDOF()
print(dof2.array)
# The two lines above set and get the quaternions (pose2) in the loader to convert them into Euler angles (dof).
# In other words, pose2 and dof2 represent the same pose but in different representations.
loader1_relbow=loader1.getTreeIndexByName('RightForeArm')
rindex2_start=loader1.dofInfo.startR(loader1_relbow)
rindex2_end=loader1.dofInfo.endR(loader1_relbow)
print(loader1.bone(loader1_relbow).getRotationalChannels())
Other examples which use ogre-python for rendering
https://github.com/taesoobear/libcalab_examples
Other examples which use libcalab-ogre3d (ogre-next) for much faster rendering
https://github.com/taesoobear/IPCDNNwalk
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
No source distribution files available for this release.See tutorial on generating distribution archives.
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file libcalab-0.2.7-cp312-cp312-manylinux_2_39_x86_64.whl.
File metadata
- Download URL: libcalab-0.2.7-cp312-cp312-manylinux_2_39_x86_64.whl
- Upload date:
- Size: 11.9 MB
- Tags: CPython 3.12, manylinux: glibc 2.39+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3b450fe4e3b3fb61b24e47fbbd100bdd074a3081a4cf27bffcdb598b9157122c
|
|
| MD5 |
e2debc952e8662639acd2a129557a884
|
|
| BLAKE2b-256 |
deec1dc1958394f68172df26262559913baf1a63b31a1f06f7ce2c0b3fa1d31e
|