x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Weird Lighting After Building Ligthing

Before I built lighting, it was quite good with temporary ligthing on the viewport. However, after I've built lighting, every road pieces on the spline meshes started to show different brightness. I tried building on preview, medium and high but result is same. I tried replacing my materials with the ones that are in starter content, but result is still same. How can I fix this? alt text

Product Version: UE 4.10
Tags:
ligthingproblem.jpg (433.1 kB)
more ▼

asked Feb 10 '16 at 11:45 PM in Rendering

avatar image

SalihBalkan
434 16 30 58

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

It looks like a light map issue. I would check to make sure the light maps are of at least 32 pixels. Also make sure that they have a decent light map UV layout (ie no overlapping UV's and all in the 0 to 1 space) and usually not in the same channel set up to use your textures.

If you are sure you have a good layout and the resolution is of adequate size, another thing you want to make sure of is that the asset is using the right UV channel that you want it to use for the light map and not your 0 channel.

The documentation has a good [article on the best practices for building light map uv's here:

https://docs.unrealengine.com/latest/INT/Engine/Content/Types/StaticMeshes/LightmapUnwrapping/index.html

If you need more specifics on how to do any of these checks let me know.

more ▼

answered Feb 11 '16 at 12:27 AM

avatar image

BackedUp20
206 2 65 11

avatar image SalihBalkan Feb 11 '16 at 01:18 AM

I set static lighting resolution to 16>32 and rebuilded lighting with preview mode. But result is worse. You can see it in the image below. Then, I noticed that some meshes UV sources was set to 0. I changed them into 1. It just didn't change anything. alt text Only some meshes are fixed by changing UV sources. But most of them got worse.

avatar image BackedUp20 Feb 11 '16 at 04:28 AM

That looks like you changed some meshes light map coordinate indexes to channels they didn't have.

So for each mesh, look to see how many UV channels it has (upper left corner of the static mesh editor will tell you). If it is only 1, check the UV layout and make sure there are no overlapping UVs or UVs outside of the 0 to 1.

If there are 2 UV channels pick the one that follows the above criteria, channel 0 or channel 1.

If neither is the case, where you have only one UV channel and the UVs overlap or extend off the 0 to 1, you will have to make your own light map UVs for the mesh or try allowing Unreal to auto generate it for you.

avatar image SalihBalkan Feb 11 '16 at 02:54 PM

Now all of my UV channels are quite simple and absolutely true. I also tried adding lightmass importance to this space, I tried setting indirect lighting quality to 2 and indirect lighting smoothness to 0.6 then I rebuilt with Production mode, but result is just a little bit better than the first image. I can't publish this game with this kind of very bad lighting. I used to know that Unreal Engine's lighting system is very good, but looks like I was so wrong. If I can't fix this, I can consider moving my project to Unity, and now it looks like the only real solution is this.

avatar image BackedUp20 Feb 11 '16 at 03:22 PM

I know you are getting frustrated, but this is a fixable issue usually caused by incorrect light map UVs or a setting around that.

When you say your UV channels are simple and true what do you mean by that?

Here are the items that I'm asking you to check. If you could provide screenshots of your assets in the static mesh editor with the items in red showing we may be able to spot a problem.

Static Mesh Browser showing items mentioned

Or alternatively check "Generate Lightmap Uvs" in the import settings and click apply. That should make a quick light map for all the assets missing one that turned black.

avatar image SalihBalkan Feb 11 '16 at 04:57 PM

Hi BackedUp, I managed to fix the problem by myself.

  1. I created a component(I chose sphere, randomly) in the spline blueprint

  2. I set 'Light Attachments as Group' under the 'Lighting' tab of the new component

  3. I attached all spline meshes to this component in the construction script, using AttachTo function

  4. And good news here :)

alt text

However, I couldn't fix these problems:

  1. Some pedestrian crossings and bicycle crossings that are made with plane mesh with an opacity map appears dark. You can see this situation on the previous image.

  2. Gaps between spline meshes' shadows:

alt text

Here is the UV map of the road piece: alt text

fixedlighting.jpg (414.8 kB)
mesh.jpg (289.2 kB)
avatar image alonlei Aug 22 '16 at 08:00 AM

I have the same problem,Can you Share your script blueprint ?

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

I have the same problem,Can you Share your script blueprint ?

more ▼

answered Aug 22 '16 at 08:00 AM

avatar image

alonlei
1 1 2

avatar image SalihBalkan Aug 22 '16 at 03:36 PM

Hi alonlei, looks like the only real solution to this is cleaning up the built lighting data and rebuilding it. To do so, follow these steps:

  1. In the World Settings tab, check "Force no precomputed lighting"

  2. Click Build twice, til number of light maps becomes 0 in World Settings

  3. Uncheck Force no precomputed lighting

  4. Build lighting again

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question