Search Unity

  1. Megacity Metro Demo now available. Download now.
    Dismiss Notice
  2. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Black lines on OSX when set to Maximized Window

Discussion in 'macOS' started by fcloss, Mar 31, 2020.

  1. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Hi,

    These last weeks I've received some messages about users with problem with my app when running on FullScreenMode.MaximizedWindow. There are black lines blinking on screen. I know that Mac has many graphical issues, but the number of users affected has grown a lot lately.



    I am using Unity 2018.4LTS. Does anyone knows anything about it?

    Thanks
     
    Last edited: Mar 31, 2020
  2. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Anyone from Unity? I am getting a bunch of emails everyday with exactly same issue.
     
  3. andrews_unity

    andrews_unity

    Unity Technologies

    Joined:
    Dec 11, 2015
    Posts:
    264
    I am not aware of any known issue, but some information would be good what versions of macOS ? openGL or metal ? any specifics on the kinds of hardware this is happening on ?
     
  4. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Hi Andrews, thanks a lot for the answer. Sure I will inform you everything I can. I have asked all the users with the issue to inform us the model and version of OSX.

    Regarding the Build Settings, it is OpengGL Core and Mono. Default Screen Mode: Windowed. Mac Retina Support: Enabled. Allow Full Screen Switch: Enabled

    The app, on the first scene (splash scene) sets the resolution for the Window to 90% of the screen size. The app can be set on full screen window by clicking on the top bar or we have a setting menu option that sets it to FullScreenMode.MaximizedWindow and keeps the same resolution (90% of the screen).

    I will write here the models and OSXs as soon as the users reply to me.

    User #1: MacBook Air (13-inch, Early 2015 model) - macOS Catalina version 10.15.4
    User #2: MacBook Air (13-inch, 2017) - macOS Catalina
    User #3: MacBook Air (13-inch, 2017) - macOS Catalina 10.15.4
    User #4 : MacBook Air 13 inch - MacOS Catalina version 10.15.3
    User #5: MacBook Air - Version 10.15.4
    User #6: MacBook Air - Version 10.15.4

    So far it seems to be with the MacBook AIr.
    Update: Definitely MacBook Air. I really don't have a MacBook Air to reproduce it, but probably and hopefully you do.

    Thanks
     
    Last edited: Apr 3, 2020
  5. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Few more information about maximized window:

    When Unity sets to maximized (with the top bar switch), it maximizes the window but keeps the same resolution as the original window, (in my case 90% of the display), it does not set it to the display resolution. This wouldn't be a problem, but it has this issue I've posted before: https://forum.unity.com/threads/ful...log-nsopenpanel-is-shown.702215/#post-4862561

    Other small issue: if i disable the "Allow Full Screen Switch", Unity, as expected, disable the full screen switch. But, as I keep my own full screen switch on a menu, when the app goes full screen, Unity makes the full screen switch on the top bar enabled again and it will remain enabled if I press it to leave full screen.
    upload_2020-4-2_11-27-11.png
    (img 1, switch disabled, window mode)

    upload_2020-4-2_11-29-48.png
    (img 2, after set to full window, switch gets re-enabled)

    Having a callback when the full screen switch is triggered would be really nice too.

    Thanks
     
    Last edited: Apr 2, 2020
  6. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    @andrews_unity just checking if you had the chance to check the two replies above.

    Thanks agian.
     
  7. andrews_unity

    andrews_unity

    Unity Technologies

    Joined:
    Dec 11, 2015
    Posts:
    264
    I did see the replies, I am looking into the issue. I am wondering if you can run this under metal instead of openGL and it has the same behavior.
     
  8. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Thanks for the reply. I could not say as I don't have a Macbook Air to reproduce it.Sorry =Z
     
  9. andrews_unity

    andrews_unity

    Unity Technologies

    Joined:
    Dec 11, 2015
    Posts:
    264
    Can you file a bug and if possible attach the project ? I don't know how big the project is etc...
     
  10. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    I have filed the bug few days ago: case 1232814

    The project is huge, I can't attach it. I could create a small project with the same resolution setter at startup. But I wouldn't be able to test it.

    If it can help you somehow, the app can be downloaded free on Mac AppStore: https://apps.apple.com/us/app/tacticalpad/id946927077?mt=12
     
  11. andrews_unity

    andrews_unity

    Unity Technologies

    Joined:
    Dec 11, 2015
    Posts:
    264
    great I shall follow up on the case
     
  12. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    Andrews, I have prepared the project but I have no idea on how to attach a project to an existing case. Can you help me with that?

    I have also added on the project a button to reproduce another Mac resolution issue, which I had filed a case but at the time, I couldn't create a project to send you (case 1176827)
     
    Last edited: Apr 14, 2020
  13. andrews_unity

    andrews_unity

    Unity Technologies

    Joined:
    Dec 11, 2015
    Posts:
    264
    I will DM you a location you can upload the project too.
     
  14. CMDi-RC

    CMDi-RC

    Joined:
    Jan 25, 2019
    Posts:
    1
    Any update on this issue? We seem to be having the same problem (also confirmed Macbook Air).
     
  15. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    No updates from them. I've submitted a sample code (case 1232814), they replied that it was sent to the developers to fix.

    What I've found out is that Unity, when maximized, does not set the window resolution to the screen resolution. It also led to a issue with native dialogs when maximized (which my app needs).

    What I've done is that I have disabled Unity's full screen toggle and, on my menu full screen toggle, I also set the resolution to the screen (device) resolution, so it is really full screen not a scaled full screen as done by Unity. I haven't received any complaints since them.

    Hope it helps you somehow.

    BR
     
  16. BrandyStarbrite

    BrandyStarbrite

    Joined:
    Aug 4, 2013
    Posts:
    2,074
    @fcloss
    I'm curious, how did you solve this strange problem?
     
  17. fcloss

    fcloss

    Joined:
    Dec 1, 2011
    Posts:
    192
    I've never got an update from Unity. But I do all the resolution set manually, I believe it was caused by an inconsistence between the resolution of the Window and the OpenGL buffer, my guess. So I do not use google Full Screen switch anymore, I set the resolution myself and, when I use native dialogs, I refresh the resolution afterwards.

    I didn't receive any complaints from users after that, so I guess it worked for everyone.
     
    BrandyStarbrite likes this.