Understanding and predicting the energy loss of swift ions in metals is important for many applications of charged particle beams, such as analysis and modification of materials, and recently for modelling metal nanoparticle radiosensitisation in ion beam cancer therapy. We have calculated the stopping power of the transition metals Pt and Au for protons and alpha particles in a wide energy range, using the dielectric formalism, which realistically accounts for the excitation spectrum of each metal through the Mermin Energy Loss Function -Generalised Oscillator Strength methodology. For each combination of projectile, energy and target, we have considered: (i) the equilibrium charge state of the projectile through the target, (ii) the energy-loss due to electron capture and loss processes, and (iii) the energy loss resulting from the polarisation of the projectile's electronic cloud due to the self-induced electric field. Our calculated stopping powers show a fairly good agreement with the available experimental data for platinum and gold, particularly the most recent ones around the stopping power maximum, which validates the methodology we have used to be further extended to other transition metals. For the materials studied (platinum and gold), two commonly used and different sources of the experimental excitation spectrum yield comparable calculated stopping powers and mean excitation energies, the latter being closer to the most recent data provided in a recent ICRU Report than to previous compilations. Despite the small differences in the sources of excitation spectra of these metals, they lead to practically the same stopping power results as far as they reproduce the main excitation features of the material and fulfil physically motivated sum rules.