rfm2  22.0
A python-based rewrite of RenderMan for Maya
rfm2.txmanager_maya Namespace Reference

Classes

class  TxScriptJob
 

Functions

def manager ()
 
def using_renderman ()
 
def node_specs (node)
 
def parse_maya_scene (start_queue=True, blocking=False)
 
def parse_new_maya_scene (start_queue=True, blocking=False)
 
def get_txmake_preset_names ()
 
def init_manager (force_create=False)
 
def pre_save_callback (*_args, **_kwargs)
 
def cleanup ()
 
def init_ui ()
 
def build_ui ()
 
def get_texture_by_path (input_path, nodeattr, ipr_mode=False, do_dirty_check=True, pre_expand=False)
 
def invalidate_all_textures ()
 
def stop ()
 
def start ()
 
def stop_and_return_remaining_task ()
 
def all_textures_available ()
 
def update_ui_when_visible (recurse=False)
 
def update_txmanager_ui_if_visible ()
 
def show ()
 
def save_scene_state (state)
 
def load_scene_state ()
 
def get_txfile_params (nattr)
 
def show_in_txmanager_ui (nattr)
 
def register ()
 
def register_prefs ()
 

Variables

string TXM_NAME = 'TxManagerControl'
 

Detailed Description

Maya adapter for the texture manager.

Function Documentation

◆ all_textures_available()

def rfm2.txmanager_maya.all_textures_available ( )
Return True if the txmanager's work queue is empty.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ build_ui()

def rfm2.txmanager_maya.build_ui ( )
Build the txmanager UI if need be.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ cleanup()

def rfm2.txmanager_maya.cleanup ( )
Cleanup when the plugin is un-loaded.

◆ get_texture_by_path()

def rfm2.txmanager_maya.get_texture_by_path (   input_path,
  nodeattr,
  ipr_mode = False,
  do_dirty_check = True,
  pre_expand = False 
)
Query the texture manager for a specific input path.

Args:
- plug (str): the node.attr plug containing the input_path.
- input_path (str): The image file name referenced in the plug.
- ipr_mode (bool): are we in IPR mode?
- do_dirty_check (bool): if false, ignore the dirty check and just return
  the real texture path.

Returns:
- Fully qualified path with expanded tokens (all but _MAPID_ which will be
  resolved by the pattern).
+ Here is the call graph for this function:

◆ get_txfile_params()

def rfm2.txmanager_maya.get_txfile_params (   nattr)
Return the TxParam object of the TxFile associated with the nattr plug.

Args:
    nattr (str): The nodeid associated with an existing texture.

Returns:
    TxParam or None: None if the nodeid is unknown to the texture manager.
+ Here is the call graph for this function:

◆ get_txmake_preset_names()

def rfm2.txmanager_maya.get_txmake_preset_names ( )
Returns a list of the txmake preset names known by the txmanager
+ Here is the call graph for this function:

◆ init_manager()

def rfm2.txmanager_maya.init_manager (   force_create = False)
Initialize the texture manager on startup so it may convert images in the
background.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ init_ui()

def rfm2.txmanager_maya.init_ui ( )
Opens the texture manager UI.
+ Here is the caller graph for this function:

◆ invalidate_all_textures()

def rfm2.txmanager_maya.invalidate_all_textures ( )
Loop through all the textures in the texture manager
and check if they are dirty. If they are, call invalidate texture.
+ Here is the call graph for this function:

◆ load_scene_state()

def rfm2.txmanager_maya.load_scene_state ( )
Load the JSON serialization from rman_globals.txmanagerData and use it
to update the texture manager.
+ Here is the call graph for this function:

◆ manager()

def rfm2.txmanager_maya.manager ( )
Return the current texture manager instance.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ node_specs()

def rfm2.txmanager_maya.node_specs (   node)
Return a (nodetype, nodecategory) tuple.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ parse_maya_scene()

def rfm2.txmanager_maya.parse_maya_scene (   start_queue = True,
  blocking = False 
)
Parse the maya scene to find all referenced textures.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ parse_new_maya_scene()

def rfm2.txmanager_maya.parse_new_maya_scene (   start_queue = True,
  blocking = False 
)
Resets the TxManager and start parsing the scene.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ pre_save_callback()

def rfm2.txmanager_maya.pre_save_callback ( _args,
**  _kwargs 
)
Called by maya as a om.MSceneMessage.kBeforeSave callback.
+ Here is the call graph for this function:

◆ register()

def rfm2.txmanager_maya.register ( )
Registers the workspaceControl if not in batch mode.

Returns:
    bool -- True if registered
+ Here is the caller graph for this function:

◆ register_prefs()

def rfm2.txmanager_maya.register_prefs ( )
Register texture manager prefs in Maya.

◆ save_scene_state()

def rfm2.txmanager_maya.save_scene_state (   state)
Save the serialized TxManager object in rmanGlobals.txmanagerData.
rfm2.txmanager_maya.save()
+ Here is the call graph for this function:

◆ show()

def rfm2.txmanager_maya.show ( )
Show the texture manager panel.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ show_in_txmanager_ui()

def rfm2.txmanager_maya.show_in_txmanager_ui (   nattr)
Open the txmanager UI and select the texture associated with a given
texture path plug.

Args:
    nattr (str): The nodeid associated with an existing texture.
+ Here is the call graph for this function:

◆ start()

def rfm2.txmanager_maya.start ( )
Start the conversion process by parsing the scene as if it had just
been opened.
+ Here is the call graph for this function:

◆ stop()

def rfm2.txmanager_maya.stop ( )
Stop the conversion process by emptying the task queue.
+ Here is the call graph for this function:

◆ stop_and_return_remaining_task()

def rfm2.txmanager_maya.stop_and_return_remaining_task ( )
stop the queue and return a list of tasks. Each task is a dict with the following fields:
- infile: input image file path
- outfile: output texture file path
- args: txmake arguments (command minus the binary and the files)

Returns:
    list of dicts -- all remaining tasks
+ Here is the call graph for this function:

◆ update_txmanager_ui_if_visible()

def rfm2.txmanager_maya.update_txmanager_ui_if_visible ( )
Only update the UI if visible
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ update_ui_when_visible()

def rfm2.txmanager_maya.update_ui_when_visible (   recurse = False)
Maya tends to delay ui display and this will recursively call itself
(up to 10 times) until the ui is visible.
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ using_renderman()

def rfm2.txmanager_maya.using_renderman ( )
Returns Trues if RenderMan is the current renderer.
+ Here is the caller graph for this function:

Variable Documentation

◆ TXM_NAME

string rfm2.txmanager_maya.TXM_NAME = 'TxManagerControl'