WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 04-17-2014, 10:19 AM
fabioped fabioped is offline
Member
 
Join Date: Feb 2013
Posts: 21
Wink ControlPoint

Hi!

I'm using controlpoints a lot, and i'm having a bit of trouble with:

- How to know if an animationpath has ended? how to wait for it?
- Why isn't scale in controlpoints working in Vizard5?

Here's the sample code from the documentation:
Code:
import viz, vizact, viztask
viz.go()

viz.add("piazza.osgb")
model = viz.add('milk.osgb',pos=(0,1.5,4), scale=(0.01, 0.01, 0.01, ))
path = viz.addAnimationPath()

#Add control points to the path, along with their time stamp.
path.addControlPoint(0,pos=(2,1,5),euler=(90,0,0),scale=(2,2,2))
path.addControlPoint(3,pos=(-2,1,6),euler=(0,90,0),scale=(.5,.5,.5))

#Loop the path in a swinging fashion (point A to point B to point A, etc.).
path.setLoopMode(viz.SWING)

#Add a model.
ball = viz.addChild('beachball.osgb')

#Link the model to a path.
link = viz.link(path,model)

#Play the path.
path.play()
Thanks!!
Reply With Quote
  #2  
Old 04-17-2014, 06:08 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Quote:
How to know if an animationpath has ended? how to wait for it?
This feature was actually added recently and will be available in the next release (some time next week).

Quote:
Why isn't scale in controlpoints working in Vizard5?
The behavior is actually the same as Vizard 4. By default, links will only apply the position and rotation from the source object to the destination. You need to modify the link mask to include scale values as well:
Code:
link = viz.link(path, model, mask=viz.LINK_ALL)
Reply With Quote
  #3  
Old 04-21-2014, 04:15 PM
fabioped fabioped is offline
Member
 
Join Date: Feb 2013
Posts: 21
Thanks!

Can you also provide me a quick info?
Why is viz.addTexQuad no longer able to pick mouseclicks? viz.pick is returning empty on vizard5.
Reply With Quote
  #4  
Old 04-23-2014, 03:20 AM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,460
Please start a new thread for this last question and provide some example code that shows the issue.
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 03:47 AM.


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