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"

Poor Quality Shadows

I am using a source code build of unreal engine 4.5 but this problem has been occurring though all versions for me.

NOTE : i am using real-time shadows with a skylight if that makes any difference and the objects have cast inset shadow enabled

EXTREMELY LOW QUALITY SHADOWS!!!

No matter how high the graphics settings are or how close i get the shadow quality is stupidly poor as iv'e pointed out in the picture below.

alt text

but on some other objects they seem to be reasonable?, bear in mind i'm using the same 3D modeling software (3ds max) and the same export/import methods?

The picture below is an example of good shadows.

alt text

Is there anyway to higher the quality of shadows no matter how pc-demanding it is. because this is the one problem that stands between cry-engine and unreal engine.

Product Version: Not Selected
Tags:
poor shadows.png (823.8 kB)
good shadows.png (1.0 MB)
more ▼

asked Oct 29 '14 at 12:17 PM in Rendering

avatar image

AndrewM47
277 68 61 81

avatar image EvilTak Oct 29 '14 at 03:26 PM

Is your house/building a static object? Static as in static selected instead of movable below the transform variables? If it is static then you will have to build the lighting to get accurate shadow results.

avatar image AndrewM47 Oct 29 '14 at 03:54 PM

As i said at the beginning "NOTE : i am using real-time shadows with a skylight if that makes any difference and the objects have cast inset shadow enabled"

avatar image Jacky Oct 29 '14 at 03:57 PM

If you are using dynamic lighting then check Settings > Engine Scalability Settings and make sure shadow quality is set to Epic.

avatar image AndrewM47 Oct 29 '14 at 04:00 PM

Where are these settings? i cant find them, are they in the editor or in the files?

avatar image AndrewM47 Oct 29 '14 at 04:01 PM

Oh yes i found them and everything was set to max (epic)

avatar image Jacky Oct 29 '14 at 04:05 PM

Ok, do this then:

Go to World Settings and find Force No Precomputed Lighting. Enable that and rebuild the lights, and make sure the light source is set to Movable and see how it looks now. Your shadows do look like baked shadows so i'm not sure how that happened if you didnt build the lights yourself. But turning off static lighting with the setting i mentioned should make sure you are using dynamic lights.

avatar image AndrewM47 Oct 29 '14 at 04:19 PM

They were already on all those settings.

avatar image AndrewM47 Oct 29 '14 at 08:38 PM

Yes, all those settings were already enabled, and they still looked like shit. That was my problem i was wondering if i could increase the default real-time resolution or something.

avatar image Jacky Oct 29 '14 at 03:45 PM

You need to increase the lightmap resolution for those meshes and the landscape. They may look ok on smaller meshes but you need more resolution for larger meshes.

avatar image AndrewM47 Oct 29 '14 at 03:57 PM

I am using Real-time shadows, so increasing the lightmap resolution does nothing.

avatar image Tim Hobson ♦♦ STAFF Oct 29 '14 at 04:10 PM

If you're using Dynamic lighting you'll want to adjust the shadow bias in the details panel for the directional light. There is a trade-off here though. Lowering the shadow bias will give you artifacts if too low.

If you need sharper shadows for your static objects you may want to take a look at Ray Traced Distance Field Soft Shadows.

Tim

avatar image AndrewM47 Oct 29 '14 at 04:18 PM

Yes, Surprisingly enough iv'e already done all of that and that was my result in the picture.

avatar image Jacky Oct 29 '14 at 04:22 PM

Can you post a screenshot of your directional light's properties?

avatar image AndrewM47 Oct 29 '14 at 05:13 PM

alt text

settings.png (52.2 kB)
avatar image Jacky Oct 29 '14 at 05:16 PM

You'll need to reduce Shadow Filter Sharpen value, and as a side note, you dont want Min Roughness to be 1 if you want proper reflections from that light source on reflective surfaces.

avatar image AndrewM47 Oct 29 '14 at 05:22 PM

This problem only really occurs on complex geometry none of the others so i honestly think its a bug in the unreal engine.

avatar image Jacky Oct 29 '14 at 05:25 PM

It is not a bug. Can you upload a sample project that replicates this issue please? Or some of the meshes that you see having this problem?

avatar image AndrewM47 Oct 29 '14 at 05:32 PM

I cant, its not worth the hassle of replicating and uploading and all that , i just thought if anybody else had this issue that they could give me a fix, its the model anyway not the project or lighting, its when i import the model for some reason it down grades the lighting quality for that particular model but when i import a different model that's got less complicated geometry, it has much much better shadow quality.

avatar image AndrewM47 Oct 29 '14 at 05:16 PM

Like i said its fine with small objects but not with buildings

avatar image AndrewHurley Oct 29 '14 at 07:08 PM

Hello 2147,

As Jacky mentioned, this is not a bug but just an improper set up of your scene. The good part is that there is a lot of great documentation on how to resolve your issue, as well as a lot of things to try clean up your shadows. To get you started in the right direction take a look at this documentation on Lightmaps. It addresses the issue you are having as well as gives you an overall explanation how lightmaps function.

http://worldofleveldesign.com/categories/udk/udk-lightmaps-01-basics-and-important-principles-for-creating-using-lightmaps.php

Although this does reference UDK, the basic principles remain the same

