Fix number of generated frames