Analysis of sputtering discharge by optical and mass spectrometry. I. Platinum and tantalum sputtered in argon