Forum Discussion

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

Porting from 0.8.0.0 SDK to 1.3.0 SDK

Is there any good set of instructions how to port code from 0.8.0.0 SDK to 1.3.0 SDK ? I see simple changing the header does not work. The functions are not only renamed, but changed as well. I miss ovrTexture and ovrGLTexture definititons, ovrViewScaleDesc structure changed, ovrProjection_RightHanded is undefined e.t.c. ... e.t.c. ... Some good list of everything what should be changed and how will be useful.

6 Replies

  • galopin's avatar
    galopin
    Heroic Explorer
    OvrHmd was already deprecated in 0.8, if you looked at it, it was an alias for ovrSession and all the API using that type name.

    You are a dev, if you need them to hold your hand for things like this, you are not really legitimate to complains about stuff :)

    The sdk < 1.0 were prototypes and it was assumed no backward compatibility with > =1.0

  • Ybalrid's avatar
    Ybalrid
    Expert Protege
    @husakm I'm currently working on my own Ogre (OpenGL) based (little, and verry badly designed) game engine, and I proted my 0.8 code to 1.3 without much trouble.

    If you want to see what the patch look like, I'm only changing stuff related to the Oculus Rift SDK on this (beside a value passed at a glCopyImageSubData)

    Here the diff between the master (0.8) and working (1.3) branch on GitHub https://github.com/Ybalrid/Annwvyn/compare/ovr1.3?expand=1 (hope it will give you an idea what to substitute do keep same functionality with the new API)

    It's working, beside the fact that the Xbox button doesn't bring back Oculus Home yet (not sure about that, I did not touch the "PlatformSDK" stuff inside the .zip yet, looks like a lib ton integrate your programs to the Oculus ecosystem...)

    Basically : you have to use ovrSession instead of ovrHmd, and they changed a bit the datatypes used to represent textures and layers of the compositor. The function that calculate the projection matrix is a tiny bit different too.
    They dropped I think every last bit of C++ of the SDK, so there is no "objects" anywere now. Not even for the mathematical objects like Quaternions, Matrices and Vectors...

    Edit : The OVR namespace with it's mathematical content is still there. They removed "OVR.H" (that's strange) and I did not take the time to locate that it was including "Extras/OVR_Math.h". So if you were using them you need to #include it.
  • Anonymous's avatar
    Anonymous
    Thank you all for the comments. I need to port from 0.8.0 to 1.3.0 so most of the issues you mention (OvrHmd e.t.c) are solved.  But the porting is not stills straight forward ... I have a very simple GLUT/OpenGL based application in VC2013/ SDK 0.8.0 witch I need to modify to 1.3.0 to understand the changes. I am trying to do this using #define switch so the code will be 0.8.0 + 1.3.0 compatible and useful as a clear porting example  ... Is there anybody available for help ? I believe it need to change 30-50 lines of code but I have issues to do this ...

  • Ybalrid said:

    It's working, beside the fact that the Xbox button doesn't bring back Oculus Home yet (not sure about that, I did not touch the "PlatformSDK" stuff inside the .zip yet, looks like a lib ton integrate your programs to the Oculus ecosystem...)



    You have to disable Windows 10 game bar integration.  Press Win-G to open the game bar and click on the settings icon and uncheck the 'Open Game Bar using <X> on the controller'