Announcement

Collapse
No announcement yet.

One-line Script: Refresh proxies.

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

  • One-line Script: Refresh proxies.

    Code:
    starttime=timestamp()
    for i in objects where classof i == VRayProxy do i.filename=i.filename
    thetime=timestamp()-starttime
    print ("refreshed filename in " + thetime as string+"ms")
    The stupidest of scripts, yet a blessing when there are changes to a proxy file that is present thousands of times in a scene.
    This is the scenario that sparked the idea:
    Empty scene, create a foliage, export to proxy with auto-proxy creation.
    Now you'll have one proxy displayed in view.
    Create another, different type of foliage, and reexport with autoproxy (it will overwrite the old proxy mesh file).
    Now you'll have two proxies displaying different trees, but both are reading the same proxy file.
    The script refreshes the proxy object filename for all the scene proxies, hence resetting the preview, and avoiding nasty accidents at rendertime

    Tested on an x2-4200 with a geforce 8800gts 640mb in d3d, 21825 proxies refreshed in 3 seconds or so.

    Have fun with it.
    Lele
    Trouble Stirrer in RnD @ Chaos
    ----------------------
    emanuele.lecchi@chaos.com

    Disclaimer:
    The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

  • #2
    sometimes the best things are the most simple.

    Thanks for this lele, no more "clone and align" needed!
    Chris Jackson
    Shiftmedia
    www.shiftmedia.sydney

    Comment


    • #3
      Hey CJ you went back to Sidney, or never changed the profile location? XD
      Lele
      Trouble Stirrer in RnD @ Chaos
      ----------------------
      emanuele.lecchi@chaos.com

      Disclaimer:
      The views and opinions expressed here are my own and do not represent those of Chaos Group, unless otherwise stated.

      Comment


      • #4
        ha, my brain is still in sydney!
        I need to update my location.....
        Chris Jackson
        Shiftmedia
        www.shiftmedia.sydney

        Comment

        Working...
        X