Role of apodization in optical parametric amplifiers based on aperiodic quasi-phasematching gratings.