UDKOSC and Oculus Rift
From CCRMA Wiki
Head bone HMD tracking example from https://developer.oculusvr.com/forums/viewtopic.php?f=44&t=936
/* GetViewRotation always match the camera to the rotation of the eye socket */ simulated event rotator GetViewRotation() { local vector out_Loc; local rotator out_Rot; if (EyeSocket == ) return Super.GetViewRotation(); Mesh.GetSocketWorldLocationAndRotation(EyeSocket, out_Loc, out_Rot); return out_Rot; } //function to aim the head where the player looks exec function LookAt(int p, int y, int r) { local SkelControlSingleBone HeadControl; local Rotator APlace; APlace.Pitch = p; APlace.Yaw = y; APlace.Roll = r; HeadControl = SkelControlSingleBone(Mesh.FindSkelControl('HeadControl')); HeadControl.bApplyRotation = true; HeadControl.SetSkelControlStrength(1.0, 0.5); HeadControl.BlendInTime = 5.0; HeadControl.bAddRotation = true; HeadControl.BoneRotation = APlace; }
Installation basics: 1) Download the new UDK from the Oculus Developer site. 2) Go to the folder C:\UDK\UDK-2013-03\UDKGame\Config\ and edit the UDKEngine.ini, (back it up first of course) 3) In the [Engine.Stereo3D] section, change the bEnabled parameter = True 4) Optional: in the [Engine.Oculus] section, change the bEnableHud parameter = False, (as the hud is kind of messed up right now). 5) Run the UDKGame program that installed with the UDK, (should be an icon on your desktop).