Added drawDebugRect method to render canvases.