Reputation: 3931
I am retrieving shaders in maya c++ api using
fn.getConnectedShaders(0,shaders,indices);
shaders is an MObjectArray containing each shader of the selected object. How to extract the ambient color and other attributes from the shader MObject ?
Upvotes: 1
Views: 340
Reputation: 356
Look into the existing plugin code. \devkit\plug-ins\D3DViewportRenderer.cpp, it extracts the "ambientColor" and other attributes.
Upvotes: 3