Hey all:
Slightly off topic...
If I have a series of images that I want to convert to an animated gif
using the command line tool 'convert' from imagemagick, they cannot be
named:
1
2
3
4
5
6
7
8
9
10
11
Because this is seen as:
1
10
11
2
3
4
5
6
7
8
9
So I am trying to write a PHP script that will sequentially convert and
number a series of images, and I won't know ahead of time how many will
be in a given sequence. This files are originally randomly numbered,
but the sequence information can be extracted, and their order
determined. I then want to rename them, and I'm thinking I should use:
01
02
03
04
05
06
07
08
09
10
11
This works, and I guess I'll just need to tally the number of images,
and figure out if the 'lefthand' zeroes should be taken to the hundreds
and thousands place.
Anyone else know a simpler way around this problem?
-cjl
Slightly off topic...
If I have a series of images that I want to convert to an animated gif
using the command line tool 'convert' from imagemagick, they cannot be
named:
1
2
3
4
5
6
7
8
9
10
11
Because this is seen as:
1
10
11
2
3
4
5
6
7
8
9
So I am trying to write a PHP script that will sequentially convert and
number a series of images, and I won't know ahead of time how many will
be in a given sequence. This files are originally randomly numbered,
but the sequence information can be extracted, and their order
determined. I then want to rename them, and I'm thinking I should use:
01
02
03
04
05
06
07
08
09
10
11
This works, and I guess I'll just need to tally the number of images,
and figure out if the 'lefthand' zeroes should be taken to the hundreds
and thousands place.
Anyone else know a simpler way around this problem?
-cjl
Comment