Quoting Jose Ignacio Gijón <[EMAIL PROTECTED]>:
> > Also, could you explain what the below is.
> > #define USES_USBVISION_PUTPIXEL 0 /* 0=Fast/oops 1=Slow/secure */
>
> This was taken from the cpia driver, and actually is not used any more,
> the driver still needs a clean up :)
This was taken from ibmcam driver, not from cpia :-)
This symbol originally enabled putting pixels of the image into
framebuffer one by one. This is really slow but allows to add absolutely
bulletproof checks. If during development you happen to write beyond the
frame buffer then expect trouble. The macro checked for that and clamped
the offending value to the nearest good one, and at the same time it
painted the pixel bright red to tell the developer about limit check
being activated.
Normally production versions of video drivers should use faster
access methods. usbvideo module (and header file) export this macro
for convenience of developer. This macro also allows (theoretically)
to access frame buffers of different layouts, not only RGB24 as it
is now.
Dmitri
--
If violence isn't solving your problems, you're not using enough of it.
- Misato Katsuragi
PGP signature