The Progenitor Masses of Wolf-Rayet Stars and Luminous Blue Variables Determined from Cluster Turnoffs. I. Results from 19 OB Associations in the Magellanic Clouds