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"

Glass transluency shadow vs Specularity

Hi everyone,

Sorry if the question has been answered already as I've been searching thoroughly through the hub and didn't find an answer.

I am trying to make some realistic glass over a pot shaped mesh. The problem I face is that I have to trade reflections for shadowing.

Here are exemples.

Detail option "Cast Volumetric Translucent Shadow" OFF :

alt text

Nice reflections but, of course, no shadow on the ground surface.

Now, just ticking the " Cast Volumetric Shadow" ON :

alt text

Nice Shadow indeed... But the reflection (specularity) has disappeared in the process. The windows are not reflecting on the material anymore.

I have tried numerous tweaks, but nothing helped. TLM is on, Surface is set to Translucent, but nothing seems to resolve the issue.

Thanks by advance.

Product Version: Not Selected
Tags:
translucent off.jpg (144.6 kB)
translucent on.jpg (122.8 kB)
more ▼

asked Jan 27 '15 at 09:28 PM in Rendering

avatar image

Guicot
71 2 5 6

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

1 answer: sort voted first

Hi Guicot,

There may be a solution for this in the future, but at the moment when you're using TLM_Volumetric_Directional, as you noticed this will give you shadows but you'll loose the reflective nature on the glass. It's best to use TLM_Surface for glass, but you'll loose the shadow information.

There are plans to improve this type of work with translucency as it's one of the more noticeable areas the engine could be improved. 4.8 will include some improvements in this direction that will be a start to this process.

I do, however, have a workaround to help for the moment though.

Here are the results of my work around:

alt text

I didn't up the lightmap resolution for the floor podium so that can be improved.

For my setup, I have two meshes.

  • Get your shadow casting mesh exactly where you want it and make sure everything bakes the way you would like.

  • Then create a copy that you can place back in that exact spot.

  • On the original shadow casting mesh you'll want to go into the details panel and uncheck the option "Render in Main Pass."

Once you've done this and build lighting you'll be able to have one mesh cast the volumetric translucent shadow and the other will be the visible mesh handling the reflections.

Give this a shot and let me know how it works out.

Thanks!

Tim

translucent.png (452.7 kB)
more ▼

answered Jan 28 '15 at 08:20 PM

avatar image

Tim Hobson ♦♦ STAFF
48.8k 888 103 878

avatar image Guicot Jan 28 '15 at 11:23 PM

Hey Tim,

Thanks for the advice ! It worked as soon as I unticked "render in main pass" on the first copy but the reflections vanished with building the scene... I tried and tried and it did not stand the lighting build. I updated the reflection captures in the meantime with no success.

This gave me an idea though, I checked back the "render in main pass" box and unchecked "cast volumetric translucent shadow" instead on the first instance and it worked as intended. However, the two objects were adding opacity to each other so I had to tune down transluency and put some more white color on my glass material to obtain something believable.

To sum it up, I now have two sames meshes on the same spot, original one showing reflections (Volumetric Translucent shadow off) and the other acting as a shadow caster. Here is what I came up with :

alt text

As you can see, the result is close to yours, but some of the triangulated geometry is now visible on the far left of the pot. I know for a fact that glass is the nightmare of all 3D artists, but a few improvements in this area would be a major step in Archviz on Unreal Engine.

This problem is resolved for me, unless you may have some more tricks to share ;)

Thanks again for your help.

avatar image Guicot Jan 31 '15 at 08:55 PM

Just a small update. I used the metallic channel and brought it to 1 to get better reflections. Added a normal map to simulate small imperfections. Pushed the color map to full white (to compensate the metallic nature of the material) and repostionned the reflection capture actor in the center of the pot. Here is the result :

alt text

I came with a more believable glass pot. Good news is, there is a lot to explore with current sytem to obtain clean results. Bad news : We still have to work with two instances and this is far from being a Physically based material.

However, I am quite pleased with the result. Still a long way to go, but I just can't say how I am excited with this new engine.

For better explanation, here is a glimpse of my set up :

alt text

glasspot_def.jpg (86.6 kB)
set up.jpg (98.2 kB)
avatar image Ikos Jan 31 '16 at 11:29 AM

Is this method still working with the 4.10/4.11 version? I'm trying to do the same thing but with "Volumetric Translucent Shadows" on the 2nd mesh it doesn't cast any shadow.

What can I do?

avatar image Tim Hobson ♦♦ STAFF Feb 01 '16 at 05:08 PM

You will also have to set the light to have Cast Volumetric Translucent Shadows enabled as well, IIRC. It's been a while since I last did a setup for this. Right at a year in fact.

avatar image Ikos Feb 01 '16 at 08:48 PM

I'm using the standard Light Source (stationary) and there is not such option.

Btw, is this the method I still need to use or we got some new features for the translucent shadows?

avatar image Guicot Feb 01 '16 at 10:35 PM

As the initiator of this conversation, I must say that I had to switch to traditional renderers for this project due to the complexity of this workaround. I would love to hear some news on that too as it prevented UE4 from being my weapon of choice. I still have to download the latest beta though...

avatar image Mardud Feb 13 '16 at 08:50 PM

Isn't the simpliest option for now tick Cast Shadow as Masked ? still better than no shadows right ?

avatar image Guicot Feb 13 '16 at 08:53 PM

I still have to try this, I don't remember this option to be available at the time. I'd love to see some feedback on this.

avatar image Tim Hobson ♦♦ STAFF Feb 18 '16 at 04:56 PM

Dynamic lighting

  • On your Movable light source, enable Cast Volumetric Translucent Shadow

  • On your Translucent object, enable Volumetric Translucent Shadow

This will allow a dynamic translucent shadow to be cast from the light source, but this only works with movable lights.

  • Note that 4.10 had an issue where the translucent shadow was not visible unless the mesh was selected in the editor. This has been fixed in 4.11.


Static Lighting:

This will bake automatically without any issue, but static lighting doesn't store specular highlights in the light bake.


Stationary Lighting

This can handle getting specular highlights, but there will not be a baked translucent shadow.


Some things you that can be done to improve lighting.

  • You can use the Surface Per-Pixel Lighting Mode in the material. Then use the the console command r.fowardlighting 1 to enable specular highlights on translucent materials. Note that this still does not store specular highlights in the lightmap with static lighting. Use this with stationary and movable lighting.

  • For reflections you can now enable Screen Space Reflections (SSR) in the material as well.

  • Use Specular value in the material. You can use a scalar value and an instance to see the difference in a scene.

The original notes above should still work regardless of the newer changes that have come in since for the forward lighting and ssr with transluceny.

avatar image aiadas Nov 23 '16 at 06:56 PM

Thx Tim. With Render in Main pass disabled and dummy objects, and if the shadows have a softbox feel to them then one can indeed simulate shadows from translucent materials with the technique described by Tim and acceptable results. Is there anything new with the newer versions like 4.14 regarding this subject?

The following screenshot is from 4.14 and Forward shading translucent materials.

alt text

bottles-ue4.jpg (256.1 kB)
(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