hook_theme_registry_alter() and theme() How can hook_theme_registry_alter() associate, for example, theme_mymodule_image_output() with the 'image' theme ID?
As reported in the documentation, hook_theme_registry_alter() is invoked from Drupal to allow third-party modules to alter the theme registry information returned from hook_theme().

The value returned from the implementations of hook_theme() is an array containing information about the different theme functions implemented by the modules (or themes).  

function node_theme() {
  return array(
    'node' =&gt; array(
      'arguments' =&gt; array('node' =&gt; NULL, 'teaser' =&gt; FALSE, 'page' =&gt; FALSE), 
      'template' =&gt; 'node',
    ), 
    'node_list' =&gt; array(
      'arguments' =&gt; array('items' =&gt; NULL, 'title' =&gt; NULL),
    ), 
    'node_search_admin' =&gt; array(
      'arguments' =&gt; array('form' =&gt; NULL),
    ), 
    'node_filter_form' =&gt; array(
      'arguments' =&gt; array('form' =&gt; NULL), 
      'file' =&gt; 'node.admin.inc',
    ), 
    'node_filters' =&gt; array(
      'arguments' =&gt; array('form' =&gt; NULL), 
      'file' =&gt; 'node.admin.inc',
    ), 
    'node_admin_nodes' =&gt; array(
      'arguments' =&gt; array('form' =&gt; NULL), 
      'file' =&gt; 'node.admin.inc',
    ), 
    'node_add_list' =&gt; array(
      'arguments' =&gt; array('content' =&gt; NULL), 
      'file' =&gt; 'node.pages.inc',
    ), 
    'node_form' =&gt; array(
      'arguments' =&gt; array('form' =&gt; NULL), 
      'file' =&gt; 'node.pages.inc',
    ), 
    'node_preview' =&gt; array(
      'arguments' =&gt; array('node' =&gt; NULL), 
      'file' =&gt; 'node.pages.inc',
    ), 
    'node_log_message' =&gt; array(
      'arguments' =&gt; array('log' =&gt; NULL),
    ), 
    'node_submitted' =&gt; array(
      'arguments' =&gt; array('node' =&gt; NULL),
    ),
  );
}


The returned array used what in my previous comment I called theme ID, and it is the same value that is passed to theme().
node_theme() doesn't use it, but the documentation for hook_theme() reports that the array can use the function index to report which function needs to be called as theme function.

A module implementing hook_theme_registry_alter() should use the following code to change the function that is invoked when theme('image') is called.

function mymodule_theme_registry_alter(&amp;$theme_registry) {
  if (isset($theme_registry['image'])) {
    $theme_registry['image']['function'] = 'theme_mymodule_image_output';
  }
}


When a module alters the theme registry using that code, any call to theme('image', ...) will not invoke theme_image() anymore, but it will invoke the function defined from that module.
To notice that it is not necessary to name the function theme_mymodule_image_output(); the code would work the same if the function is renamed mymodule_image_output() and the code of mymodule_theme_registry_alter() is accordingly changed. I usually use the prefix theme_ to make clear the function is a theme function.