I am having a really difficult time with the pfxToon node. It has been giving me some very odd inconsistant behavior when using the "Offset Mesh" feature. I am using the "Offset Mesh" feature to build a live displacment mesh in the view port using a "Line Width Map" of a texture file, in this example a 2d fractal. I'd like to animate the U and V offsets and or the rotation UV of the place2dTexture" node being connected to the "Line Width Map" but it never seems to work conistantly. Attached bellow is a sample snippit of code to reporduce the issue, I hope somebody has expereicne with this one.
//Create Base Mesh
polyPlane -w 10 -h 10 -sx 10 -sy 10 -ax 0 1 0 -cuv 2 -ch 0;
//Create pfxToon Node
assignNewPfxToon;
setAttr pfxToonShape1.profileLines 2;
setAttr pfxToonShape1.borderLines 0;
setAttr "pfxToonShape1.lineWidth" 2;
//Create Shader
shadingNode -asTexture fractal;
shadingNode -asUtility place2dTexture;
connectAttr place2dTexture1.outUV fractal1.uv;
connectAttr place2dTexture1.outUvFilterSize fractal1.uvFilterSize;
connectAttr -force fractal1.outAlpha |pfxToon1|pfxToonShape1.lineWidthMap;
//Not Working WHY?
setAttr "place2dTexture1.offsetU" 2;
setAttr "place2dTexture1.offsetV" 2;
setAttr "place2dTexture1.rotateUV" 107.106;
//Weird temparary fix that sometime works and sometimes doesn't
expression -s "pfxToonShape1.lineWidth = rand(2, 2.0000001);" -o pfxToonShape1 -ae 1 -uc all ;
select |pfxToon1|pfxToonShape1;