Sketchfab Forum

First scene - shadow cookies on lights in Sketchfab?


(Rory Baxter) #1

This is my first game scene in Unity with the intention of exporting it to Sketchfab.

The scene has two point fill lights, a sky portal, and one main directional light with a cookie that casts shadows like light breaking through trees.

My main question is - can you use cookies on lights to cast shadows in Sketchfab or is this something I would need to bake in Unity? (I've read that lightmaps baked in Unity don't transfer to Sketchfab?)

The simple diorama of models were made in Blender then assembled in Unity. I did it this way because of a comment I read here by Glenotron on the creation of his pirate ship - "... lighting/baking in Unity (I prefer the tools), then saving out the .exr lightmap as a .png, so I can use it elsewhere".

The unity scene screen shots (below) show simple Unity materials on all objects (some unfinished) except the backdrop (and ceiling) which uses an 'Unlit' shader so that it doesn't recieve shadows from the trees.

All advice welcome. Thanks.


(Waleguene) #2

Hi @Rory.Baxter,

You will need to bake the lighting in Unity since the exporter doesn't handle any lighting feature for now.

For lightmap support, converting it from .exr to .png works but it's not guaranteed to work in all cases:

  • It will be ok if the lightmap UVs are predefined in the model
  • If they are generated by Unity, it will not work since Unity applies offset and scale factors on them and those are not exported.

I hope it helps,


Create lightmap UVs in Blender?
(Rory Baxter) #3

Yes, thanks, that really helps.

After reading your post again I deleted a question I had for you (which was asking whether Blender could give me what I needed).

So I will look into generating the lightmap UVs in Blender.

Thanks again Waleguene.