Using .htaccess rewrites wouldn't be a good approach since it would fail when the plugin is disabled.
You also can't rewrite image URLs with WordPress because its native request parsing does not recognize single file names. However, if an image doesn't exist, the web server will redirect the request over to WordPress for handling. This allows us to hook in and include your dynamic image template.
add_action('init', 'wpse_44612_init', 0);
With this approach, your URL appears as a static image, but is dynamically generated via your PHP class file.
You can download the plugin file is here.