seubjoh
August 13th, 2009, 06:50 PM
So I have a stack of pictures that I need to read and I've named them target0, target1, target2, etc. but to type each of those into a string like:
textureFilename[0] = "target1.png";
is inconvenient. Is there a way I can make the number in the string an integer value, similar to a printf, so that I can just put this in a loop?
What I mean by a printf is:
printf("target%d.png", i);
is there something I can do like this for entering a string name in?
Thanks!
textureFilename[0] = "target1.png";
is inconvenient. Is there a way I can make the number in the string an integer value, similar to a printf, so that I can just put this in a loop?
What I mean by a printf is:
printf("target%d.png", i);
is there something I can do like this for entering a string name in?
Thanks!