Three dimensional strain measurements with x-ray energy dispersive spectroscopy