Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 12 Next capture
2021 2022 2023
1 capture
12 Jun 22 - 12 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by MacheteSurgeon · Feb 01, 2017 at 08:08 PM · fullscreenmultiple-monitors

Rendering a single fullscreen window across multiple monitors

Hello there Unity Answers! I'm currently working on a project here at work and could use some help. I'm attempting to render a single fullscreen window across multiple displays and after a bit of trial and error I stumbled upon an odd quirk which seems to have achieved just that.

I'm afraid I can't share my local project but below are the steps to reproduce this behavior.

  • Create a new empty Unity3D project

  • Create a new component and add somewhere in your scene. Make it run the following code during Start()

    Screen.SetResolution( SCREEN_WIDTH, SCREEN_HEIGHT, false ); Display.displays[0].Activate();

  • Replace SCREEN_WIDTH and SCREEN_HEIGHT with values as appropriate. Setting these values to something smaller than your target screen creates a borderless window centered in the middle of your display. Setting them to the same height, but a larger width will create a window which draws fullscreen and onto the next display. Setting the width equal to both displays and the height as your display's height results in a fullscreen window drawing across both displays.

  • Build and run, and admire your new fullscreen window

I've read through the documentation but haven't been able find anything which explains this behavior. Does anyone here know how this is working? It only seems to apply to the 0th display, as sending a different camera to the 3rd screen and calling Display.Activate() on it renders a fullscreen window which fills only that display instead of my provided window dimensions. Setting the screen dimensions from within Display.Activate() didn't have the same results either and attempts to duplicate this behavior onto a third and fourth monitor have so far proven unsuccessful.

I'm running on Windows and have tested this effect in both Unity 5.4 and Unity 5.5. This question has also been crossposted to the /r/Unity3D community and can be found here

Comment
Add comment
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

1 Reply

· Add your reply
  • Sort: 
avatar image
0

Answer by tanoshimi · Feb 01, 2017 at 08:37 PM

I'm not sure exactly what you want to know in terms of how it works, but I wrote a blog post a couple of years back describing how I created a game stretched across monitors: https://alastaira.wordpress.com/2015/05/15/creating-a-unity-game-stretched-over-two-monitors/

Comment
Add comment · Show 1 · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image MacheteSurgeon · Feb 01, 2017 at 08:52 PM 0
Share

Thanks for the reply @tanoshimi. Based on my testing I seem to have duplicated the functionality of the -popupwindow flag you mentioned in your blogpost without explicitly providing it to the game.

$$anonymous$$y final project must render to three displays with two of them sharing the same fullscreen window ( this is due to technical limitations and an NDA prevents me from discussing any further detail ) so rendering to a texture and then displaying across two windows isn't a feasible solution, and neither is combining displays in my video card. It'd also be good to know how this behavior is being triggered so I can be sure that future versions of Unity won't prevent me from using this "feature" and perhaps gain further control of this behavior along the way.

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

5 People are following this question.

avatar image avatar image avatar image avatar image avatar image

Related Questions

Borderless window in standalone player 5 Answers

Switch Monitor during Runtime 2 Answers

Fullscreen on a second (non primary) monitor 1 Answer

Fullscreen on non-primary monitor in OS X 0 Answers

using multiple monitors / video outputs? 5 Answers


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges