Author Topic: Round Edges Precise doesn't work with Front/Back  (Read 1277 times)

2023-02-01, 16:20:31

Tanner

  • Active Users
  • **
  • Posts: 64
    • View Profile
Hi all,

I recently modelled a waste receptacle with perforations in the metal skin. While I know its fake, to help with avoiding weird visual artifacts from two planes with perforations, I use the corona front/back node together with the bitmap in the opacity slot. It helps give the impression of a thick metal plate without seeing back holes (if that makes sense).

The issue I ran into, however, is that if I have a RoundEdges node in the base bump slot as well, the effect round edges effect doesn't happen when the RE is set to Precise-Same Mtl Only. If I set it to Fast, it works.

It's by no means a make-or-break situation but I was curious if the incompatibility with Precise Mode and Front/Back was by design.

2023-02-01, 17:11:05
Reply #1

TomG

  • Administrator
  • Active Users
  • *****
  • Posts: 5462
    • View Profile
Say hello to Corona Pattern, removing the need for faking it ;)
Tom Grimes | chaos-corona.com
Product Manager | contact us

2023-02-01, 17:33:20
Reply #2

Tanner

  • Active Users
  • **
  • Posts: 64
    • View Profile
Hi Tom - perhaps but there are still times where I prefer this method.

2023-02-02, 09:50:54
Reply #3

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 12754
  • Marcin
    • View Profile
Hi, which version of Corona are you using?

I tried reproducing this, but it seems to be working fine.
I have a box object with a Front Back map used as opacity. The maps are set in a way to produce circular holes on one side and square holes on the other side.
I have "same material only" option enabled in the Round Edges map, like in your screenshots.

If you are doing something else, can you please explain your full setup? Why exactly are you using the Front Back map?
Maybe you can share a simple scene?
Marcin Miodek | chaos-corona.com
3D Support Team Lead - Corona | contact us

2023-02-02, 10:22:57
Reply #4

romullus

  • Global Moderator
  • Active Users
  • ****
  • Posts: 8833
  • Let's move this topic, shall we?
    • View Profile
    • My Models
Not directly related to the issue raised in the topic, just a pro-tip - by plugging slightly blurred opacity map in to bump, or additional bump channel, you can dramatically improve material's appearance in your renders.
I'm not Corona Team member. Everything i say, is my personal opinion only.
My Models | My Videos | My Pictures

2023-02-02, 18:01:20
Reply #5

Tanner

  • Active Users
  • **
  • Posts: 64
    • View Profile
Maru:
I'm on Max 2020.3, Corona 9 Hf1. But my material setup is different. For one, I try to avoid gradient ramp whenever possible and so my opacity is controlled by a coronabitmap.  I failed to mention before that the bin's MatID 1 and 2 are controlled by the same physical material but with a coronamultimap controlling the opacity and bump for both materials (one obviously is solid, the other perforated). I've attached a simple copy of the scene with the texture map included. Maybe I got too cute with it and there's too much for the materials to coordinate round edges with.

Romullus:
I actually had the original bitmap slotted into a coronabumpconvert node and increased the blur because I agree, it helps with the realism but it didn't work and I didn't change that yet. However, I do have a duplicate texture I can use for creating that punched-through look of the holes and will be implementing that instead.

Both:
I also included two renderings from another project I did here in Toronto where a similar kind of material setup is used on ceiling baffles. The opacity is controlled by an AO node with the triplanar slotted into the unoccluded slot. A previous version of this had a frontback node in line as well but was removed for this version.  I included it in the shared scene. In regards to Tom's suggestion of CoronaPattern, I feel like this is a good use of textured perforations especially when every baffle is a different shape. I'm sure you can get the pattern to work here as well but the ease of a material won in favour.

2023-02-10, 17:08:13
Reply #6

Aram Avetisyan

  • Corona Team
  • Active Users
  • ****
  • Posts: 557
    • View Profile
Hi,

I have thoroughly tried to get exactly what you have, recreated my version from scratch.

Yes. If done exactly as you have done, which let me say is not "correct" or optimal, the effect of Round Edges gets lost.
The issue here is the use of FrontBack map, specifically having its back color set to Black. If you change black to pure white, you will see Round Edges with Precise mode working correctly.
Apparently Round Edges, especially with Precise mode and when used with FrontBack map, are sensitive to this color changes.

But the main issue here is the not optimal set up of model and/or material.
The box in attached scene has thickness, so there is no need to use FrontBack map. Moreover: if you use FrontBack map, any face which is seen from "behind" has the Back color and does not take into account the Front color otherwise seen from the other side.
I attach renders here to you can understand better.

This is not a bug clearly. You just complicated the material setup I think.
The solution in your case is to simply not use FrontBack map for Opacity, and everything should work fine.
You can find the simple scene I created attached as well.

Hope this helps.
« Last Edit: 2023-02-13, 10:10:58 by Aram Avetisyan »
Aram Avetisyan | chaos-corona.com
Chaos Corona Support Representative | contact us

2023-02-16, 11:41:13
Reply #7

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 12754
  • Marcin
    • View Profile
I do not fully understand what is going on here, and also why you are using the FrontBack map. But here is a workaround that is hopefully helpful: if you lower the opacity map's amount to 99.99, the rounded edges effect works correctly and it should not affect the appearance of the objects in any way.
Marcin Miodek | chaos-corona.com
3D Support Team Lead - Corona | contact us

2023-02-16, 13:54:30
Reply #8

Tanner

  • Active Users
  • **
  • Posts: 64
    • View Profile
My goal was just to have a backface culling effect in a rendering so that I wouldn't see basically two layers of overlapping perforations. I got it to work regardless, it was just a matter of bringing to attention the roundedges didn't appreciate front/back in the opacity slot and being set to precise.

But I appreciated all of the input on the workarounds.