WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Thread Tools Rate Thread Display Modes
Old 12-07-2015, 07:37 AM
Novakin Novakin is offline
Join Date: Dec 2015
Posts: 9
What is the difference between parent and link?

See title. Just started using Vizard for a couple of weeks now, read a lot of the documentation but can't quite understand this.

Say I want to have an object move together with another. For example I could have a glove in the scene and I want that glove to hold a flashlight. The way I understand it, I could either:
- call setParent() on the flashlight to set it's parent to the glove
- call link() to link the flashlight to the glove

Is this right?
Reply With Quote
Old 12-09-2015, 10:05 PM
Jeff Jeff is offline
WorldViz Team Member
Join Date: Aug 2008
Posts: 2,466
Some tasks can be more easily accomplished using links while others are easier with parent/child relationships. You could use either a link or parent in the example you've provided. With parent/child relationships you can move the objects in their own local or parent coordinate system. The coordinate systems tutorial covers this topic. With links the source object's transform (position, orientation, scale) is applied to the destination object. However, there are operations that can be applied on the link to modify the source transform before it is applied to the destination. For example, different combinations of position, orientation, and scale can be applied to the destination object using masks and offsets between source and destination can be defined.
Reply With Quote
Old 12-10-2015, 02:37 AM
Novakin Novakin is offline
Join Date: Dec 2015
Posts: 9
That makes it more clear, thanks!
Reply With Quote

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 09:50 PM.

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