¡@

Home 

c++ Programming Glossary: fd

In C++, How to get MD5 hash of a file?

http://stackoverflow.com/questions/1220046/in-c-how-to-get-md5-hash-of-a-file

the file by its file descriptor unsigned long get_size_by_fd int fd struct stat statbuf if fstat fd statbuf 0 exit 1 return.. by its file descriptor unsigned long get_size_by_fd int fd struct stat statbuf if fstat fd statbuf 0 exit 1 return statbuf.st_size.. long get_size_by_fd int fd struct stat statbuf if fstat fd statbuf 0 exit 1 return statbuf.st_size int main int argc char..

Where is a file mounted?

http://stackoverflow.com/questions/2337139/where-is-a-file-mounted

the file its parent its parent's parent etc. using openat fd .. until I reach one of the etc mtab entries. How do I know..

OneOfAType container — storing one each of a given type in a container — am I off base here?

http://stackoverflow.com/questions/3221501/oneofatype-container-storing-one-each-of-a-given-type-in-a-container-am-i

const More methods here int main Example use FileData fd FileBasicData data fd.Get FileBasicData etc For some reason.. here int main Example use FileData fd FileBasicData data fd.Get FileBasicData etc For some reason though this design feels..

How to get a list of video capture devices (web cameras) on linux ( ubuntu )? (C/C++)

http://stackoverflow.com/questions/4290834/how-to-get-a-list-of-video-capture-devices-web-cameras-on-linux-ubuntu-c

sys ioctl.h #include linux videodev.h int main int fd struct video_capability video_cap struct video_window video_win.. video_window video_win struct video_picture video_pic if fd open dev video0 O_RDONLY 1 perror cam_info Can't open device.. 1 perror cam_info Can't open device return 1 if ioctl fd VIDIOCGCAP video_cap 1 perror cam_info Can't get capabilities..

How to get a list video capture devices NAMES (web cameras) on linux ( ubuntu )? (C/C++)

http://stackoverflow.com/questions/4483366/how-to-get-a-list-video-capture-devices-names-web-cameras-on-linux-ubuntu

sys ioctl.h #include linux videodev.h int main int fd struct video_capability video_cap struct video_window video_win.. video_window video_win struct video_picture video_pic if fd open dev video0 O_RDONLY 1 perror cam_info Can't open device.. 1 perror cam_info Can't open device return 1 if ioctl fd VIDIOCGCAP video_cap 1 perror cam_info Can't get capabilities..

mmap() vs. reading blocks

http://stackoverflow.com/questions/45972/mmap-vs-reading-blocks

const int page_size 0x1000 int off 0 void data int fd open filename.bin O_RDONLY while off file_size data mmap NULL.. while off file_size data mmap NULL page_size PROT_READ 0 fd off do stuff with data munmap data page_size off page_size Clearly..

How to set baud rate to 307200 on Linux?

http://stackoverflow.com/questions/4968529/how-to-set-baud-rate-to-307200-on-linux

rate of a serial port struct termios options tcgetattr fd options cfsetispeed options B115200 cfsetospeed options B115200.. options B115200 cfsetospeed options B115200 tcsetattr fd TCSANOW options This works very well. But know I have to communicate..