There's this program called MAME that can be used to generate graphics based on ROM files...

Seriously, though - unsure what you're trying to do, but your best bet is probably going to be to use screenshots from MAME. ROM images (at least arcade ROM images) are not standardized enough that sprite data and the like could be easily extracted - any given game's going to have it stored in a different ROM, memory location, etc. A program designed to extract graphics from an arcade ROM would have to be programmed separately for every game (or few games) out there - it would be a programming project on par with MAME itself.
But I could just be talking out of my arse...