Chaos Corona Forum

Chaos Corona for 3ds Max => [Max] I need help! => Topic started by: CASA_MT on 2019-03-05, 10:09:08

Title: Corona 3.0 Displacement Artifacts
Post by: CASA_MT on 2019-03-05, 10:09:08
Hi Coronauts,

in our company we just upgraded to 3.0 (including Hotfix) for 3ds Max and ran into an issue regarding the new displacement.
I tried to find a solution in the forum, but did not find any.

We always use chamfered edges on our walls in order to make them more realistic.
When using displacement, these chamfered edges will become the typical distorted geometry known from older methods of displacement.
I attached some images to show what exactly I mean.
I do not recall this issue from any project we did with 2.0.
So far this problem occured in two seperate scenes with different kinds of geometry, so it might be safe to say that it is a general problem.
Is there a quick fix for this problem?
Title: Re: Corona 3.0 Displacement Artifacts
Post by: romullus on 2019-03-05, 10:13:38
Might be autobump. You can disable it in dev/debug settings and see if that helps.
Title: Re: Corona 3.0 Displacement Artifacts
Post by: CASA_MT on 2019-03-05, 11:14:45
Disableing AutoBump unfortunately does not do the trick, weirdly enough it was already disabled (although I did not alter any settings in dev/debug)...
Has nobody else come across this problem? Maybe for the most part it is not really visible when displacing large irregular surfaces like brick walls without a corner or uneven muddy terrain.
Title: Re: Corona 3.0 Displacement Artifacts
Post by: romullus on 2019-03-05, 11:38:51
Other thing that comes to my mind, is that your chamfered corners consists of extremelly elongated polygons. Maybe Corona subdivision algorithm doesn't like them. Could you try to add some extra horizontal lines to see if that helps.
Title: Re: Corona 3.0 Displacement Artifacts
Post by: CASA_MT on 2019-03-05, 13:32:09
I added some horizontal lines and the chamfered edges turn out a little bit better... Therfor another problem appears on the right flat side of the wall, which is really strange, as it does not seem to tesselate this simple geometry properly.
You can clearly see the new edges as artefacts in the displaced geometry, this has usually never been an issue before.
(I only attach the AO-pass, as the phenomenon is most prominent there).
Title: Re: Corona 3.0 Displacement Artifacts
Post by: maru on 2019-03-06, 19:13:27
Did it really render different in some older version of Corona?
I think it is related to the UVW mapping of this object. The texture is just stretched/squashed in that area. Is it any different if you render a diffuse texture or bump, without displacement?
Title: Re: Corona 3.0 Displacement Artifacts
Post by: romullus on 2019-03-06, 23:16:59
I don't think it's UVW mapping issue. I did some tests and it seems that chamfered areas are easy to solve with some subdivision, but then strange artifacts arise in previously good areas. Exactly like it's shown in #4 post in this topic. I don't recall that i saw something like that in earlier versions of Corona. It might be worth to perform some comparisons, but i don't have much time for that at the moment. The only solution that i found to deliver clean result, is to set displacement size to very low value and quadrify mesh with very low step size, but that's hardly practical.
Title: Re: Corona 3.0 Displacement Artifacts
Post by: CASA_MT on 2019-03-07, 10:29:29
The wall has a simple box-mapping applied, nothing fancy there.
In fact we had a case in which a wall with a relatively simple brick-texture applied to it(and chamfered edges) worked fine in 2.0 and had to be re-done in 3.0 - we deleted the chamfers and then it was ok (although I would consider this an unsatisfiying solution).
Unfortunately I cannot show these steps, as we did not save the image due to the corrupt geometry and currently we do not have the time to switch back to 2.0 to show exactly what I mean.
At that point we still considered it an isolated case.

I do agree with romullus, as an unnecessary subdivision might be an "ok-ish" solution, but seems redundant, especially as it worked fine before.

I attached the MAX-file of the wall including the textures, maybe you can have a look at it at some time.
Title: Re: Corona 3.0 Displacement Artifacts
Post by: benfattino on 2019-12-07, 00:17:40
Same problem when have chamfer and displacement. Max 2019 and corona 5. Any idea?
Title: Re: Corona 3.0 Displacement Artifacts
Post by: dj_buckley on 2019-12-07, 00:29:29
Seems pretty much the same as my issue here https://forum.corona-renderer.com/index.php?topic=26782.0

I believe the devs are looking into it, but as it stands, or as far as I'm concerned displacement, doesn't work properly on anything other than a flat plane with no subdivision - and even then I doubt if it's correct.

The solution I was giving was 'add more tessellation' which I'd agree with if we weren't told from the start that you don't need to subdivide your geo for displacement to work in Corona.

Not only that but as already mentioned in this thread and mine above - adding extra geometry isn't really a practical/useful solution.

So I'm going to go out on a limb here and say displacement, as it stands, is broke, unless it's just on a plane.  Even in their own news release for Corona 5 - one of the examples is just on a flat plane https://corona-renderer.com/blog/corona-renderer-5-for-3ds-max-released/ the other example looks like such a dense mesh anyway (or very evenly sized quads) it's hard to notice if there are any artifacts.