leapmotion / LeapMotionCoreAssets

Unity Assets for Leap Motion v2 Skeletal Tracking
Apache License 2.0
166 stars 81 forks source link

Unity 5.2.0 / Oculus 0.7.0 Runtime VR Integration #129

Closed RandomOutput closed 9 years ago

RandomOutput commented 9 years ago

This PR Updates Core Assets to support Unity's embedded virtual reality support and the Oculus 0.7.0 Runtime.

Stakeholder Signoff

Fixes leapmotion/Front-End-Integrations#3 Fixes leapmotion/Front-End-Integrations#4 Fixes leapmotion/Front-End-Integrations#5 Fixes leapmotion/Front-End-Integrations#7 Fixes leapmotion/Front-End-Integrations#9 Fixes leapmotion/Front-End-Integrations#10 Fixes leapmotion/Front-End-Integrations#12

To Test:

Configuration Manager

protodeep commented 9 years ago

Regarding: " Confirm that the configuration manager properly reflects the left and right graphics model hands selected in the hand controller when in VR hands / VR world mode."

If I swap the robot hands for other 3D hands on the HandController, the config manager overrides this at runtime. That intended?

protodeep commented 9 years ago

Also, I'm getting offset finger positions in my right hand when using 3D robot hands regardless of whether "Separate Left/Right" is checked.

image

protodeep commented 9 years ago

And, if I drag a GlowRobotFullRightHand onto the right hand slot of the HandController, it will pop back to whatever is in the left hand slot as soon as I click anywhere else in the editor.

Kip27 commented 9 years ago

These scenes are crashing for me on play in-editor and when attempting to build with Unity 5.2.0 and Oculus runtime 0.7.0.0

protodeep commented 9 years ago

Override Device Type enum set to "Invalid". Intended?

mmenicutch commented 9 years ago

The issue with the apps crashing seems to be that the non VR scenes are outputting to the oculus when you have an oculus plugged into your system. It only causes a crash for some systems, others don't get hands or passthrough.

protodeep commented 9 years ago

Quickswitch on Dragonfly only switches by moving hand up, not down. Both directions work on peripheral

Kip27 commented 9 years ago

ImageHands scene not working. Error: Cannot use LeapImageRetriever if there is no HandController! No images in-editor or when built.

RandomOutput commented 9 years ago

@protodeep: Commit 2d818ec should resolve:

@Kip27 @mmenicutch As discussed, for non-VR scenes, the oculus must be unplugged and/or 'virtual reality supported' must be disabled in the unity 'player settings' tab.

RandomOutput commented 9 years ago

@Kip27 9484ca7 should resolve the broken desktop image hands scene.

mmenicutch commented 9 years ago

It seems that anything involving keyboard controls in the oculus scenes no longer works, tab to start recording in the bug reporter scene and the WASD controls in the moving demo no longer function.

mmenicutch commented 9 years ago

I'm also seeing an issue with Quickswitch functioning while in the editor, but no longer working when built.

protodeep commented 9 years ago

@mmenicutch @RandomOutput For the BugReporter recording, pressing the left shift key unlocks the tab key. No UI for this at runtime, but there is an enum in the editor on the BugReporter that explains this behavior.

RandomOutput commented 9 years ago

@mmenicutch f16ee39 and 3e6bb11 should address the bug reporter instructions being wrong, and the moving demo no longer having wasd and mouse look.

RandomOutput commented 9 years ago

@mmenicutch 499eb13 should resolve quick switch working in editor but not in build.

Amarcolina commented 9 years ago

I'm getting warnings for unused vars in SystemWipeRecogniser, for m_wipeInfoDirty and wipeInfoLock

Amarcolina commented 9 years ago

I start a new empty scene, and drop the LMHeadMountedRig into the scene. It defaults to the AR_WORLD_AR_HANDS configuration, but the background quad is being overwritten by the skybox. In AR mode the cameras clear flags should be set to Color Only instead of Skybox.

Amarcolina commented 9 years ago

When using VR_WORLD_AR_HANDS config, when shaking my head I am getting some weird artifacts with the image hand.
handartifact

Amarcolina commented 9 years ago

I built an exe of SpaceTimeAlignment and I believe I understand what is causing the artifacts. It can be noticed by using the dragonfly (I made sure to override the device type just in case) and turning on the tracked skeleton. I am noticing that the tracked skeleton slides relative to the image of the hand when I move my head. This can sometimes lead to the image highlight sliding right off the hand (as seen above). I think that what is happening is that the images are being timewarped (leading to them lining up with virtual objects), but the hand controller itself is not being rewound, so objects that are a child of the hand controller are still stuck in the wrong coordinate space and do not line up properly.

RandomOutput commented 9 years ago

@Amarcolina 149cdf2 should resolve the system wipe recognizer warnings.

RandomOutput commented 9 years ago

@Amarcolina In 34f4c7a, Advanced Mode is refactored in the manner we discussed. Give it a shot when you have a moment.

Amarcolina commented 9 years ago

One small change that might be nice, if you add m_Script to the list of basic names, which will allow the default script field to show up even if advanced mode is off. Also AdvancedMode.cs is currently a MonoBehaviour, it should probably be a static class.

RandomOutput commented 9 years ago

@Amarcolina resolved in a1970c1

Amarcolina commented 9 years ago

That looks great! The cameras still have their clear flags set to skybox for AR_WORLD mode, which is preventing the quad background from showing through when there is a skybox. Also im not sure when it happened but it seems the left and right cameras of the camera alignment in the prefab are unsigned.

RandomOutput commented 9 years ago

@Amarcolina Fixed the clear flags in 53fd5c8.