Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Dismiss Notice

Feature Request VR developer here, asking about hiding windows.

Discussion in 'VR' started by thaiwas, Jun 12, 2023.

  1. thaiwas

    thaiwas

    Joined:
    May 1, 2018
    Posts:
    8
    Hello! I have some unity software that would benefit if you could bring back 3D rendering of hidden content.
    It used to work fine, but then in some version, it cased a huge memory leak, but now, if I hide the window it just stops rendering completely.
    As you know, VR software doesn't need windows to function, and it is basically screen trash in my case.

    The function in question is

    [DllImport("user32.dll")]
    static extern bool ShowWindow(IntPtr hWnd, int nCmdShow);
     
  2. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Did you enable 'play in background ' or something similar in the player setting?
    Do you use 2021 or 2022 lts?

    Edit: do you mean the game application window after building, or unity windows?
     
  3. thaiwas

    thaiwas

    Joined:
    May 1, 2018
    Posts:
    8
    Yes, play in backgound is enabled, and it works, I have the unity window running on background, but if I try to move the window, the VR app freezes, and thats annoying. I used to hide the window but now I cant. And yes, I mean window after building.
     
  4. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Make a bug report for that so it can be fixed
     
  5. thaiwas

    thaiwas

    Joined:
    May 1, 2018
    Posts:
    8
    I have more pressing issues to talk to oculus customer service about, but sure, I¨ll mention it.
     
  6. DevDunk

    DevDunk

    Joined:
    Feb 13, 2020
    Posts:
    4,362
    Not oculus service. Make a bug report in unity (Help - Submit a bug report)
     
  7. thaiwas

    thaiwas

    Joined:
    May 1, 2018
    Posts:
    8
    Oh, ok.