ForwardAdd pass doesn't work on iOS

I took the standard shader, and stripped it down to just two passes (forwardbase and forwardadd) that simply return a color. Base returns 0.5, and add returns a light red.

In the unity editor this works, and objects appear pink. But on an actual iPhone the objects simply appear dull white, indicating that the forwardadd pass is ignored.

Am I missing something? Is there a build setting or something that needs to be configured? I can’t get my iPhone to include the forwardadd pass!!

You won’t always have a forward pass; it is just for adding additional pixels lights. Depending on your quality settings you may get 0 or several forward passes, and the default settings for iOS would be low enough to not need any. On mobile you definitely want to avoid reprocessing all your geometry and the entire screen more than once per frame if at all possible. The base pass should be able to handle a single pixel light (as well as baked lighting and maybe some vertex lights/SH) and that is usually all you’d want.

1 Like

You’re absolutely correct, I knew some about shaders but didn’t know about the quality settings. I also realized that my effect doesn’t actually need to interact with any lighting, so I removed the ForwardAdd Lightmode tag and just left my code as a pass without any tags. Now it works like a charm on my iphone, even on the ‘fastest’ quality setting preset.

Thank you very much for your help!