Great that you're interested
I think you should start by forking the BlendLuxCore repository.
However if you don't know git, you can also just edit the Python source files in your BlendLuxCore installation. This is easier if you don't have prior programming/version control knowledge.
kintuX wrote: Wed Sep 12, 2018 6:49 pm
For starters i'd like to modify HSV node inputs. Specifically, I want to lift max. Saturation & Value from 2 to X.
But as expected, simply changing those values in hsv.py does nothing.
So what do i need to do? Where can i get the relevant information?
You should first look into the LuxCore code that reads the properties and creates the texture:
https://github.com/LuxCoreRender/LuxCor ... s.cpp#L491
Some non-textured values are clamped there, but since all inputs of the HSV texture are texturable, this code allows arbitrary inputs.
Next, you should look at the LuxCore code that computes the texture output at a given hitpoint:
https://github.com/LuxCoreRender/LuxCor ... sv.cpp#L33
In case of the HSV texture this is a bit complicated, you might want to look at some other textures to get what is essentially going on.
Anyway, what I did just now is check if there is any clamping happening here.
In the HSV texture, only the color input is clamped (in line 46).
So it is possible to pass any saturation or value!
This means that the only clamping that is going on is inside the Python addon.
In
nodes/textures/hsv.py we see that the saturation socket is of type "LuxCoreSocketFloat0to2".
Socket classes are declared in
nodes/sockets.py.
You can copy and paste the name of most socket classes here into the string in hsv.py.
For example, you could change it to "LuxCoreSocketFloatUnbounded" to get a float input without bounds.
And with this, you get the following:
However, there's also another trick you can use without any coding:
Because we saw that on the LuxCore side, no clamping happens, we can use a "Constant Value" node to plug any value into the saturation socket.
Anyway, this might be interesting for you:
https://github.com/LuxCoreRender/BlendL ... master/doc (Blender addon documentation, not as much as I'd like to have)
https://wiki.luxcorerender.org/LuxCore_ ... anual_v2.1 (manual for the property definitions)
https://github.com/LuxCoreRender/LuxCor ... uxcore.cpp (LuxCore Python API)
https://wiki.luxcorerender.org/Writing_ ... ine_Plugin
https://wiki.luxcorerender.org/Compiling_LuxCore
Hope I didn't overwhelm you
