Is there anyway to apply one material to the object in one view-port and a different material in a different view-port? or have x-ray mode only effect specific meshes?
what I'm trying to do:
In persp mode I want the mesh to have a normal lambert so I can see the model easily for modelling, but in my side view-port I want to either be able to have a different lambert on it which I have the transparency set really low in order to see the reference image behind it OR I could use x-ray mode but then the reference image gets harder to read
any tips?
till then I guess I'm stuck flipping back and forth between my two materials : (
Replies
Here's the dirty mel I've been using to toggle it on and off per object for the last 7 years :
// declare variables string $selected[]; string $hilited[]; string $object; int $test[]; int $hold; // assign values to variables for selected objects $selected = `ls -sl -dag -ap -typ surfaceShape`; $hilited = `ls -hl -dag -ap -typ surfaceShape`; // loop through any objects in component mode // and toggle their x-ray display for ($object in $hilited){ $test = `displaySurface -q -xRay $object`; $hold = $test[0]; if ($hold != false) displaySurface -xRay false $object; else displaySurface -xRay true $object; // clear test variable clear $test; } // loop through any objects in object mode // and toggle their x-ray display for ($object in $selected){ $test = `displaySurface -q -xRay $object`; $hold = $test[0]; if ($hold != false) displaySurface -xRay false $object; else displaySurface -xRay true $object; // clear test variable clear $test; } // clear selection variables clear $selected; clear $hilited;import pymel.core as pm def xraytoggle(): sel = pm.ls(sl=True, dag=True, ap=True, typ='surfaceShape') hilighted = pm.ls(hl=True, dag=True, ap=True, typ='surfaceShape') for i in hilighted: value = pm.displaySurface(i, q=True, xRay=True) if value[0]: pm.displaySurface(i, xRay=False) else: pm.displaySurface(i, xRay=True) for i in sel: value = pm.displaySurface(i, q=True, xRay=True) if value[0]: pm.displaySurface(i, xRay=False) else: pm.displaySurface(i, xRay=True) xraytoggle()Depending on the reference it can start to look muddy really quick and end up being useless
thanks for all the replies! I'll have to look into those scripts : ) much appreciated!