Advertisement
Guest User

Untitled

a guest
Jun 30th, 2015
378
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.75 KB | None | 0 0
  1. #!/usr/bin/env python
  2. # -*- coding: UTF-8 -*-
  3.  
  4. """ Module 456: This is a Houdini startup script.
  5. Houdini runs this script after you open a saved scene.
  6. """
  7.  
  8. import logging
  9. import hou
  10.  
  11. # Create logger and streamhandler
  12. logging.basicConfig(level=logging.DEBUG)
  13. logger = logging.getLogger(__name__)
  14.  
  15. logger.info('Running 456.py...')
  16.  
  17.  
  18. def reloadHDAs():
  19.     """ This method reloads all Houdini Digital Assets from the HOUDINI_OTLSCAN_PATH.
  20.    It is the equivalent of running the UI Refresh Asset Libraries UI item.
  21.    """
  22.  
  23.     # Run Houdini HScript command
  24.     hou.hscript('otrefresh -r')
  25.     logger.info('Successfully reloaded all HDAs!')
  26.  
  27.     currentLoadedHdas = hou.hda.loadedFiles()
  28.     logger.debug(currentLoadedHdas)
  29.  
  30.  
  31. reloadHDAs()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement