Forum Discussion

🚨 This forum is archived and read-only. To submit a forum post, please visit our new Developer Forum. 🚨
juang3d's avatar
juang3d
Honored Guest
12 years ago

Enable positional tracking with DK1.1 and a webcam?

Hi there.

Is there a way to enable this? I know the positional tracking may not be as good as with DK2, but it should not be so hard, right?

Cheers.

4 Replies

  • I tried to accomplish this using QR codes, but QR code libraries don't want to return you the size/orientation of the recognized glyph.

    I also tried with a library called ARToolkit which is more aligned with the target task... finding the position in 3D space of a recognized object, but the AR library was frustratingly difficult to work with.

    I also have a couple of depth sensing cameras that use time-of-flight to get depth information. I attempted to use the depth field produced to track the faceplate of the Rift in 3D space, but the high-noise and high-latency of the depth cameras again made it difficult.

    I haven't invested a ton of effort into any of these because the usefulness of the effort is limited to only people with a DK1 who don't plan on getting a DK2 (or who are waiting on the consumer version). I'm certain that it would be possible to come up with a solution using at least one of these approaches. Probably the use of the AR toolkit is most promising because it only requires a printer and a conventional webcam, rather than the specialized depth sensing cameras the last approach entails. Someone with more motivation than I have would probably be able to get it to work.
  • jherico, fearless leader of the cross-platform virtual reality developer revolution, have you considered ArUco yet for this task?

    http://www.uco.es/investiga/grupos/ava/node/26



    http://www.youtube.com/watch?v=-mhdMoPInf8

    To me ArUco works as advertised. The core API really is (essentially) just one line of C++ to invoke. It can give you all four goodies: the symbol identifier, a 3D position, the glyph scale and an orientation. It includes examples for receiving an OpenGL-ready matrix4 transformation.

    If you have an existing opencv development prompt it should take you less than 30 minutes to go from git clone to testing detections. Then, I highly-recommend doing a google image search for "aruco ar code" on your cell phone (or ipad etc.) and holding those results up for ArUco to "see." This may blow your mind, and also help find which of the 1024 possible ArUco symbols work best in current conditions.

    Currently I'm down a different rabbit hole -- application-level support for DK2's organic portrait mode (ie: so you just plug the thing in and run your software w/o bs) -- but I might give up on that if to collaborate on secondary positional tracking for DK1/DK2.

    Regards,
    -vr

    ps: another ArUco-Rift love story: http://outerra.blogspot.com/2013/08/absolute-positioning-with-oculus-rift.html
  • juang3d's avatar
    juang3d
    Honored Guest
    I was meaning more leveraging the already existent tracking system that is used with the DK2, manually generating the tracking points in the DK1 and tracking with a regular camera or a PS3 camera, it may not give as good results as DK2, but it could work, I just wanted to know if there was some way to enabling this in the SDK.

    Of course AR techniques could be great, but in that case I would pick some cameras mounted in the DK1 and leveraging them not just for positioning but for a complete AR experience.

    Cheers.
  • "jherico" wrote:
    I tried to accomplish this using QR codes, but QR code libraries don't want to return you the size/orientation of the recognized glyph.


    If you are not tied to using QR codes, but can change to DataMatrix you could look at:
    http://libdmtx.org/

    This library will identify one or more Datamatrix in an image, but will also give you the corner locations. I used this is a little project of mine a few years ago to highlight the location of the found barcode(s).

    http://sourceforge.net/projects/pydmscanner/

    Cheers,
    Simon.