WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 09-12-2006, 02:42 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Quote:
Originally Posted by pbeeson
I noticed in version 3 that viz.phys.intersectLine() is much faster than viz.intersect(), but viz.phys.intersectLine seems to have some problems:

1) It returns intersections for non-visible objects (object whose visibility is set to off), which is different that viz.intersect()
I just fixed this. Setting an object to non-visible will automatically disable physics on it.

Quote:
Originally Posted by pbeeson
2) It ignores the viz.disable(viz.COLLISION) command. Is there a way to get it to ignore certain objects?
I can run viz.phys.intersectLine(begin,end,True) to get a list and then check object IDs, but I don't know if there is an easier way (especially considering that if you have many objects, it might be an optimzation to not check for intersections with particular objects at certain times, e.g. if you are casting rays from within an object).
I just modified the physics intersectLine/Node commands so that they ignore objects which have physics disabled on them. viz.COLLISION will still only pertain to the old viz.intersect() command.

I know this really doesn't help you now, but we will probably release an update within the next few days.
Reply With Quote
  #2  
Old 09-12-2006, 04:00 PM
pbeeson pbeeson is offline
Member
 
Join Date: Aug 2006
Posts: 31
Quote:
Originally Posted by farshizzo
I know this really doesn't help you now, but we will probably release an update within the next few days.
It doesn't help me even when I get the update. In 2.53, I could have a body that represented the "viewer". That body could be not visible, so that intersect() would not see it, but collidingwith() still did see it. But, I get by with calling phys.intersect(start,end,True) and then removing points that intersect the viewers own "body".
Reply With Quote
  #3  
Old 09-12-2006, 04:12 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Quote:
Originally Posted by pbeeson
It doesn't help me even when I get the update. In 2.53, I could have a body that represented the "viewer". That body could be not visible, so that intersect() would not see it, but collidingwith() still did see it. But, I get by with calling phys.intersect(start,end,True) and then removing points that intersect the viewers own "body".
So you want an object to be invisible, but still allow phys.intersect to work? Then just disable rendering on the object:
Code:
object.disable(viz.RENDERING)
Sorry if I misunderstood your question.
Reply With Quote
  #4  
Old 09-12-2006, 04:19 PM
pbeeson pbeeson is offline
Member
 
Join Date: Aug 2006
Posts: 31
Quote:
Originally Posted by farshizzo
So you want an object to be invisible, but still allow phys.intersect to work? Then just disable rendering on the object:
Code:
object.disable(viz.RENDERING)
Sorry if I misunderstood your question.
I don't care if it is invisible. All I know is that by doing avatar.visible(viz.OFF), in version 2.53, viz.intersect() would never return an intersection with the avatar, but viz.collidingwith() WOULD work if the avatar collided with antoher obstacle.

Maybe THAT was the bug, and now it is fixed. It's just different.
Reply With Quote
  #5  
Old 09-12-2006, 04:26 PM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
Quote:
Originally Posted by pbeeson
Maybe THAT was the bug, and now it is fixed. It's just different.
Correct, that behaviour was a bug. In the next release when an object is set to invisible using the node.visible() command, it will not respond to any intersection queries.
Reply With Quote
Reply


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 06:58 PM.


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