US9261982B2 - Image adjusting method and optical navigating apparatus utilizing the image adjusting method - Google Patents

Image adjusting method and optical navigating apparatus utilizing the image adjusting method Download PDF

Info

Publication number
US9261982B2
US9261982B2 US13/802,819 US201313802819A US9261982B2 US 9261982 B2 US9261982 B2 US 9261982B2 US 201313802819 A US201313802819 A US 201313802819A US 9261982 B2 US9261982 B2 US 9261982B2
Authority
US
United States
Prior art keywords
brightness value
image
brightness
pixel
current image
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active, expires
Application number
US13/802,819
Other versions
US20140152567A1 (en
Inventor
Tzu-Yu Chen
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Pixart Imaging Inc
Original Assignee
Pixart Imaging Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Pixart Imaging Inc filed Critical Pixart Imaging Inc
Assigned to PIXART IMAGING INC. reassignment PIXART IMAGING INC. ASSIGNMENT OF ASSIGNORS INTEREST (SEE DOCUMENT FOR DETAILS). Assignors: CHEN, TZU-YU
Publication of US20140152567A1 publication Critical patent/US20140152567A1/en
Application granted granted Critical
Publication of US9261982B2 publication Critical patent/US9261982B2/en
Active legal-status Critical Current
Adjusted expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • G06T5/92Dynamic range modification of images or parts thereof based on global image properties
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/03Arrangements for converting the position or the displacement of a member into a coded form
    • G06F3/033Pointing devices displaced or positioned by the user, e.g. mice, trackballs, pens or joysticks; Accessories therefor
    • G06F3/0354Pointing devices displaced or positioned by the user, e.g. mice, trackballs, pens or joysticks; Accessories therefor with detection of 2D relative movements between the device, or an operating part thereof, and a plane or surface, e.g. 2D mice, trackballs, pens or pucks
    • G06F3/03543Mice or pucks
    • G06T5/009

Definitions

  • the present invention relates to an image adjusting method and an optical navigating apparatus utilizing the image adjusting method, and particularly relates to an image adjusting method and an optical navigating apparatus utilizing the image adjusting method, which can perform contrast enhancing according to various brightness information of the image.
  • An optical navigating apparatus such as an optical mouse, utilizes an image sensor to catch continuous images, and then utilizes the features of these images (ex. brightness) to compute displacement of the optical navigating apparatus.
  • the caught images may be affected by some factors such that the images are out of focus or have indefinite features, thus the computing for displacement may have error.
  • the printed circuit board thickness which the image sensor is provided on must be controlled to fall in a predetermined range, or the caught image may be out of focus.
  • the surface that the optical navigating apparatus passes may have no apparent features, such that the image may have indefinite features.
  • one objective of the present invention is to provide an image adjusting method, which utilizes brightness information of an image to determine if a contrast enhancing operation should be performed to an image and the intensity of the contrast enhancing operation.
  • Another objective of the present invention is to provide an optical navigating apparatus utilizing the above-mentioned image adjusting method, which utilizes brightness information of an image to determine if a contrast enhancing operation should be performed to an image and the intensity of the contrast enhancing operation, such that a clearer image can be provided.
  • the optical navigating apparatus can perform a more accurate displacement detecting operation.
  • One embodiment of the present invention discloses a computer readable recording media, having at least one program code recorded thereon, an image adjusting method can be performed when the program code is read and executed.
  • the image adjusting method comprises: catching a current image; computing at least one kind of brightness information of the current image; respectively setting corresponding threshold values to different kinds of the brightness information; and determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value.
  • an optical navigating apparatus which comprises: at least one light source, for emitting light to an object; an image sensor, for catching a current image that is generated via the object and the light; and a displacement detecting module, for computing at least one kind of brightness information of the current image, for respectively setting corresponding threshold values to different kinds of the brightness information, and for determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value.
  • the displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the adjusted image if the displacement detecting module performs the contrast enhancing operation.
  • the displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the current image if the displacement detecting module does not perform the contrast enhancing operation.
  • various kinds of brightness information can be utilized to determine if the image should be adjusted or not.
  • the indefinite feature of the brightness information or the image can be utilized to determine how to adjust the contrast of the image.
  • the optical navigation utilizing the images adjusted by these mechanisms can perform more accurate displacement detecting.
  • FIG. 1 is a schematic diagram illustrating an image adjusting method according to the embodiment of the present invention.
  • FIG. 2 is a detail flow chart for the image adjusting method according to the embodiment of the present invention.
  • FIG. 3 is a schematic diagram illustrating a de-gradient operation according to the embodiment of the present invention.
  • FIG. 4 is a schematic diagram illustrating the image before de-gradient operation.
  • FIG. 5 is a schematic diagram illustrating the image after de-gradient operation.
  • FIG. 6 is a block diagram illustrating an optical navigating apparatus according to one embodiment of the present invention.
  • FIG. 1 is a schematic diagram illustrating an image adjusting method according to the embodiment of the present invention. Please note FIG. 1 only illustrates one example and does not mean to limit the scope of the present invention.
  • an average brightness value AV is computed, which can be the average brightness value for a previous image, or the average brightness value for a current image.
  • a brightness value difference between a pixel to be adjusted brightness value and the average brightness value AV, and the brightness value difference is utilized to adjust the pixel to be adjusted.
  • the brightness value difference between a brightness value for a pixel to be adjusted P 1 and the average brightness value AV is X
  • the pixel to be adjusted P 1 is adjusted to be an adjusted pixel P 1 ′, such that the brightness value difference between the adjusted pixel P 1 ′ and the average brightness value AV is doubled.
  • the adjusted pixel P 1 ′ has a brightness value 2X.
  • the brightness value difference between a brightness value for a pixel to be adjusted P 2 and the average brightness value AV is ⁇ 0.5X
  • the pixel to be adjusted P 2 is also adjusted to be an adjusted pixel P 2 ′, such that the brightness value difference between the adjusted pixel P 2 ′ and the average brightness value AV is doubled.
  • the adjusted pixel P 2 ′ has a brightness value ⁇ X.
  • the brightness difference between the adjusted pixel and the average brightness value AV is not limited to be twice the brightness difference between a brightness value of the pixel to be adjusted and the average brightness value AV.
  • the ratio between these two brightness values can be other values.
  • other brightness information of the image can be utilized to adjust this ratio, and be utilized to determine if the contrast enhancing operation should be performed.
  • FIG. 2 is a detail flow chart for the image adjusting method according to the embodiment of the present invention.
  • FIG. 2 comprises the following steps:
  • the brightness information is compared with these threshold values, and it is determined if the contrast enhancing operation should be performed and if the ratio should be adjusted according to the comparing result.
  • the brightness information includes at least one of the following information: an average brightness value of the current image; a maximum brightness value of the current image; a minimum brightness value of the current image; a brightness range of the current image (i.e. difference between a maximum brightness value and a minimum brightness value of the image); a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value; a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value; and a maximum value of brightness value differences for adjacent pixels of the current image.
  • step 209 Compare the brightness information and the threshold values, and determine if the contrast enhancing operation should be performed according to the comparing result. If yes, go to step 209 , if not, go to step 217 .
  • the determining mechanism can include only one determining mechanism or more than one determining mechanisms. For example, it can be determined if the contrast enhancing operation should be performed or not according to at lease one of: the average brightness value of the image, the maximum brightness value of the image; and the minimum brightness value of the image. Besides, it also can be determined according to a brightness range of the current image. The image is easy to be identified if the brightness range of the current image is large enough, thus no contrast enhancing operation is needed. Additionally, either a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value, or a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value, can be utilized to determine if the contrast enhancing operation should be performed or not.
  • the maximum value of brightness value differences for adjacent pixels of the image can be utilized to determine if the contrast enhancing operation should be performed or not. If the brightness value differences for adjacent pixels are large enough, it means the image is easy to be identified, thus no contrast enhancing operation is needed.
  • the step 209 is utilized to determine the ratio, that is, the K in the step 211 .
  • a value of K is determined by a number that the brightness information is larger than the threshold value. For example, a parameter Cetup that indicates a number that the pixels in the current image are too dark is computed in the step 221 . If the parameter Cetup is larger than the threshold value Upth and K is not larger than the threshold value Kmax, then K is increased. In the step 223 , a parameter Cetdn that indicates a number that the pixels in the current image are too bright is computed. If the parameter Cetdn is larger than the threshold value dnth and K is not 0, then K is decreased.
  • step 225 If both the parameters Cetup and the Cetdn are less than the threshold values, go to step 225 and keeps K.
  • the orders of the steps 221 and 223 can be exchanged. However, please not the steps 221 , 223 and 225 are only for example, but also other mechanisms can also be utilized to set K.
  • Equation (1) P +( P ⁇ avg cur )* K Equation (1)
  • the operation corresponding to Equation (1) includes the following steps: computing a brightness value difference between a pixel to be adjusted brightness value (P) for a pixel to be adjusted in the current image and the average brightness value (avg cur ); and adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information (i.e. determining K).
  • Equation (2) P +( P ⁇ avg pre )* K Equation (2)
  • the operation corresponding to Equation (2) includes the following steps: computing a brightness value difference between a pixel to be adjusted brightness value (P) for a pixel to be adjusted in the current image and the average brightness value (avg pre ); and adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information (i.e. determining K).
  • the average brightness value of the image that is not performed the contrast enhancing operation and which of the image that has been adjusted by the contrast enhancing operation are the same, but it does not mean to limit.
  • Step 213 Determine if the contrast enhancing operation should be performed or not according to the feature caught in the step 213 . For example, if various indefinite features still exist in the image, it means the next image may need contrast enhancing operation. If it is determined that the contrast enhancing operation is needed, back to the step 209 . If not, go to step 217 .
  • Utilize other processes to process the image For example, utilize a normal process having no contrast enhancing operation to catch the image and compute displacement for the optical navigating apparatus, while utilizing the optical navigating apparatus.
  • an image adjusting method can b acquired, which includes the following steps: (a) catch a current image; (b) compute at least one kind of brightness information of the current image; (c) respectively set corresponding threshold values to different kinds of the brightness information; and (d) determine if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value.
  • image adjusting method can be performed via executing program code recorded on a computer readable recording media.
  • FIG. 3 is a schematic diagram illustrating a de-gradient operation according to the embodiment of the present invention.
  • the average brightness value of the image is computed first, and then the average brightness value of each pixel line is compared with which of the adjacent pixel lines, such that a brightness tendency can be acquired.
  • the pixel line 2 is compared with the pixel line 3 and the pixel line 1 .
  • the pixel line 3 is compared with the pixel line 2 and the pixel line 4 .
  • the relations between the average brightness value of each pixel line and which of a previous pixel line or a next pixel line thereof can be acquired, such that the brightness tendency of the image can be acquired as well.
  • the image can be determined that is has a brightness tendency for becoming dark.
  • an incorrect adjusted image may be generated such that the accuracy for displacement computing of the optical navigating apparatus is affected.
  • an average brightness value for a whole image can be acquired, and then each pixel line is compensated (ex. increase or decrease the brightness value) according to the brightness value difference between the average brightness value for the whole image and the average brightness value for each pixel line.
  • the brightness tendency of the image can be computed according to a maximum brightness value or a minimum brightness value for each pixel line. For example, a maximum brightness value of the pixel line 2 is compared with which of the pixel line 3 and which of the pixel line 1 . Alternatively, a maximum brightness value of the pixel line 3 is compared with which of the pixel line 2 and which of the pixel line 4 . In one embodiment, if the brightness tendencies computed according to the average brightness value, the maximum brightness value and the minimum brightness value are different, no de-gradient operation is performed.
  • FIG. 4 is a schematic diagram illustrating the image before de-gradient operation, which corresponds to the embodiment shown in FIG. 3 .
  • the image IM has a brightness tendency that becomes dark up-down.
  • the image IM shown in FIG. 5 has uniform brightness distribution.
  • FIG. 6 is a block diagram illustrating an optical navigating apparatus according to one embodiment of the present invention. Please note the optical navigating apparatus according to the present invention is not limited to have all devices shown in FIG. 6 .
  • the optical navigating apparatus 600 includes a light source 601 (or more than one light sources), an image sensor 603 , and a displacement detecting module 605 .
  • the light source 601 emits light to an object (a surface Sr in this embodiment).
  • the image sensor 603 catches a current image LPA that is generated via the surface Sr and the light.
  • the displacement detecting module 605 computes at least one kind of brightness information of the current image LPA, respectively sets corresponding threshold values to different kinds of the brightness information, and determines if a contrast enhancing operation should be performed to the current image LPA to generate an adjusted image PLPA according to a number that the brightness information is over the threshold value.
  • the displacement detecting module 605 determines if displacement exists between the Surface Sr and the optical navigating apparatus 600 according to the adjusted image PLPA if the displacement detecting module 605 performs the contrast enhancing operation.
  • the displacement detecting module 605 determines if displacement exists between the surface Sr and the optical navigating apparatus 600 according to the current image LPA if the displacement detecting module 605 does not perform the contrast enhancing operation.
  • the displacement detecting module 605 comprises an image signal processing unit 607 , an image signal analyzing unit 609 and a displacement computing unit 611 (but not limited).
  • the image signal processing unit 607 and the image signal analyzing unit 609 respectively receives the current image LPA.
  • the image signal analyzing unit 609 analyzes brightness information of the current image LPA and transmits the brightness information LI to the image signal processing unit 607 .
  • the image signal analyzing unit 609 can analyze several previous images and store the brightness information thereof.
  • the image signal processing unit 607 determines if the contrast enhancing operation should be performed or not according to the brightness information LI.
  • the displacement computing unit 611 determines if displacement exists between the Surface Sr and the optical navigating apparatus 600 and outputs the displacement information MI according to the current image LPA if the image signal processing unit 607 does not perform the contrast enhancing operation. On the contrary, the displacement computing unit 611 determines if displacement exists between the surface Sr and the optical navigating apparatus 600 and outputs the displacement information MI according to the adjusted image PLPA if the image signal processing unit 607 performs the contrast enhancing operation.
  • the displacement information MI is transmitted to the control unit 613 , and then the control units accordingly controls the light source 601 and the image sensor, but not limited.
  • optical navigating apparatus 600 can be acquired according to above-mentioned embodiments, thus it is omitted for brevity here.
  • various kinds of brightness information can be utilized to determine if the image should be adjusted or not.
  • the indefinite feature of the brightness information or the image can be utilized to determine how to adjust the contrast of the image.
  • the optical navigation utilizing the images adjusted by these mechanisms can perform more accurate displacement detecting.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Image Processing (AREA)
  • Studio Devices (AREA)

Abstract

A computer readable recording media, having at least one program code recorded thereon, an image adjusting method can be performed when the program code is read and executed. The image adjusting method comprises: catching a current image; computing at least one kind of brightness information of the current image; respectively setting corresponding threshold values to different kinds of the brightness information; and determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value.

Description

BACKGROUND OF THE INVENTION
1. Field of the Invention
The present invention relates to an image adjusting method and an optical navigating apparatus utilizing the image adjusting method, and particularly relates to an image adjusting method and an optical navigating apparatus utilizing the image adjusting method, which can perform contrast enhancing according to various brightness information of the image.
2. Description of the Prior Art
An optical navigating apparatus, such as an optical mouse, utilizes an image sensor to catch continuous images, and then utilizes the features of these images (ex. brightness) to compute displacement of the optical navigating apparatus. However, the caught images may be affected by some factors such that the images are out of focus or have indefinite features, thus the computing for displacement may have error.
For example, the printed circuit board thickness which the image sensor is provided on must be controlled to fall in a predetermined range, or the caught image may be out of focus. Alternatively, the surface that the optical navigating apparatus passes may have no apparent features, such that the image may have indefinite features.
SUMMARY OF THE INVENTION
Therefore, one objective of the present invention is to provide an image adjusting method, which utilizes brightness information of an image to determine if a contrast enhancing operation should be performed to an image and the intensity of the contrast enhancing operation.
Another objective of the present invention is to provide an optical navigating apparatus utilizing the above-mentioned image adjusting method, which utilizes brightness information of an image to determine if a contrast enhancing operation should be performed to an image and the intensity of the contrast enhancing operation, such that a clearer image can be provided. By this way, the optical navigating apparatus can perform a more accurate displacement detecting operation.
One embodiment of the present invention discloses a computer readable recording media, having at least one program code recorded thereon, an image adjusting method can be performed when the program code is read and executed. The image adjusting method comprises: catching a current image; computing at least one kind of brightness information of the current image; respectively setting corresponding threshold values to different kinds of the brightness information; and determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value.
Another embodiment of the present invention discloses an optical navigating apparatus, which comprises: at least one light source, for emitting light to an object; an image sensor, for catching a current image that is generated via the object and the light; and a displacement detecting module, for computing at least one kind of brightness information of the current image, for respectively setting corresponding threshold values to different kinds of the brightness information, and for determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value. The displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the adjusted image if the displacement detecting module performs the contrast enhancing operation. The displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the current image if the displacement detecting module does not perform the contrast enhancing operation.
In view of above-mentioned embodiments, various kinds of brightness information can be utilized to determine if the image should be adjusted or not. Also, the indefinite feature of the brightness information or the image can be utilized to determine how to adjust the contrast of the image. By this way, a more clear image can be acquired, thereby the problem that the image may be out of focus or has indefinite features as described in the prior art can be solved. Also, the optical navigation utilizing the images adjusted by these mechanisms can perform more accurate displacement detecting.
These and other objectives of the present invention will no doubt become obvious to those of ordinary skill in the art after reading the following detailed description of the preferred embodiment that is illustrated in the various figures and drawings.
BRIEF DESCRIPTION OF THE DRAWINGS
FIG. 1 is a schematic diagram illustrating an image adjusting method according to the embodiment of the present invention.
FIG. 2 is a detail flow chart for the image adjusting method according to the embodiment of the present invention.
FIG. 3 is a schematic diagram illustrating a de-gradient operation according to the embodiment of the present invention.
FIG. 4 is a schematic diagram illustrating the image before de-gradient operation.
FIG. 5 is a schematic diagram illustrating the image after de-gradient operation.
FIG. 6 is a block diagram illustrating an optical navigating apparatus according to one embodiment of the present invention.
DETAILED DESCRIPTION
FIG. 1 is a schematic diagram illustrating an image adjusting method according to the embodiment of the present invention. Please note FIG. 1 only illustrates one example and does not mean to limit the scope of the present invention. As shown in FIG. 1, an average brightness value AV is computed, which can be the average brightness value for a previous image, or the average brightness value for a current image. After that, a brightness value difference between a pixel to be adjusted brightness value and the average brightness value AV, and the brightness value difference is utilized to adjust the pixel to be adjusted. For example, it is supposed that the brightness value difference between a brightness value for a pixel to be adjusted P1 and the average brightness value AV is X, and then the pixel to be adjusted P1 is adjusted to be an adjusted pixel P1′, such that the brightness value difference between the adjusted pixel P1′ and the average brightness value AV is doubled. That is, the adjusted pixel P1′ has a brightness value 2X. In another embodiment, the brightness value difference between a brightness value for a pixel to be adjusted P2 and the average brightness value AV is −0.5X, then the pixel to be adjusted P2 is also adjusted to be an adjusted pixel P2′, such that the brightness value difference between the adjusted pixel P2′ and the average brightness value AV is doubled. Therefore, the adjusted pixel P2′ has a brightness value −X. However, the brightness difference between the adjusted pixel and the average brightness value AV is not limited to be twice the brightness difference between a brightness value of the pixel to be adjusted and the average brightness value AV. The ratio between these two brightness values can be other values. Also, other brightness information of the image can be utilized to adjust this ratio, and be utilized to determine if the contrast enhancing operation should be performed.
FIG. 2 is a detail flow chart for the image adjusting method according to the embodiment of the present invention. FIG. 2 comprises the following steps:
Step 201
Set a plurality of parameters, which include various kinds of threshold values. In the following steps, the brightness information is compared with these threshold values, and it is determined if the contrast enhancing operation should be performed and if the ratio should be adjusted according to the comparing result.
Step 203
Catch an image.
Step 205
Compute brightness information for the current image. The brightness information includes at least one of the following information: an average brightness value of the current image; a maximum brightness value of the current image; a minimum brightness value of the current image; a brightness range of the current image (i.e. difference between a maximum brightness value and a minimum brightness value of the image); a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value; a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value; and a maximum value of brightness value differences for adjacent pixels of the current image.
Step 207
Compare the brightness information and the threshold values, and determine if the contrast enhancing operation should be performed according to the comparing result. If yes, go to step 209, if not, go to step 217.
The determining mechanism can include only one determining mechanism or more than one determining mechanisms. For example, it can be determined if the contrast enhancing operation should be performed or not according to at lease one of: the average brightness value of the image, the maximum brightness value of the image; and the minimum brightness value of the image. Besides, it also can be determined according to a brightness range of the current image. The image is easy to be identified if the brightness range of the current image is large enough, thus no contrast enhancing operation is needed. Additionally, either a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value, or a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value, can be utilized to determine if the contrast enhancing operation should be performed or not. If these two pixel numbers are large, it may indicate that the image is too dark or too bright, thus the feature for such image still be indefinite even the contrast enhancing operation is performed. Alternatively, the maximum value of brightness value differences for adjacent pixels of the image can be utilized to determine if the contrast enhancing operation should be performed or not. If the brightness value differences for adjacent pixels are large enough, it means the image is easy to be identified, thus no contrast enhancing operation is needed.
Step 209
The step 209 is utilized to determine the ratio, that is, the K in the step 211. In one embodiment, a value of K is determined by a number that the brightness information is larger than the threshold value. For example, a parameter Cetup that indicates a number that the pixels in the current image are too dark is computed in the step 221. If the parameter Cetup is larger than the threshold value Upth and K is not larger than the threshold value Kmax, then K is increased. In the step 223, a parameter Cetdn that indicates a number that the pixels in the current image are too bright is computed. If the parameter Cetdn is larger than the threshold value dnth and K is not 0, then K is decreased. If both the parameters Cetup and the Cetdn are less than the threshold values, go to step 225 and keeps K. The orders of the steps 221 and 223 can be exchanged. However, please not the steps 221, 223 and 225 are only for example, but also other mechanisms can also be utilized to set K.
Step 211
Perform a contrast enhancing operation.
In one embodiment, the following Equation (1) is utilized to perform the contrast enhancing operation:
P′=P+(P−avgcur)*K  Equation (1)
P indicates the pixel to be adjusted brightness value before adjusting, P′ indicates the pixel to be adjusted brightness value after adjusting (i.e. the adjusted pixel), avgcur indicates the average brightness value of the current image, K is relative to the brightness information and is a rational number. The contrast enhancing operation shown in FIG. 1 is an example with K=1. Therefore, the operation corresponding to Equation (1) includes the following steps: computing a brightness value difference between a pixel to be adjusted brightness value (P) for a pixel to be adjusted in the current image and the average brightness value (avgcur); and adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information (i.e. determining K).
In another embodiment, the following Equation (2) is utilized to perform the contrast enhancing operation:
P′=P+(P−avgpre)*K  Equation (2)
P indicates the pixel to be adjusted brightness value before adjusting, P′ indicates the pixel to be adjusted brightness value after adjusting (i.e. the adjusted pixel), avgpre indicates the average brightness value of a previous image, K is relative to the brightness information and is a rational number. The contrast enhancing operation shown in FIG. 1 is an example with K=1. Therefore, the operation corresponding to Equation (2) includes the following steps: computing a brightness value difference between a pixel to be adjusted brightness value (P) for a pixel to be adjusted in the current image and the average brightness value (avgpre); and adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information (i.e. determining K).
In one embodiment, the average brightness value of the image that is not performed the contrast enhancing operation and which of the image that has been adjusted by the contrast enhancing operation are the same, but it does not mean to limit.
Step 213
Catch features for the image that has been adjusted by the contrast enhancing operation (i.e. adjusted image).
Step 215
Determine if the contrast enhancing operation should be performed or not according to the feature caught in the step 213. For example, if various indefinite features still exist in the image, it means the next image may need contrast enhancing operation. If it is determined that the contrast enhancing operation is needed, back to the step 209. If not, go to step 217.
Step 217
Utilize other processes to process the image. For example, utilize a normal process having no contrast enhancing operation to catch the image and compute displacement for the optical navigating apparatus, while utilizing the optical navigating apparatus.
In view of above-mentioned embodiments, an image adjusting method according to one embodiment of the present invention can b acquired, which includes the following steps: (a) catch a current image; (b) compute at least one kind of brightness information of the current image; (c) respectively set corresponding threshold values to different kinds of the brightness information; and (d) determine if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value. Such image adjusting method can be performed via executing program code recorded on a computer readable recording media.
Before computing the brightness information, a de-gradient operation can be performed to make the brightness distribution for the image more uniform. FIG. 3 is a schematic diagram illustrating a de-gradient operation according to the embodiment of the present invention. In this embodiment, the average brightness value of the image is computed first, and then the average brightness value of each pixel line is compared with which of the adjacent pixel lines, such that a brightness tendency can be acquired. For example, the pixel line 2 is compared with the pixel line 3 and the pixel line 1. Alternatively, the pixel line 3 is compared with the pixel line 2 and the pixel line 4. By this way, the relations between the average brightness value of each pixel line and which of a previous pixel line or a next pixel line thereof can be acquired, such that the brightness tendency of the image can be acquired as well. In the example of FIG. 3, the image can be determined that is has a brightness tendency for becoming dark. In such case, if the contrast enhancing operation is performed without the de-gradient operation, an incorrect adjusted image may be generated such that the accuracy for displacement computing of the optical navigating apparatus is affected.
Many methods can be applied to perform the de-gradient operation. In one example, an average brightness value for a whole image can be acquired, and then each pixel line is compensated (ex. increase or decrease the brightness value) according to the brightness value difference between the average brightness value for the whole image and the average brightness value for each pixel line. Besides the average brightness value for each pixel line, the brightness tendency of the image can be computed according to a maximum brightness value or a minimum brightness value for each pixel line. For example, a maximum brightness value of the pixel line 2 is compared with which of the pixel line 3 and which of the pixel line 1. Alternatively, a maximum brightness value of the pixel line 3 is compared with which of the pixel line 2 and which of the pixel line 4. In one embodiment, if the brightness tendencies computed according to the average brightness value, the maximum brightness value and the minimum brightness value are different, no de-gradient operation is performed.
FIG. 4 is a schematic diagram illustrating the image before de-gradient operation, which corresponds to the embodiment shown in FIG. 3. As shown in FIG. 4, the image IM has a brightness tendency that becomes dark up-down. After the de-gradient operation, the image IM shown in FIG. 5 has uniform brightness distribution.
FIG. 6 is a block diagram illustrating an optical navigating apparatus according to one embodiment of the present invention. Please note the optical navigating apparatus according to the present invention is not limited to have all devices shown in FIG. 6. As shown in FIG. 6, the optical navigating apparatus 600 includes a light source 601 (or more than one light sources), an image sensor 603, and a displacement detecting module 605. The light source 601 emits light to an object (a surface Sr in this embodiment). The image sensor 603 catches a current image LPA that is generated via the surface Sr and the light. The displacement detecting module 605 computes at least one kind of brightness information of the current image LPA, respectively sets corresponding threshold values to different kinds of the brightness information, and determines if a contrast enhancing operation should be performed to the current image LPA to generate an adjusted image PLPA according to a number that the brightness information is over the threshold value. The displacement detecting module 605 determines if displacement exists between the Surface Sr and the optical navigating apparatus 600 according to the adjusted image PLPA if the displacement detecting module 605 performs the contrast enhancing operation. The displacement detecting module 605 determines if displacement exists between the surface Sr and the optical navigating apparatus 600 according to the current image LPA if the displacement detecting module 605 does not perform the contrast enhancing operation.
In one embodiment, the displacement detecting module 605 comprises an image signal processing unit 607, an image signal analyzing unit 609 and a displacement computing unit 611 (but not limited). The image signal processing unit 607 and the image signal analyzing unit 609 respectively receives the current image LPA. The image signal analyzing unit 609 analyzes brightness information of the current image LPA and transmits the brightness information LI to the image signal processing unit 607. Also, the image signal analyzing unit 609 can analyze several previous images and store the brightness information thereof. The image signal processing unit 607 determines if the contrast enhancing operation should be performed or not according to the brightness information LI. The displacement computing unit 611 determines if displacement exists between the Surface Sr and the optical navigating apparatus 600 and outputs the displacement information MI according to the current image LPA if the image signal processing unit 607 does not perform the contrast enhancing operation. On the contrary, the displacement computing unit 611 determines if displacement exists between the surface Sr and the optical navigating apparatus 600 and outputs the displacement information MI according to the adjusted image PLPA if the image signal processing unit 607 performs the contrast enhancing operation. In one embodiment, the displacement information MI is transmitted to the control unit 613, and then the control units accordingly controls the light source 601 and the image sensor, but not limited.
Other detail operations of the optical navigating apparatus 600 can be acquired according to above-mentioned embodiments, thus it is omitted for brevity here.
In view of above-mentioned embodiments, various kinds of brightness information can be utilized to determine if the image should be adjusted or not. Also, the indefinite feature of the brightness information or the image can be utilized to determine how to adjust the contrast of the image. By this way, a more clear image can be acquired, thereby the problem that the image may be out of focus or has indefinite features as described in the prior art can be solved. Also, the optical navigation utilizing the images adjusted by these mechanisms can perform more accurate displacement detecting.
Those skilled in the art will readily observe that numerous modifications and alterations of the device and method may be made while retaining the teachings of the invention. Accordingly, the above disclosure should be construed as limited only by the metes and bounds of the appended claims.

Claims (20)

What is claimed is:
1. A non-transitory computer readable recording medium, having at least one program code recorded thereon, an image adjusting method can be performed when the program code is read and executed, wherein the image adjusting method is applied to an optical navigating apparatus comprising an image sensor and a displacement detecting module, wherein the image adjusting method comprises:
(a) catching a current image via the image sensor;
(b) computing at least one kind of brightness information of the current image via the displacement detecting module;
(c) respectively setting corresponding threshold values to different kinds of the brightness information via the displacement detecting module; and
(d) determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value via the displacement detecting module, and determining a ratio for the contrast enhancing operation according to the number that the brightness information is over the threshold value via the displacement detecting module.
2. The non-transitory computer readable recording medium of claim 1, wherein the brightness information has at least one of following information:
an average brightness value of the current image;
a maximum brightness value of the current image; and
a minimum brightness value of the current image.
3. The non-transitory computer readable recording medium of claim 2, wherein the brightness information comprises at least one kind of information described below:
a brightness range of the current image;
a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value;
a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value; and
a maximum value of brightness value differences for adjacent pixels of the current image.
4. The non-transitory computer readable recording medium of claim 1, wherein the brightness information comprises an average brightness value of the current image, where the contrast enhancing operation comprises:
computing a brightness value difference between a pixel to be adjusted brightness value for a pixel to be adjusted in the current image and the average brightness value; and
adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information.
5. The non-transitory computer readable recording medium of claim 4, wherein the image adjusting method utilizes a following equation to perform the contrast enhancing operation:

P′=P+(P−avgcur)*K
wherein P indicates the pixel to be adjusted brightness value before adjusting, P′ indicates the pixel to be adjusted brightness value after adjusting, avgcur indicates the average brightness value of the current image;
wherein K is relative to the brightness information, is a rational number and is the ratio for the contrast enhancing operation.
6. The non-transitory computer readable recording medium of claim 1, wherein the image adjusting method further comprises computing an average brightness value of a previous image, where the contrast enhancing operation further comprises:
computing a brightness value difference between a pixel to be adjusted brightness value for a pixel to be adjusted in the current image and the average brightness value; and
adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information.
7. The non-transitory computer readable recording medium of claim 6, wherein the image adjusting method utilizes a following equation to perform the contrast enhancing operation:

P′=P+(P−avgpre)*K
wherein P indicates the pixel to be adjusted brightness before adjusting, P′ indicates the pixel to be adjusted brightness after adjusting, avgpre indicates the average brightness value of the previous image
wherein K is relative to the brightness information is a rational number and is the ratio for the contrast enhancing operation.
8. The non-transitory computer readable recording medium of claim 1, wherein the current image and the adjusted image have the same average brightness value.
9. The non-transitory computer readable recording medium of claim 1, wherein the image adjusting method further comprises performs a de-gradient operation to process the current image after the step (a).
10. An optical navigating apparatus, comprising:
at least one light source, for emitting light to an object;
an image sensor, for catching a current image that is generated via the object and the light; and
a displacement detecting module, for computing at least one kind of brightness information of the current image, for respectively setting corresponding threshold values to different kinds of the brightness information, and for determining if a contrast enhancing operation should be performed to the current image to generate an adjusted image according to a number that the brightness information is over the threshold value;
wherein the displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the adjusted image if the displacement detecting module performs the contrast enhancing operation;
wherein the displacement detecting module determines if displacement exists between the object and the optical navigating apparatus according to the current image if the displacement detecting module does not perform the contrast enhancing operation; wherein the displacement detecting module determines a ratio for the contrast enhancing operation according to the number that the brightness information is over the threshold value.
11. The optical navigating apparatus of claim 10, wherein the brightness information has at least one of following information:
an average brightness value of the current image;
a maximum brightness value of the current image; and
a minimum brightness value of the current image.
12. The optical navigating apparatus of claim 11, wherein the brightness information comprises at least one kind of information described below:
a brightness range of the current image;
a pixel number for current image pixels having a brightness value smaller than a minimum brightness threshold value;
a pixel number for current image pixels having a brightness value larger than a maximum brightness threshold value; and
a maximum value of brightness value differences for adjacent pixels of the current image.
13. The optical navigating apparatus of claim 10, wherein the brightness information comprises an average brightness value of the current image, where the contrast enhancing operation comprises:
computing a brightness value difference between a pixel to be adjusted brightness value for a pixel to be adjusted in the current image and the average brightness value; and
adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information.
14. The optical navigating apparatus of claim 13, wherein the displacement detecting module utilizes a following equation to adjust the pixel to be adjusted of the current image to perform the contrast enhancing operation:

P′=P+F(P−avgcur)*K
wherein P indicates the pixel to be adjusted brightness value before adjusting, P′ indicates the pixel to be adjusted brightness value after adjusting, avgcur indicates the average brightness value of the current image;
wherein K is relative to the brightness information, is a rational number and is the ratio for the contrast enhancing operation.
15. The optical navigating apparatus of claim 10, wherein the displacement detecting module further computes an average brightness value of a previous image, where the contrast enhancing operation further comprises:
computing a brightness value difference between a pixel to be adjusted brightness value for a pixel to be adjusted in the current image and the average brightness value; and
adjusting the pixel to be adjusted according to the brightness value difference, the pixel to be adjusted brightness value and the brightness information.
16. The optical navigating apparatus of claim 15, wherein the displacement detecting module utilizes a following equation to adjust the pixel to be adjusted of the current image to perform the contrast enhancing operation:

P′=P+(P−avgpre)*K
wherein P indicates the pixel to be adjusted brightness before adjusting, P′ indicates the pixel to be adjusted brightness after adjusting, avgpre indicates the average brightness value of the previous image;
wherein K is relative to the brightness information, is a rational number and is the ratio for the contrast enhancing operation.
17. The optical navigating apparatus of claim 10, wherein the current image and the adjusted image have the same average brightness value.
18. The optical navigating apparatus of claim 10, wherein the displacement detecting module further performs a de-gradient operation to process the current image after the image sensor catches the current image.
19. The non-transitory computer readable recording medium of claim 1, wherein the ratio for the contrast enhancing operation is related with an enhancing amount of the contrast enhancing operation.
20. The optical navigating apparatus of claim 10, wherein the ratio for the contrast enhancing operation is related with an enhancing amount of the contrast enhancing operation.
US13/802,819 2012-12-04 2013-03-14 Image adjusting method and optical navigating apparatus utilizing the image adjusting method Active 2033-09-07 US9261982B2 (en)

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
TW101145448A 2012-12-04
TW101145448 2012-12-04
TW101145448A TWI472989B (en) 2012-12-04 2012-12-04 Image adjusting method and optical navigating apparatus utlizing the image adjusting method

Publications (2)

Publication Number Publication Date
US20140152567A1 US20140152567A1 (en) 2014-06-05
US9261982B2 true US9261982B2 (en) 2016-02-16

Family

ID=50824941

Family Applications (1)

Application Number Title Priority Date Filing Date
US13/802,819 Active 2033-09-07 US9261982B2 (en) 2012-12-04 2013-03-14 Image adjusting method and optical navigating apparatus utilizing the image adjusting method

Country Status (2)

Country Link
US (1) US9261982B2 (en)
TW (1) TWI472989B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20220358322A1 (en) * 2021-05-05 2022-11-10 Pixart Imaging Inc. Computer readable recording medium which can be used to perform image quality improvement method and optical navigation method

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11216922B2 (en) 2019-12-17 2022-01-04 Capital One Services, Llc Systems and methods for recognition of user-provided images
CN112019763B (en) * 2020-07-31 2021-12-21 广东小天才科技有限公司 A photographing method and terminal device
US11740709B2 (en) * 2021-06-10 2023-08-29 Pixart Imaging Inc. Image quality improving method, optical navigation device control method, and optical navigation device using the methods
CN117611578B (en) * 2024-01-17 2024-06-11 深圳市新良田科技股份有限公司 Image processing method and image processing system

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6175659B1 (en) * 1998-10-06 2001-01-16 Silicon Intergrated Systems Corp. Method and apparatus for image scaling using adaptive edge enhancement
US20040119682A1 (en) * 2002-12-18 2004-06-24 International Business Machines Corporation Self-correcting autonomic mouse
US20040212593A1 (en) * 2003-04-23 2004-10-28 Sunplus Technology Co., Ltd. Optical mechanism of an optical mouse
US20070046829A1 (en) * 2005-08-30 2007-03-01 Jimmy Su Apparatus and method for enhancing image contrast
US20080118176A1 (en) * 2006-11-21 2008-05-22 Wintek Corporation Adjusting apparatus for enhancing the contrast of image and method therefor
US20090033682A1 (en) * 2007-08-03 2009-02-05 Samsung Electronics Co., Ltd. Method and system of immersive generation for two-dimension still image and factor dominating method, image content analysis method and scaling parameter prediction method for generating immersive sensation
US20090102793A1 (en) * 2007-10-22 2009-04-23 Microsoft Corporation Optical mouse
US20110025604A1 (en) * 2009-08-03 2011-02-03 Yuan-Jung Chang System for adjusting a light output of an optical mouse and a mouse thereof
US20120188262A1 (en) * 2011-01-25 2012-07-26 Qualcomm Incorporated Detecting static images and reducing resource usage on an electronic device

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0963111A1 (en) * 1998-06-02 1999-12-08 Deutsche Thomson-Brandt Gmbh Method and apparatus for dynamic contrast improvement in video pictures
JP2001195035A (en) * 2000-01-14 2001-07-19 Fujitsu General Ltd Contrast adjustment circuit
US6826310B2 (en) * 2001-07-06 2004-11-30 Jasc Software, Inc. Automatic contrast enhancement
CN103139598B (en) * 2013-03-14 2014-11-19 天津大学 A method for determining the normalized contrast range that affects stereoscopic image comfort

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6175659B1 (en) * 1998-10-06 2001-01-16 Silicon Intergrated Systems Corp. Method and apparatus for image scaling using adaptive edge enhancement
US20040119682A1 (en) * 2002-12-18 2004-06-24 International Business Machines Corporation Self-correcting autonomic mouse
US20040212593A1 (en) * 2003-04-23 2004-10-28 Sunplus Technology Co., Ltd. Optical mechanism of an optical mouse
US20070046829A1 (en) * 2005-08-30 2007-03-01 Jimmy Su Apparatus and method for enhancing image contrast
US20080118176A1 (en) * 2006-11-21 2008-05-22 Wintek Corporation Adjusting apparatus for enhancing the contrast of image and method therefor
US20090033682A1 (en) * 2007-08-03 2009-02-05 Samsung Electronics Co., Ltd. Method and system of immersive generation for two-dimension still image and factor dominating method, image content analysis method and scaling parameter prediction method for generating immersive sensation
US20090102793A1 (en) * 2007-10-22 2009-04-23 Microsoft Corporation Optical mouse
US20110025604A1 (en) * 2009-08-03 2011-02-03 Yuan-Jung Chang System for adjusting a light output of an optical mouse and a mouse thereof
US20120188262A1 (en) * 2011-01-25 2012-07-26 Qualcomm Incorporated Detecting static images and reducing resource usage on an electronic device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20220358322A1 (en) * 2021-05-05 2022-11-10 Pixart Imaging Inc. Computer readable recording medium which can be used to perform image quality improvement method and optical navigation method
US11734912B2 (en) * 2021-05-05 2023-08-22 Pixart Imaging Inc. Computer readable recording medium which can be used to perform image quality improvement method and optical navigation method

Also Published As

Publication number Publication date
TWI472989B (en) 2015-02-11
TW201423524A (en) 2014-06-16
US20140152567A1 (en) 2014-06-05

Similar Documents

Publication Publication Date Title
US9261982B2 (en) Image adjusting method and optical navigating apparatus utilizing the image adjusting method
US10885626B2 (en) Identifying apparatus, identifying method, and program
CN111742214B (en) Defect type determination method for substrate inspection device and screen printing machine
US9582872B2 (en) Optical film defect detection method and system thereof
US10860901B2 (en) Detection system, information processing apparatus, evaluation method, and program
CN109036265A (en) Optical compensation device applied to display panel and operation method thereof
CN104601899A (en) Image processing apparatus and image processing method
JP2014115264A (en) Three-dimensional shape measuring device and control method therefor
US11354799B2 (en) Image processing for inspecting an inspection target image so that a difference in the difference image greater than a threshold value is reduced
US10359727B2 (en) Image processing apparatus, image processing method, and storage medium, that determine a type of edge pixel
US20170061898A1 (en) Display apparatus and irradiation light controlling method
US9170682B2 (en) Image processing method for optical touch system
US10331244B2 (en) Navagation device with fast frame rate upshift and operating method thereof
US9846816B2 (en) Image segmentation threshold value deciding method, gesture determining method, image sensing system and gesture determining system
CN103873786A (en) Image adjustment method and optical navigator using same
JP6114559B2 (en) Automatic unevenness detector for flat panel display
CN112969289B (en) Feeding fool-proof method for PCB
US20150042761A1 (en) Method, apparatus, and stereo camera for controlling image lightness
US9274614B2 (en) Optical mouse apparatus based on image variation and related method thereof
US20200049825A1 (en) Image noise compensating system, and auto clean machine
JP2017225094A (en) Image reading device and image reading program
US9454242B2 (en) Optical displacement detection apparatus and optical displacement detection method thereof
CN120359742A (en) Method for evaluating lighting settings for vehicle system calibration
US20160364627A1 (en) Image determining method and object coordinate computing apparatus
US9799107B2 (en) Image brightness adjusting method, object tracking method and object tracking apparatus

Legal Events

Date Code Title Description
AS Assignment

Owner name: PIXART IMAGING INC., TAIWAN

Free format text: ASSIGNMENT OF ASSIGNORS INTEREST;ASSIGNOR:CHEN, TZU-YU;REEL/FRAME:029991/0894

Effective date: 20130313

STCF Information on status: patent grant

Free format text: PATENTED CASE

FEPP Fee payment procedure

Free format text: ENTITY STATUS SET TO UNDISCOUNTED (ORIGINAL EVENT CODE: BIG.); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY

MAFP Maintenance fee payment

Free format text: PAYMENT OF MAINTENANCE FEE, 4TH YEAR, LARGE ENTITY (ORIGINAL EVENT CODE: M1551); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY

Year of fee payment: 4

MAFP Maintenance fee payment

Free format text: PAYMENT OF MAINTENANCE FEE, 8TH YEAR, LARGE ENTITY (ORIGINAL EVENT CODE: M1552); ENTITY STATUS OF PATENT OWNER: LARGE ENTITY

Year of fee payment: 8