ValveSoftware / steamvr_unity_plugin

SteamVR Unity Plugin - Documentation at: https://valvesoftware.github.io/steamvr_unity_plugin/
BSD 3-Clause "New" or "Revised" License
1.03k stars 256 forks source link

HTC Vive Controllers not showing in scene #323

Closed larryjohncarter closed 3 years ago

larryjohncarter commented 5 years ago

Hello, I am using Unity 2018.3.5f1 with SteamVR latest version from Unity Asset Store which is 2.2.0. I have set up the SteamVR input and everything. However when I go into the Interactions_Example scene provided by SteamVR asset, the controllers are not being tracked. I have tried everything including making a new project. Even when I attach a script to debug buttons, it doesn't show any debug logs.

zite commented 5 years ago

Are you getting any errors in the console? You say you did generate actions in the SteamVR input window?

On Thu, Feb 14, 2019 at 2:12 AM larryjohncarter notifications@github.com wrote:

Hello, I am using Unity 2018.3.5f1 with SteamVR latest version from Unity Asset Store which is 2.2.0. I have set up the SteamVR input and everything. However when I go into the Interactions_Example scene provided by SteamVR asset, the controllers are not being tracked. I have tried everything including making a new project. Even when I attach a script to debug buttons, it doesn't show any debug logs.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/ValveSoftware/steamvr_unity_plugin/issues/323, or mute the thread https://github.com/notifications/unsubscribe-auth/AAMIMJV8irftvhf7t4gt7DdgtHSVDo5Mks5vNTZxgaJpZM4a7QPS .

larryjohncarter commented 5 years ago

No errors at all. just doesnt track the controllers

BennyFab commented 5 years ago

I have the same problem. The controller model doesn't render and no tracking is occuring. I have set up action in the input. The transform of both controllers stay 0,0,0 but they work in games and are tracking in steam VR. it doesn't work with any unity project even the sample ones. I have no idea where to start to fix this problem.

zite commented 5 years ago

Neither of you are getting any errors? How about warnings? Can you paste the editor log so I can see the flow of logs?

You can find the editor log here: Hit the windows key then paste in: %LOCALAPPDATA%\Unity\Editor There you'll find Editor.log

You can paste to: https://gist.github.com/

BennyFab commented 5 years ago

Ok soo... I restarted a completely new project and it finaly Worked (I don’t know why or how and I don’t like that) Here is all that happen and the editor log if it can help someone.

So when installing the plugin I had those warning and messsages:

ImportFBX Warnings: Can't generate normals for blendshape 'Squeeze' on mesh 'finger', mesh has no smoothing groups.

ImportFBX Warnings: Can't generate normals for blendshape 'GD_mesh' on mesh 'GD_mesh.001', mesh has no smoothing groups.Can't generate normals for blendshape 'Key 2' on mesh 'GD_mesh.001', mesh has no smoothing groups.

ImportFBX Warnings: Can't generate normals for blendshape 'puff' on mesh 'Body', mesh has no smoothing groups.

Lighting data asset ‘LightingData’ is incompatible with the current Unity version. Please use Generate Lighting to rebuild the lighting data. Realtime Global Illumination cannot be used until the lighting data is rebuilt.

[SteamVR Setup] Generated you an editor app key of: application.generated.unity.vrtest.exe. This lets the editor tell SteamVR what project this is. Has no effect on builds. This can be changed in Assets/SteamVR/Resources/SteamVR_Settings UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_Settings:LoadInstance() (at Assets/SteamVR/Scripts/SteamVR_Settings.cs:80) Valve.VR.SteamVR_Settings:get_instance() (at Assets/SteamVR/Scripts/SteamVR_Settings.cs:17) Valve.VR.SteamVR_AutoEnableVR:Update() (at Assets/SteamVR/Editor/SteamVR_AutoEnableVR.cs:48) UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

[SteamVR Setup] Enabled virtual reality support in Player Settings. (you can disable this by unchecking Assets/SteamVR/SteamVR_Settings.autoEnableVR) UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_AutoEnableVR:Update() (at Assets/SteamVR/Editor/SteamVR_AutoEnableVR.cs:56) UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

[SteamVR Setup] Added OpenVR to supported VR SDKs list. UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_AutoEnableVR:Update() (at Assets/SteamVR/Editor/SteamVR_AutoEnableVR.cs:91) UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

[SteamVR Setup] Installing OpenVR package... UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_AutoEnableVR:Update() (at Assets/SteamVR/Editor/SteamVR_AutoEnableVR.cs:123) UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

[SteamVR Setup] Successfully installed OpenVR package. UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_AutoEnableVR:Update() (at Assets/SteamVR/Editor/SteamVR_AutoEnableVR.cs:205) UnityEditor.EditorApplication:Internal_CallUpdateFunctions()

Lighting data asset ‘LightingData’ is incompatible with the current Unity version. Please use Generate Lighting to rebuild the lighting data. Realtime Global Illumination cannot be used until the lighting data is rebuilt. UnityEditorInternal.InternalEditorUtility:GetGameObjectInstanceIDFromComponent() UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

There were no warning or error when adding steamVR prefab (camera rig and SteamVR)

But when pressing play I forgot to add an input folder with the necessary files (I clicked yes to create the default one, and clicked generate in the input windows ) so I had those messages:

[SteamVR] Could not find actions file at: C:/Users/fabla/Documents/VR Test/actions.json UnityEngine.Debug:LogError(Object) Valve.VR.SteamVR_Input:IdentifyActionsFile(Boolean) (at Assets/SteamVR/Input/SteamVR_Input.cs:1282) Valve.VR.SteamVR:CreateInstance() (at Assets/SteamVR/Scripts/SteamVR.cs:179) Valve.VR.SteamVR:Initialize(Boolean) (at Assets/SteamVR/Scripts/SteamVR.cs:98) Valve.VR.SteamVR_Behaviour_Pose:OnEnable() (at Assets/SteamVR/Input/SteamVR_Behaviour_Pose.cs:88) [SteamVR] No pose action set for this component UnityEngine.Debug:LogError(Object) Valve.VR.SteamVR_Behaviour_Pose:Start() (at Assets/SteamVR/Input/SteamVR_Behaviour_Pose.cs:76)

GUI Window tried to begin rendering while something else had not finished rendering! Either you have a recursive OnGUI rendering, or the previous OnGUI did not clean up properly.

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/actions.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/bindings_holographic_controller.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/bindings_knuckles.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/bindings_oculus_touch.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/bindings_vive_controller.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/binding_holographic_hmd.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/binding_rift.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/binding_vive.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/binding_vive_pro.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

[SteamVR] Copied example input JSON to path: C:/Users/fabla/Documents/VR Test/binding_vive_tracker_camera.json UnityEngine.Debug:Log(Object) Valve.VR.SteamVR_CopyExampleInputFiles:CopyFiles(Boolean) (at Assets/SteamVR/Input/Editor/SteamVR_CopyExampleInputFiles.cs:58) Valve.VR.SteamVR_Input_EditorWindow:CopyOrClose() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:293) Valve.VR.SteamVR_Input_EditorWindow:CheckFileInitialized() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:321) Valve.VR.SteamVR_Input_EditorWindow:OnGUI() (at Assets/SteamVR/Input/Editor/SteamVR_Input_EditorWindow.cs:383) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

Assertion failed on expression: 'device.IsInsideFrame()'

It is the same exact thing (I beleive) I did yesterday but now it works. The controller appears and track. One thing I did read was to check the project setting in player to make sure that in the XR setting openVR was first, but it already was so I didn’t change anything there. I must admit I am a bit confused about what happen. Thank you for your help.

https://gist.github.com/BennyFab/59ec77c43079aa3238893f17470abc95 Editor.log

zite commented 5 years ago

Thanks for the log @BennyFab, yeah I'm not really seeing any issues there. Hard to tell since it's working now. @larryjohncarter can you provide a editor log as well?

rinrinrinrinrinrinrin commented 5 years ago

Hello. Sorry to interrupt, I may have the similar symptom and having trouble. My version is same as others and when I tried out the quick guide and other tutorials, controller wont work out. It works out fine on other places like SteamVR Home, so i think its not the problem with the machine itself.

i would put the picture of console if this would be of any help,

capture

zite commented 5 years ago

@rinrinrinrinrinrinrin what version of steamvr are you running?

BennyFab commented 5 years ago

It Happened again, no error message nothing. I even started a brand new project with only the SteamVR plugin. Editor.log

smashriot commented 5 years ago

I also ran into this problem testing SteamVR 2.2 and have a workaround below. I'm surely taking the long way around here to resolve, but hopefully helps @zite find the issue.

Steps to reproduce:

MacOS: 10.14.3 SteamVR Runtime: 1.2.10 (current Steam Release branch) Create New Project in 2018.3.6f (this one is called: Testing) Import SteamVR 2.2.0 Package Accept All SteamVR project settings changes

Copy actions.json from Assets/SteamVR/Input/ExampleJSON to project root (folder that contains Assets, Library etc). Might not be necessary on Windows, but I'm on Mac, see #265

Window -> SteamVR Input Save and generate

Open SteamVR/InteractionSystem/Samples/Interactions_Example scene Run, notice there are no Vive Controllers showing in scene.

Workaround Steps:

Go back to SteamVR Input window Open binding UI

Note, there is no binding set for the Vive Controller. Click Create Binding Click Replace Default Binding Name it and Save Click Back.
The Binding UI now shows that binding as your current binding.

There is now a new file in project root (named after your project name): application_generated_unity_testing_exe_binding_vive_controller.json

open that file in a text editor. Also, open Assets/SteamVR/Input/ExampleJSON/bindings_vive_controller.json in text editor.
replace "bindings": {} block in your generated json with that from the vive controller json (or whatever controller you are using).

Go back to binding UI and it will complain of no bindings. open binding and click replace default binding again and save.

Run scene and enjoy the visible controllers.

working file references:

Here's a gist of my actions.json and application_generated_unity_testing_exe_binding_vive_controller.json files:

https://gist.github.com/smashriot/1251e6db12cefbe7fe793988da14c576

smashriot commented 5 years ago

Tested again this morning with a fresh project. It's the input JSON files, and is easy to fix.

New project in 2018.3.6f, import 2.2.0 Steam VR:

CurtisRose commented 5 years ago

I am having the same trouble described above. Editor.log

It's almost certainly something to do with my actions/bindings/these JSON files but without an error message how could I hope to debug the problem?

When I set the bindings back to the default through what @smashriot said, that solves my problem. So whatever I'm trying to do with my actions is causing the controllers to not appear but also does not display messages/errors.

chilton commented 5 years ago

Same problem here, on Mac and Windows. I've been chasing this for about a month now and it's infuriating. No warnings that make any sense. I've chased the problem through the debugger, and I have the same errors that rinrinrinrinrinrinrin's screenshot above shows. According to the debugger, it can't find the actions.json file. The .input part of that class method is null, at that point.

smashriot commented 5 years ago

For a standalone MacOS build, Unity copies json files to the same folder as the .app.

When running AppName.app, the Unity Player.log shows: [SteamVR] Could not find actions file at: /Users/username/Desktop/Builds/AppName.app/actions.json

To fix, the json files need to be moved inside the root folder of the AppName.app package (right click and Show Package Contents).

zite commented 5 years ago

I would recommend testing on windows. @chilton those errors should either indicate an out of date openvr_api.cs or an out of date SteamVR version. It might be worth trying SteamVR Beta as well if neither of those are out of date.

brianbatista commented 5 years ago

I wanted to add that even with @smashriot solution, this doesn't work for me. My controllers still disappear. Only way to make them show up after trying to modify the inputs in the JSON files is starting over from scratch with a brand new project. Not even deleting Steam VR folder and reimporting it fixed the issue after I tried modifying the inputs.

This makes no sense at all.

iconnor commented 5 years ago

On windows 10, Unity 2018.3.9f1 and StreamVR 2.2.0 I can get a glove to show up but not the controller. As soon as the scene loads the controller disappears. Clicking the menu gets it back, but then it goes as soon as the menu unloads.

image

When I test in the simple scene it also does not show up.

EDIT

It only works for me if I never edit the SteamVR Input settings. Once I try to do that, the controllers no longer appear. So the advice in this tutorial article where it talks about defining actions is when the controllers fail. I hope this help reproducing the bug and finding a fix.

jirimotejlek commented 5 years ago

Same problem here on Windows 10, I can confirm that even removing everything related to SteamVR and reimporting it doesn't solve this minor problem of controllers not showing up.

editor.log

apiotuch commented 5 years ago

Same issue with Windows 10, Unity 2018.3.9f1 and SteamVR 2.2.0 using Vive Controllers. I tried Smashriot's solutions. Neither worked for me.

I must also add, I started having issues when I renamed default and added a single action, and then set up the binding of the new action to the menu button. I could still use the menu button and it reacts in Unity (opens a simple menu using Unity UI), but tracking does not update, and no models appear. When I hold the bottom Vive menu button, the controllers appear, I can interact with the Vive menu, but exiting that menu, the controllers disappear again.

Seeing how long this issue has persisted, I am really disappointed with the lack of an official solution or update from Steam on this, especially when they recommend developers to abandon the old SteamVR plugin in favor of this version. IT DOESN'T WORK!

I've tried restarting Unity, SteamVR, my machine, and downloading an older version from my repo onto my machine from before I started having the issues. Nothing fixes the issue.

FIXED:

I removed the SteamVR 2.2.0 plugin and imported 1.2.3 and it magically started working again, interaction and visible controllers. Now I will write my own mapping to get the menu to appear (which isn't hard for me to do). My trust with Valve's 'recommendation' is shattered.

JustinAtSama commented 5 years ago

I am experiencing the same issue. Does Valve any idea as to what is causing this issue? We can all probably help out if we had some pointers. Also which SteamVR version is considered stable?

apiotuch commented 5 years ago

1.2.3 seems stable, you sacrifice many of the new features, but if the new features don't work, no sense in holding onto them. I look forward to a stable release, but right now 2.2.0 is not it. I was able to easily decouple the actions from the controllers in Unity, but in a different (stable) way within Unity. I can turn the controllers on and off, and actions still trigger correctly. It isn't perfect but it works. 2.2.0 makes all VR projects permanently break (whether in editor or actual games launched through steam) which is just unacceptable, especially since there is no known cause, difficult to troubleshoot since no errors even show up in the console, and inconsistent; but once it happens it is devastating. After looking into it more, Khronos Group is still not finished with updating the OpenXR standard, sitting at 0.90 release. And just with what I briefly had a chance to use with SteamVR 2.2.0, I am concerned as to why many of the configuration within Unity is minimized and advanced features redirected out of Unity. It just seem over convoluted and unnecessary, since Unity has built in solution such as profiles or even ScriptableObjects. Maybe if I understood the motivation behind some of the design decisions, I wouldn't have to presume the dev team just doesn't want to integrate this plugin into Unity all that well. Does anyone know when a stable release will come out?

zite commented 5 years ago

Sorry to hear people are having issues with this, I wasn't watching it as it previously sounded like a mac only issue so I labeled it as such.

The tutorial you link tells you to delete the Pose action which is how steamvr input tracks controllers and updates their orientation. If you delete that then controller updates will not work. I recommend following the official documentation and tutorials here: https://valvesoftware.github.io/steamvr_unity_plugin/tutorials/SteamVR-Input.html

If you rename the default action set you may break links to existing actions. You'll need to check through to make sure actions are still getting assigned properly.

Skeleton Actions are specifically for hands, and not for controllers. Controllers are displayed and updated using the SteamVR_RenderModel component. If you don't add that to your rig they will not show up.

Are any of you getting errors?

chilton commented 5 years ago

As I stated, this is a Mac and Windows issue, and I tested on the beta and shipping versions of the products. Nothing was out of date.

chilton commented 5 years ago

And this has been a showstopper for a few weeks. It works fine in the editor, and fails on the app builds.

I'm actually dealing with it again today. If I figure out what is happening, I'll report back.

smashriot commented 5 years ago

As another data point here, just ran into an issue where controllers stopped showing up in builds. The culprit was Managed Stripping Level set to Med/High.

Stripping set to Disabled/Low works with Mono/IL2CPP with .Net 4.x Stripping set to Med/High does NOT show controllers with Mono/IL2CPP with .Net 4.x

Haven't had a chance to dig into it further, but reverting stripping to Low resolved my controllers not showing in build issue today (MacOS export)

Oyshoboy commented 5 years ago

Same issue here, hands just not showing up, everything is clear in console.

SteamVR re-importing not working, exactly as @brianbatista wrote. When Starting completely new project - everything is working fine.

Also I spotted strange behavior when pressing "play" button. After game is launched, SteamVR menu appearing automatically:

JustinAtSama commented 5 years ago

Good to see people trying to solve this. Since my first post here, i switched over to version 1 and never looked back.

Get Outlook for Androidhttps://aka.ms/ghei36


From: Helg Broforsky notifications@github.com Sent: Monday, May 6, 2019 11:11:54 AM To: ValveSoftware/steamvr_unity_plugin Cc: Justin Buzon; Comment Subject: Re: [ValveSoftware/steamvr_unity_plugin] HTC Vive Controllers not showing in scene (#323)

Same issue here, hands just not showing up, everything is clear in console: [https://camo.githubusercontent.com/42492b46a1c07876a3ccda92303fe7c638c71206/68747470733a2f2f692e696d6775722e636f6d2f39774468474c522e706e67]https://camo.githubusercontent.com/42492b46a1c07876a3ccda92303fe7c638c71206/68747470733a2f2f692e696d6775722e636f6d2f39774468474c522e706e67

— You are receiving this because you commented. Reply to this email directly, view it on GitHubhttps://github.com/ValveSoftware/steamvr_unity_plugin/issues/323#issuecomment-489719357, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ALKXMGLHCTAHXCAO74QYTNTPUBYGVANCNFSM4GXNAPJA.

Oyshoboy commented 5 years ago

Found fix!

So the problem is that input somehow disabling, or crashing, so you need to refresh it! Here are steps which helped me:

1) Window => SteamVR Input 2) Click "Open binding UI" 3) Select your action set 4) Press "Edit this bindings" 5) Then check if everything setted up properly, and if so, just press "Save Personal Binding" 6) Go back to SteamVR input in unity 7) click "Save and generate"

Hope it's helps somebody 😺

ericvanderwal commented 5 years ago

Using master, with unity 2018.4 LTR, also no controllers in scene and no tracking. Tried for several days with no luck. None of the solutions here seem to work. Only is an issue when making my own action set. Default does appear. Any other custom action sets to do not. No errors. Cleared and deleted everyone, reimported steam, started from scratch, but same result. Looks like this issue has been open for months however.

A-Ivan commented 5 years ago

I had been having issues for the past weeks with not being able to visualize my VR controllers in my Unity scenes and not being able to obtain pose information from the controllers. Strangely the input from the buttons were working and whenever I went to the SteamVR Menu system the controllers appeared and then disappeared when the menu was closed and I returned to Unity.

I tried going back to an older commit, updating Unity (updated to 2019.1.11, originally on 2019.1.7), updating Steam VR Plugin (updated to 2.3.2, originally on 2.2.0), but nothing fixed the issue.

I'm on a Windows 10 Computer.

My solution: I followed instructions from @smashriot JSON comments (on this page)

  1. Move/Replace SteamVR Input JSON files (Assets\SteamVR\Input\ExampleJSON) to the root (Unity Project Root not Assets Root).
  2. Unity Menu -> Window -> SteamVR Input
  3. Save and Generate
  4. Restart Unity Scene

I also created a new actionset to be safe, the problem might have been from me editing the default one.

Below is the original comment:

For a standalone MacOS build, Unity copies json files to the same folder as the .app.

When running AppName.app, the Unity Player.log shows: [SteamVR] Could not find actions file at: /Users/username/Desktop/Builds/AppName.app/actions.json

To fix, the json files need to be moved inside the root folder of the AppName.app package (right click and Show Package Contents).

StakFallT commented 4 years ago

Sorry to hear people are having issues with this, I wasn't watching it as it previously sounded like a mac only issue so I labeled it as such.

The tutorial you link tells you to delete the Pose action which is how steamvr input tracks controllers and updates their orientation. If you delete that then controller updates will not work. I recommend following the official documentation and tutorials here: https://valvesoftware.github.io/steamvr_unity_plugin/tutorials/SteamVR-Input.html

If you rename the default action set you may break links to existing actions. You'll need to check through to make sure actions are still getting assigned properly.

Skeleton Actions are specifically for hands, and not for controllers. Controllers are displayed and updated using the SteamVR_RenderModel component. If you don't add that to your rig they will not show up.

Are any of you getting errors?

THIS!!!^^^ I too followed that damn tutorial...

