WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 08-25-2015, 10:00 AM
BWhiteDerby BWhiteDerby is offline
Registered User
 
Join Date: Aug 2015
Posts: 1
Rotating an object around a point

Hi all, I'm trying to add a series of animations to objects that cause it orbit another, similar to the vizact.spin() function. Is there an easy way to do this? If not could you please help me come up with the code to do so?
Many thanks.
Reply With Quote
  #2  
Old 08-25-2015, 04:37 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
You can create a parent/child hierarchy and then spin the parent:

Code:
import viz
import vizact
viz.go()

viz.addChild('dojo.osgb')

group = viz.addGroup(pos=[0,2,5])
ball = viz.addChild('beachball.osgb',pos=[2,0,0])
ball.setParent(group)

spin = vizact.spin(0,1,0,45)
group.runAction(spin)
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
animate an object using 5dt data glove 5 ultra agrima Vizard 3 07-01-2014 11:17 AM
Find collision point of line and arbitrary object asdf Vizard 2 01-28-2013 10:04 AM
retrieve Object names Geoffrey Vizard 11 12-11-2009 04:26 AM
rotating an object Penguin Vizard 10 05-18-2009 05:24 PM
Object rotating around world axis, not own axis tacbob Vizard 1 02-15-2007 09:12 AM


All times are GMT -7. The time now is 04:00 PM.


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