Author Topic: CTexmap/CoronaAO Environment bug  (Read 7854 times)

2015-07-08, 11:30:01

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
Hi
I ran into a bug today while working with Corona AO.

When you render Corona AO using cTexmap the environment pixels are filled with a gradient.
(it looks like the one from the material preview). When you use this in combination with the Matteshadow shader you do not get a usefull alpha channel and cant clip out the garbage data.

It would be advantageous to be able to be able to set the environment to return pure white or black. (or just respect the max environment colour)



2015-07-08, 11:59:24
Reply #1

Icman

  • Users
  • *
  • Posts: 2
    • View Profile
If you are using Render Elements there is checkbox for Ignore background....

2015-07-08, 13:51:49
Reply #2

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
*facepalm*
thanks man that did it, you've made my day!

would still make sense to fix that bug. but atleast it's no long a show stopper

2015-07-08, 13:53:52
Reply #3

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 13741
  • Marcin
    • View Profile
It's not a bug if you can disable it. Someone may want to render background with an override.
Marcin Miodek | chaos-corona.com
3D Support Team Lead - Corona | contact us

2015-07-08, 13:58:59
Reply #4

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
The envionment settings are not reflected in this pass. the environment color for that scene is bright green..

the gradient is the material preview... it has nothing to do with scene content. Setting the corona environment or the max environment have no effect on this..

What possible use case is there for a box gradient in the middle of your render?

What am I missing here? Please atleast show me what your suggesting because I cant imagine a situation where a box graident contaminating your render is a good idea.

2015-07-08, 14:12:00
Reply #5

Ondra

  • Administrator
  • Active Users
  • *****
  • Posts: 9048
  • Turning coffee to features since 2009
    • View Profile
What am I missing here? Please atleast show me what your suggesting because I cant imagine a situation where a box graident contaminating your render is a good idea.

Its made this way so you get nice preview of the AO map in material editor. I will try to differentiate material editor from environment render.
Rendering is magic.How to get minidumps for crashed/frozen 3ds Max | Sorry for short replies, brief responses = more time to develop Corona ;)

2015-07-08, 14:22:58
Reply #6

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 13741
  • Marcin
    • View Profile
What am I missing here? Please atleast show me what your suggesting because I cant imagine a situation where a box graident contaminating your render is a good idea.
I did not mean rendering AO as ctexmap, but for example let's say checker map for some debugging purposes - you will apply it to all objects and also to environment. What you see as environment when using AO as ctexmap is simply the material preview. How do you imagine the AO map should look applied to the background? If you put CoronaFrontBack map into ctexmap, it will look wrong too. But what's the point of it? What would you expect instead?
Marcin Miodek | chaos-corona.com
3D Support Team Lead - Corona | contact us

2015-07-08, 15:05:25
Reply #7

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
Ondra:
Thanks, I appreciate that :)


Maru:
If there is no geometry I would expect to see nothing. But I take your point that it may be useful to be able to override the environment.
Ideally though if a shader relying on scene geometry is applied then it should not return any result as there is no geo to shade.
In all my time working in 3D i've never found a need to override the environment in a render element. Perhaps the default could be changed to save anyone else the confusion.
« Last Edit: 2015-07-08, 15:14:53 by rfletchr »

2015-07-08, 15:16:26
Reply #8

maru

  • Corona Team
  • Active Users
  • ****
  • Posts: 13741
  • Marcin
    • View Profile
Maru:
If there is no geometry I would expect to see nothing. But I take your point that it may be useful to be able to override the environment.
Ideally though if a shader relying on scene geometry is applied then it should not return any result as there is no geo to shade.
In all my time working in 3D i've never found a need to override the environment in a render element. Perhaps the default could be changed to save anyone else the confusion.
That is why you have that checkbox, but changing default does sound reasonable.
Marcin Miodek | chaos-corona.com
3D Support Team Lead - Corona | contact us

2015-07-08, 15:21:26
Reply #9

Ludvik Koutny

  • VIP
  • Active Users
  • ***
  • Posts: 2557
  • Just another user
    • View Profile
    • My Portfolio
CTexmap is not just AO pass maker, it's render element to make arbitrary passes out of shading networks.

If you create for example AO pass, and don't want to be cutting it out with the mask, just apply overall to the scene, you will probably want your BG color to be white, so if you multiply it over beauty, your background won't turn black.

At the same time, if you want for example mask of certain bitmap features on bottle etiquette, where white is contents of the Mask, and black is empty area, then you will probably want BG to be black as well.

So since you already need two different colors, then it makes most sense to just change ignore background checkbox to override background color checkbox, and stick a color swatch in there. That way, you can set it either black, or white, or any other color. Since it's for arbitrary passes, there may be some rare cases where you may want some other color than black or white.

Pokoy has requested something like this some time ago for Cmasking_ID pass, where I wasn't sure it would pay off, but I stressed several times it would indeed be useful for CTexmap, and since you are another one who requested it, it should be easy to push it through.

2015-07-08, 16:55:10
Reply #10

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
Yep, that'd work well.

2015-07-10, 16:51:11
Reply #11

Ondra

  • Administrator
  • Active Users
  • *****
  • Posts: 9048
  • Turning coffee to features since 2009
    • View Profile
fixed
Rendering is magic.How to get minidumps for crashed/frozen 3ds Max | Sorry for short replies, brief responses = more time to develop Corona ;)

2015-07-11, 10:17:54
Reply #12

rfletchr

  • Active Users
  • **
  • Posts: 41
    • View Profile
wow! rendering really is magic! Im looking forward to trying that out