Patent ID: 8300888
Filing Date: 2012-10-30
Classification: G06F,G06T

Abstract:
1. An image displacement detection method, comprising the following steps: (A) capturing an image by an sensor of an optical mouse; (B) determining if a first frame exists, if so, storing the image of the step (A) as a second frame, and entering the step (C) for next execution; if not, storing the image of the step (A) as a first frame, and then returning to the step (A); (C) determining if a previous image displacement vector exists, if so, entering the step (D); if not, executing the following steps: (D) determining if an X-axis displacement of the previous image displacement vector is smaller than or equal to a maximum displacement on X-axis, and if a Y-axis displacement of the previous image displacement vector is smaller than or equal to a maximum displacement on Y-axis, if so, entering the step (E1) for next execution, if not, entering the step (F1) for next execution; (E1) using the center position of the first frame as a starting point to determine the center position of the M*M image matching reference block with an inversed direction displacement of the previous image displacement vector; (E2) proceeding the search and matching on the second frame so as to find the best matched or the same subblock with the image matching reference block in the second frame; (E3) calculating to obtain the current image displacement vector based on the position of the subblock located in the second frame and the position of the image matching reference block located in the first frame, and then returning to the step (A); (F1) if the X-axis displacement of the previous image displacement vector is larger than the maximum displacement on X-axis, the X-axis displacement will be configured to be equal to the maximum displacement on X-axis; and if the Y-axis displacement of the previous image displacement vector is larger than the maximum displacement on Y-axis, the Y-axis displacement will be configured to be equal to the maximum displacement on Y-axis; (F2) employing the center position of the first frame as the starting point, and determining the center position of the M*M image matching reference block with the inversed direction displacement of the previous image displacement vector completed in the step (F1); (F3) proceeding the search and matching on the second frame so as to find the best matched or the same subblock with the image matching reference block in the second frame; (F4) calculating to obtain the current image displacement vector based on the position of the subblock located in the second frame and the position of the image matching reference block located in the first frame, and then returning to the step (A); wherein the current image displacement vector is successive in time to the previous image displacement vector.