Thanks for your tip.
I managed to figure out how batch renderer works in Maya, finally.
It took me quite a while to get to know this mechanism, so I guess it would be useful for somebody else.
By clicking Batch Render in the menu, Maya spawns another process that executes Render executable (in Windows it's maya_dir/bin/Render.exe).
Render.exe takes an argument "-r" for a renderer name.
The renderer name is nothing special.
It is only a string for Render.exe to find the XML file that describes the renderer.
You can see those XML files in maya_dir/bin/rendererDesc.
Besides listing arguments the renderer provides, the XML file also contains MEL scripts to do the actual rendering.
For example, in command prompt if you execute:
Render.exe -r myCustom
Render.exe will try to read myCustomRenderer.xml. If it exists, the MEL in it will be executed.
Because Render.exe is another Maya process independent to the original Maya that spawns it, it is necessary to register the renderer (using "renderer" command) and load the required plugins (if any) for Render.exe again.
All these commands should be put into the XML file for the custom renderer.
You will also need Maya to execute Render.exe with the right renderer name.
This is done by -batchRenderOptionsStringProcedure flag of "renderer" command.
Pass it a function which returns a string like this:
global proc string myBatchRenderOptionsString()
{
return " -r myCustomRenderer ";
}
The returned string will be appended when executing Renderer.exe.
There's some other info here:
http://usa.autodesk.com/adsk/servlet/ps/dl/item?linkID=9242258&id=13376545&siteID=123112