I have an original image in JPG format with a (nearly) white background. I want to resize it to 800px (maintaining aspect ratio) and then create a stack of the same image, let's say four copies, and have the output as a JPG again on a 1000x1000 white canvas.
No matter what I try, I can't get the images to stack with the area around the outside remaining transparent. To make it more complicated, I also don't want any white areas inside the object to be transparent as that lets the images underneath show through (as you can also see in my failed attempt).
ImageMagick-7.0.8-Q16 on Windows
Original (2360x2812)

Desired output - Something like this (1000x1000)

My Fail (with only two images in stack) (1000x1000)

ImageMagick-7.0.8-Q16 on Windows