This Plug-in for Gimp will let you put a scanned CD photo into a 'virtual' case.
To use it, install the plug-in, open the CD image with Gimp and then go to Filters -> Artistic -> CD Casefier…
Select the size of the (square) output image and click OK. Depending on the image chosen, you may want to set the “Try to crop corners” option, which works best for real CD scanned pictures.
Installation notes: Just untar-gzip the file into your ~/.gimp26/plug-ins folder. Make sure that the cdcasefier.py is executable. Note: I’ve stolen the case picture from the Rhythmbox project.