Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 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 Catlard · Oct 18, 2011 at 09:29 AM · shaderslighttexturestransparentdiffuse

Some textures not affected by light? (With screenshots)

So! I've got a bunch of different textures, and the shader I'm using is the same on all of them, pretty much (the transparent diffuse shader). They're all in the same layer, as well, for now. Anyway, some of them are reacting to light properly and are nice and bright; others are just doing this dark gray thing that I can't figure out. When I switch the textures to something else on the dark gray objects in the following two screenshots, they come up reacting to light, as normal...but I don't know why just these textures have issues. Any ideas?

Cheers

Screenshot 2:: Dark objects in the scene... Screenshot 2: Dark objects in gameplay...

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

5 Replies

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

Answer by CaseyW · Mar 04, 2014 at 09:19 AM

I know this is an old question, but this is one solution I found with dark planes.

The local vertical component must be non-zero, even though the plane has no height.

For example my plane was 12, 0, 12 in scale. And it wasn't lit properly.

Once I changed it to 12, 1, 12 it lit up accurately. I double checked and that was the issue for me each time.

Posting this for future visitors :)

Comment
Add comment · Show 3 · 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 Catlard · Mar 04, 2014 at 09:24 AM 0
Share

Agreed! Thanks for the answer.

avatar image salex100m · Jan 05, 2015 at 12:21 AM 0
Share

HOLY CRAP! I can't believe it was that simple a fix.... I have been battling this issue for a long time on and off.. thank you!

avatar image pointcache · Mar 08, 2016 at 04:21 AM 0
Share

Omg thank you. Just wow, $$anonymous$$A$$anonymous$$ES SENSE RIGHT?

avatar image
3

Answer by syclamoth · Oct 18, 2011 at 09:44 AM

Are your normals alright? They might be pointing the wrong direction- depending on the shader, this can have several (mostly bad) effects. Usually you just don't see anything (which is a much more obvious problem) but some shaders still draw the back-faces, but with diffuse lighting it'll look as if they are being lit from behind. Since there are no lights behind the objects, they will end up dark!

Try moving your lights to behind the objects, and see how it looks. If it makes a difference, then try rotating them around 180 degrees, or fixing it up in your 3d modelling package.

(I'm loving the visual style there, btw!)

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 Catlard · Oct 18, 2011 at 10:01 AM 0
Share

syclamoth! Thanks for your quick answer. Regrettably, I've tried rotating them around, but no dice. I've also tried transferring the textures to cubes, and one side is correct, but the others are dark. Confusing! So, perhaps it has something to do with the normals on my planes being weird. Originally I had them on unlit transparent shaders, and it looks fine that way--but for some reason diffuse ain't cuttin' it. If you'd like me to, I can send you the .png file of the image. Actually, these aren't 3d objects I made in a modeller--just planes. so they shouldn't have any crazy issues with normals, correct?

Hooray for visual style! I have a kick-butt artist, it's true. I wish I could take credit for it.

If you'd like to see what the game looks like when it's not sucking in this particular way, check out the dev blog, if you'd care to, at radicalClimber.Blogspot.com.

Thanks!

Simon

avatar image
1

Answer by Catlard · Oct 18, 2011 at 10:11 AM

I've fixed the problem, though I haven't located the original issue. I just re-created the objects with new planes, and now light bounces off of them correctly. Odd, eh?

Comment
Add comment · 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
1

Answer by Jonathan Bauer · Feb 20, 2013 at 05:02 AM

I had an issue where specific materials in my scene were appearing darker than they did normally. It happened without me working on these materials in any way, but I was modifying the textures and geometry in Maya, exporting as FBX, then modifying the prefabs. I deleted these problem materials and then reimported the FBXs, which automatically created these materials again, but they appeared at the correct light level again.

Comment
Add comment · 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
0

Answer by numandina · Jun 23, 2015 at 06:13 AM

I had an issue where some textures were not affected by light, I fixed it by using Diffuse shader instead of Mobile/Diffuse. This is for anyone out there experiencing an issue with lights.

Comment
Add comment · 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

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

8 People are following this question.

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

Related Questions

Legacy transparent cutout diffuse material ontop of toon lit material does not work anymore on android? 0 Answers

Shader Semi-Transparent to self, but masks what's behind it 1 Answer

a 'bar' or neon like light. 3 Answers

Shader with shadows that can change alpha channel 0 Answers

Why Shuriken "Color Over Lifetime" doesn't affect transparent materials? 2 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