Problems with tutorial 13

Nov 27, 2009 at 8:53 AM

 

I cannot execute tutorial 13.
I was able to build tutorial 13 with no error. 
I am running this program,but I cannot see anything. 
What can I see by executing this program?
Any idea ?

I cannot execute tutorial 13.

I was able to build tutorial 13 with no error. 

I am running this program,but I cannot see anything. 

 

What can I see by executing this program?

Any idea ?

 

Coordinator
Nov 29, 2009 at 6:31 PM

Do you have Vuzix iWear VR920? As the name says, it's a tutorial program for iWear VR920, and it shows overlaid virtual contents on top of a marker array in stereo.

Ohan

Nov 30, 2009 at 5:08 AM

Hi Ohan,

I do not have Vuzix iWear VR920.

I understood about it.

Thanks for your help.

 

May 8, 2010 at 3:26 AM
Edited May 8, 2010 at 3:51 AM

Hi Ohan,

I was not able to recognize any stereoscopic view while trying this tutorial.

Everything seems to compile fine, and the vuzix iWear VR920, I am assuming it is installed correctly, because I can its Stereoscopy ready and enabled when I run the iWear Monitor.

When I debugged the code, I found that the variable iTracker.ProductID is equal to  IWR_PROD_None.

 

Any idea?

Michael

Coordinator
May 9, 2010 at 1:36 PM

That is probably you do not have the latest software patch from Vuzix. I'm not sure it's publicly available, but if not, then just modify the code to use VR920 code since Wrap920AR device is still not publicly available anyway.

Ohan

May 10, 2010 at 5:48 PM
Thanks for the reply.... It worked fine when I hard coded the ID of VR920. Thank You
Jun 1, 2010 at 9:33 PM

Hey Ohan, 

I have similar problem to Michael,  iTracker.ProductID is detected as IWR_PROD_NONE so i've commented out this

(line 194, Tutorial13.cs)

if (iTracker.ProductID == iWearDllBridge.IWRProductID.IWR_PROD_VR920)

to make it full screen. (I do have iWareVR920 and it works with my applications that  are using GoblinXNA.dll 3.3)

However i have a bigger problem. When i run Tutorial13 it shows me the following error

Index was out of range. Must be non-negative and less than the size of the collection.Parameter name: index

(line 1800, Scene.cs)

if (leftEyeVideoID != rightEyeVideoID)
videoCaptures[actualRightEyeVideoID].GetImageTexture(
bufferedVideoImages[1][curVideoBufferIndex],
                                        ref nullPtr);


since both rightEyeVideoID = -1 & actualRightEyeVideoID = -1

How do i make it work?

Thanks,

Alexey.

 

Coordinator
Jun 2, 2010 at 9:43 PM

If it's VR920, it shouldn't be using rightEyeVideoID since there is only 1 camera attached to VR920 with CamAR. rightEyeVideoID is used with Wrap920AR which has 2 integrated webcams. Make sure your code doesn't go into Wrap920AR part.

Ohan

Jun 3, 2010 at 4:59 PM

From what i understand if i set

 bool stereoMode = ture;

in Tutorial 13, it sets cameraNode.Stereo (in Scene.cs) to be true

which causes error after it gets to  if (leftEyeVideoID != rightEyeVideoID) (line 1799, in Scene.cs)

that's where i get confused. does cameraNode.Stereo referes to virtual camera or the real capturing device?

 

Answering your previous post it doesn't come close to Wrap920AR code since my  iTracker.ProductID is detected as IWR_PROD_NONE as i mentioned before.

So all i wanna do is enable stereoscopic view for my VR920 iWear with an underlying mono-video stream from a SINGLE capturing device.

 

Alexey.

Coordinator
Jun 9, 2010 at 12:05 AM

I forgot to add the following codes:

if (iTracker.ProductID == iWearDllBridge.IWRProductID.IWR_PROD_WRAP920)
            {
                scene.LeftEyeVideoID = 0;
                scene.RightEyeVideoID = 1;
                scene.TrackerVideoID = 0;
            }
            else
            {
                scene.LeftEyeVideoID = 0;
                scene.RightEyeVideoID = 0;
                scene.TrackerVideoID = 0;
            }

Adding the else phrase around lines 224~229 will make it work.

Ohan

Jun 9, 2010 at 4:33 PM

Tnx, Ohan!

To whoever is following this:

I modified Tutorial13.SetupMarkerTracking()

old code:

 

if (iTracker.ProductID == iWearDllBridge.IWRProductID.IWR_PROD_WRAP920)
{
    scene.LeftEyeVideoID = 0;
    scene.RightEyeVideoID = 1;
    scene.TrackerVideoID = 0;
}

 

new code:

 

if (iTracker.ProductID == iWearDllBridge.IWRProductID.IWR_PROD_WRAP920)
{
    scene.LeftEyeVideoID = 0;
    scene.RightEyeVideoID = 1;
    scene.TrackerVideoID = 0;
}
else
{
    scene.LeftEyeVideoID = 0;
    scene.RightEyeVideoID = 0;
    scene.TrackerVideoID = 0;
}

This helped me to get rid of the error. However, as i mentioned before my 

 

iTracker.ProductID is detected as IWR_PROD_NONE, thus it did not output anything to my iWear (if you walk trough all the calls in Draw()).

This small fix helped me make it work:
1) allow property iWearTracker.iWearDllBridge.IWRProductID to be SET
public iWearDllBridge.IWRProductID ProductID
{
  get { return productID; }
  set { productID = value; }
}

2) in Tutorial13.Initializa() add following line after iTracker.Initialize();
iTracker.ProductID = iWearDllBridge.IWRProductID.IWR_PROD_VR920;

Thanks again Ohan. Hope you take into account this issue for next release!

Alexey.
Coordinator
Jun 9, 2010 at 6:56 PM

Maybe the official release of iWear driver doesn't have the correct product ID setting yet, but the new driver should be able to set the product ID to correct one once Wrap92AR becomes available.

Ohan

Jun 9, 2010 at 7:23 PM
Edited Jun 9, 2010 at 7:23 PM

let's hope it does! =)

btw, had to add one more line to make it work in MONO mode as well

 

if (stereoMode)
{
    if (iTracker.ProductID == iWearDllBridge.IWRProductID.IWR_PROD_WRAP920)
    {
        scene.LeftEyeVideoID = 0;
        scene.RightEyeVideoID = 1;
        scene.TrackerVideoID = 0;
    }
    else
    {
        scene.LeftEyeVideoID = 0;
        scene.RightEyeVideoID = 0;
        scene.TrackerVideoID = 0;
    }
}

Alexey.