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 Paulius-Liekis · Dec 15, 2010 at 10:22 AM · shaderpipelinenormalmapfixed

Fixed pipeline normal mapping on iPhone

Is it posible to write fixed pipeline "reflective shader with normal map"? If so, how?

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
0
Best Answer

Answer by Aras · Jan 03, 2011 at 03:15 PM

You want a cubemap reflection perturbed by a normal map, per pixel? No, that's not really possible with fixed function.

And yeah, there's no performance difference between programmable & fixed function shaders, if you do the shaders right. The programmable GPUs these days do not have any fixed function stuff, so they just generate shaders behind the scenes. In Unity's OpenGL ES 2.0 implementation we do generate the shaders ourselves, since GLES2.0 does not have fixed function stuff at all.

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 skovacs1 · Dec 15, 2010 at 04:23 PM

For the programmable pipeline, check out the 4-th last shader (Example/WorldRefl Normalmap) here.

This should compile out to multiple passes in the compiled shader and I believe that would include the passes for fixed-function cards if applicable, no?

Comment
Add comment · Show 4 · 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 Paulius-Liekis · Dec 16, 2010 at 10:21 AM 0
Share

You might be right, although I'm not certain. $$anonymous$$y suspicion is that these shaders will do much more than I want: like include lights and so on. I just want to have base texture with environment reflection in some areas.

avatar image skovacs1 · Dec 16, 2010 at 05:55 PM 0
Share

It's fairly easy to write an unlit programmable shader that does what you ask. Could you elaborate on why it must be "fixed pipeline", if you don't $$anonymous$$d my asking?

avatar image Paulius-Liekis · Dec 17, 2010 at 08:26 AM 0
Share

it must be wrong belief that fixed pipeline is faster :)

avatar image skovacs1 · Dec 17, 2010 at 03:43 PM 0
Share

I cannot say that it is not faster at all, but there are reasons that there is a programmable pipeline and that shaders can run code - a fixed-function pipeline is very restrictive and harder to read and write. In general, while they may be marginally more performant, restricting yourself to fixed-functions is generally going to make your life much harder. Unfortunately for your question, that is beyond where I and most users here in UnityAnswers are willing to fight with it. If you want an unlit normal-mapped reflective programmable shader, I can help with that however.

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

No one has followed this question yet.

Related Questions

Mobile Bumped Diffuse problem 1 Answer

How Add NormalMap 0 Answers

Compiling HDRP/Lit shader takes 41 minutes, how can I reduce this? 1 Answer

Question about Unity's Shader Graphs and Low End Pipeline 0 Answers

Leaf displacement shader that works for LWRP doesn't work with HDRP and gives odd results. 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