Logo Search packages:      
Sourcecode: zbar version File versions  Download package

int zbar_video_request_iomode ( zbar_video_t video,
int  iomode 
)

request a preferred I/O mode for debug/testing. You will get errors if the driver does not support the specified mode.

    0 = auto-detect
    1 = force I/O using read()
    2 = force memory mapped I/O using mmap()
    3 = force USERPTR I/O (v4l2 only)
Note:
must be called before zbar_video_open()
Since:
0.7

Definition at line 200 of file video.c.

References ZBAR_ERR_INVALID, and zbar_video_request_iomode().

Referenced by zbar::Video::request_iomode(), zbar_processor_init(), and zbar_video_request_iomode().

{
    if(vdo->intf != VIDEO_INVALID)
        return(err_capture(vdo, SEV_ERROR, ZBAR_ERR_INVALID, __func__,
                         "device already opened, unable to change iomode"));
    if(iomode < 0 || iomode > VIDEO_USERPTR)
        return(err_capture(vdo, SEV_ERROR, ZBAR_ERR_INVALID, __func__,
                         "invalid iomode requested"));
    vdo->iomode = iomode;
    return(0);
}


Generated by  Doxygen 1.6.0   Back to index