fn CameraFilter obj= ((classof obj== freeCamera ) or (classof obj == VrayPhysicalCamera) or (classof obj== TargetCamera)) try(destroyDialog CameraMapTool) catch() rollout CameraMapTool "CAMERA MAP TOOL" width:190 height:300 ( group "CAMERA SELECTION" ( label label1 "First select the Camera" pos:[16,24] width:128 height:13 label label2 "to project from" pos:[16,40] width:126 height:13 pickbutton btn_SelectCamera "Select Camera" width:130 height:21 filter:CameraFilter align:#center ) group "MATERIAL SELECTION" ( label lbl3 "Select the material " pos:[16,110] width:128 height:13 label lbl4 "to use" pos:[16,125] width:128 height:13 materialbutton choosemtl "Pick Material" align:#center ) group "SELECT OBJECTS AND GO" ( label lbl5 "Select the objects and" pos:[16,195] width:128 height:13 label lbl6 "press GO" pos:[16,210] width:128 height:13 button btn_GO "!!GO!!" width:72 height:21 align:#center ) on btn_SelectCamera picked camara do ( btn_SelectCamera.text= camara.name global SelectCamera= btn_SelectCamera.object ) on choosemtl picked mtl do ( --global materialito= selection.material=mtl materialito = mtl choosemtl.text = mtl.name ) on btn_GO pressed do with undo on ( --Objetos=#() --Objetos= $ as array for o= 1 to selection.count do ( CamMapModif= (SpaceCameraMap name:"Projection") if selection[o].modifiers[1]!= undefined then deleteModifier selection[o] 1 addModifier selection[o] CamMapModif CamMapModif.cameraNode= SelectCamera selection[o].material = materialito ) ) ) createDialog CameraMapTool