What you're going to need is to open the image and echo out the contents. Assuming that you have the URL to every image stored in the database as well (lets call the image url $imageurl), this will be a fairly easy script.
$im = imagecreatefromjpeg($imageurl);
imagejpeg($im,100); // 100% quality
destroyimage($im);
That will only work if you have GD installed, though. If you don't, you'll have to use the file functions.
header("Content-type: image/jpeg");
$fp = fopen($imageurl,"r");
$contents = fread($fp,filesize($imageurl));
fclose($fp);
echo($contents);
Hope this helps.