Cleanup: simplify BLI_stringdec use

This commit is contained in:
Campbell Barton 2015-10-16 15:17:54 +11:00
parent 2f35217849
commit c9d3243f2b
1 changed files with 1 additions and 8 deletions

View File

@ -4444,14 +4444,7 @@ float *BKE_image_get_float_pixels_for_frame(struct Image *image, int frame)
int BKE_image_sequence_guess_offset(Image *image)
{
unsigned short numlen;
char head[FILE_MAX], tail[FILE_MAX];
char num[FILE_MAX] = {0};
BLI_stringdec(image->name, head, tail, &numlen);
BLI_strncpy(num, image->name + strlen(head), numlen + 1);
return atoi(num);
return BLI_stringdec(image->name, NULL, NULL, NULL);
}
bool BKE_image_has_anim(Image *ima)