DzCustomMDLBrick creation
Omniflux
Posts: 377
In 4.8.0.3, the shader mixer got support for auto creating a custom MDL brick. Is this functionality accesible via scripting?
getAutoAddParameter() works great to connect parameters between bricks, but I've got to get the parameters in the first brick first. I can use loadMDLModule() to read a module in and get a DzIrayMDLModule containing the DzMDLDefinition(s), but I cannot find a way to autopopulate DzCustomMDLBrick.
Do I have to manually create the parameters at this point?
Comments
What I have so far is
If I drop an MDL file in the Shader Mixer, I get this
but from the code so far, I can only get this
What is the missing step here?
Short answer: I don't have a clue.
But...
Hope this helps.
P.
Unfortunately, I think the shader area is undocumented because it is incomplete. I've found several instances of
TypeError: ambiguous call of overloaded function setType(); candidates were setType(ParamType) setType(int)
or
TypeError: cannot call type(): unknown return type `DzBrickSet::ShaderType' (register the type with qScriptRegisterMetaType())
Yeah... Scripting in DAZ Studio reminds me often of playing Zork in the 1980s
So.... I opened a support ticket and then quickly figured it out.
On the DzCustomMDLBrick you just need to set the value on getMDLCallableControl()
Good to know - Thanks.