US 7835595 B2 Abstract An image processing method for scaling an image from an original resolution to a target resolution is provided. A pixel value P
_{T }of a target pixel point N_{T }in the target resolution is theoretically composed of original pixel values P_{1}-P_{K }of original pixel points N_{1}-N_{K }in the original resolution, wherein K is a positive integer larger than 1. First, theoretical combination ratios R_{1}-R_{K }corresponding to the original pixel points N_{1}-N_{K }are found. Then, the theoretical combination ratios R_{1}-R_{K }are converted to corresponding weights W_{1}-W_{K}, wherein each of the corresponding weights W_{1}-W_{K }is an integer between 1 and 2^{n}, n is an integer, and the sum of the corresponding weights W_{1}-W_{K }is 2^{n}. The original pixel values P_{1}-P_{K }are calculated with the corresponding weights W_{1}-W_{K }using a scaler, to generate the pixel value P_{T }of the target pixel point N_{T }and complete the image processing.Claims(14) 1. An image processing method for scaling an image from an original resolution to a target resolution, wherein a pixel value P
_{T }of a target pixel point N_{T }in the target resolution is theoretically composed of original pixel values P_{1}-P_{K }of original pixel points N_{1}-N_{K }in the original resolution, and K is a positive integer larger than 1, the method comprising:
a computer performing the steps of:
finding theoretical combination ratios R
_{1}-R_{K }corresponding to the original pixel points N_{1}-N_{K};converting the theoretical combination ratios R
_{1}-R_{K }to corresponding weights W_{1}-W_{K}, wherein each of the corresponding weights W_{1}-W_{K }is an integer between 1 and 2^{n}, n is an integer, and the sum of the corresponding weights W_{1}-W_{K }is 2^{n}; andcalculating the original pixel values P
_{1}-P_{K }with the corresponding weights W_{1}-W_{K }using a scaler, to generate the pixel value P_{T }of the target pixel point N_{T }and complete the image processing,wherein converting the theoretical combination ratios R
_{1}-R_{K }to corresponding weights W_{1}-W_{K }further comprise checking a look-up table to obtain the corresponding weights W_{1}-W_{K}, wherein the look-up table has a plurality of table fields, each having a field order, and provides a conversion rule from a value to an integer not larger than 2^{n}, and n is an integer, andwherein checking the look-up table to obtain the corresponding weights W
_{1}-W_{K }further comprise:providing a theoretical combination ratio R
_{K};determining whether the theoretical combination ration R
_{K }being look up is less than a limit value; andsetting the corresponding weight W
_{K }to zero if the theoretical combination ratio R_{K }being looked up is less than the limit value.2. The method as claimed in
_{1}-R_{K }to corresponding weights W_{1}-W_{K }further comprises obtaining the corresponding weight W_{K }by:3. The method as claimed in
_{K }is equal to the field order of a table field of the look-up table if a reference value within the table field of the look-up table exceeds or equals the theoretical combination ratio R_{k}, in which 1≦k≦K.4. The method as claimed in
_{k }is determined to be the field order of a first table field of the look-up table or the field order of a second table field of the look-up table using a half-adjust rounding or a rounding off method when a theoretical combination ratio R_{k }is between a first reference value within the first table field and a second reference value within the second table field, in which 1≦k≦K.5. The method as claimed in
6. The method as claimed in
_{1}-P_{K }with the corresponding weights W_{1}-W_{K }using a scaler to generate the pixel value P_{T }of the target pixel point N_{T }further comprises:
generating the pixel value P
_{T }of the target pixel point N_{T }by:7. A system for scaling an image from an original resolution to a target resolution, wherein a pixel value P
_{T }of a target pixel point N_{T }in the target resolution is theoretically composed of original pixel values P_{1}-P_{K }of original pixel points N_{1}-N_{K }in the original resolution, and K is a positive integer larger than 1, the method comprising:
a microcontroller for generating a look-up table according to the original resolution, wherein the look-up table has a plurality of table fields, each having a field order, and provides a conversion rule from a value to an integer not larger than 2
^{n}, and n is an integer;a memory for providing the original pixel values P
_{1}-P_{K};a table index generator for obtaining from the look-up table corresponding weights W
_{1}-W_{K }according to theoretical combination ratios R_{1}-R_{K }corresponding to the original pixel points N_{1}-N_{K}, wherein each of the corresponding weights W_{1}-W_{K }is an integer between 1 and 2^{n}, and sum of the corresponding weights W_{1}-W_{K }is 2^{n}; anda scaler for generating the pixel value P
_{T }of the target pixel point N_{T }according to the original pixel values P_{1}-P_{K }and the corresponding weights W_{1}-W_{K};wherein the microcontroller find the theoretical combination ratios R
_{1}-R_{K }and the table index generator further determines whether the theoretical combination ratio R_{K }being look up is less than a limit value and sets the corresponding weight W_{K }to zero if the theoretical combination ratio R_{K }being looked up is less than the limit value.8. The system as claimed in
_{T }of the target pixel point N_{T}.9. The system as claimed in
_{K }by the formula:10. The system as claimed in
_{K }is equal to the field order of a table field of the look-up table if a reference value within the table field of the look-up table exceeds or equals the theoretical combination ratio R_{k}, in which 1≦k≦K.11. The method as claimed in
_{k }is determined to be the field order of a first table field of the look-up table or the field order of a second table field of the look-up table using a half-adjust rounding or a rounding off method when a theoretical combination ratio R_{k }is between a first reference value within the first table field and a second reference value within the second table field, in which 1≦k≦K.12. The system as claimed in
13. The system as claimed in
_{T }of the target pixel point N_{T }using the formula:14. The system as claimed in
_{1}-N_{K }are two-dimensional pixel points.Description 1. Field of the Invention The invention relates to image processing, and in particular, to an image processing system and method for scaling or resolution of an image. 2. Description of the Related Art Image and display systems often require image resolution to be scaled up or down to meet various requirements. Images (pixels) resolution may be scaled upward from low resolution to high resolution. Images may also be scaled down when the original resolution is higher than the desired display resolution. When an original image is displayed in a different resolution to form a new image, the changed resolution causes the pixel value of each pixel point in a newly formed image to be formed by more pixel values of original pixel points in the original image with specific theoretical combination ratios applied thereto. For example, if a pixel value of pixel point N A common technique used to scale image resolution is linear interpolation. The linear interpolation utilizes pixel value of each pixel point needed for the new pixel point and its related theoretical combination ratio to generate the new pixel value of a pixel point in the new image resolution. As shown in Scaling an image up or down directly by linear interpolation requires several multiplication and division operations, thus requiring hardware design with sufficient bit number of multipliers and dividers to perform the necessary operations. Typically, as the bit number of multiplier or divider increases, hardware cost and complexity increase accordingly. In this example, if the image is scaled from a resolution with 500 points to another resolution with 300 points, at least nine bits of multiplier/divider in the hardware are required to complete the operations. Once the image is enlarged or becomes a two- or more dimension image, the bit number of multiplier/divider needed for hardware is also increased relatively. Accordingly, hardware costs and the time for operation increase. Thus, a method and system for scaling image resolution with reduced hardware cost and operating time are desired. An exemplary embodiment of a system for scaling an image from an original resolution to a target resolution is provided, wherein a pixel value P The invention also provides an image processing method for scaling an image from an original resolution to a target resolution, wherein a pixel value P The invention can be more fully understood by reading the subsequent detailed description and examples with reference to the accompanying drawings, wherein: The following description is of the best-contemplated mode of carrying out the invention. This description is made for the purpose of illustrating the general principles of the invention and should not be taken in a limiting sense. The scope of the invention is best determined by reference to the appended claims. The invention provides a method and system to convert the theoretical combination ratios R The look-up table T provides a conversion rule from a reference value to an integer not larger than 2 The table index generator An original resolution Q before image scaling and a new resolution P to be scaled are provided to the scaling system As shown in Moreover, reference value U For example, as shown in It should be noted that, in this embodiment, reference values within the table fields are arranged from smallest to largest, thus comparing and finding a reference value closest to the theoretical combination ratio R In addition, if a target pixel value P For example,
As shown in formula (4), pixel value P Similarly, the pixel value P
By checking the look-up table T, since 100 is between U Formula (2) can be represented by formula (5) as:
Again, pixel value P For example, it is assumed that the predetermined value is 16 and the pixel value P
In this example, when checking the table, the theoretical combination ratio corresponding to the pixel point N
In sum, if a pixel value P The invention provides a method using only n bit of multiplier to reduce the bit number of multiplier and remove the divider for operation such that hardware cost and complexity are significantly reduced. In addition, the value of bit number n can be adjusted properly to gain a better performance for the related operations. These benefits will be better observed especially when the image to be scaled is a two- or more dimensional image.
The operations in formula (11), require at least two 9 bits of multipliers/dividers in the hardware. Moreover, these operations are time consuming. In this example, if a 4 bit of multiplier is used, the factor for operation is to be 2 Thus, formula (11) can be represented as:
From formula (11), original 300×300 operations by 9 bit of multiplier are simplified using I Although in the embodiment according to the invention the image is downscaled, it is to be understood that the invention can also be used for up-scaling in other embodiments.
For example, if pixel value P
Similarly, by converting the theoretical combination ratios corresponding to the pixel values P While the invention has been described by way of example and in terms of preferred embodiment, it is to be understood that the invention is not limited thereto. To the contrary, it is intended to cover various modifications and similar arrangements (as would be apparent to the skilled in the art). Therefore, the scope of the appended claims should be accorded the broadest interpretation so as to encompass all such modifications and similar arrangements. Patent Citations
Classifications
Legal Events
Rotate |