  We propose a new mechanism to generate primordial curvature perturbations,
based on the resonant production of particles during inflation. It is known
that this phenomenon can trap the inflaton for a fraction of e-fold. This
effect is governed by the mass of the produced particles and by their coupling
to the inflaton, parameters which can depend on the expectation value of other
fields. If one of such additional fields - a 'modulaton' - is light, then its
fluctuations, acquired during the earlier stages of inflation, will induce a
spatial modulation of the trapping, and thus of the end of inflation,
corresponding to a curvature perturbation. We calculate the power spectrum,
bispectrum and trispectrum of the curvature perturbations generated by this
mechanism, taking into account the perturbations due to the inflaton
fluctuations as well. We find that modulated trapping could provide the main
contribution to the observed power spectrum and lead to detectable primordial
non-gaussianities.
