Baked lightmaps not showing on mobile device (iPad/Android)

Hey guys,

I’ve been troubled with this problem for two days now (just so you know I didn’t just ran to this forum to cry out for help).
I’ve been trying to reproduce a simple baked scene, with one direct light, set to baked (no realtime), with hard shadows on, a plane, and a cube, both set to static, both with a standard shader.
In the lighting tab I’ve thrown away the skybox (for testing purposes), put the ambient intensity to 0, and left the rest of the settings at their default.
To be clear: in the editor view, everything looks fine.
With continuous baking on, the lightmaps seemed to update properly.
And in the lightmap tab, I can see the correct lightmap textures.
However, when building and testing on a mobile device, everything is black (note that ambient GI was 0).
Then I thought, maybe I do need to manually bake, press the bake button, and produce a lightmapsnapshot.
But that didn’t work either.
I was also confused by something I found in the lightmapping cookbook in the unity documentation (file://localhost/Applications/Unity/Unity.app/Contents/Documentation/en/Manual/GlobalIllumination.html)

  • Assign a Texture to the Emission slot in a material using the Standard shader.

This was one of the basic steps to getting lightmaps to work, but I don’t get it…

If I put the direct light to mixed, I think the realtime-diffuse part of the light is working, but I don’t see any shadows…

What am I doing wrong?

1 Like

Hi! The documentation that was shipped isn’t as up to date as the online version. Please have a look here Unity - Manual: Lighting

Lightmapping on Android and iPad should work - no need to assign emission texture :slight_smile:

Sounds like you did the correct thing already - light set to baked and Baked GI checked in the lighting window.

Same problem here!
Sorry but yesterday I open a new thread ( Unity 5 - Lightmapping Issues (Android 4.4.2) - Unity Engine - Unity Discussions ) not seeing this one…

I’ve just tested my scene on an iPhone 5 with iOs 8.2 and the result is the same as on my Samsung Galaxy Note 2 (first screenshot of my thread).

Those are my lighting options:

I’d be guessing that the culprit here is gles2.
Realtime GI is supported only on gles3

I thought the same but in my case that’s not Realtime, is it?
I’ve two directional lights (Baking: Mixed, but if I set them to Baked it’s the same), a Reflection Probe (Baked) and in the Lighting Options I checked Baked GI… isn’t that correct to have everything baked and no Realtime GI?
Did I miss some options or did I misunderstood something?

That’s correct.

I’ve just checked and indeed, something broke with gles2. Good catch, I’ll forward it to devs.

3 Likes

Thanks! Can you update us on this post with news?
I’m working on games on mobile (both Android and IOS) and I’d like to upgrade my projects to Unity5! Lightmapping is now the only thing that is preventing me to that…

Haha nice!
I’d given up on this :slight_smile:

I’ve made the case public, so you can track it’s status here

Thanks a lot!

We need to make more people aware of this.
Don’t you think it’s strange that nobody since the release of Unity 5 has complained about this?
Does this mean there aren’t any mobile-developers targeting low-end or semi-low-end devices that made the step to Unity 5 yet? Because I would assume they would still use lightbakes.
This is unbelievable! :slight_smile:

1 Like

and I thought I was an idiot…

I’ve been building with GL ES 2.0 as it runs faster than 3.0

at least it works on metal

Any news about it? Any can share a good settings to lightmap the project to use on Android?

Well, I find it works on android 4.0.3 fine (My tab hasn’t ever had an update out for it, so that’s why I am using it still! ;))

Any idea on when this will be fixed? - GL ES 2.0 required for GearVR competition which has a fast approaching deadline in 11 days!

@silenstack: Again, I don’t see the issue… :confused: They work on my end!
One thing I would check is if they work with other shaders that sample lightmaps. (E.g. legacy shaders)
Also, if you guys wish me to do so, I can post shader code here for testing. (Such code will be based on my current shader framework, of which works with lightmaps flawlessly! :))

Currently using the Standard Shader although I guess I loose all of its PBR wonderfulness during bake so may as well use legacy.

Will attempt a bake now and report back!

Hi,

We’ve isolated this issue into the automatic baking mode. As a temporary workaround, disable continuous baking, click bake manually and it should start working again.

Hope this helps.

–Mikko

Wait, I’m not using automatic baking - I’m only using manual bake and I get no lightmaps targeting ES 2.0. Have yet to test legacy shaders but will asap

Hm, that’s odd. The repro I have starts working if I disable automatic baking, and breaks again if I re-enable it. If you can get a repro that shows it broken in non-auto mode on GLES2 (and works on GLES3 or on desktop), please file a bug and PM the case number to me, I’d like to take a look.

So auto-baking’s the culprit? I will have to test this.