{"action":"created","issue":{"url":"https://api.github.com/repos/urho3d/Urho3D/issues/153","repository_url":"https://api.github.com/repos/urho3d/Urho3D","labels_url":"https://api.github.com/repos/urho3d/Urho3D/issues/153/labels{/name}","comments_url":"https://api.github.com/repos/urho3d/Urho3D/issues/153/comments","events_url":"https://api.github.com/repos/urho3d/Urho3D/issues/153/events","html_url":"https://github.com/urho3d/Urho3D/issues/153","id":26320206,"number":153,"title":"Oculus Rift Integration","user":{"login":"tersers","id":4276957,"avatar_url":"https://avatars.githubusercontent.com/u/4276957?v=3","gravatar_id":"","url":"https://api.github.com/users/tersers","html_url":"https://github.com/tersers","followers_url":"https://api.github.com/users/tersers/followers","following_url":"https://api.github.com/users/tersers/following{/other_user}","gists_url":"https://api.github.com/users/tersers/gists{/gist_id}","starred_url":"https://api.github.com/users/tersers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tersers/subscriptions","organizations_url":"https://api.github.com/users/tersers/orgs","repos_url":"https://api.github.com/users/tersers/repos","events_url":"https://api.github.com/users/tersers/events{/privacy}","received_events_url":"https://api.github.com/users/tersers/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/urho3d/Urho3D/labels/feature%20request","name":"feature request","color":"fbca04"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":20,"created_at":"2014-01-26T19:19:17Z","updated_at":"2016-09-03T18:04:00Z","closed_at":null,"body":"Hello! \r\n\r\nI have experience developing with the OculusRift in C++, and I would be interested in integrating the Oculus with Urho3D so it can easily be used as a component.\r\n\r\nThis may take some time because I am in a game development course at university, and the workload does not favour any spare time. That being said, the game I am making this semester (I chose Urho for the engine) will be using the Oculus, so I'll write a C++ integration in my local project and then port it to the engine once it's done. I've done this before in Ogre, so I know the necessary operations with the engine's components, such as shaders and viewports.\r\n\r\nThe latest I can see this being completed would be April."},"comment":{"url":"https://api.github.com/repos/urho3d/Urho3D/issues/comments/244561118","html_url":"https://github.com/urho3d/Urho3D/issues/153#issuecomment-244561118","issue_url":"https://api.github.com/repos/urho3d/Urho3D/issues/153","id":244561118,"user":{"login":"eugeneko","id":8576192,"avatar_url":"https://avatars.githubusercontent.com/u/8576192?v=3","gravatar_id":"","url":"https://api.github.com/users/eugeneko","html_url":"https://github.com/eugeneko","followers_url":"https://api.github.com/users/eugeneko/followers","following_url":"https://api.github.com/users/eugeneko/following{/other_user}","gists_url":"https://api.github.com/users/eugeneko/gists{/gist_id}","starred_url":"https://api.github.com/users/eugeneko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eugeneko/subscriptions","organizations_url":"https://api.github.com/users/eugeneko/orgs","repos_url":"https://api.github.com/users/eugeneko/repos","events_url":"https://api.github.com/users/eugeneko/events{/privacy}","received_events_url":"https://api.github.com/users/eugeneko/received_events","type":"User","site_admin":false},"created_at":"2016-09-03T18:04:00Z","updated_at":"2016-09-03T18:04:00Z","body":"There is one more connected issue. It is easy to implement naive\ntwo-viewport rendering, but it is tremendously wasteful to do tons of\npre-rendering work twice.\nUrho also needs some mechanism to make several viewports 'grouped' to avoid\nas much duplicate work as possible.\n\n2016-09-03 20:49 GMT+03:00 Quibilia <notifications@github.com>:\n\n> It's roughly possible on the application end, from my experience. I tried\n> writing a VR program with Urho3D a few months ago, but it was never\n> finished.\n>\n> ovrSession session;\n> ovrGraphicsLuid luid;\n> ovrHmdDesc hmdDesc;\n> ovrSizei hmdRes;\n> ovrTrackingState ts;\n>\n> void MainClass::Setup()\n> {\n>     if (OVR_FAILURE(ovr_Initialize(nullptr)))\n>     {\n>         URHO3D_LOGERROR(\"Failed to initialize the Oculus Rift SDK. VR will not work in this session.\");\n>     }\n>     else\n>     {\n>         if (OVR_FAILURE(ovr_Create(&session, &luid)))\n>         {\n>             ovr_Shutdown();\n>             URHO3D_LOGERROR(\"Failed to create the required pointers for Oculus Rift support. VR will not work in this session.\");\n>\n>     }\n>         else\n>         {\n>             hmdDesc = ovr_GetHmdDesc(session);\n>             hmdRes = desc.Resolution;\n>\n>             engineParameters_[\"WindowWidth\"] = hmdRes.Width;\n>             engineParameters_[\"WindowHeight\"] = hmdRes.Height;\n>         }\n>     }\n> }\n>\n> void MainClass::Start()\n> {\n>     SubscribeToEvent(E_RENDERUPDATE, URHO3D_HANDLER(MainClass, HandleRenderUpdate));\n> }\n>\n> void MainClass::Stop()\n> {\n>     ovr_Destroy(session);\n>     ovr_Shutdown();\n> }\n>\n> void MainClass::HandleRenderUpdate(StringHash type, VariantMap& data)\n> {\n>     ts = ovr_GetTrackingState(session, ovr_GetTimeInSeconds(), ovrTrue);\n>\n>     if (ts.StatusFlags & (ovrStatus_OrientationTracked | ovrStatus_PositionTracked))\n>     {\n>         // I haven't programmed with the newer SDK, so I'm not sure what you'd do with the data here.\n>     }\n> }\n>\n>\n> The biggest issue is that the window will be automatically placed on your\n> main desktop, which isn't necessarily the Rift. It is possible to modify\n> the Graphics class so that it uses the device LUID to setup a window on the\n> Rift, but this can be tedious. What I would love is if there was an engine\n> parameter that the user could use to specify the monitor to render to; I'm\n> sure this is somehow possible using WindowPositionX and WindowPositionY,\n> but a monitor specification would be much easier.\n>\n> —\n> You are receiving this because you are subscribed to this thread.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/urho3d/Urho3D/issues/153#issuecomment-244560282>, or mute\n> the thread\n> <https://github.com/notifications/unsubscribe-auth/AILcwGOHe4tefqeN6OQJRSVzvwHL8901ks5qmbMRgaJpZM4BcolJ>\n> .\n>\n"}}
{"actor":{"display_login":"eugeneko"}}