Add OGL options to VEX Surface Shader operator

   3580   3   0
User Avatar
Member
401 posts
Joined:
Offline
I created a VEX Surface Shader Operator via File -> New Operator Type

Now I want to add the OGL SHOP Options to display texturemaps in the viewport.
I cannot add them through the Edit Parameter Interface, as the Properties are defined by the Vex Code.

If I add a #pragma rendermask OGL to my vex code I get a lonely OGL diffuse (ogl_diff) parameter added to my shader dialog.

How to add the complete OGL Folder to such a shader?

Thanks,

Georg
this is not a science fair.
User Avatar
スタッフ
2591 posts
Joined: 7月 2005
Offline
rdg
I created a VEX Surface Shader Operator via File -> New Operator Type

Now I want to add the OGL SHOP Options to display texturemaps in the viewport.
I cannot add them through the Edit Parameter Interface, as the Properties are defined by the Vex Code.

If I add a #pragma rendermask OGL to my vex code I get a lonely OGL diffuse (ogl_diff) parameter added to my shader dialog.

How to add the complete OGL Folder to such a shader?

Thanks,

Georg

I'm not sure I understand exactly, but have a look at $HH/scripts/shop/shop_oglsurface.py.
User Avatar
Member
401 posts
Joined:
Offline
Sorry, while making this screenshot I guess I undestood some details.
A VEX Surface Shader defines all dialogs in the code, that's why I cannot add the parameters in the ‘Edit Operator Type’ window …

Still:
A shader created with with “New Operator Type” doesn't allow to add the OGL options. Unlike the VOP SOP which has these OGL options ‘preinstalled’.

I don't want to add them via the gear, as I don't understand all this galley stuff yet.

I want a VEX Shader with code that has OPL Options … if this is possible.

But I'll check the file you mentioned and see if I can come up with something.

Attachments:
ogl.jpg (54.2 KB)

this is not a science fair.
User Avatar
Member
401 posts
Joined:
Offline
the script you mentioned looks good, but though my shader doesn't support OGL2 no spare parameters are created on creation.

shop.supportedRenderers()
('VMantra', ‘OGL’)
this is not a science fair.
  • Quick Links