The vertical stripes on Macs from 2011 with AMD 6xxxM GPUs tend to suggest that the GPU has died. In the 27” iMac from that era, the GPUs use the MXM-B standard, which means you can replace the card with a standard one; Nvidia GTX 7xxM cards that came out from Dell/Alienware laptops tend to work pretty well for that. Once you replace the GPU with a non-Apple one, you won’t have any boot screen any more, so you’ll want an HDD with an OS on it: if you are running macOS High Sierra on that drive, and you have a Nvidia GTX 7xxM card installed, it should be supported out of the box by the OS. Before bothering with the GPU, though, make sure that the HDD is actually working by plugging it into a computer and seeing if it functions. If it’s dead, just replace the drive.
I’d see if there is a connection issue on the screen cable. The connection might be bad. In addition to this, you might be suffering from the "stage light” issues that were explored by iFixit. If that doesn’t work, try an NVRAM reset, and if it still doesn’t work, the problem is somewhere else.
Ok, I’ve found the answer. If you have a Install macOS Mojave.app file, which I got from somebody else’s supported machine, you can flash the /Contents/SharedSupport/BaseSystem.dmg to a USB drive with a tool like Etcher. The only catch is that this is a recovery partition image, so you the bootable USB will download a copy of macOS from Apple’s servers, but at least it offers the option for machines that don’t support internet recovery, because I don’t own a Mac.
If it was a mid 2007/early 2008 Macbook Pro 15”/17”, it is actually a GPU defect. It needs to be replaced with a revised version. In fact, dosdude1 made a video about that. If it’s a late 2008-mid 2010 15”/17” Macbook Pro, it’s actually a problem with a capacitor on the GPU buck converter circuit, it is not a problem with the GPU in these machines (C7771 on the 2008 and 2009 models, C9560 on the 2010 models.) If it’s a early/late 2011 15”/17” Macbook Pro with AMD Radeon HD 6xxxM graphics, it’s a GPU issue that can be fixed using the technique described at dosdude1.com/gpudisable.
If it was a mid 2007/early 2008 Macbook Pro 15”/17”, it is actually a GPU defect. It needs to be replaced with a revised version. In fact, dosdude1 made a video about that. If it’s a late 2008-mid 2010 15”/17” Macbook Pro, it’s actually a problem with a capacitor on the GPU buck converter circuit, it is not a problem with the GPU in these machines (C7771 on the 2008 and 2009 models, C9560 on the 2010 models.) If it’s a early/late 2011 15”/17” Macbook Pro with AMD Radeon HD 6xxxM graphics, it’s a GPU issue that can be fixed using the technique described at dosdude1.com/gpudisable.