Image quality improvement method and optical navigation device
By classifying and adjusting the brightness value of the abnormal data unit sensed by the optical mouse image sensor, the impact of fixed patterns on image quality and optical navigation is solved, and higher image quality and navigation accuracy are achieved.
Patent Information
- Application Number
- CN202111186486.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2021-05-05
- Filing Date
- 2021-10-12
- Publication Date
- 2025-08-29
- Estimated Expiration
- 2041-10-12
AI Technical Summary
Fixed patterns on the glass surface of existing optical mice affect image quality and the accuracy of optical navigation, resulting in inaccurate movement sensing.
The image sensor senses the brightness value and classification parameters of the data unit, distinguishes between normal and abnormal data units, and adjusts the brightness value of the abnormal data unit to reduce the difference, and calculates the movement of the optical navigation device.
It effectively reduces the impact of fixed patterns, improves image quality and optical navigation accuracy.
Smart Images

Figure CN115309275B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to an image quality improvement method and an optical navigation device, and more particularly to an image quality improvement method and an optical navigation device for reducing interference caused by fixed patterns. Background Art
[0002] Conventional optical mice typically have a glass surface underneath to protect the image sensor from damage and contamination by dirt and dust. The glass surface may have a fixed pattern, such as one caused by scratches or dirt. However, if the fixed pattern is too noticeable, it may affect the optical mouse's motion sensing. Summary of the Invention
[0003] An object of the present invention is to disclose a method for improving image quality, which can reduce the influence of fixed patterns.
[0004] Another object of the present invention is to disclose an optical navigation method that can reduce the influence of fixed patterns.
[0005] An embodiment of the present invention discloses a method for improving image quality, comprising: (a) classifying a data unit in a target image into a normal data unit and an abnormal data unit based on a relationship between the brightness value of the data unit and a classification parameter, wherein the classification parameter is related to the image quality of the target image or the brightness value of the data unit; and (b) adjusting the brightness value of the abnormal data unit according to an adjustment parameter to generate an adjusted brightness value, thereby reducing the difference between the adjusted brightness value and the brightness value of the normal data unit.
[0006] Another embodiment of the present invention discloses an optical navigation method for use in an optical navigation device including an image sensor, comprising: (a) obtaining a sensing image through the image sensor; (b) classifying the data units in the sensing image into normal data units and abnormal data units based on a relationship between the brightness values of the data units and a classification parameter, wherein the classification parameter is related to the image quality of the sensing image or the brightness value of the data unit; (c) adjusting the brightness value of the abnormal data unit according to an adjustment parameter to generate an adjusted brightness value, such that the difference between the adjusted brightness value and the brightness value of the normal data unit is reduced; and (d) calculating the movement of the optical navigation device based on the adjusted brightness value and the brightness value of the normal data unit.
[0007] According to the aforementioned embodiment, the influence of the fixed pattern of the cover on the optical navigation device can be reduced, and according to the aforementioned embodiment, the image quality can also be improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0008] Figure 1FIG. 4 is a block diagram of an optical navigation device using an optical navigation method according to an embodiment of the present invention.
[0009] Figure 2 FIG. 4 is a flow chart of an optical navigation method according to an embodiment of the present invention.
[0010] Figure 3 Draws Figure 2 A flow chart of a practical example of the optical navigation method is shown.
[0011] Figure 4 、 Figure 5 、 Figure 6 、 Figure 7 Draws Figure 3 A schematic diagram of a practical example of the flowchart shown.
[0012] The description of the accompanying drawings is as follows:
[0013] 100 optical navigation device
[0014] 101 processing circuit
[0015] 103 storage device
[0016] 105 image sensor
[0017] 107 light sources
[0018] 109 cover
[0019] Steps 201-207, 301-313
[0020] AB(x,y) abnormal data unit
[0021] ABP abnormal part
[0022] D(x, y) sensing image
[0023] NP normal part
[0024] N(x, y) normal data units
[0025] F(x,y) image after adjustment DETAILED DESCRIPTION
[0026] The present invention will be described below using multiple embodiments. Please note that the components in each embodiment may be implemented via hardware (e.g., a device or circuit) or firmware (e.g., at least one program written into a microprocessor). Furthermore, the terms "first," "second," and similar terms in the following description are used solely to define different components, parameters, data, signals, or steps. They are not intended to limit the order in which they are presented.
[0027] Figure 1FIG. 1 shows a block diagram of an optical navigation device 100 using an optical navigation method according to an embodiment of the present invention. Figure 1 In the embodiment, the optical navigation device 100 is an optical mouse, but is not limited thereto. The optical navigation device 100 may be any other optical navigation device, such as an optical touch panel. In addition, the arrangement of the components of the optical navigation device 100 is not limited to Figure 1 The embodiment shown.
[0028] like Figure 1 As shown, the optical navigation device 100 includes a processing circuit 101, a storage device 103, an image sensor 105, a light source 107, and a cover 109. The light source 107 is configured to emit light. The image sensor 105 is configured to sense an image generated based on the light from the light source 107. For example, the light source 107 transmits light through the cover 109 onto a surface (e.g., a desktop) on which the optical navigation device 100 is located, and the image sensor 105 senses an image based on the light reflected from the surface after passing through the cover 109. The storage device 103 is configured to store at least one program. When the processing circuit 101 executes the stored program, an optical navigation method can be performed, which will be described in detail later.
[0029] Figure 2 A flow chart of an optical navigation method according to an embodiment of the present invention is shown, which can be executed by the optical navigation device 100. The optical navigation method includes the following steps:
[0030] Step 201
[0031] The image sensor 105 obtains a sensed image.
[0032] Step 203
[0033] The processing circuit 101 classifies the data units of the sensed image into normal data units and abnormal data units according to the relationship between the brightness value of the data units and the classification parameters. Figure 1 The cover 109 in the sensing image may sense an abnormal data unit if the cover 109 has a fixed pattern.
[0034] The classification parameter is related to the image quality of the sensed image or the brightness value of the data unit. Each data unit includes at least one pixel. For ease of explanation, in the following embodiments, each data unit includes only one pixel.
[0035] Step 205
[0036] The processing circuit 101 adjusts the brightness value of the abnormal data unit according to the adjustment parameter to generate an adjusted brightness value, so as to reduce the difference between the adjusted brightness value and the brightness value of the normal data unit.
[0037] Step 207
[0038] The processing circuit 101 calculates the motion of the optical navigation device 100 based on the adjusted brightness value and the brightness value of the normal data unit. Specifically, the processing circuit 101 calculates the motion of the optical navigation device 100 based on the continuous adjusted images having the adjusted brightness value and the brightness value of the normal data unit.
[0039] Figure 3 Draws Figure 2 The flowchart of a practical example of the optical navigation method is shown. Note that Figure 3 It is just an example, and any steps that can achieve the same function should also fall within the scope of the present invention. In addition, the scope of the present invention is not limited to Figure 3 Numbers shown.
[0040] Figure 3 The flowchart in includes the following steps:
[0041] Step 301 (an example of step 201)
[0042] The processing circuit 101 obtains a sensing image D(x, y) through the image sensor 105 .
[0043] The sensed image D(x, y) may be a raw image sensed by the image sensor 105. Alternatively, the sensed image D(x, y) may be an image generated by processing the raw image through the image sensor 105. For example, the sensed image D(x, y) may be an image generated by filtering the raw image.
[0044] As described above, since the image sensor 105 Figure 1 The cover 109 in the image senses an image. If the cover 109 has a fixed pattern, such as dirt or scratches, the sensed image may contain abnormal data units.
[0045] Step 303 (an example of step 203)
[0046] The processing circuit 101 obtains a classification parameter M_TH. As described above, the classification parameter is related to the image quality of the sensed image D(x, y) or the brightness values of the data units of the sensed image D(x, y). In one embodiment, the classification parameter M_TH is determined by the median of the brightness values of the data units of the sensed image D(x, y). For example, the classification parameter M_TH is equal to the median. Please note that the brightness value of the sensed image D(x, y) can also be considered as the image quality of the sensed image D(x, y).
[0047] In one embodiment, the classification parameter M_TH is related to the classification parameter M_TH used in the previous process. For example, if the optical navigation device 100 is started and the optical navigation device 100 is started for the first time Figure 2 and Figure 3 If the initial classification parameter M_TH is processed, it will be the median and recorded. The next classification parameter M_TH will be related to the initial classification parameter M_TH. In one embodiment, the classification parameter M_TH is determined by the formula M_TH = (Bm + P * M_pre) / Q, where Bm is the median brightness value of the data units in the sensed image D(x, y), M_pre is the previously recorded classification parameter, and P and Q are positive integers (e.g., 3 or 4).
[0048] Step 305 (an example of step 203)
[0049] The processing circuit 101 classifies the data units of the sensed image D(x,y) into normal data units N(x,y) and abnormal data units AB(x,y) based on the relationship between the brightness values of the data units and the classification parameter M_TH. In one embodiment, if the absolute value of the brightness value of the data unit is lower than the classification parameter M_TH, the data unit is classified as a normal data unit N(x,y), and if the absolute value of the brightness value of the data unit is higher than the classification parameter M_TH, the data unit is classified as an abnormal data unit AB(x,y).
[0050] Therefore, the method disclosed in the present invention classifies data units with particularly high or low brightness values in the image portion of the sensed image D(x,y) as abnormal data units AB(x,y).
[0051] Step 307
[0052] Processing circuit 101 performs closing processing (morphology) on the abnormal data units AB(x,y). That is, the normal data units N(x,y) between two sets of abnormal data units AB(x,y) are also classified as abnormal data units AB(x,y). This method makes the image formed by the abnormal data units AB(x,y) more complete, and allows subsequent steps to be performed without complex calculations. However, in other embodiments, step 307 may not be included.
[0053] Step 309 (an example of step 205)
[0054] The processing circuit 101 adjusts the brightness value of the abnormal data unit AB(x,y) according to the adjustment parameter to generate an adjusted brightness value.
[0055] In one embodiment, the sensed image D(x, y) is adjusted according to the following formula:
[0056] F(x,y)=D(x,y) if the data unit is a normal data unit N(x,y); otherwise
[0057] F(x,y)=D(x,y) / K
[0058] F(x,y) represents the adjusted image.
[0059] Therefore, the above formula means that the brightness value of the normal data unit N(x,y) in the sensed image D(x,y) remains unchanged, while the brightness value of the abnormal data unit AB(x,y) is divided by K, where K is the adjustment parameter and is a positive number. In this way, the impact of the abnormal data unit AB(x,y) can be reduced.
[0060] In one embodiment, K is related to the number of abnormal data units AB(x,y) or the brightness values of the abnormal data units AB(x,y). For example, if the number of abnormal data units AB(x,y) is large, or the brightness values of the abnormal data units AB(x,y) are particularly high or low, the impact of the abnormal data units AB(x,y) can be reduced by increasing K. Conversely, if the number of abnormal data units AB(x,y) is small, or the brightness values of the abnormal data units AB(x,y) are close to those of the normal data units N(x,y), K can be reduced. Furthermore, in one embodiment, K is changed frame by frame, that is, different Ks correspond to different frames, which can more effectively reduce the impact of the abnormal data units AB(x,y).
[0061] Step 311
[0062] Record the current classification parameter M_TH for use in the next processing. For example, record the current classification parameter M_TH to Figure 1 In the storage device 103.
[0063] Step 313
[0064] An adjusted image F(x,y) is generated, wherein the abnormal data unit AB(x,y) has an adjusted brightness value.
[0065] Figure 4 、 Figure 5 、 Figure 6 、 Figure 7 Draws Figure 3 The flowchart shown is a diagram of a practical example. Please note that Figure 4-Figure 7 Only for Figure 2 and Figure 3 The examples of the steps in the embodiment do not represent any limitation to the present invention.
[0066] exist Figure 4In , a sensing image D(x,y) is acquired, which includes a normal portion NP and an abnormal portion ABP (e.g., an image caused by a scratch). Figure 5 In the example, the data unit of the normal part NP is judged as the normal data unit N(x,y), and the data unit of the abnormal part ABP is judged as the abnormal data unit AB(x,y). Figure 5 It is only used to indicate that the data unit is judged as a normal data unit N(x, y) or an abnormal data unit AB(x, y), and does not mean that the present invention must generate Figure 5 The image shown.
[0067] In addition, Figure 6 In , the abnormal data unit AB(x,y) is closed, so the abnormal data unit AB(x,y) forms a complete area. In addition, Figure 7 In the image F(x,y), an adjusted image F(x,y) is obtained. The abnormal portion ABP of the adjusted image F(x,y) has an adjusted brightness value, and the brightness value of the normal portion NP is the same as that of the normal portion NP in the sensed image D(x,y). This reduces the difference between the brightness value of the normal portion NP in the sensed image D(x,y) and the brightness value of the abnormal portion ABP of the adjusted image F(x,y). Therefore, the influence of the abnormal portion ABP in the image can be reduced.
[0068] Please also understand that the aforementioned embodiments are not limited to use in optical navigation. In this case, such a method would include the aforementioned steps 203 and 205 and could be considered as an image quality improvement method for improving a target image. Specifically, this image quality improvement method includes the following steps: classifying data units of a target image (such as the aforementioned sensed image, but not limited thereto) into normal data units and abnormal data units based on a relationship between the brightness values of the data units and classification parameters. The classification parameters are related to the image quality of the target image or the brightness values of the data units. The brightness values of the abnormal data units are adjusted according to the adjustment parameters to generate adjusted brightness values, so as to reduce the difference between the adjusted brightness values and the brightness values of the normal data units.
[0069] According to the aforementioned embodiment, the influence of the fixed pattern of the cover on the optical navigation device can be reduced, and according to the aforementioned embodiment, the image quality can also be improved.
[0070] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention are intended to be within the scope of protection of the present invention.
Claims
1. A method for improving image quality, used in an optical navigation device including an image sensor, characterized in that: include: (a) classifying a data unit in a target image into a normal data unit and an abnormal data unit according to a relationship between a brightness value of the data unit and a classification parameter, wherein the classification parameter is related to the image quality of the target image or the brightness value of the data unit; as well as (b) adjusting the brightness value of the abnormal data unit according to an adjustment parameter to generate an adjusted brightness value, so as to reduce a difference between the adjusted brightness value and the brightness value of the normal data unit.
2. The image quality improvement method according to claim 1, wherein: The data unit is a pixel, and the brightness value of the data unit is a pixel value.
3. The image quality improvement method according to claim 1, wherein: If the absolute value of the brightness value of the data unit is lower than the classification parameter, step (a) classifies the data unit as the normal data unit; if the absolute value of the brightness value of the data unit is higher than the classification parameter, step (a) classifies the data unit as the abnormal data unit.
4. The image quality improvement method according to claim 1, wherein: The classification parameter is determined according to the median of the brightness value of the data unit.
5. The image quality improvement method according to claim 4, wherein: The classification parameter is determined according to the formula M_TH=(Bm+P*M_pre) / Q, where M_TH is the classification parameter, Bm is the median of the brightness value of the data unit, M_pre is the previous classification parameter recorded, and P and Q are positive integers.
6. The image quality improvement method according to claim 1, wherein: In step (b), the brightness value of the abnormal data unit is divided by K to adjust the brightness value of the abnormal data unit, where K is the adjustment parameter and is a positive integer.
7. The image quality improvement method according to claim 6, wherein: K is related to the number of the abnormal data units or the brightness value of the abnormal data units.
8. The image quality improvement method according to claim 7, wherein: K changes from frame to frame.
9. An optical navigation method, used in an optical navigation device including an image sensor, comprising: (a) obtaining a sensing image through the image sensor; (b) classifying the data units in the sensed image into normal data units and abnormal data units according to a relationship between the brightness values of the data units and a classification parameter, wherein the classification parameter is related to the image quality of the sensed image or the brightness value of the data units; (c) adjusting the brightness value of the abnormal data unit according to the adjustment parameter to generate an adjusted brightness value, such that a difference between the adjusted brightness value and the brightness value of the normal data unit is reduced; and (d) calculating the movement of the optical navigation device according to the adjusted brightness value and the brightness value of the normal data unit.
10. The optical navigation method according to claim 9, wherein: The data unit is a pixel, and the brightness value of the data unit is a pixel value.
11. The optical navigation method according to claim 9, wherein: If the absolute value of the brightness value of the data unit is lower than the classification parameter, step (a) classifies the data unit as the normal data unit; if the absolute value of the brightness value of the data unit is higher than the classification parameter, step (b) classifies the data unit as the abnormal data unit.
12. The optical navigation method according to claim 9, wherein: The classification parameter is determined according to the median of the brightness value of the data unit.
13. The optical navigation method according to claim 12, wherein: The classification parameter is determined according to the formula M_TH=(Bm+P*M_pre) / Q, where M_TH is the classification parameter, Bm is the median of the brightness value of the data unit, M_pre is the previous classification parameter recorded, and P and Q are positive integers.
14. The optical navigation method according to claim 9, wherein: In step (c), the brightness value of the abnormal data unit is divided by K to adjust the brightness value of the abnormal data unit, where K is the adjustment parameter and is a positive integer.
15. The optical navigation method according to claim 14, wherein: K is related to the number of the abnormal data units or the brightness value of the abnormal data units.
16. The optical navigation method according to claim 15, wherein: K changes from frame to frame.
Citation Information
Patent Citations
Image adjustment method and optical navigator using same
CN103873786A
Work mode control method and optical encoder using the same
TW201715207A