what material is assigned to selected object

how to find what material is assigned to the object ?
example if i have anisotropic assigned; how do i query ?

i searched in maya help where i got shadingNode that doesnt let me query but i can use it to create

using

Code:

string $myShader;
$myShader = `shadingNode -asShader anisotropic`;


though when i right click and choose "Assign material to selection" it is assigned

like this

Code:

sets -e -forceElement anisotropic1SG;


if my material is anisotropic1SG then does that mean anisotropic1SG is also a shading group ,

btw what is the difference between shader and material ?

No Responses to “what material is assigned to selected object”

Post a Comment