Announcement

Collapse
No announcement yet.

Vray Proxy global switch

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Vray Proxy global switch

    It would be handy to have a global switch to control the display properties of all proxies in a scene. So you could change all proxies from "preview from file" to either "point" or "bounding box".
    It would help display performance on heavly proxied scenes.
    Or maybe this is possible via Max script???

  • #2
    there is already a script doing that called Proxy Switcher, u can find it in iCube (http://rendering.ru/index.php/download-scripts/) web site and its free.
    Best regards,
    Andrian
    _____________________________________
    www.fekta.eu
    Portfolio
    CG Talk

    Comment


    • #3
      Nice one Fekta, thanks for sharing. That should make life a bit easier! Ta.

      Comment


      • #4
        or look here: http://www.chaosgroup.com/forums/vbu...ad.php?t=41316
        for Codi's script - works an absolute charm

        Comment


        • #5
          Thanks for the plug, glad it helped you

          Those scripts are quite old, here is a nicer version (just select the following code and drag to the toolbar)
          Code:
          xut_roll_scene_proxy_diplay_switcher
          
          try(destroyDialog xut_roll_scene_proxy_diplay_switcher)catch()
          
          rollout xut_roll_scene_proxy_diplay_switcher "VRayProxy Display Manager"
          (
              button chk_set_BB "Bounding Box" width:160
              button chk_set_FF "From File" width:160
              button chk_set_point "Point" width:160
          
              fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
          
              on chk_set_BB pressed do set_scene_proxy_display 0
              on chk_set_FF pressed do set_scene_proxy_display 1
              on chk_set_point pressed do set_scene_proxy_display 2
          
          )
          
          createDialog xut_roll_scene_proxy_diplay_switcher width:180 style:#(#style_fixed,#style_toolwindow,#style_sysmenu)
          cheers

          Comment


          • #6
            Even better! Thanks Codi and sv
            I so could of done with this script about a month ago...

            Comment


            • #7
              Thanks Codi. With apologies, I added a little bit to it to allow it to allow the options to affect the selected proxies rather than the entire scene:

              Code:
                     xut_roll_scene_proxy_diplay_switcher
              
                  try(destroyDialog xut_roll_scene_proxy_diplay_switcher)catch()
              
                  rollout xut_roll_scene_proxy_diplay_switcher "VRayProxy Display Manager" width:162 height:111
                  (
                      button chk_set_BB "Bounding Box" pos:[1,7] width:160 height:21
                      button chk_set_FF "From File" pos:[1,33] width:160 height:21
                      button chk_set_point "Point" pos:[1,59] width:160 height:21
                      fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                      checkbutton ckb_selected "Selected Only" pos:[16,87] width:135 height:17 enabled:true toolTip:"" checked:false
                      on chk_set_BB pressed do
                          set_scene_proxy_display 0
                      on chk_set_FF pressed do
                          set_scene_proxy_display 1
                      on chk_set_point pressed do
                          set_scene_proxy_display 2
                      on ckb_selected changed state do 
                     (    if state == on
                              then fn set_scene_proxy_display mode = for o in selection where classof o == VRayProxy do o.display = mode
                              else fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                      )
              
                  )
                  CreateDialog xut_roll_scene_proxy_diplay_switcher width:162 style:#(#style_fixed,#style_toolwindow,#style_sysmenu)
              Works fine for me but I haven't tested it extensively and make no promises that there's not a better way to do it.
              www.dpict3d.com - "That's a very nice rendering, Dave. I think you've improved a great deal." - HAL9000... At least I have one fan.

              Comment


              • #8
                No problem dlparsi, good idea.

                Changing the display function on the fly is an interesting approach

                Comment


                • #9
                  Updated for SP3 - "Preview from File - Faces" option...
                  Code:
                  (
                         xut_roll_scene_proxy_diplay_switcher
                  
                      try(destroyDialog xut_roll_scene_proxy_diplay_switcher)catch()
                  
                      rollout xut_roll_scene_proxy_diplay_switcher "VRayProxy Display Manager" width:162 height:143
                      (
                          button chk_set_BB "Bounding Box" pos:[1,7] width:160 height:21
                          button chk_set_FFe "From File (Edges)" pos:[1,33] width:160 height:21
                          button chk_set_point "Point" pos:[1,85] width:160 height:21
                          button chk_set_FFf "From File (Faces)" pos:[1,59] width:160 height:21
                          fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                          checkbutton ckb_selected "Selected Only" pos:[13,118] width:135 height:17 enabled:true toolTip:"" checked:false
                          on chk_set_BB pressed do
                              set_scene_proxy_display 0
                          on chk_set_FFe pressed do
                              set_scene_proxy_display 1
                          on chk_set_point pressed do
                              set_scene_proxy_display 2
                          on chk_set_FFf pressed do
                              set_scene_proxy_display 3
                          on ckb_selected changed state do
                          (    if state == on
                                   then fn set_scene_proxy_display mode = for o in selection where classof o == VRayProxy do o.display = mode
                                   else fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                           )
                  
                      )    CreateDialog xut_roll_scene_proxy_diplay_switcher width:162 style:#(#style_fixed,#style_toolwindow,#style_sysmenu)
                  
                  )
                  www.dpict3d.com - "That's a very nice rendering, Dave. I think you've improved a great deal." - HAL9000... At least I have one fan.

                  Comment


                  • #10
                    Thanks dlparisi for the update

                    Comment


                    • #11
                      Hi, Just found this old stuff and add a new button to the "whole Mesh" option:

                      (
                      xut_roll_scene_proxy_diplay_switcher

                      try(destroyDialog xut_roll_scene_proxy_diplay_switcher)catch()

                      rollout xut_roll_scene_proxy_diplay_switcher "VRayProxy Display Manager" width:162 height:170
                      (
                      button chk_set_BB "Bounding Box" pos:[1,7] width:160 height:21
                      button chk_set_FFe "From File (Edges)" pos:[1,33] width:160 height:21
                      button chk_set_point "Point" pos:[1,85] width:160 height:21
                      button chk_set_FFf "From File (Faces)" pos:[1,59] width:160 height:21
                      button chk_set_WM "Whole Mesh" pos:[1,111] width:160 height:21
                      fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                      checkbutton ckb_selected "Selected Only" pos:[13,140] width:135 height:17 enabled:true toolTip:"" checked:false
                      on chk_set_BB pressed do
                      set_scene_proxy_display 0
                      on chk_set_FFe pressed do
                      set_scene_proxy_display 1
                      on chk_set_point pressed do
                      set_scene_proxy_display 2
                      on chk_set_FFf pressed do
                      set_scene_proxy_display 3
                      on chk_set_WM pressed do
                      set_scene_proxy_display 4
                      on ckb_selected changed state do
                      ( if state == on
                      then fn set_scene_proxy_display mode = for o in selection where classof o == VRayProxy do o.display = mode
                      else fn set_scene_proxy_display mode = for o in geometry where classof o == VRayProxy do o.display = mode
                      )

                      ) CreateDialog xut_roll_scene_proxy_diplay_switcher width:162 style:#(#style_fixed,#style_toolwindow,#style_sysm enu)

                      )​

                      Comment

                      Working...
                      X