I don't know too much about Safari's archtitecture, so you might be better off looking at the apps page on Apple's site.
This is the list of compatible formats Safari uses:
I found something cool though.
As with Mac OS X itself, Safari uses open source software at its core. For its Web page rendering engine, Safari draws on KHTML and KJS software from the KDE open source project. And of course, being a good open source citizen, Apple shares its enhancements with the open source community."
So there might be some sort of Safari like Open Source app out there already for other OS's.