I personally can't see much use in something like this, asside from slowing down gallery, duplicating a well established, working system and using up lots of disk space if you accidentally forget about it...
But if you want, I'd suggest checking out G2 and then making a detailed post along with an RFE. I think what you want would be so trivially easy to do in G2 that you could probably learn the API and do it. G2 has hooks, and all you'd need to do was find the image load hook and write a module that records the ip, item visited, etc to a file every time an image is loaded. You could do this for tons of things, keeping seperate stats for who loads thumbs, resized and full images or almost anything.
The more modules for G2 the better!