WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 01-09-2012, 08:10 AM
Andy Andy is offline
Member
 
Join Date: Mar 2008
Location: Germany
Posts: 36
setParent with child of a 3dMax model

I have a 3dmax model with some subnodes and I want to set another node as a child of one of this subnodes.

I have a simple example file, why is the ball place in the center of the model and not in the center of the subnode? In Vizard 3 it works correctly. Any idea?

Code:
import viz
viz.go()

viz.clearcolor(viz.SKYBLUE)
viz.addChild('tut_ground.wrl')
viz.MainView.setPosition([0,1.8,-14])

ball = viz.add('ball.wrl')
ball.setScale(3,3,3)
node = viz.add('testChilddNode_4.IVE')

subNode1 = node.getChild('Quader02-GEODE')
subNode2 = node.getChild('Quader03-GEODE')

ball.parent(subNode2)

node.setPosition([0,3,0])
Attached Files
File Type: zip setParent.zip (1.4 KB, 426 views)
Reply With Quote
  #2  
Old 01-09-2012, 05:28 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
I ran your script and I get the same results with Vizard 3 and 4. The ball is centered around the small box at the top. Where are you expecting the ball to be positioned?
Reply With Quote
  #3  
Old 01-10-2012, 01:13 AM
Andy Andy is offline
Member
 
Join Date: Mar 2008
Location: Germany
Posts: 36
Hi
I have found the problem. I have a global config 'vozcore.cfg' an set 'viz.model.optimize = 1 '. If I do this, the ball is center around the big box at the bottom, if I set it to 0 it works like it should.
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Change model alpha and memory leak hosier Vizard 2 06-25-2009 10:55 AM
Importing a 3d human model and getting it to interact. yak Vizard 3 06-01-2009 02:19 PM
Model sizes Pastscapian Vizard 15 10-07-2006 02:48 PM
Pivot points for child objects in Vizard with 3ds Max Gladsomebeast Vizard 0 09-19-2006 11:21 AM
Child Object Rotation paulgoldberg Vizard 5 09-05-2006 11:33 AM


All times are GMT -7. The time now is 10:25 AM.


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