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 jaysbays · Jul 24, 2016 at 10:41 PM · errorshaderiosmaterialdrawing

Errors with shaders/materials on newer iOS devices

Hey there, I'm having a strange error drawing the ground object for my game on newer iOS devices

The ground in my game has a sand coloured material as well as shadows from other objects falling onto it. However, for some reason, half of it gets drawn white and no shadows are applied. (see image below)

It happens only on iPhones 5S and newer. It does not happen on Android. Since it only happens on devices running Metal Graphics I figured it had something to do with that. I deleted Metal from the Auto Graphics API list in the Player Settings. It is now using OpenGLES 3.0 then 2.0 as the graphics API but it is still occurring (I will try removing 3.0 and just use 2.0 and see if the error persists).

Just wondering if there is anyone else who has gotten this error and if they have figured a way to fix it?

alt error-image

alt shader

Comment
Add comment · Show 7
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 jaysbays · Jul 24, 2016 at 11:44 PM 0
Share

Okay so I have tested the project and confirmed that this error does not occur with Open GL ES 2.0. Only 3.0 and $$anonymous$$etal.

avatar image tanoshimi · Jul 25, 2016 at 06:26 AM 0
Share

The rest of the scene appears to have renderered ok, so is there anything different about the material assigned to that object?

avatar image jaysbays tanoshimi · Jul 25, 2016 at 06:39 AM 0
Share

Nothing that comes to $$anonymous$$d. Created it in the editor just like all the others. Also if you look closely, you can see that half of it gets rendered properly, but the other half is all white.

avatar image Naphier · Jul 25, 2016 at 08:38 AM 0
Share

What shader are you using?

avatar image jaysbays Naphier · Jul 25, 2016 at 04:24 PM 0
Share

Standard shader. I just edited my question to include a screenshot of the material on the game object not being rendered properly

avatar image Naphier jaysbays · Jul 25, 2016 at 04:50 PM 1
Share

Try $$anonymous$$obile diffuse. There's also a version of it out there with the ability to add color/tint without texture.

Show more comments

1 Reply

· Add your reply
  • Sort: 
avatar image
1
Best Answer

Answer by Naphier · Jul 26, 2016 at 02:12 AM

The answer is to use mobile diffuse shader on mobile devices. It's more guaranteed to work.

Follow up question: @jaysbays says:

This worked, thank you! Any idea why the shadows now slightly flicker (they look like they are wobbling back and forth) whenever the camera moves?

That's tough, sounds like the shadow quality. You would thin the shadows would be just fine onto mobile diffuse shaders, but maybe not. You could try deferred lighting. If your level is not generated you could bake the lights and likely have better results.

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 jaysbays · Jul 26, 2016 at 05:55 AM 0
Share

Thanks again! Switched to deferred rendering on iOS only (forward on Android) and the problem seems to be solved.

avatar image Naphier jaysbays · Jul 26, 2016 at 05:24 PM 1
Share

Glad deferred worked out. You should report the issue to Unity too, so they know it exists. Cheers!

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

4 People are following this question.

avatar image avatar image avatar image avatar image

Related Questions

Transparency working in the editor but not when I build 0 Answers

Vertex Fragment Shaders are BROKEN? 2 Answers

Efficient shader for sky plane 1 Answer

Error: Material doesnt have texture property. 1 Answer

See through issue in iOs 0 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