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 Katori · Sep 21, 2016 at 03:15 PM · iosframerate

Getting to 60fps on iOS

Hi all,

I'm building a pretty simple app with a couple of GameObjects and a few simple scripts. When I built to iOS, I expected the frame-rate to be 60fps solid as I've only spent a couple hours on the project and only have a couple of objects and scripts. But I got 30fps. I saw the trick about setting the Application's targetFrameRate, so I did that. Still 30.

So I did a test. I made a blank scene with just a camera and my FPS counter UI, and the targetFrameRate script. Still 30, with no GameObjects besides the camera and UI (with one text element) and no script besides setting the targetFrameRate.

So what's going on? How can I achieve 60? I'm using Unity 5.3.5, btw. Thanks for your time.

Comment
Add comment · Show 2
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 Landern · Sep 21, 2016 at 03:27 PM 0
Share

Have you set vsync in the quality settings?

avatar image Bunny83 · Sep 21, 2016 at 05:21 PM 1
Share

Well, iOS always has vsync enabled and uses a strict one. As soon as your frame time is greater than 16.6666 ms you will drop to 30 fps (the next smaller stable vsync rate --> 33.333 ms).

So depending on your actual hardware you mght have too many drawcalls or you use too heavy shaders (Unity's standard shader for example).

Some hardware also have other restrictions which might limit the framerate to 30 fps. How do you count your FPS? Do you use a skybox or do you just clear the background?

1 Reply

· Add your reply
  • Sort: 
avatar image
1

Answer by tanoshimi · Sep 21, 2016 at 05:26 PM

From your description, it sounds like you're using the default procedural skybox on your camera, which is a per-pixel shader. If you're running a mid-range iPhone, just filling every pixel on the screen with that shader could be enough to exceed 16.6ms frametime, forcing you down to 30FPS.

Try setting the camera clear flag to a solid colour instead - does that work? If not, are you sure your target frame rate script is being executed?

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 Katori · Sep 21, 2016 at 08:16 PM 0
Share

I should mention two things that I neglected to mention: I'm testing on an iPhone 6S Plus on iOS 10, and I installed a simple skybox texture using the "$$anonymous$$obile/Skybox" shader since I had already heard about the skybox issue.

I'll re-build the project with no skybox and a test to make sure the script fired, and get back. Thanks for the response.

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

68 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 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 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

Is iOS hardware always locked at 60hz? 1 Answer

iOS VSync always active? 1 Answer

Create 'Tippex' for a drawn line. 1 Answer

Why does VR on Android run noticeably slower? 0 Answers

Drag Rigidbody Script lags on IOS device? 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