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

Bug HELP: Multi Monitor Setup failing on only one Machine

Discussion in 'Editor & General Support' started by Studiomaurer, Sep 6, 2023.

  1. Studiomaurer

    Studiomaurer

    Joined:
    Sep 5, 2012
    Posts:
    56
    So I made a Windows 11 Application for a three projector setup with Unity 2022.3.5. It worked fine.

    Now I implemented a small bugfix unrelated to the monitor setup and made a new Build, zipped it, sent it to the computer on site and started it there.
    It starts up on the left screen with the unity logo as expected (windows main screen).
    It initializes all three screens, but then will only show screen 2 (center) in the correct position correctly straightened by your system. The left and right screens are black, while the app is usable and doesn’t throw any errors.

    The previous build is running fine with all three projectors shown, so it shouldn’t be a hardware configuration problem of the machine on site. Nothing has been changed there.
    No settings have been changed when doing the build. The bugfix was a minor change in the logic of the Application. I exported using the very same unity editor.
    The new build runs correctly on my development computer with three screens connected.

    I cannot think of anything I might do to troubleshoot this.
    Could you give me any hint on what I might not have thought of which might trigger this behaviour? Any hint is highly appreciated.
     
  2. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    3,899
    Assuming you use source control, I would roll back to the changelist with which you made the previous build (the one that is working) and then build this version again.

    If this new build with the old code also works correctly, this would make it seem likely that one of the changes since that version must be causing the issue. You should then meticulously check each change in the source control changelists with a focus on script and settings changes.

    You should cherry-pick each change that you suspect may be causing the issue and implement this change in the old (working) version of the project that creates working builds, in hopes of finding that one change that breaks the build. If you end up re-implementing every change but the build continues to work ... :confused: well, I'd probably stop looking for the cause at this point and just consider it fixed. :)

    If this old-code new-build also fails to work, it may have to do with a change to the system the build was created on - unlikely but not unheard of. If the working build was created on a different machine, try making the build with the latest bugfixes on that machine too and see if that works.

    If you use any configuration files (or registry settings, or web requests, or ...) the app loads settings or data from, check those for changes too. The issue could be related to such config or settings the app creates on the target machine.
    For instance, perhaps the older working build only works because there was one setting manually changed by someone in order to make the app work with this particular three projector setup. But now the new build doesn't have that setting because it's stored per-instance (for whatever reason, perhaps some Player Settings changed where under AppData the settings are stored?) and you either forgot about making one particular config change or you are not aware that someone made such a change before to make the build work.

    You gotta love those issues. :D Stay calm, be analytical, take one step at a time. When you feel stuck, take a step back, consider all the possibilities where something might have changed, and eventually you'll find that terribly obvious or downright stupid thing that fixes it. ;)
     
  3. Studiomaurer

    Studiomaurer

    Joined:
    Sep 5, 2012
    Posts:
    56
    Thank you for your kind words. You are right, a build from a unchanged backup is also not working. It is kind of shocking to me that builds between two Win11 Computers with the exact same Unity Version are not deterministic. The computer in the exhibition has no direct internet connection. It is hard enough to push data on it, if I actually have to WORK on it, it means driving 200 miles. Will the Unity Editor ever become a reliable choice?
     
  4. CodeSmile

    CodeSmile

    Joined:
    Apr 10, 2014
    Posts:
    3,899
    There could not be anything more non-deterministic as two computers that run on two different operating systems:
    you and that other person. :p

    But usage and the installation of different tools and apps and changing config settings according to each user's preference aside: Just the hardware alone has some built-in or accidental issues with determinism!

    Surely you've heard of a batch of hardware-identical computers where one of them did not boot or exhibited difference in behaviour. Even the "same" hardware is different, it could be running a different firmware version or use identical chips but from different factories or one of the chips got "downgraded and rebranded" from a high-end to a lower-end model due to not meeting electrical specs.
     
  5. Studiomaurer

    Studiomaurer

    Joined:
    Sep 5, 2012
    Posts:
    56
    Yeah, but there is no other person. Project is identical (traveling with me on a ssd). How can it be that something as profoundly basic as displaying on three displays (I wouldn't even mind if the order was wrong) will not work. The screens obviously have been recognized, as screen 2 is displayed on display 2 as expected and the unity startup logo was on screen 1, as expected. Why would the cameras go black? Again, unchanged project, same settings, built on different PC.
    I would even expect differences in the execution of DOTS and stuff like that, but not in the core functionality of a build.