Results 1 to 4 of 4
hi,everyone i got a troublesome issue.My camera's chip is OV511 and i use some ioctl() Functions to print the following informations about it.such as: type=513,channels=1,maxwidth=640,maxheight:480,min width:64,minheight: 48 brightness=40448,contrast=0,hue=32768 colour=49152,whiteness=26880,depth=12 palette=10 ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
- 04-15-2007 #1
- Join Date
- Apr 2007
problem with USB camera based on Video4Linux
type=513,channels=1,maxwidth=640,maxheight:480,min width:64,minheight: 48
palette=10 /* YUV420 format*/
chromakey=0,clipcount=0,width: 320,height: 240
VID_TYPE_SUBCAPTURE 512 /* Can capture subareas of the image */
i grabbed one frame image successfully by using mmap case and throw it to frambuffer which i'd mmapped.Then this image display on screen immediately but just in black and white colour.All the parameters when calling ioctl() Functions such ioctl(vd->fd, VIDIOCGCAP, &(vd->capability),ioctl(vd->fd, VIDIOCGPICT, &(vd->picture),etc haven't been changed while using the default only.I guess the datas throwed to frambuffer should be conveted into RGB format.if it's true how can i do that?Anyone has some useful Function so i can do it easily? I need you help and i'm appreciate.Thanks a lot.
- 04-16-2007 #2
At first, if I understand your post aright, then you should probabably have better posted this in an application section as the hardware of this peripheral seems to work perfectly.
Where are you using those ioctl functions? I presume in a self-written or modified application program or do those ioctls pop up in a GUI program?
Don't you get that frame as a file onto the disks of your computer where you could apply all sorts of programs to that file containing the frame?Bus Error: Passengers dumped. Hech gap yo'q.
- 04-17-2007 #3
- Join Date
- Apr 2007
Thank you for reply above all,i show those head files in my program.
all ioctl() functions i used is just from above files.After I grabbed one frame image,i can save it into a iamge file or display it directly on screen by frambuffer.But it's just black and white only anyway,that's the point.
Well i'll adopt your suggestion to post in Application section,and thank you again.
- 04-17-2007 #4
I guess when you copy the image file from the camera file system onto your computer's file system and it is already b/w then maybe it's a configuration of the camera itself.
Because a simple file copy is highly unlikely than it changes the contents of the image file.
But if you "grab" as you say the file already with your program then it might copy AND modify it, not at the same time, but in one go, as a sequential process. In that case one of your arguments in one of those ioctl calls might not be the right one.Bus Error: Passengers dumped. Hech gap yo'q.