WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rating: Thread Rating: 2 votes, 5.00 average. Display Modes
  #1  
Old 06-05-2007, 11:31 PM
TunTun TunTun is offline
Member
 
Join Date: May 2007
Posts: 16
another ABSOLUTE_LOCAL question

HI,

I want to manually animate avatar's left hand. Here is my code:

object = viz.add('Female.cfg')
object.rotate(180,0,0)
object.translate(0,0,7)

lefthand = object.getbone('skel_HandL')
lefthand.lock()

print ' '
pa = lefthand.get(viz.POSITION, viz.ABSOLUTE_WORLD)
print '(BEFORE) World Position of left hand is: ', pa[0], ', ', pa[1], ', ', pa[2]

lefthand.translate(2,12,3,viz.xxxxxxxxxx)

print ' '
pa = lefthand.get(viz.POSITION, viz.ABSOLUTE_WORLD)
print '(AFTER) World Position of left hand is: ', pa[0], ', ', pa[1], ', ', pa[2]


In the position of xxxxxxxxxx, I tried ABSOLUTE_WORLD, ABSOLUTE_LOCAL, RELATIVE_LOCAL, and RELATIVE_WORLD. But only ABSOLUTE_LOCAL changed the position of the left hand. And even with ABSOLUTE_LOCAL, the printed position before/after translate command were the same. Did I miss something?

Thanks.
Reply With Quote
  #2  
Old 06-06-2007, 08:37 AM
TunTun TunTun is offline
Member
 
Join Date: May 2007
Posts: 16
In case I didn't make it clear. My question, continuing the last poster, is why ABSOLUTE_WORLD or RELATIVE_WORLD didn't change anything? And why the displayed position before/after translate command always be the same, even I saw some change in the VR? Did I use <bone> command correctly?

Thanks.
Reply With Quote
Reply

Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 05:55 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2026, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC