The exact code is going to depend on how the slideshow script works. You might not need to pre-load all of the images to get the effect you're after. If the slideshow runs slowly enough, pre-loading the first three or four images might give the browser enough of a head start that everything runs smoothly.
I don't work with media players very much, but I think you should look into some more cross-browser compatible code than a simple <embed> tag. Good luck!