avatar image AndrewM47 Oct 29 '14 at 07:48 PM

I don't think you understand my problem, as iv'e said "NOTE : i am using real-time shadows with a skylight if that makes any difference and the objects have cast inset shadow enabled" its real-time shadows not baked.

avatar image AndrewHurley Oct 30 '14 at 09:08 PM

The image posted of your directional light has the shadow bias set to 0.08. Was this the case when you posted the picture of your mesh?

avatar image AndrewM47 Oct 30 '14 at 09:52 PM

Yes it was.

avatar image AndrewHurley Oct 31 '14 at 01:23 PM

Ok, would you mind increasing this value and letting me know your results?

avatar image AndrewM47 Oct 31 '14 at 02:06 PM

Increasing the bias?

avatar image AndrewM47 Oct 31 '14 at 02:10 PM

Well i set the bias to zero and its still looks the same, but the actual shadow resolution is low and always stays low no matter what i do?

avatar image AndrewHurley Oct 31 '14 at 02:13 PM

set the bias to like 0.8 and increase the shadow filter sharpening.

avatar image AndrewM47 Oct 31 '14 at 07:33 PM

That didn't change much, but my problem is low resolution shadows on that particular model. But on other models it has high resolution shadows.

but i used the same scale size and the same import/export settings.

avatar image Jacky Oct 31 '14 at 07:41 PM

There isn't much we can do anymore unless you share a sample project or the model itself.

avatar image AndrewM47 Oct 31 '14 at 08:05 PM

Ok, so something weird just happened. As i took a small chunk out of the model to send to you and imported it to UE4 to test it, the shadow resolution was fine? I'm going to mess around with it some more but as of yet it appears that simple geometry like a wall/window is fine but anything indoors is not? Well that's what happens on my build anyway.

avatar image AndrewM47 Oct 31 '14 at 09:08 PM

False alarm, Unless i import my model 30 polys at a time i'm not going to change these shadows. So after all it is a bug with unreal's import model interpretation method. I could fix this if we had the ability to edit Cast Inset Shadow's LOD and LOD distance factor, but we cant unless we go into the source code. >:(

PS , if unreal staff see this, please let us have the ability to turn OFF lod on cast inset shadows for character models etc

avatar image Jacky Oct 31 '14 at 09:16 PM

Again, no, this is not a bug. This is a problem with that mesh. I can import and have perfect dynamic shadows(inset or not) with more complex, hundreds of thousands of polygon models, and other people dont have issues either unless it has something to do with the way their mesh is created. And again, Unreal staff can't help you on this if you dont share something that replicates this issue.

avatar image AndrewM47 Oct 31 '14 at 09:28 PM

Well is was suggesting to unreal staff to give people more control over shadows in cast inset shadows, but this is a problem that is happening with more than just that mesh and no matter how much i chop and change the mesh the problem still stays, and its not the way its made because iv'e made other models the same way and size that don't have this issue, so i can only assume its a bug when it happens to certain models for no obvious reason. Even when i delete 1 poly at a time and reimport the mesh to find what poly is causing the problem it does nothing it still has low quality shadows

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

1 answer: sort voted first

Hello 2147,

I have set up a scene that uses fully dynamic shadows with Ray Traced Shadows enabled to help you better understand how to adjust your shadows and possibly why you are seeing artifacts.

Steps to follow:

  1. In your project settings within the "Engine" section, click on "Rendering."

  2. Check the box that says "Generate Mesh Distance Fields"

  3. After enabling this option, Save and Restart the Editor for the changes to be made.

  4. Now within your "Directional Light" under the "Distance Field Shadows" check the box that says "Use RayTraced DistanceField Shadows."

  5. The two settings within that same section will increase your shadows quality by either softening them, or the reverse.

  6. Increasing the "Light Source Angle" will increase your shadow soften.

  7. Another section that gives you more control over your shadows with "Ray Traced Shadows" enabled is "Cascaded Shadow Maps."

  8. There is one setting that could help resolve your issue within here, it is called "Cascade Distribution Exponent." What this does: "Controls whether the cascades are distributed closer to the camera (larger exponent) or further from the camera (smaller exponent). An exponent of 1 means that cascade transitions will happen at a distance proportional to their resolution"

There is one checkbox within the same section that also pertains to the inset shadows you mentioned.

Use the images posted as reference to set-up your scene. All of these settings are specific to your own level and scene so try changing the values and observing the differences in shadows and and their softening/sharpness.

Enabling the "Distance Field Shadows"

alt text

Directional Light Moveable Settings

alt text

Here is some great documentation on improving your shadows using dynamic lights with raytraced shadows enabled as well as ambient occlusion. Keep in mind this is a fairly new technique for lighting and shadowing and is not perfected, so you will have to tweak things to get them the way you would like to look.

Ray Traced Shadows: https://docs.unrealengine.com/latest/INT/Engine/Rendering/LightingAndShadows/RayTracedDistanceFieldShadowing/index.html

Distance Ambient Occlusion: https://docs.unrealengine.com/latest/INT/Engine/Rendering/LightingAndShadows/DistanceFieldAmbientOcclusion/index.html

Regards,

Andrew Hurley

more ▼

answered Nov 03 '14 at 07:45 PM

(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