Search Unity

Easy Input for Gear VR and Oculus Go [Released]

Discussion in 'Assets and Asset Store' started by greggtwep16, May 2, 2017.

  1. Spookytooth3D

    Spookytooth3D

    Joined:
    Oct 31, 2013
    Posts:
    73
    ok... with a good understanding of the workflow at this point, do you have any plans to release a SteamVR version for Vive?
     
  2. goddestroyer

    goddestroyer

    Joined:
    Jan 11, 2017
    Posts:
    12
    I've just purchased the asset and imported it into my scene in Unity 2018.3.4f1. I already had the current Oculus Integration installed from Unity Store:
    https://assetstore.unity.com/packages/tools/integration/oculus-integration-82022

    Upon opening my project, the asset complains that Oculus utilities are not installed. to find the latest Oculus utilities I go here:
    https://developer.oculus.com/downloads/package/oculus-utilities-for-unity-5/

    and that page makes it sound like that package is outdated and superceded maybe by the Oculus Integration from the asset store, above.

    When I install the Oculus Utilities anyway, I immediately get flooded with console errors about incompatible OVR files:
    "Assets/Oculus/VR/Scripts/OVRHeadsetEmulator.cs(56,55): error CS1061: Type `OVRManager' does not contain a definition for `headPoseRelativeOffsetTranslation' and no extension method `headPoseRelativeOffsetTranslation' of type `OVRManager' could be found. Are you missing an assembly reference?"

    "
    Assets/Oculus/VR/Scripts/Util/OVRSystemPerfMetrics.cs(224,27): error CS0117: `OVRPlugin' does not contain a definition for `GetPerfMetricsFloat'
    "


    So I ask as of today what is the recommended version of unity + oculus utilities and oculus integration to be able to use your asset?
     
  3. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Back a few years ago, I briefly released a daydream version of the API, but Google later changed their whole API breaking everything which obviously wasn't a good experience. The fact is there are numerous SDK's pretty much one for every company that does VR and supporting them all isn't feasible.

    My current products only support the Oculus API and only focus on 3 degrees of freedom not 6. If at some point Unity's wrapper API actually can do everything the native API's can then I'll certainly do one for that, but until then, I don't have any plans on supporting any of the other native SDKs.
     
  4. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    As of right now, the latest version from the store works good with our latest beta (email our support address with your invoice number for this version).

    In general though ever since Oculus moved their SDK to the store this is a more complicated questions because the assetstore doesn't keep older versions and Oculus has broken their plugin more than a few times (you can read their reviews to confirm). They generally update quite often and most of the times things are ok but not always. Also, the asset store version isn't just the input sdk it's everything they do (avatars, etc.) and is quite large. If you are going to use everything they provide this is fine, but most people don't and having unnecessary stuff slows things down. The main issue though is the lack of version history that used to exist when they hosted it on their site, so if they broke something you could easily just revert to previous.
     
  5. eovento

    eovento

    Joined:
    Feb 22, 2018
    Posts:
    38
    Good evening, Greg! :)
    How are you?

    Although there is no official update on the Asset, I can see you've sent a few patches to some users. Is there a way of seeing a list of all you have implemented already that me and other users could be interested? And maybe ask it by email?

    I would be very interested in a way to move towards the controller is pointing, instead of the direction I'm looking at. And I don't now if this is something you might already have, so I would not keep on bothering you... among other things.

    A list would be very useful.

    If you could shine a light on this for me, telling me what I would have to change on your scripts, I would also be very thankful. :)

    Wish you and all here a great weekend!
     
  6. goddestroyer

    goddestroyer

    Joined:
    Jan 11, 2017
    Posts:
    12
    Thanks for the input. This was also kind of my experience in trying to get set up with all of this. I agree with what you are saying about most games don't need everything the Oculus integration library does. My app is extremely simple and was released for Daydream. I got the Easy VR Input Helper to work by only installing Oculus utilities 1.28 the last version released from their site, and first UNINSTALLING the "Oculus Integration" asset from the unity store (full manual uninstall).
     
  7. goddestroyer

    goddestroyer

    Joined:
    Jan 11, 2017
    Posts:
    12
    But my current issue now is I was able to get 1 of my interactive game items to respond to the Easy Input Helper laser pointer by adding a "standard pointer reactor" to the item and re-creating the same Unity Event Triggers I already had set up on the object. The problem is I have a map with dozens of interactive objects, and each has 3 or more Event Triggers to set up. That would take ages to re-create with the "standard pointer reactor".

    can you hook the laser pointer events to the normal Unity Event trigger system? then my game would "just work" already with the Oculus Go controller using the Easy Input Helper. I have skimmed this thread a lot but haven't seen the similar question yet at least. thanks for responding
     
  8. wlau1378

    wlau1378

    Joined:
    Dec 1, 2017
    Posts:
    1
    Is there any video tutorials we can take a look at beside the documentation?
     
  9. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    You could point the receiver to the event system itself, which if you don't have any extra data that you were relying on would probably work. However, most of Unity's triggers usually forwarded data as well (pointer data, axis data, etc.) which is a different paradigm. Both have there strengths and weaknesses and indeed if you have dozens of objects that is tedious with the receiver paradigm. If you do need underlying data so that forwarding wouldn't work, my suggestion would be to just modify the standard pointer receiver directly for your needs (subscribing to event trigger directly, checking colliding object name, or whatever your needs were). That way you can avoid needing to fiddle with any inspectors.
     
  10. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Here is the current state of the beta in relation to the store version and a rough roadmap.

    Additions complete:
    1. fixed rotation controller (rotation in fixed increments)
    2. conditional show laser allows portions of the pad (up/down/left/right)
    3. Straight laser now can teleport as well
    4. laser color can change based on whether or not it's a current valid spot
    5. Orientation controller (think flight stick flying a ship)
    6. Runtime detection of whether go or gear vr and display the correct controller model if using default models.
    7. Fix for folder structure change in Oculus integration
    8. Teleport improvements (lerp option for teleporting instead of instant, direction indicator on reticle)

    Priority current work:
    1. Redoing helper window popup system so Unity will approve further updates (this is holding up getting submissions to the store)

    Future work
    1. Various requests still in progress
    2. Improve documentation
    3. Create tutorial videos
     
  11. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    The standard orientation controller in the beta can be used for this. It was originally designed to control a space shooter ship from one of our customers but is a built in a way that it can be any gameobject not just a spaceship. If you put the hand controller as the gameobject it would follow its direction. You'd probably be the first testing it for that purpose but it should work. Certainly send your invoice to our support address if you want to try that out.
     
  12. Jatin_J3

    Jatin_J3

    Joined:
    Oct 31, 2014
    Posts:
    9
    Hi !
    Thanks for the asset. I was trying Fps controller, The problem is it is crossing box collider, this is not supposed to happen.
    Can you please tell me solution?
    Thanks
     
  13. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Which box collider in the example? The floor?

    Shouldn't happen in the unedited example, certainly let me know if it is. If you are making your own modifications then make sure the colliders don't overlap on start as that's usually the culprit.
     
  14. Jatin_J3

    Jatin_J3

    Joined:
    Oct 31, 2014
    Posts:
    9
    I am using FPSController example.
    Please see screenshot here.
    I have added one cube over here. And it has box collider + rigid body.
     

    Attached Files:

  15. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    The stationary objects like your box should only have a collider. The character is what has a collider plus rigidbody on it (since you are controlling it and its moving). Once corrected you shouldn't be able to walk through the box anymore.

    The floor in the example is essentially the same thing. You can look at its inspector if you want to use it as a reference.
     
  16. Jatin_J3

    Jatin_J3

    Joined:
    Oct 31, 2014
    Posts:
    9
    FPSController has rigidbody + collider and the box has also collider+regid body
    though i am able to cross it.
     
  17. Jatin_J3

    Jatin_J3

    Joined:
    Oct 31, 2014
    Posts:
    9
    transform.Translate (actionVector3);
    This is causing issue i think
     
  18. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    The box should not have a rigidbody if you don't intend it to move and want it to act as a wall. You can compare it to the floor in the FPS example. There are also a few other tangible examples in the pointer example.
     
  19. Jatin_J3

    Jatin_J3

    Joined:
    Oct 31, 2014
    Posts:
    9
    Yes, It is working now. Thanks.
     
    greggtwep16 likes this.
  20. dylanjameswalch

    dylanjameswalch

    Joined:
    Jun 20, 2018
    Posts:
    12
    Hello!

    I am encountering an issue with my world canvas UI not being intractable on a new scene. I have the EventSystem with the input module persist through each scene because it is used for the UI for main character.

    Is it necessary to replace this EventSystem every time you load a new scene or will it work on a new scene? Or is it possible to have two of these Event Systems at the same time to handle the persistent UI and new scene UI?

    I have tried to attach the existing UI Camera to the Event Camera of the new World Space Canvas but it will not work correctly in my Oculus Go build. Do you have any advice for me with this issue?

    Thanks for your help.
     
  21. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    There are several examples that showcase UIs but a couple of notes based on your comments.

    1. Your pointer's distance in the inspector determines how far you can interact with. Make sure the distance between you and the UI isn't greater than this distance (ie. if you have it set to 20 units but are standing 100 units away it isn't going to register).

    2. Generally speaking unless you are doing something really rare you only want one event system in a scene. This isn't added at runtime but at design time, and you'll notice that any time you add any canvas or Unity UI to the scene Unity automatically creates an event system for you if one is not present. If already present and you add a second canvas Unity already knows an event system is there and maintains there only being one.

    3. The UI camera is my component and automatically adds itself to all the canvas's when the scene is started. The only time you'd want to manually add it is if you are creating a new canvas at runtime after start, instead of designing it in the editor.

    4. VR really only handles world space UI's well. Since they are in world space sometimes it's easy to not realize if a UI is facing forwards or backwards and by default Unity only allows selecting from the front side. Sometimes for initial testing its worth unchecking ignore reverse graphics on the graphics raycaster until you verify which way is forward so you can click from either side before rechecking it.

    5. Verify on the pointer that you have UI raycast checked and the input module that you are using in the pointer's inspector.

    Certainly let me know if you still can't select after checking these. If you are doing a bunch of runtime stuff can you post the code you are using when you are generating the canvas/UI?
     
  22. Joits

    Joits

    Joined:
    Jul 12, 2016
    Posts:
    29
    Hi Gregg
    A quick questions. I'm developing for Oculus Go and using world space Canvases to interact with certain elements. I'm running into a weird issue with the interaction. I need to keep my thumb on the Go's trackpad and then press the trigger in to register a hit on the canvas. In the example scene provided, there are no problems.
    Do you have any solution to my issue?

    Thanks
     
  23. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Is this the case in editor as well? That's certainly a bizarre one considering the example scenes work without issues for you. I can't think of any other component that would interfere in a strange way like that. Certainly let me know the answer to above since it will help me eliminate some of the possibilities.
     
  24. Joits

    Joits

    Joined:
    Jul 12, 2016
    Posts:
    29
    There are also issues in the editor. I cannot interact with anything by clicking with the mouse. Im able to move the controller around and the StandardPointerReceiver works on the "hover" event. The click function in StandardPointerClickReceiver does not work in editor, but works when I make a built for the Oculus Go.
     
  25. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Are you using the editor emulation outlined in the documentation? In this case the emulating the trigger with the u key when highlighted? Does that also work for the examples but not your own scene?
     
  26. Joits

    Joits

    Joined:
    Jul 12, 2016
    Posts:
    29
    Hmm yeah sorry it does work in the editor as expected. I must have missed that part in the documenation, sorry!
    The problem with track pad interaction still persists when i make a built though.
     
  27. goddestroyer

    goddestroyer

    Joined:
    Jan 11, 2017
    Posts:
    12
    I have gotten very close to my final desired solution with the Easy Input package, but one problem remains:
    When I teleport the user as a result of a button click event, the event continues to repeat as long as the oculus go controller button is held down, even when i only want 1 event to fire once.

    In my scene i have two teleport objects (human-like character outlines) sitting across a table from each other. if you point at the teleport point and click, the event is captured by the target teleport object's "Standard Pointer Click Receiver" and you teleport across the table. however since the new teleport location is facing the old teleport location and the pointer is now pointing back to the original teleport object, as the user you endlessly teleport back and forth instantly between the two teleport objects as long as the button is held down, rather than just teleporting once from the single click event.
    The pointer click event is continuously being broadcasted as long as the trigger is held down rather than ending after the initial click.

    I have tried adjusting the settings for "max press length" as well as trying to define the event handlers in many of the different event types on the Standard Pointer Click Receiver, such as on hover click start, on hover click, etc. they always have the same behavior where the same single trigger press continually repeats a click event instead of broadcasting just 1 click.

    It's a shame being 99% of the way to my goal and not being able to get this to work, I am about to abandon the Easy Input helper to start over from scratch from Oculus-provided examples which are harder to work with.

    I would appreciate any input at all.

    pointerreceiver.PNG inputhelper.PNG
     
  28. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    If it works in editor and especially since you mention that the examples work on device, I'd lean towards there is probably an Oculus component you have in your scene that's interfering with Easy Input. Some of the functionality like pointers and the rest overlap so having both in your scene may cause issues.

    If that doesn't help you can zip up and send out support email address your scene and I can take a look.
     
  29. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    For hover click this is the correct behavior since it will repeat the event as long as you are hover clicking. Hover click end should behave properly for your usecase. Hover click start would normally be possible as well but if you are rotating the player so that you are hitting the new item right of the bat I could see how that would repeat as well.

    In the latest beta I'm working on updates to the teleport receiver that would allow you to specify a lockout time. Send our email address your invoice number if you'd like the latest beta.
     
    goddestroyer likes this.
  30. goddestroyer

    goddestroyer

    Joined:
    Jan 11, 2017
    Posts:
    12
    Thanks for your input. As I recall i think i tested almost every event type i could, but i will check again with hover click end.
     
  31. netpost

    netpost

    Joined:
    May 6, 2018
    Posts:
    388
    Hi,

    I get these errors in unity 2018.3.4f1. Would it be possible to know if there is a way to solve this.
    Thank you for your help!:

    Assets\Easy Input for Gear VR\Scripts\Core\Editor\CreateAxesEditor.cs(515,9): warning CS0618: 'EditorApplication.hierarchyWindowChanged' is obsolete: 'Use EditorApplication.hierarchyChanged'
     
  32. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    The one you posted is a warning and will function normally with it. Is there one that's an actual error? If so certainly let me know and I'll look into it. That particular Unity version is working properly over here. Are you seeing some issues during gameplay?
     
  33. LaCorbiere

    LaCorbiere

    Joined:
    Nov 11, 2018
    Posts:
    29
    Aloha. I'm having problems applying the Standard Laser Pointer Script to the standard OVR rig (named 'Player' in the screen grab). As you can see from the screen shot, I have applied to Standard Laser Pointer script to the OculusGoControllerModel. When the application runs in the Oculus Go, The controller is up and off to one side and the laser pointer is absent. Maybe some confliction along the line? I have fiddled about with the Height Offset too.

    Also, I hear talk of a patch available? Is it just testing phase or publicly available? Many thanks!

    LaserPointerProbs.jpg
     
  34. netpost

    netpost

    Joined:
    May 6, 2018
    Posts:
    388
    Thank you very much for the quick reply. I started 5 different projects and it seems I can't get away without errors. in the GearVR setting window I always have the "Oculus Utilities aren't dowloaded and imported (required for Gear VR)" so I click the Download button that bring me to the Oculus utilities 1.28 download page. But this message never disappear. I also I found out that the Oculus utilities 1.28 is now replaced for the oculus Integration 1.36. But even if I create a new project install the oculus Integration 1.36 first than, your asset, I still have the same problem and of course the error that goes with it. To summarize, your GearVr wizard setting window is not really working anymore. the problem is really easy to recreate everytime with a new session. My guess is the link to the oculus utility isn't good anymore and this is really confusing.

    Thanks again.
     
  35. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Email our support address from the asset store page your invoice number and I can send you the latest beta which accounts for the folder structure changes that Oculus made (which is how I detect if you've downloaded it or not).
     
  36. netpost

    netpost

    Joined:
    May 6, 2018
    Posts:
    388
    Thank you again for the quick reply. Unfortunately when I try to contact Ladmer Tech, I have a blue screen asking me to "choose which account to send the email from". But I have no option to select from. I am using Gmail and it doesn't show...

    My invoice is IN010000463237.

    Thanks!
     
  37. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Thanks, what email address would you like for me to send the beta to?
     
  38. netpost

    netpost

    Joined:
    May 6, 2018
    Posts:
    388
    Thanks again!
     
    Last edited: Apr 30, 2019
  39. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    I have sent you the beta which should resolve your issues. I would edit your post above to remove your email address so that you don't get extra spam from any web crawlers that would mine that info.
     
  40. netpost

    netpost

    Joined:
    May 6, 2018
    Posts:
    388
    Email erased Thank you!
     
  41. AJS654321

    AJS654321

    Joined:
    Oct 11, 2018
    Posts:
    57
    hi, ive just bought this asset, how do I add the curved teleporter to my scene please? and is there a way to switch off the movement so you just use the teleporter please? thanks
     
  42. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    Everything is in self contained components so you can mix/match only what you need. In the case of what you describe, you simply need the curved laser and the teleport receiver on the object(s) you want to be able to teleport to.

    If you want a tangible example, the closest is the pointer example and since you mentioned wanting to switch off non teleport movement, simply remove the dpad component from the player in that scene.
     
  43. AJS654321

    AJS654321

    Joined:
    Oct 11, 2018
    Posts:
    57
    hi, thanks for the reply, is their a dummies guide for a newbie to unity to use this asset please? ive tried following the pdf documentation, but im not getting anywhere? ive added the easyinputhelper, what do I do next?

    do I simply add the script to the object I want to teleport?

    also is it possible to use an xbox one s controller with this on the oculus go?

    thanks for your patience, im just new and learning
     
  44. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    There isn't a fully step by step document, but I'd be happy to answer any questions.

    After you've added the main easyinputhelper gameobject to your scene you simply add the components your particiular game needs. For teleporting you'd need whichever laser you want to use (likely the curved laser) to be attached to your gameobject that represents you hand. You also need a teleport receiver attached to the objects you want to be able to teleport to (in the example this was the ground). As far as xbox controllers instead of the go controller there are components for those as well. You can check out the various axis controllers and button controllers. The dropdowns in the inspectors are for which button or joystick in particular you want to use.

    For learning the examples are your best bet. The pointer example showcases teleporting if you click the curved laser button.
     
    AJS654321 likes this.
  45. AJS654321

    AJS654321

    Joined:
    Oct 11, 2018
    Posts:
    57
    hi, thanks for the reply and your patience with me,

    ok ive started a new scene, ive added an easyinputhelper, a plane and added a standard teleporter receiver script to it and a capsule with a standard curved laser pointer script,

    what do I do next please? cheers
     
  46. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    For just teleporting from a component perspective that's all that's required.

    That being said make sure you have the following three things on those objects.
    1. Make sure the floor (plane) has a collider on it (usually a box collider).
    2. Make sure the inspector for the laser pointer has collider raycast checked
    3. Make sure the inspector for the laser point has layers to check set to either everything or the specific layers that you plane is using.
     
  47. AJS654321

    AJS654321

    Joined:
    Oct 11, 2018
    Posts:
    57
    hi, thanks for the reply,

    ive done everything you have said, but it still doesn't work? all it does is rotate the camera? u can see the curved laser pointer in the headset,

    attached images of my setup for you to have a look at please.

    thanks again for your help, andy

    capsule.JPG plane.JPG ive
     
  48. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    The biggest issue I see is you don't have plane on the layer you set, (the plane's layer is default but you have the inspector set to plane).

    A couple of normal Unity things that I can see from those inspectors for characters.

    1. I don't see a rigidbody on your capsule. I'm assuming you want gravity and the floor collisions. Usually this is the way to go, especially for uneven surfaces, but if the plane is completely flat and you can get away without it.

    2. You mentioned being able to see the laser. I'm actually surprised because you didn't set a material. Normally you'd want to pick one.

    3. Height offset being 0 means when you get the teleport working you are going to teleport even with the ground. Normally you want the feet of your character to be at that point so you'd enter a height offset for however tall your character is (you can also do this in the teleport receiver if you'd prefer to do it there.

    4. You're using a mesh collider on the plane. For just a box it probably doesn't matter unless it's super thin, but normally you want to use a simpler collider for performance reasons (box, etc.).
     
  49. AJS654321

    AJS654321

    Joined:
    Oct 11, 2018
    Posts:
    57
    hi

    thanks again for your reply and your patience with me, Im completely new to unity, im a 3d modeller, I know how to get my models into the scene and texture and lighting, but that is all,

    ive set the layer to default on plane and everything on capsule,

    I added a rigidbody to my capsule, I didn't know that I had to do this?

    I added a material to the laser ,

    I added box collider to the plane

    I ran the program again through my oculus go and all it does it rotate the camera, I cant see the laser now too

    im really struggling with this asset, and finding it not "EASY" is there anyway you could make a simple unity scene for me please to get this working please?

    I just need to be able to teleport around my scene by either pressing the trigger or the touch pad, just like the GitHub fusedver gear teleporter, ive got till next Saturday to get this working please
     
  50. greggtwep16

    greggtwep16

    Joined:
    Aug 17, 2012
    Posts:
    1,546
    That's not what I meant. The layer that you have on the plane is default, but on your curved laser you have "layers to check" set to plane. These have to match. So if your plane's layer is default you have to have default selected. Or if you wish you can set layers to check to everything as well. Without this the curved layer never will hit your target because it isn't checking that physics layer.

    Also there is already an example scene for teleporting. The pointer example showcases teleporting when you click to the curved laser.