There's
a Joe Fromm script that does that - I think it's called the Laminate
script. It takes all open images and assembles them into a single
image,
where each of the original images becomes a layer in the new image.
I think Gary Barton has all Joe's scripts available in
The Lab at his site:
http://pixelnook.home.comcast.net/TheLab.html