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 /
  • Help Room /
avatar image
0
Question by KokodokoGames · Aug 29, 2015 at 12:31 PM · guisceneguitexturescene-switching

GUI image displayed too large, why other scenes suddenly incredibly small?

This question is a bit similar to another question I have posted, but this is about the GUI system.

I have a Unity project with player resolution of 800x600. My background image is also 800x600.

Now I have created a game scene where I display the sprite at scale 1. This displays the image too small so I have to fiddle with the camera settings to try and fit the 800x600 image into the screen which is also 800x600 pixels. This seems very unwieldy to me, but apparently this is how Unity works?

The new problem comes from adding a GUI scene. This scene contains a GUI image, again at 800x600 resolution. This time, surprisingly, the image is displayed too large, and again I have to fiddle with settings to get a 800x600 image to display at 800x600 resolution.

My question: what am I missing here? I thought that the GUI system is always just 100% of its native resolution? It still seems to screw around with display sizes.

The other question is: when switching between the GUI scene and the regular game scene, the game scene is suddenly displayed VERY VERY tiny (about 10x10 pixels). I have to zoom in to about 1000% percent to even see the game scene.

This problem occurs as soon as I add a GUI scene to my project.

Is this a bug in Unity or should I update some settings somewhere?

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 KlausJoensuu · Aug 29, 2015 at 01:53 PM

It is because you're gui is make by pixels, try using screen.width and screen.height for the size. If too big then add a minus sign and a amount.

Comment
Add comment · Show 2 · 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 KokodokoGames · Aug 30, 2015 at 10:07 AM 0
Share

And where can I adjust the size of the GUI? The width and height settings are greyed out.

avatar image KlausJoensuu · Aug 30, 2015 at 11:15 AM 0
Share

You will half to use code. For size in code just use the screen.height and screen.width

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

28 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Store values between scenes 0 Answers

Script is detecting input with ZERO actions 0 Answers

How do i create a scene variable? 3 Answers

Main Menu Help 2 Answers

help to fix bug with using GUIUtility.RotateAroundPivot + GUI.DrawTexture 1 Answer


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