Making a waving flag
Make a new document, 1000x1000 pixels, white background
Get the flag you want and add it to the newly created document on a new layer, on a new document.
Now CTRL+Click on the flag layer thumbnail to get the selection of the flag and make a new layer above it...