Lajos,
In order to avoid skip frames, please change the parameters skipDistributionWindowLength and numSkipInDistributionWindow as follows.
rateControlParams.skipDistributionWindowLength = 5;
rateControlParams.numSkipInDistributionWindow = 0;
This will make sure that in CBR mode, none of the frames are skipped.