There is a workaround using the processing.runalg()
method, described in this post: Using in-memory vector layer with QGIS processing / SEXTANTEUsing in-memory vector layer with QGIS processing / SEXTANTE.
EDIT: the script I copied was for vector clipping (not raster). I replaced it by GDAL's Clip raster by extent algorithm which does precisely what you want. You need to use the path to your raster as an input (and not the raster itself), though:
out_raster = processing.runalg("gdalogr:cliprasterbyextent", "path/to/raster.tif", "", "0,0,2,2", "", None)