A 60-year-old man with known stable angina presents with chest pain. He uses his glyceryl trinitrate (GTN) spray and the pain resolves within 5 minutes. He asks how GTN works. What is the primary mechanism of action of nitrates in relieving anginal pain?