How to get the rollouts of a scripted plugin material when UI has been replaced?

How to get the rollouts of a scripted plugin material when UI has been replaced?

Anonymous
Not applicable
323 Views
2 Replies
Message 1 of 3

How to get the rollouts of a scripted plugin material when UI has been replaced?

Anonymous
Not applicable
Hello,

I want to extend an existing material class and make my own GUI for it. I then create my plugin as follow:
plugin material MyMaterial
name:"MyMaterial"
classID:#(0x69fedc0d, 0x7c79a4d2)
extends:Standard replaceUI:true


Nevertheless, according to the settings entered by the user, I want to display one of the rollouts that was in the standard material (could be Blind Basic Parameters for example). But I don't want it all the time.

Does someone know how I can get all the rollouts of my base class? Or the rollouts of any standard material?


I tried with
replaceUI:false
but it this case all the base rollouts are visible, and all the time.

Thanks a lot,


Werwack
0 Likes
324 Views
2 Replies
Replies (2)
Message 2 of 3

keithm
Enthusiast
Enthusiast
You'll most likely have to recreate the UI for the variables you wish to keep accessible to the user.


plugin material MyMaterial
name:"MyMaterial"
classID:#(0x69fedc0d, 0x7c79a4d2)
extends:Standard
replaceUI:true
(
rollout Test "Test"
(
colorPicker _Diffuse "Diffuse"
on _Diffuse changed val do
(
Delegate.Diffuse = val
)
)
)
0 Likes
Message 3 of 3

Anonymous
Not applicable
Hello Keith,

Thanks for the answer.
Indeed, that's a possibility. I tried it and found several limitations, then my question.

The limitations I've found are:
- it could be a lot of work to recreate all the components of a rollout
- some behaviors cannot be reproduced in maxscript, or at the cost of a long development time (drag and drop of textures on some buttons...)
- on a material, clicking on a map we have "duplicated" doesn't allow the navigation into the material (in other words, I haven't found how to keep or simulate the fact that we can edit a texture map and then come back to its parent with the navigation arrows of the material editor)

I am then thinking about a completely different approach for my materials (which I have not found yet :/)


Regards,


Werwack
0 Likes