Namespaces | |
converters | |
Functions | |
timespec | calc_img_timestamp (const timeval &buffer_time, const time_t &epoch_time_shift_us) |
Calculate image timestamp from buffer time and epoch time shift. In this, the buffer time is first converted into microseconds before the epoch time shift, which is to be given in microseconds is added to it. Afterwards it is split into seconds and nanoseconds for the image timestamp. More... | |
unsigned char | CLIPVALUE (const int &val) |
time_t | get_epoch_time_shift_us () |
Get epoch time shift. More... | |
int | xioctl (int fd, int request, void *arg) |
timespec usb_cam::util::calc_img_timestamp | ( | const timeval & | buffer_time, |
const time_t & | epoch_time_shift_us | ||
) |
Calculate image timestamp from buffer time and epoch time shift. In this, the buffer time is first converted into microseconds before the epoch time shift, which is to be given in microseconds is added to it. Afterwards it is split into seconds and nanoseconds for the image timestamp.
unsigned char usb_cam::util::CLIPVALUE | ( | const int & | val | ) |
time_t usb_cam::util::get_epoch_time_shift_us | ( | ) |
Get epoch time shift.
Run this at start of process to calculate epoch time shift https://stackoverflow.com/questions/10266451/where-does-v4l2-buffer-timestamp-value-starts-counting