take pointers. > > > >if (-1 == ioctl(fd, VIDIOCCAPTURE, (int *)&b)) > > > { perror("capture"); close(fd); exit(1);} > > > > > >is called i get: > > > > > >"capture: Invalid argument" > > > > > >but if i run "xawtv" first, i do not get the error, so i obviously not > > >setting something right. > > Set the video window and/or set the framebuffer address (VIDIOCSFBUF or > VIDIOCSWIN). xawtv does this too, so once xawtv's done this, you don't > need to do it anymore. > this is what i did for setting up the VIDIOCSWIN: struct video_clip vcl[10]; struct video_window vw; vw.x=0; vw.y=0; vw.width=640; vw.height=480; vw.chromakey=1; vcl[0].x=0; vcl[0].y=0; vcl[0].width=640; vcl[0].height=480; vw.clips=vcl; vw.clipcount=0; ioctl(fd,VIDIOCSWIN,&vw); and i am still getting the error... thanks,