[sane-devel] "gamma" and "bayer" ? What are they?

Theodore Kilgore kilgota@banach.math.auburn.edu
Wed, 11 Jun 2003 19:51:40 -0500 (CDT)


Henning,

Perhaps you would be one to know this, or it is fine if someone else
answers the question, too. I want this information because I am trying to
write a driver for a camera, as a summer project (specifically for the
lots of cameras which call themselves USB vendor:product 0x2770:0x9120 and
belong to Class ff, Subclass ff, Protocol ff.
These are some really cheap cameras (352x288 max resolution) so I took
it on as a summer project, to learn how they work and to write a driver.

My question is sufficiently on topic that I feel comfortable asking it
from the sane-devel mailing list. Perhaps the gphoto-devel list would be a
more appropriate place to ask, but I am sorry to say that the gphoto-devel
mailing list seems unable to add me as a subscriber in spite of my
attempts, over the past several weeks, to subscribe to it.

My question:

What are "gamma" and "bayer" and where can I find some literature to read
up on such topics?

I ask this because I am at this point able to get a picture out of the
camera by the very primitive procedure of editing a debug log file. I know
that both the Windows driver and the gphoto camlib program which I have
written give identical data output. But

a. the actual output is exactly one byte per pixel, and saving it as a
"raw" file leads nowhere except to error messages when one tries to open
them.

b. The log output for one picture is much larger (because of whitespace),
and putting a BMP or a PPM header on it actually turns the log output
(after suitable editing to remove everything but the actual data) into a
picture which roughly approximates the actual picture taken but is of
quite low quality.

So I suspect that some kind of interpolation routine is going on, in order
to fill up the whitespace. The point is, what kind of interpolation? What
different kinds are there? And how are they implemented?

One can obviously confront similar problems when dealing with scanner
output, and my questions relate to basic techniques in video imaging.
Therefore, on the grounds that I do subscribe to the sane-devel
list and am apparently unable to subscribe to the gphoto-devel list in
spite of strenuous efforts to do so, I ask about the problems here,
instead.

I hope, as I said already, that these questions are considered of general
interest. I would welcome any information, explanations, or references for
reading about the relevant topics. I don't seem to find very much about
this with Google, or perhaps I don't know exactly what to search for, so
even the right words for a search would help, I think.

Thank you very much,

Theodore Kilgore