Commit 1ddd1ec1 authored by Galo Maldonado's avatar Galo Maldonado
Browse files

show joint frames

parent f3ecb732
import sys
sys.path.append('src')
sys.path.append('ospi')
import subprocess
import time
#from ospi
import viewer_utils as vw
import wrapper as wr
import motion_parser as mtp
......@@ -11,6 +15,13 @@ filename='/local/gmaldona/devel/Models/data/whole_body/wholebody.osim'
# Create a wrapper specific to the whole-body model
# The wrapper parse the OpenSim model and builds pinocchio model and data
wb_model = wr.Wrapper(filename, mesh_path, name='whole-body_model1')
# call the gepetto viewer server
gvs = subprocess.Popen(["./gepetto-viewer.sh","&"])
print 'Loading the viewer ...'
time.sleep(2)
# Init the viewer and add the model to it
viewer = vw.Viewer('viewer',wb_model)
viewer.setVisibility(wb_model.name+"/floor", "OFF")
......@@ -18,6 +29,11 @@ viewer.display(wb_model.q0, wb_model.name)
# See kinematic ranges of motion
# See markers
# See axis
viewer.JointFrames(wb_model.name)
# parse motion:
time, q, colheaders, qOsim = mtp.parseMotion(wb_model.model, wb_model.joint_transformations, '/home/gmaldona/Dropbox/kv03_filtered_ik.mot','quat')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment