Search Unity

Unity freezes when creating a new GestureRecognizer (5.5 and up)

Discussion in 'Editor & General Support' started by BorvanBeers, Apr 28, 2017.

  1. BorvanBeers

    BorvanBeers

    Joined:
    Jan 9, 2014
    Posts:
    11
    Recently I reinstalled windows 10 on my computer. After also reinstalling Unity I noticed my application freezing whenever I hit play.

    After some debugging I found out that creating a new GestureRecognizer was making Unity freeze. The play icon grays out and cpu usage drops to 0.0%. Unity will no longer respond to anything I do and I'm forced to kill it via task manager.

    Here's the code:

    Code (CSharp):
    1.  
    2. using System.Collections;
    3. using System.Collections.Generic;
    4. using UnityEngine;
    5. using UnityEngine.VR.WSA.Input;
    6.  
    7. public class gest : MonoBehaviour
    8. {
    9.     GestureRecognizer g;
    10.  
    11.     // Use this for initialization
    12.     void Start () {
    13.  
    14.         g = new GestureRecognizer();
    15.  
    16.     }
    17.    
    18.     // Update is called once per frame
    19.     void Update () {
    20.        
    21.     }
    22. }
    23.  
    Things I've tried to fix it from freezing:
    • Reboot Unity
    • Tried different versions of Unity
    • Rebooted windows
    • Adding .dll files from data folder of a working pc (same project, same installer, same everything and it doesn't freeze there)
    • Reimporting all assets..
    It seems like it's not Unity related but any help would be greatly appreciated.
     
  2. BorvanBeers

    BorvanBeers

    Joined:
    Jan 9, 2014
    Posts:
    11
    bump, need an answer for work...
     
  3. BorvanBeers

    BorvanBeers

    Joined:
    Jan 9, 2014
    Posts:
    11
  4. ujell

    ujell

    Joined:
    Apr 27, 2017
    Posts:
    2
    I'm having the exact same issue. For me, disabling related code for the editor and testing on the device is possible, but still really annoying. So far I tried Unity 5.5.3p2 and 5.6, neither worked. Unity log also has nothing related.

    Moreover in HoloToolkit-Unity repository, this problem first mentioned in January and didn't have a solution yet, so it doesn't seem promising...
     
  5. ujell

    ujell

    Joined:
    Apr 27, 2017
    Posts:
    2
    For the future reference; having a clean re-install (instead of build-in "reset my PC" feature) solved the problem for me.
     
  6. KarlosZafra

    KarlosZafra

    Joined:
    Sep 8, 2016
    Posts:
    18
    Installing Windows 10 SDK solved the problem for me. It would be nice if Unity detects the SDK is missing.
     
  7. Freaking-Pingo

    Freaking-Pingo

    Joined:
    Aug 1, 2012
    Posts:
    310
    Thank you @KarlosZafra, I think you partially helped me out of my problem.

    I struggled with this problem for two days and I finally got it working.
    - Installed all versions of the Windows 10 SDK (I don't believe its necesary to install them all but I became desperate)
    - I figured out I did not have Windows Developer settings enabled
    - My two previous steps didn't work until I restarted my computer

    An issue were created on Github which I contributed to:
    https://github.com/Microsoft/HoloToolkit-Unity/issues/710
     
    BorvanBeers likes this.
  8. BorvanBeers

    BorvanBeers

    Joined:
    Jan 9, 2014
    Posts:
    11
    Enabling Developer settings in windows fixed the issue. Thread may now be closed, thanks @Freaking-Pingo !
     
  9. Forrest-Trepte

    Forrest-Trepte

    Joined:
    Jan 22, 2013
    Posts:
    8
    Does anyone know if this has been reported to Unity as a bug? Enabling developer mode fixed this for me, but it would be nice for Unity to present instructions to the user instead of hanging.
     
  10. Forrest-Trepte

    Forrest-Trepte

    Joined:
    Jan 22, 2013
    Posts:
    8
    I created a minimum repro case and reported this via the Unity Bug Reporter.
     
  11. Forrest-Trepte

    Forrest-Trepte

    Joined:
    Jan 22, 2013
    Posts:
    8