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 JBC · Jun 07, 2011 at 08:31 PM · surface shaderspecularemissivesurfaceshader

Specular vs. Emission in Surface Shader?

Reading through the examples for custom lighting in Surface Shaders, there is an o.Emission property that is used in the same manner of Specular. The usual definition for emission is that it 'emits'. When should emission be used opposed to specular?

(Is there some better docs for what the built-in values for Surface Shaders are? )

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

2 Replies

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

Answer by Paulius-Liekis · Jun 07, 2011 at 08:46 PM

As you said "Emission" emits light (i.e. object shines - it doesn't get darker if it's not lit by light). Specular just defines how much "specular part of light" should be used.

(these descriptions sound funny even to myself:))

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 JBC · Jun 07, 2011 at 08:59 PM 0
Share

That would explain its use in the cubic map example. The image gave a bit of a plastic wrap effect, but the real effect there is the lack of light source. Good to know. Thanks.

(Any other docs/links on this?)

avatar image
0

Answer by Wolfram · Jun 07, 2011 at 09:04 PM

"Specular" influences the intensity of viewer-dependent highlights caused by lightsources in your scene. The "spread"/sharpness of these highlights is influenced by "Shininess".

"Emission", on the other hand, is the "self-illumination" of the material, and therefore not influenced by any lightsources whatsoever. If you set Emission to Color.red, your object will be fully-red, anywhere, even in shadows/shades.

They are therefore quite different.

When to use:

Emission is used for glowing objects, illuminated buttons, etc.

We usually set "Emission" to white, if we have a textured plane in camera space which we use for (3D-)GUI elements. In fact, in this case we use a "VertexLit" shader, set "diffuse/main color" to black, and "specular" to black, and "emissive" color to Color.grey (=50% grey; 100% white will overshoot), which has the same effect, but the VertexLit-Shader is rudimentary OpenGL, and should be faster than an arbitrary complex Surface shader, not sure.

Setting the other colors to black and the emission color to "full" 50% will recreate the full texture colors/brightness, no matter where (or if) lightsources are in the scene.

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 DaveA · Jun 07, 2011 at 09:41 PM 0
Share

Another way to state Specular is that it's the 'shininess' of an object, so something like chalk wouldn't have much, but polished metal or glass would have a lot. Being in the same texture, it means you can mix it up, so your image of, say, a mud puddle can have not-so-shiny mud as well as pretty-shiny water in it.

avatar image JBC · Jun 07, 2011 at 10:30 PM 0
Share

The confusion lays in the fact that the Surface Shader example for Cube$$anonymous$$ap Reflection uses Emission ins$$anonymous$$d of Specular when the effect that is created is Specular looking. see: ../Documentation/Components/SL-SurfaceShaderExamples.html

avatar image Wolfram · Jun 14, 2011 at 12:34 PM 0
Share

@JBC: True, the problem ist that all lighting effects are already included within the Cube$$anonymous$$ap texture, so when applying the Cube$$anonymous$$ap, you don't want to add additional lighting effects, but ins$$anonymous$$d just display the Cube$$anonymous$$ap unaltered. And that is exactly what Emission does.

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

Shader error: too many "TEXCOORD" 1 Answer

How to not require normals in a surface shader 1 Answer

Using the Lightmap UV texcoords in a Unity 5 Surface Shader? 1 Answer

access to Lighting Pass in Surface Shader? 0 Answers

Access GameObject position and model position in surface shader? 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