Realistically more time is sunk into the design of this blog than content for it, and so in similar fashion it's my honour to introduce you to my photoblog Odyssey—a completely over-engineered marvel that has the capacity to, but probably wont be updated any more regularly than this blog you're currently reading.
I've seen a lot of ways people choose to display photos in a gallery, and there's usually some form of trade-off every time. Either you must conform to some thumbnail size and aspect ratio (example), or you just hope that no-one ever scrolls to the bottom of the page to see a miss-aligned ragged edge (example), or even no chance of previewing the images: just keep clicking and hope that it's worth it (example).
The general issue here can be considered as a partition problem, which in less mathsy language asks the question: How can we arrange a group of objects of various size into a container without overlapping or overflowing? The answer to this question is one which falls into the NP-Complete category of annoying things most people don't want to deal with.