Go to the documentation of this file.00001 import hrpsys
00002 import commands
00003
00004 openhrp_dir = commands.getoutput("pkg-config --variable=prefix openhrp3.1")
00005 model_dir="file://"+openhrp_dir+"/share/OpenHRP-3.1/sample/model/"
00006
00007 sim = hrpsys.Simulator()
00008 sim.initViewer()
00009 box = sim.loadBody("box", model_dir+"box.wrl")
00010 box.rootLink().R = [0,0,0]
00011 box2 = sim.loadBody("box2", model_dir+"box2.wrl")
00012 sim.addCollisionCheckPair(box, box2)
00013 sim.initialize()
00014 sim.simulate(1.0)