Zite, you hit the nail on the head with the Pose thing. The fix was stupidly simple. At least for me. I had the same problem as a few others did in which smashriot's workaround, unfortunately, didn't work. For me, everything snapped right up and started working soon as I did what I did. So, starting from the Unity editor with no SteamVR Input tab showing here's what I did in step-by-step fashion (I've bolded the keywords of the steps as a means of providing a shortcut to the reading):

(Skip to step 5 if you already know how to get to the Controller Binding screen from within Unity -- if my fix doesn't work for you, try it again but start at 1 instead. If that doesn't fix it, then you probably have a slightly different issue causing the same problem -- sorry! :( )

  1. Navigate to menu bar and click Window
  2. From the drop-down menu, click on the entry that says SteamVR Input
  3. Near the bottom right of the new modal dialog box that popped up, there should be a button that says "Open binding UI", click that button.

(Initially when I had the problem, I didn't have anything listed under Current Binding, but I eventually got that corrected -- this step-by-step assumes your have something showing there)

  1. Under Current Binding, there should be a lighter blue content-box with a binding-profile icon, the name of the binding, a button labeled Edit, and maybe even some information that the binding was created by you, when it was last updated, etc. Click the Edit button.

Here is the meat and potatoes of the fix I figured out (using information Zite posted about what "pose" is all about -- thanks Zite! :) )

  1. Under the controllers, you should see 4 buttons (on my screen it's four. It may vary?). You are looking for the button that says "Edit Action Poses". Click the button that says "Edit Action Poses".

  2. A new box will pop up listing the Poses. They probably all say "Unused" (as they did in my case). Click on the text that says Unused on the line that reads "Left Hand Raw".

  3. Like the previous bindings you set for things like the Grip button, Trigger, Trackpad, etc., a new popup will appear (after clicking the text that reads "Unused" for the proper line). This popup should list Pose and Unused. Click on Pose.

  4. Left Hand Raw should now have the text "Pose" next to it on the same line. Click Close.

  5. At the very bottom of the screen, you will see six buttons. Click on the button that says "Save Personal Binding"

  6. A new popup box will appear asking for the name and description. Fill in the data (if you feel the need to modify any of the existing information), and click the Save button.

  7. You should briefly say the word "Uploading" appear just to the upper left of the left controller in the Controller Binding screen. Wait for that to finish.

  8. Close the Controller Binding screen.

  9. Re-play your Unity project. You should now see your controller appear! You may have to do the pose modification for the right controller too if you did not have the checkbox (under the controllers in the Controller Binding screen) labeled Mirror Mode checked on. But that should fix the problem. Shouldn't be any need to move files or copy anything anywhere, unless you have a situation preventing you from doing what I detailed out.

KyleStrader commented 4 years ago

@StakFallT Your answer worked for me. I suggest everyone with this issue, and a custom binding scheme give this answer a whirl.

VirtualLearningLab commented 4 years ago

Here is another potential simple fix, go check the binding UI like "StakFallT" describes (OPS! If you can't access the site, change the port in the url from) http://localhost:8998/ to http://localhost:27062/). In the binding UI, you can find your bindings, if the one you created can't be found under current binding, but right underneath it (under the "create new binding" button), with the option of viewing or activating it, activate it and it should resolve it. Stupid little fix, not sure why it happened, but atleast it works now :D

seanweiss91 commented 4 years ago

@StakFallT Thank you so much for this detailed solution, worked for me as well!

TyxDev commented 3 years ago

I had the problem as well when my controllers didn't track in Editor but worked well in build. I finally resolved it simply by clicking "Save and generate" in Window/SteamVR Input, I did, in fact , modified the input a little bit before the problem occured, might be related then. Hope this could help if someone still have the problem

StakFallT commented 3 years ago

@KyleStrader & @seanweiss91

My pleasure (seriously)! I can't stand and HATE when people reply to a thread somewhere on the internet and say the solved the problem they detailed out and go through the effort to even come back to their thread and say they solved it but don't detail out what they did and then you stumble upon the same thread due to having the same issue and low and behold it's like a sick joke someone's playing on ya lol

zite commented 3 years ago

It sounds like this issue is either fixed or a mac thing, I'm going to close this. If there's still an issue buried here please create a new post for it.