I receive images on the PC from two cameras. The stream is not continuous but takes place at event detection. Therefore, I have to receive around 8-10 image pairs after a particular time. Since I have to process the images, I want to first keep all the images in a large buffer and later process them in a batch. It is also acceptable to keep images in two large buffers (one for each camera). How do I keep these pair of images in one (or two) large buffer(s)? I am implementing this program in C.
Share
Assumeing the following API to get the image:
you could do the following:
This stores your data sequentially:
in the buffer pointed to by
pBuffer.To retrieve a reference to the data describing image N from the buffer
pBufferyou could use the following method:Then to actually get an image you could do like so: