home *** CD-ROM | disk | FTP | other *** search
/ Hackers Magazine 57 / CdHackersMagazineNr57.iso / Software / Multimedia / k3d-setup-0.7.11.0.exe / share / k3d / scripts / command_node_inspector.py < prev    next >
Text File  |  2008-07-21  |  414b  |  23 lines

  1. #python
  2.  
  3. import k3d
  4.  
  5. class inspector:
  6.     def print_node(self, Node, Level):
  7.         message = ""
  8.         for j in range(Level):
  9.             message += "    "
  10.  
  11.         message += "command-node: " + Node.command_node_name()
  12.  
  13.         k3d.log.debug(message)
  14.  
  15.         for child in Node.children():
  16.             self.print_node(child, Level + 1)
  17.  
  18. for node in k3d.command_nodes():
  19.     inspector().print_node(node, 0)
  20.  
  21. k3d.ui().message("Output sent to the K-3D log window.")
  22.  
  23.