Movie Maker version 4.1.3

Hi

I am using, for me, a new version of Processing (4.1.3). I have produced a number of image files:
1.png, 2.png… 250.png and have the saved in a special frame folder.
When I am running the movie maker it does not end with the last picture. It rather scrambles the files.
Should I rename the files or what can I do.
When I am using a commercial program (with watermarks) it gives a correct result.

Best regards
K.

Hello @Kylie,

Try sequential numbers that are the same length padded with zeroes in front of the number.

0001
0002

0020
0021

0200
0201

2000
2001

9999

Processing can do this when saving frames:
https://processing.org/reference/saveFrame_.html

You may need a utility program to rename them if they are generated outside of a Processing sketch.

:)

Hi
Thanks! - It worked. I created a special function, where Hit is the saved frame counter.

void   SaveToFile(int Hit){
  if (Hit<10){saveFrame("/frame/Path-000"+str(Hit)+".png");}
  if (Hit>=10&&Hit<100){saveFrame("/frame/Path-00"+str(Hit)+".png");}
  if (Hit>=100&&Hit<1000){saveFrame("/frame/Path-0"+str(Hit)+".png");}
  if (Hit>=1000&&Hit<10000){saveFrame("/frame/Path-"+str(Hit)+".png");}
}
1 Like

Or even easier :

void SaveToFile(int Hit){
saveFrame("/frame/Path-"+nf(Hit, 5)+".png");
}
1 Like