I didn't know I could post, attach I guess, here. I'll do that later.
There is one puzzling format difficulty I have with the file that
requires some attention. I hope to have that cleared up in the next hour
or two. Actually, there's a twist in the format that should be
mentioned. The first image (frame) is 640x480, and I'm pretty sure one
byte per pixel. However, every other image (frame) after that is 128
pixels square. An auxiliary text file provides where, x and y pixel
position, the small image should be pasted to form a complete image with
the 640x480 frame. However, if one can get as far as simply displaying
the first frame and then the following smaller frames, I think that
would be quite sufficient for starters.
Yes, I've made some "touchdowns" before on the link you provided earlier
this year. I do need to fiddle with PIL again to get some semblance of
an idea how to use.
Christopher Barker wrote:
Wayne Watson wrote:
David, I have many video files, but only want to process them one at
a time. The format is unique, but simple. Basically, 640x480 b/w bmp
images one right after the other.
In here:
http://www.pythonware.com/library/pil/handbook/introduction.htm
Under "image sequences" there is enough info to tell you want to do if
PIL understands your format.
What happens when you point PIL at the file? Does it find the first
image? does it find more than one? If not, then you may need to break
them apart yourself before feeding them to PIL.
Also if it's as simple as a binary dump of a standard data type, then
you could probably use numpy's "fromfile" to read the data in, you
could then covert to a PIL image for the histogram, or just use
numpy's histogram functions to compute it.
You may want to post a (small) sample file here, and others can take a
look if you're still confused.
-Chris
--
Wayne Watson (Watson Adventures, Prop., Nevada City, CA)
(121.015 Deg. W, 39.262 Deg. N) GMT-8 hr std. time)
Obz Site: 39° 15' 7" N, 121° 2' 32" W, 2700 feet
350 350 350 350 350 350 350 350 350 350
Make the number famous. See 350.org
The major event has passed, but keep the number alive.
Web Page: <www.speckledwithstars.net/>
_______________________________________________
Image-SIG maillist - Image-SIG@python.org
http://mail.python.org/mailman/listinfo/image-sig