Page 1 of 1
subimage specification returns no images
Posted: 2014-08-21T23:08:21-07:00
by Jerware
I'm running the following command from a Windows shell:
Code: Select all
convert "video.mpeg[2000-3999]" -coalesce -background black -alpha remove -type truecolor -resize 16x16! -quality 100 "temp\%06d.bmp"
It spits out all 2000 files perfectly, but then it reports the following error:
convert.exe: subimage specification returns no images `video.mpeg' @ error/constitute.c/ReadImage/577.
Normally I wouldn't mind because I'm getting the desired frames extracted, but I need to share this process with my users and I don't want them confused. Is something wrong with my command? Any help is appreciated. Thanks!
EDIT: I should note that frames [0-1999] do not report an error.
Re: subimage specification returns no images
Posted: 2014-08-22T06:28:06-07:00
by snibgo
Looking at that source code, which is complex, IM is trying and failing to clone all the images. It only does this when you have a scene geometry, eg [2000-3999]. Perhaps it is running out of memory. (Cloning shouldn't take much memory, but may take you over a threshold. Each image has a 13,000 bytes overhead so 2000 takes 26 MB.) How large are the video frames?
This isn't a fatal error. Does "-quiet" suppress the message?
You can redirect messages with "2> file.txt", then check the file for fatal error messages.
Re: subimage specification returns no images
Posted: 2014-08-22T09:11:40-07:00
by Jerware
Thanks for investigating. Using -quiet does not hide the error. I don't think it's a memory issue though. I've simplified the problem, and you can see for yourself.
Download this 48k video file, which is 640x480 and 20 frames long:
http://ledseq.com/downloads/20frames.mp4
Run the following and it works fine:
Code: Select all
convert 20frames.mp4[0-9] -type truecolor -resize 16x16! -quality 100 %06d.bmp
Run the following and you get the error:
Code: Select all
convert 20frames.mp4[10-19] -type truecolor -resize 16x16! -quality 100 %06d.bmp
Thoughts?
Re: subimage specification returns no images
Posted: 2014-08-22T10:29:08-07:00
by snibgo
The bug seems to be complex. It seems to happen when last < 2 * first. Eg [3-4] and [3-5] creates the error; [3-6] is okay.
This occurs with the mp4 file, but not if I first convert it to a multi-page tiff and extract images from that tiff.
Hence the problem may be an interaction with ffmpeg. I don't have a suitable environment for testing further.
Please report this on the bugs forum
viewforum.php?f=3, with a link to this thread.
Re: subimage specification returns no images
Posted: 2014-08-22T11:12:57-07:00
by Jerware
Done. Thanks!