WorldViz User Forum

WorldViz User Forum (
-   Vizard (
-   -   Cave Collision problem (

TopazFrost 02-11-2014 05:56 PM

Cave Collision problem

I am converting a project that was a HMD to CAVE. Unfortunately, doing so massive broke my code due to non-overlapping the function calls and different masks.

Anyway, I have it "ducted taped" for the most part, but there is one problem I do not understand. I am having the same problem as this person:

Thus, my menu that should stay relative to a person flies away when I run into a wall. BUT, the callback solution in the other thread doesn't fire. In fact, my code throws an error when I even try to change the collision saying the cave origin viewpoint returned by vizcave.CaveView doesn't have that function.

The stepsize() call does not work properly either. I have a few steps and without the CAVE, I climb; with the CAVE I'm stuck at the bottom. This is a problem since I need to implement jumping/floating and I can't even jump onto the first step.

I've tried to implement my own collision detection, but it does not work too well (just a line intersection from my current position .5m off the floor to about .2m in the direction I want to go). If I could get the current position, it would help, but .getPosition() returns a position on the floor, and .getPosition(viz.VIEW_ORI), .getPosition(viz.BODY_ORI) , and .getPosition(viz.HEAD_ORI) all return [0,0,0]

While I'm here, perhaps you can explain another thing I did wrong. With the HMD the participant's eye height works by using viz.eyeheight(); with the CAVE I have to use "view".setPosition() (sort of works). Why did it break?

Jeff 02-12-2014 12:33 AM

When using the vizcave module the CaveView object controls the viewpoint:


view = vizcave.CaveView(tracker)
In order for the viewpoint collision event to occur, the CaveView must collide with the wall. The user's tracked movements only affect the projection matrices and will not trigger that event. The images in the vizcave page help to clarify the difference between movements of the CaveView and tracked user.

TopazFrost 02-13-2014 02:34 PM

Huh, it looks like my earlier reply did not go through.

I am using CaveView. But the collision event just wasn't firing about 50% of the time. I eventually found the problem. It was firing on the wrong object... I was returning the top of the stage rather than the sides so my code wasn't seeing the event. Checking for that type of event and then searching for nearby objects fixed the problem...I hope.

All times are GMT -7. The time now is 07:28 PM.

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