>  So the question: is the app actually supposed to loop-query all
>  available controls and display each of them? Or is an application
>  supposed to use the controls that are known to it, and omit any
>  unknown/private controls? Or am I missing something crucial here?

        printf("controls\n");
        for (i = 0;; i++) {
                memset(&qctrl,0,sizeof(qctrl));
                qctrl.id = V4L2_CID_BASE+i;
                if (-1 == ioctl(fd,VIDIOC_QUERYCTRL,&qctrl))
                        break;
                if (qctrl.flags & V4L2_CTRL_FLAG_DISABLED)
                        continue;
                printf("    VIDIOC_QUERYCTRL(BASE+%d)\n",i);
                print_struct(stderr,desc_v4l2_queryctrl,&qctrl,"",tab);
        }
        for (i = 0;; i++) {
                memset(&qctrl,0,sizeof(qctrl));
                qctrl.id = V4L2_CID_PRIVATE_BASE+i;
                if (-1 == ioctl(fd,VIDIOC_QUERYCTRL,&qctrl))
                        break;
                if (qctrl.flags & V4L2_CTRL_FLAG_DISABLED)
                        continue;
                printf("    VIDIOC_QUERYCTRL(PRIVATE_BASE+%d)\n",i);
                print_struct(stderr,desc_v4l2_queryctrl,&qctrl,"",tab);
        }


  Gerd



--
video4linux-list mailing list
Unsubscribe mailto:video4linux-list-request@;redhat.com?subject=unsubscribe
https://listman.redhat.com/mailman/listinfo/video4linux-list

Reply via email to