Ask Your Question

Access one part of the image

asked 2014-09-23 05:46:04 -0500

Ardui gravatar image

Hi, I'm working on Optical flow LK method and balance strategy using Optical flow. For now I found out the vector length using

float fVmag = sqrt((float)((points[0][i].x-points[1][i].x)*(points[0][i].x-points[1][i].x)+(points[0][i].y-points[1][i].y)*(points[0][i].y-points[0][i].y)));

now I want to access only the vector length that are presented on the left side of the image. I was thinking to use image.cols/2 to split it into two equal parts. But I dont know how to access the data inside that region.

Any help or suggestion will be grateful. Thanks guys.

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2014-09-23 08:15:10 -0500

To copy on half of the image, you could do it like that:

edit flag offensive delete link more


Thanks for your reply. I'll try it now. so do you suggest copy the left section of image and calculate the vector length present in that region separately??

Ardui gravatar imageArdui ( 2014-09-23 08:40:13 -0500 )edit

Question Tools


Asked: 2014-09-23 05:46:04 -0500

Seen: 109 times

Last updated: Sep 23 '14