Usually the power supply coils on PSU, motherboard or GPU. If in warranty you make a claim. Out of warranty you shellac the coils. Remember that shellac on coils has been done for some 60+ years. Lots on the web about this.
I just noticed a high pitched noice coming from my PC when games are open and viewing the desktop. The pitch gets higher, the higher my GPU freq is. The moment I open my game again, the noice reduces to an unnoticable level. The noice is still there when I exit games entirely, but barely noticable. The noice is there regardless of the fans spinning or not, which bothers me the most.
I've got a MSI GTX 970 - 4GB of around 3 years old, not overclocked.
Provided a quick video, might not be the best but it will do the job.
So a summary:
- Weird high pitched noise
- only happens when I have a game open but minimized
- It is most likely not the fans
- It gets louder/higher the higher my current freq.