WorldViz User Forum  

Go Back   WorldViz User Forum > Vizard

Reply
 
Thread Tools Rate Thread Display Modes
  #1  
Old 12-01-2015, 03:26 PM
szkuls szkuls is offline
Member
 
Join Date: Dec 2015
Posts: 2
Vizconnect grabber grab area

Hello,

I am able to get the grabber tool working with vizconnect but the hotspot for grabbing an object seems to be the same size at the center or pivot of the object no matter how large or small the object is. For example here is a code snippet with two cubes. The one on the left is easily highlighted and grabbed where as the larger cube on the right can still be grabbed but is very difficult to see where the hand is or if you are close to the center of the cube to make the grab.

Code:
import viz
import vizconnect
import vizshape

vizconnect.go ('vizconnect_desktop.py')

scene = viz.addChild ('piazza.osgb')

smallBox = vizshape.addBox (size = (1,1,1))
smallBox.setPosition ([0, 1, 0])
bigBox = vizshape.addBox (size = (5,5,5))
bigBox.setPosition  ([6, 3, 0])

tool = vizconnect.getRawTool ('grabber')
tool.setItems ([smallBox, bigBox])
Is there a way to adjust the hotspot or collision/intersection area of the items that are set to grabbable? Ideally, I would like to have the bounding box be the intersection area for the the hand to grab.

Thanks!
Reply With Quote
  #2  
Old 12-02-2015, 05:08 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
Thanks for the example, I'll check with a developer about this.
Reply With Quote
  #3  
Old 12-17-2015, 11:30 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,471
The grabber tool intersection test is based on the distance to the center of the object. You can, however, modify the distance test used so that it works with the bounding box. The attached example should work, but this is not officially supported code.
Attached Files
File Type: zip bounding box distance.zip (4.9 KB, 1768 views)
Reply With Quote
Reply

Tags
grabber, tool, vizconnect

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
Zspace display in Vizconnect JB_HP_Viz Vizard 5 06-05-2015 03:28 PM
Switching between input devices setup in vizconnect and not using vizconnect JB_HP_Viz Vizard 1 01-20-2015 05:19 AM
delete hand in vizconnect rvenegas Vizard 4 06-05-2014 10:17 PM
Vizconnect Save As Dialog Jeff Vizard 0 05-01-2014 09:45 AM
Setting up a 'reaction area' Karthi Vizard 4 01-29-2004 04:39 PM


All times are GMT -7. The time now is 11:30 AM.


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