Chaos Corona for 3ds Max > [Max] Feature Requests

Tonemapping & Maxscript

<< < (2/3) > >>

maru:
Unfortunately, Vexus team are not responding to me so far. I will share any updates here once I hear from them.

maru:
Vexus team have replied to my message and we are in touch. The plan is to help each other with the improvements.

DPS:
Thanks Marcin

JokerMartini:
Hey everyone,
I'm one of the developers of Vexus and I can point out where we are having issues supporting corona as well as some possible solutions.

The Goal:
As you may know Vexus is a node based scene assembly tool. Within Vexus we want to give users the ability to create/manipulate the Tone Mapping settings inside of the Corona VFB. However there are some pitfalls that are preventing that from being possible via maxscript.

The Issues:
- There is no way to remove all Tone Mapping operators from the ui. Using the following code
--- Code: ---setProperty renderers.current "colorMap.pipeline" null
--- End code ---
simply just resets the operators to the Default which contains a list of operators that the user may not want.
- There is no way to save and load Tone Mapping presets via maxscript.
- Simply creating Tone Mapping operators with maxscript results in buggy because it's only successful if the use assigns an ID to the operator however there is no provided safe way of knowing what id can be assigned to the operator.

Solution Ideas:
- Provide a method to easily clear all ToneMapping operators so the list appears actually empty from a visual standpoint
- Provide a method for adding and operator where the user is not required to supply and ID to the operator. Option provide a method where I can get and ID which I can then safely use as and ID for the Tone Mapping operator. Currently for a user to add and operator they have to do the following...

--- Code: ---fn addLutOperatorPlugin =
(
    op = LutOperatorPlugin()
op.colorMappingOperator_enabled = true
op.colorMappingOperator_path = "L:\_Max_stuff\_Corona_LUTs_Tonemapping Only\DS_4_Values.CUBE"
op.colorMappingOperator_opacity = random 0.0 1.0

    id = random 1 500
setProperty op "colorMappingOperator.id" id
    lastOperator = getProperty renderers.current "colorMap.pipeline"
    setProperty op "colorMappingOperator.nextOperator" lastOperator
    setProperty renderers.current "colorMap.pipeline" op
)
addLutOperatorPlugin()

--- End code ---
I would suggest making the method more user friendly removing the requirement for the user to come up with some random id value and simplify the appending of the operator like this (pseudo code)

--- Code: ---op = LutOperatorPlugin()
op.colorMappingOperator_enabled = true
op.colorMappingOperator_path = "L:\_Max_stuff\_Corona_LUTs_Tonemapping Only\DS_4_Values.CUBE"
op.colorMappingOperator_opacity = random 0.0 1.0
append renderers.current.colorMap.pipeline.operators op

--- End code ---

It would be nice if the operators were managed almost more like how render elements are. An array of Objects that can be iterated through, append, remove...ect. Right now the manipulating of operators is more complicated than needed making it difficult to implement. We can't safely and reliably append new operators and/or save/load existing operator presets.

Frood:

--- Quote from: JokerMartini on 2023-01-10, 19:17:27 ---It would be nice if the operators were managed almost more like how render elements are.

--- End quote ---

This was exactly my suggestion when I once was asked how it should/could look at the maxscript side. Now, everybody who wants to do serious scripting stuff with tone mapping has to write libraries instead.

I don't know if you aware of this one:

https://forum.corona-renderer.com/index.php?topic=36778.msg201269#msg201269

Have not tried/used it yet and it would need some changes to be able to use it for Camera tone mapping as well though. I almost never use global tone mapping so I'd have to modify it anyway.


Good Luck



Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version