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"

[Closed] Translucent vs. Translucent clipping

Hello there,

a couple of weeks ago I posted a thread from my UE3 UDN account at work, on the topic of clipping of translucent objects vs. other translucent objects. sadly the response was "UE3 handles depth sorting on a per-object basis" which pretty much meant "can't fix it". the problem mainly affects the case of translucent objects moving inside a (translucent) plane that represents water. pretty simple and quite a common case to have in a game, so we (team of mostly programmers) were kinda disappointed due to the fact that such a modern and widely used engine didn't handle such a basic and important functionality better

today I tried to reproduce the issue on our lovely Rocket and to my surprise, a top-notch next-gen engine like UE4 still handles depth sorting of translucent objects the old way: the object that's closer to the camera gets rendered first as a whole. so if you have two translucent objects clipping into eachother and move the camera around them you see a hard switch in their rendering.

alt text

could this be improved?

Product Version: Not Selected
Tags:
ue4trans.jpg (91.8 kB)
more ▼

asked Mar 11 '14 at 05:11 AM in Rendering

avatar image

ue4-archive ♦♦ STAFF
49.9k 3662 1989 9113

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

The question has been closed Oct 15 '14 at 08:09 PM by Tim Hobson for the following reason:

Archived Post generating comments/questions


2 answers: sort voted first

Order independent solution of translucency is a problem that has not yet been solved in an efficient way. There are a few potential solutions that either use randomness and introduce noise (stochastic translucency) or cost a lot of performance (per-pixel linked lists).

Early on in UE4's development we prototyped out some solutions. A variation on per-pixel linked lists was the best solution we had at the time and it cost about 6x more than per-object sorted translucency. So if enabled you'd have to reduce the number of pixels affected by translucency by a factor of 6 to fit in to the same budget. We decided the overhead was simply not worth it. We'd rather have a lot of FX and overdraw.

In addition to the performance concerns, UE4 is an engine meant to scale down to lower end PC and integrated graphics. Order independent translucency could only be supported on DX11 class hardware and even then only on platforms where you can afford the 6x penalty.

more ▼

answered Mar 11 '14 at 05:11 AM

avatar image

ue4-archive ♦♦ STAFF
49.9k 3662 1989 9113

avatar image ue4-archive ♦♦ STAFF Mar 11 '14 at 05:11 AM

fine, but maybe for PC we could have the decision up to ourselves? PC games with UE4 require a DX10 card anyway (DX11 recommended), so what about a SystemSetting that enables per-pixel translucency sorting?

Im curious about how other engines do it btw

avatar image ue4-archive ♦♦ STAFF Mar 11 '14 at 05:11 AM

I can't speak for other engines but we generally only implement and support features we intend to use ourselves. Every feature adds complexity to the code, the testing process and makes it more expensive to add other features we intend to use.

As I said, we have no plans to use the technique internally due to the performance cost and therefore have no plans to implement it for others. Sorry!

avatar image ue4-archive ♦♦ STAFF Mar 11 '14 at 05:11 AM

sorry to bring this back from the dead (didn't know if I should've started a new Question for this same topic)

recently a co-worker pointed me to this paper about AMD's solution for a problem that seems similar if not the same as this. the paper only explains the technique in a few lines but even it might be useful as-is, or I'm thinking maybe a big company like Epic could have contacts with AMD :)

anyway here's the link to the paper: http://www.ptc.com/WCMS/files/141236/en/Creo_OIT_white_paper_041112.pdf

avatar image ue4-archive ♦♦ STAFF Mar 11 '14 at 05:11 AM

That white paper describes the per-pixel linked list method. We experimented with that method and a few variations on it. Again, there is a heavy performance penalty to that method compared to traditional per-object sorting that most game engines use.

A new technique for order independent blending is interesting and may be something we experiment with in the future. The results are not pixel accurate like per-pixel linked lists but would be significantly faster!

http://jcgt.org/published/0002/02/09/

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

Hi! I have a question on kind of the same topic.

I'm developing a strategy game with the camera set to top down with the possibility to tilt it a little each way. When using a translucent material for grass it looks great, however where i have overlapping grass-meshes they pop in and out depending on the camera position, I guess the engine computes which mesh is nearest to the center of the camera and displays it in that order. I've messed around with settings to try to see if anything affect this problem, and the only thing I found was to set the field of view to 5 which did lower the popping significantly, however that makes the game perceived as more or less 2d. It doesn't really matter which grass mesh is seen as long as the engine sticks to displaying the same all the time.

My question: Is it possible to make the depth test of the grass meshes to a second camera which is orthographic, while still seeing through the normal camera as a work around of this issue for my game?

more ▼

answered Oct 14 '14 at 12:11 PM

avatar image

jorg1234
1 2 2

avatar image Tim Hobson ♦♦ STAFF Oct 15 '14 at 08:09 PM

Hi Jorg,

Can you post this as a new question. This is an archived post from our UE4 Beta that is no longer being tracked.

Thank you!

Tim

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

Follow this question

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

Answers to this question