CN112785511A - Image anti-aliasing processing method and electrical equipment - Google Patents

Image anti-aliasing processing method and electrical equipment Download PDF

Info

Publication number
CN112785511A
CN112785511A CN202010613931.4A CN202010613931A CN112785511A CN 112785511 A CN112785511 A CN 112785511A CN 202010613931 A CN202010613931 A CN 202010613931A CN 112785511 A CN112785511 A CN 112785511A
Authority
CN
China
Prior art keywords
image
foreground
values
foreground image
background
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.)
Pending
Application number
CN202010613931.4A
Other languages
Chinese (zh)
Inventor
李伟民
谢海军
吴恩豪
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.)
Qingdao Economic And Technology Development District Haier Water Heater Co ltd
Haier Smart Home Co Ltd
Original Assignee
Qingdao Economic And Technology Development District Haier Water Heater Co ltd
Haier Smart Home Co Ltd
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 Qingdao Economic And Technology Development District Haier Water Heater Co ltd, Haier Smart Home Co Ltd filed Critical Qingdao Economic And Technology Development District Haier Water Heater Co ltd
Priority to CN202010613931.4A priority Critical patent/CN112785511A/en
Publication of CN112785511A publication Critical patent/CN112785511A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/70Denoising; Smoothing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/50Image enhancement or restoration using two or more images, e.g. averaging or subtraction

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Image Processing (AREA)

Abstract

The invention discloses an image anti-aliasing processing method and electrical equipment, wherein the image anti-aliasing processing method comprises the following steps: acquiring a foreground image and a background image; respectively determining the weighted value of the RGB numerical value of the foreground image and the weighted value of the RGB numerical value of the background image according to the transparency value of the foreground image; and synthesizing and calculating the foreground image and the background image according to the weight values of the foreground image and the background image to obtain a synthesized image. According to the image anti-aliasing processing method, the target image is preprocessed, the control module only needs to perform synthesis calculation on the foreground image and the background image, the effect of eliminating image edge aliasing can be achieved well, the calculation amount of the control module is reduced remarkably, and the method is also suitable for the low-end control module. The method is applied to the electrical equipment with strict cost control, and the image display quality of the equipment can be improved.

Description

Image anti-aliasing processing method and electrical equipment
Technical Field
The invention belongs to the technical field of image processing, and particularly relates to an image anti-aliasing processing method and electrical equipment adopting the method.
Background
Vision is the most important sense of human perception in the outside world at present, image display is more and more widely applied with the development and innovation of technology, and the requirement of human on the display effect of electronic equipment with an image display function is higher and higher.
In the field of electrical equipment, the display module of the display module is from an LED lamp to a nixie tube and then to an LCD (liquid crystal display) screen, and higher requirements lead to higher and higher quality display effects. Because a more refined display effect needs a control module with stronger performance to process, in the industry of household appliances with strict cost control, the display control is generally realized by using control modules with lower performance, such as a microcontroller, a single chip microcomputer and the like, the corresponding function is simple, the display effect is poorer, and the high cost brought by the high-performance control module is unacceptable for the industry of electrical equipment with no display as the main function.
Therefore, how to improve the display effect of the low-end display control module is a technical problem mainly solved by the invention.
Disclosure of Invention
The invention provides an image anti-aliasing processing method aiming at the technical problem that a processor with lower processing performance cannot process images with higher display precision in the prior art, and can solve the problem.
In order to realize the purpose of the invention, the invention is realized by adopting the following technical scheme:
an image antialiasing processing method comprising:
acquiring a foreground image and a background image;
respectively determining the weighted value of the RGB numerical value of the foreground image and the weighted value of the RGB numerical value of the background image according to the transparency value of the foreground image;
and synthesizing and calculating the foreground image and the background image according to the weight values of the foreground image and the background image to obtain a synthesized image.
Further, the method for determining the weight values of the foreground image and the background image comprises the following steps:
Q1(x,y)=a(x,y)/255;
Q2(x,y)= (255-a(x,y))/255;
wherein, a (x, y) is the transparency value of the foreground image at the pixel point (x, y), Q1(x, y) is the weighted value of the RGB values of the foreground image at the pixel point (x, y), and Q2(x, y) is the weighted value of the RGB values of the background image at the pixel point (x, y).
Further, the RGB values of the composite image are generated by performing linear fitting on the RGB values of the foreground image and their corresponding weight values, and the RGB values of the background image and their corresponding weight values.
Further, the RGB values of the composite image are calculated by:
r(x,y)= r1(x,y)* Q1(x,y)+ r2(x,y) * Q2(x,y);
g(x,y)= g1(x,y)* Q1(x,y)+ g2(x,y) * Q2(x,y);
b(x,y)= b1(x,y)* Q1(x,y)+ b2(x,y) * Q2(x,y);
wherein r1(x, y), g1(x, y), b1(x, y) respectively represent R, G, B values of the foreground image at the pixel point (x, y);
r2(x, y), g2(x, y), b2(x, y) respectively represent R, G, B values of the background image at the pixel point (x, y);
r (x, y), g (x, y), b (x, y) represent R, G, B values at the pixel point (x, y) of the composite image, respectively.
Further, before acquiring the foreground image and the background image, the method further comprises an image preprocessing step:
and respectively carrying out edge smoothing on all the target images to obtain foreground images of all the target images.
The invention also provides an electrical device, comprising:
the storage module stores all foreground images and background images;
the control module is used for acquiring the foreground image and the background image from the storage module, respectively determining the weighted value of the RGB value of the foreground image and the weighted value of the RGB value of the background image according to the transparency value of the foreground image, and carrying out synthesis calculation on the foreground image and the background image according to the weighted values of the foreground image and the background image to obtain a synthesized image;
and the display module is used for receiving the composite image generated by the control module and displaying and outputting the composite image.
Further, the control module determines the weight values of the foreground image and the background image by adopting the following method:
Q1(x,y)=a(x,y)/255;
Q2(x,y)= (255-a(x,y))/255;
wherein, a (x, y) is the transparency value of the foreground image at the pixel point (x, y), Q1(x, y) is the weighted value of the RGB values of the foreground image at the pixel point (x, y), and Q2(x, y) is the weighted value of the RGB values of the background image at the pixel point (x, y).
Further, the control module performs linear fitting once by using the RGB values of the foreground image and the weight values corresponding thereto, and the RGB values of the background image and the weight values corresponding thereto, to generate the composite image.
Further, the control module calculates the RGB values of the synthesized image by the following linear fitting method:
r(x,y)= r1(x,y)* Q1(x,y)+ r2(x,y) * Q2(x,y);
g(x,y)= g1(x,y)* Q1(x,y)+ g2(x,y) * Q2(x,y);
b(x,y)= b1(x,y)* Q1(x,y)+ b2(x,y) * Q2(x,y);
wherein r1(x, y), g1(x, y), b1(x, y) respectively represent R, G, B values of the foreground image at the pixel point (x, y);
r2(x, y), g2(x, y), b2(x, y) respectively represent R, G, B values of the background image at the pixel point (x, y);
r (x, y), g (x, y), b (x, y) represent R, G, B values at the pixel point (x, y) of the composite image, respectively.
Further, the foreground image in the storage module is obtained by performing edge smoothing on the target image, and the edge smoothing is completed by external equipment.
Compared with the prior art, the invention has the advantages and positive effects that: according to the image anti-aliasing processing method, the target image is preprocessed, the control module only needs to perform synthesis calculation on the foreground image and the background image, the effect of eliminating image edge aliasing can be achieved well, the calculation amount of the control module is reduced remarkably, and the method is also suitable for the low-end control module. The method is applied to the electrical equipment with strict cost control, and the image display quality of the equipment can be improved.
Other features and advantages of the present invention will become more apparent from the following detailed description of the invention when taken in conjunction with the accompanying drawings.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
FIG. 1 is a flowchart illustrating an embodiment of an anti-aliasing method for an image according to the present invention;
FIG. 2 is a diagram illustrating the effect of the target image according to the first embodiment;
FIG. 3 is a diagram illustrating the effect of a foreground image in the first embodiment;
FIG. 4 is a diagram illustrating the effect of synthesizing an image according to the first embodiment;
FIG. 5 is a diagram illustrating an effect of another target image according to the first embodiment;
FIG. 6 is an enlarged view of portion A of FIG. 5;
FIG. 7 is an effect diagram of the composite image of FIG. 5;
FIG. 8 is an enlarged view of portion B of FIG. 7;
fig. 9 is a schematic block diagram of an embodiment of an electrical device according to the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail with reference to the accompanying drawings and examples.
It should be noted that in the description of the present invention, the terms of direction or positional relationship indicated by the terms "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc. are based on the directions or positional relationships shown in the drawings, which are merely for convenience of description, and do not indicate or imply that the device or element must have a specific orientation, be constructed and operated in a specific orientation, and thus, should not be construed as limiting the present invention. Furthermore, the terms "first" and "second" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
Example one
In the field of image display processing technology, in order to eliminate the sawtooth effect of an image, a relatively complex algorithm is required, and a processing module with strong performance is correspondingly required to run the algorithm so as to realize the processing of image data. In order to achieve the effect of eliminating image aliasing on a low-end processing module with weak data processing capability and improve the quality of a display picture, the embodiment proposes an image anti-aliasing processing method, as shown in fig. 1, which includes the following steps:
acquiring a foreground image and a background image;
respectively determining the weighted value of the RGB numerical value of the foreground image and the weighted value of the RGB numerical value of the background image according to the transparency value of the foreground image;
and synthesizing and calculating the foreground image and the background image according to the weight values of the foreground image and the background image to obtain a synthesized image.
The control module acquires a foreground image and a background image to be displayed from the storage module, and performs synthesis calculation on the foreground image and the background image to obtain a synthetic image for display output, wherein the effect of the synthetic image is shown in fig. 4. Because the foreground image is finished in processing equipment except the electrical equipment, the control module of the electrical equipment does not need to adopt a complex algorithm to carry out edge smoothing pretreatment.
Before acquiring a foreground image and a background image, performing image preprocessing, namely performing edge smoothing on all target images to obtain a foreground image of the target images, and storing the foreground image in a storage module, wherein one or more background images are stored in the storage module at the same time; the storage module is a functional module with a storage function of the electrical equipment, and the electrical equipment is also provided with a control module which has a basic image processing function and can generate a control instruction to control the electrical equipment to work. The effect of the target image is shown in fig. 2, and the effect of the foreground image after the edge smoothing processing is shown in fig. 3, only the foreground image may be stored in the storage module of the electrical equipment, and the target image may not be stored, so as to save the storage space of the storage module.
The image processing method of the embodiment is particularly suitable for electric equipment which does not take display as a main function, such as a refrigerator which takes refrigeration as a main function, a washing machine which takes clothes treatment as a main function, an air conditioner which takes air conditioning as a main function, a water heater which takes heating water as a main function and the like, and the common point of the equipment is that certain patterns, numbers, characters and the like are displayed for interacting with a user or outputting certain parameter information and the like to the user, the displayed patterns and image contents are limited, the output display image is simple in structure, and generally, a target image is superposed on a background image for display and output. Therefore, in this embodiment, the foreground image of the target image is obtained by performing edge smoothing on all the target images, and only the foreground image and the background image need to be stored in the storage module of the electrical equipment.
The synthesis calculation can be simple image superposition, only the foreground image of the target image needs to be superposed on the background image for display and output, and since the foreground image is subjected to edge smoothing processing, after the foreground image is superposed on the background image, as shown in fig. 4, the edge sawtooth effect of the synthesized image can be obviously eliminated, meanwhile, higher calculation requirements cannot be brought to the control module, and the low-performance control module can also realize the low-performance control module.
The control module needs to select corresponding image output according to the actual working mode and working condition, so that the foreground image and the background image to be displayed are obtained from the storage module according to the preset condition for synthesis calculation.
The image display has a wide application range and is diversified, and for convenience of description, the present embodiment will be described by taking the most common display device, which is an electric device that uses LCD liquid crystal display, as an example.
An LCD liquid crystal screen is a two-dimensional array of pixels, each of which has a controllable gray scale (also called brightness), which can be described by the expression:
Figure DEST_PATH_IMAGE002
wherein, x and y represent coordinates, z represents pixel value, that is, the brightness of a pixel point, for example, a screen with 8 × 8 resolution and 8 bit color depth, the value range of the coordinates is [0,7], and the value range of the pixel value is [0, 255 ].
The color depth of a color screen can reach 16 bits or even 24 bits, the color depth comprises three components of R (red), G (green) and B (blue), the three components are used for expressing the color of a pixel point, in order to express more gorgeous color, an alpha component, namely transparency, is added to some screens, so the color depth of the pixel can reach ARGB8888, namely 32 bits of color depth, wherein the larger the alpha value is, the more opaque the pixel is, when the alpha value is 255, the pixel is completely transparent, when the value is 0, the more transparent the pixel is, when the transparency of one color is larger than the other color, if the two colors are displayed on the same pixel point, the larger the alpha value is, the smaller the coverage value is, and the coverage degree is determined by the alpha value.
Therefore, when the control module performs the synthesis calculation on the foreground image and the background image, in order to further eliminate the aliasing effect at the edge of the foreground image, the foreground image after the edge smoothing processing in this embodiment includes the transparency value and the RGB value of each pixel. That is, the target image does not have transparency information, and after being preprocessed, the transparency value is added to the target image to form a foreground image.
The method of the present embodiment mainly solves the problem of how to make the low-end chip display the anti-aliasing effect, and the anti-aliasing effect should be mixed with the background color, so as to be applied to all images. Therefore, the transparency value is used in the scheme, the value is used for determining the mutual coverage degree of the two superposed images, and the foreground image and the background image can be mixed by using the transparency value in the scheme, so that the anti-aliasing effect is really displayed on the screen.
Preferably, in this embodiment, the control module performs the synthesis calculation according to the transparency value of the foreground image. That is, the RGB values in the synthesized image are obtained by performing linear calculation on the RGB values of the foreground image and the RGB values of the background image at the same position, the weight value of the RGB values of the foreground image is positively correlated with the transparency value of the position, the weight value of the RGB values of the background image is negatively correlated with the transparency value of the position, and the transparency value refers to the transparency value of the foreground image.
The larger the transparency value of the foreground image, the darker, i.e. the more opaque, the color. The larger the weighted value of the RGB value of the corresponding foreground image is, the larger the proportion of the RGB value at the same position of the composite image is, the smaller the proportion of the RGB value of the background image is, and the closer the RGB value at the corresponding position of the composite image is to the RGB value of the foreground image. Conversely, the closer the RGB values of the background image are to the corresponding position of the composite image.
In the foreground image, the transparency value at the edge position is smaller than that at the non-edge position, therefore, in the composite image, the display effect of the foreground image is that the color is gradually transited from the non-edge position to the edge position, and the transition is in a state of fitting with the background color, and the edge sawtooth effect is effectively eliminated from the visual effect of human beings.
And the RGB numerical values of all the pixel points of the synthesized image are calculated and finally displayed on a screen through the coordinates and the RGB numerical values. Preferably, in this embodiment, the method for performing synthesis calculation on the foreground image and the background image includes:
and respectively obtaining the weighted values of the RGB values of the foreground image and the background image.
The RGB numerical value of the synthetic image is generated by performing linear fitting on the RGB numerical value of the foreground image and the corresponding weight value thereof, and the RGB numerical value of the background image and the corresponding weight value thereof.
In the present embodiment, Q1(x, y) = a (x, y)/255 is preferable;
Q2(x,y)= (255-a(x,y))/255;
wherein, a (x, y) is the transparency value of the foreground image at the pixel point (x, y), Q1(x, y) is the weighted value of the RGB values of the foreground image at the pixel point (x, y), and Q2(x, y) is the weighted value of the RGB values of the background image at the pixel point (x, y).
Then, the RGB values of the composite image are:
r(x,y)= r1(x,y)* Q1(x,y)+ r2(x,y) * Q2(x,y);
g(x,y)= g1(x,y)* Q1(x,y)+ g2(x,y) * Q2(x,y);
b(x,y)= b1(x,y)* Q1(x,y)+ b2(x,y) * Q2(x,y);
wherein a (x, y) represents the transparency value of the pixel point of the foreground image at the position (x, y);
r1(x, y), g1(x, y), b1(x, y) respectively represent R, G, B values of the foreground image at the pixel point (x, y);
r2(x, y), g2(x, y), b2(x, y) respectively represent R, G, B values of the background image at the pixel point (x, y);
r (x, y), g (x, y), b (x, y) represent R, G, B values at the pixel point (x, y) of the composite image, respectively.
As can be seen from the above, for a position where the RGB numerical transparency value of the foreground image is zero, the RGB numerical value of the composite image is equal to the RGB numerical value of the background image.
The formula shows that when the transparency value of the foreground image of a certain pixel point is larger, namely more opaque, the RGB value of the synthetic image at the position is calculated to be closer to the RGB value of the foreground image at the position; conversely, the smaller the transparency value, i.e. the more transparent, the closer the RGB values of the composite image at the position are calculated to the RGB values of the background image at the position, so that the color of the foreground image gradually transitions from non-edge to edge and gradually transitions in a state of fitting to the background color.
The image preprocessing step is completed by external equipment, so that a control module of the electrical equipment only needs to perform simple linear calculation on the foreground image and the background image, the requirement on the computing capability of the control module is low, the conventional low-configuration control module can complete the image preprocessing step, and meanwhile, the visual effect of eliminating the image edge sawteeth can be realized.
The edge smoothing (i.e., anti-aliasing algorithm) usually requires morphological processing on a graph to identify the boundary of the graph, and then convolves data at the boundary to gradually diffuse colors, and the anti-aliasing algorithm includes a large amount of data processing, which is difficult to be implemented for low-end chips, but the edge smoothing is a simple process for external devices, for example, a processor with better performance can be used for batch processing through software, or the edge smoothing can be processed through existing image processing software, for example, image processing tools such as currently used photoshop, etc., and an edge smoothing algorithm is built in the edge smoothing tool, so that a target image can be quickly processed into a foreground image. As shown in fig. 2 and 3, fig. 2 is a target image, and fig. 3 is a foreground image, and it can be seen that the edge of the foreground image has a smooth display effect compared with the target image of fig. 2.
In order to facilitate the control module of the electrical equipment to read data, the external equipment stores the foreground image as a binary format file in the storage module. Similarly, the background image can also be saved in the storage module as a binary format file. The control module reads a foreground image and a background image to be displayed from the storage module before outputting the images, and generates a synthetic image after synthetic processing and displays and outputs the synthetic image.
The composite image may be composed of a foreground image and a background image, or may be composed of a plurality of foreground images and a background image, or composed of a foreground image and a plurality of background images, or composed of a plurality of foreground images and a plurality of background images. When a plurality of background images are contained, a splicing mode can be adopted. The foreground image is superimposed over the background image.
The control module acquires one or more foreground images to be displayed and a background image from the storage module to perform synthesis calculation, and when a plurality of acquired foreground images are acquired, nonzero RGB values among the plurality of foreground images are not overlapped. That is, the foreground images do not overlap each other. When the acquired background images are multiple, the non-zero RGB values among the multiple background images are not overlapped. That is, the background images are not superimposed on each other.
As shown in fig. 5-8, fig. 5 and 6 are effect diagrams of target images, and fig. 7 and 8 are effect diagrams of composite images, and it can be seen from the above diagrams that the anti-aliasing effect of the image processed by the image anti-aliasing processing method of the present embodiment is significant, and is very close to the ideal anti-aliasing effect, and at the same time, it is verified that when the background image is a complex image, the anti-aliasing processing can be mixed with background images of various grays, and the data processing amount of the chip in the whole process is small, so that the chip can not only fully function, but also does not occupy excessive resources. The method has good universality, and almost all microcontrollers and single-chip microcomputers can realize the method.
Example two
The present embodiment provides an electrical apparatus, as shown in fig. 9, which includes a control module, a storage module, and a display module, wherein:
all foreground images and background images are stored in the storage module;
the control module acquires a foreground image and a background image from the storage module, respectively determines the weighted values of the RGB values of the foreground image and the weighted values of the RGB values of the background image according to the transparency value of the foreground image, and carries out synthesis calculation on the foreground image and the background image according to the weighted values of the foreground image and the background image to obtain a synthesized image;
and the display module is used for receiving the composite image generated by the control module and displaying and outputting the composite image.
The synthetic calculation of the control module can be simple image superposition, only the foreground image of the target image needs to be superposed on the background image for display and output, and because the foreground image is subjected to edge smoothing processing, after the foreground image is superposed on the background image, the edge sawtooth effect can be obviously eliminated, meanwhile, higher calculation requirements cannot be brought to the control module, and the control module with low performance can also realize the method.
However, such a composite image has a limited effect of removing edge jaggies, and thus cannot achieve an ideal image display effect.
In view of this, in the present embodiment, it is preferable to apply a method of calculating a weight value according to a transparency value of the foreground image in the control module, and performing a synthesis calculation of the foreground image and the background image by using the weight value. The image antialiasing processing method described in the first embodiment may be specifically referred to in the synthesis calculation method, and details of this embodiment are not described herein.
It should be noted that the control module of this embodiment is a microcontroller or a single chip microcomputer. Because the image anti-aliasing processing method adopted by the control module of the embodiment has simple algorithm and good universality, almost all microcontrollers and single-chip microcomputers can realize the method without any requirement on the performance of the control module.
The above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be apparent to those skilled in the art that various changes may be made and equivalents may be substituted for elements thereof; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions.

Claims (10)

1. An image anti-aliasing processing method, comprising:
acquiring a foreground image and a background image;
respectively determining the weighted value of the RGB numerical value of the foreground image and the weighted value of the RGB numerical value of the background image according to the transparency value of the foreground image;
and synthesizing and calculating the foreground image and the background image according to the weight values of the foreground image and the background image to obtain a synthesized image.
2. The image anti-aliasing processing method according to claim 1, wherein the weight values of the foreground image and the background image are determined by:
Q1(x,y)=a(x,y)/255;
Q2(x,y)= (255-a(x,y))/255;
wherein, a (x, y) is the transparency value of the foreground image at the pixel point (x, y), Q1(x, y) is the weighted value of the RGB values of the foreground image at the pixel point (x, y), and Q2(x, y) is the weighted value of the RGB values of the background image at the pixel point (x, y).
3. The method of claim 2, wherein the RGB values of the composite image are generated by performing a linear fit of the RGB values of the foreground image and their corresponding weight values and the RGB values of the background image and their corresponding weight values.
4. The image antialiasing processing method according to claim 3, characterized in that the RGB values of the composite image are calculated by:
r(x,y)= r1(x,y)* Q1(x,y)+ r2(x,y) * Q2(x,y);
g(x,y)= g1(x,y)* Q1(x,y)+ g2(x,y) * Q2(x,y);
b(x,y)= b1(x,y)* Q1(x,y)+ b2(x,y) * Q2(x,y);
wherein r1(x, y), g1(x, y), b1(x, y) respectively represent R, G, B values of the foreground image at the pixel point (x, y);
r2(x, y), g2(x, y), b2(x, y) respectively represent R, G, B values of the background image at the pixel point (x, y);
r (x, y), g (x, y), b (x, y) represent R, G, B values at the pixel point (x, y) of the composite image, respectively.
5. The image antialiasing processing method according to any of claims 1 to 4, characterized by further comprising, before acquiring the foreground image and the background image, an image pre-processing step of:
and respectively carrying out edge smoothing on all the target images to obtain foreground images of all the target images.
6. An electrical device, comprising:
the storage module stores all foreground images and background images;
the control module is used for acquiring the foreground image and the background image from the storage module, respectively determining the weighted value of the RGB value of the foreground image and the weighted value of the RGB value of the background image according to the transparency value of the foreground image, and carrying out synthesis calculation on the foreground image and the background image according to the weighted values of the foreground image and the background image to obtain a synthesized image;
and the display module is used for receiving the composite image generated by the control module and displaying and outputting the composite image.
7. The electrical device of claim 6, wherein the control module determines the weight values of the foreground image and the background image by:
Q1(x,y)=a(x,y)/255;
Q2(x,y)= (255-a(x,y))/255;
wherein, a (x, y) is the transparency value of the foreground image at the pixel point (x, y), Q1(x, y) is the weighted value of the RGB values of the foreground image at the pixel point (x, y), and Q2(x, y) is the weighted value of the RGB values of the background image at the pixel point (x, y).
8. The electrical equipment according to claim 7, wherein the control module performs a linear fitting using the RGB values of the foreground image and their corresponding weight values, and the RGB values of the background image and their corresponding weight values to generate the composite image.
9. The electrical device of claim 8, wherein the control module calculates the RGB values of the composite image using a linear fit method of:
r(x,y)= r1(x,y)* Q1(x,y)+ r2(x,y) * Q2(x,y);
g(x,y)= g1(x,y)* Q1(x,y)+ g2(x,y) * Q2(x,y);
b(x,y)= b1(x,y)* Q1(x,y)+ b2(x,y) * Q2(x,y);
wherein r1(x, y), g1(x, y), b1(x, y) respectively represent R, G, B values of the foreground image at the pixel point (x, y);
r2(x, y), g2(x, y), b2(x, y) respectively represent R, G, B values of the background image at the pixel point (x, y);
r (x, y), g (x, y), b (x, y) represent R, G, B values at the pixel point (x, y) of the composite image, respectively.
10. The electrical equipment according to any one of claims 6 to 9, wherein the foreground image in the storage module is obtained by performing edge smoothing on the target image, and the edge smoothing is performed by an external device.
CN202010613931.4A 2020-06-30 2020-06-30 Image anti-aliasing processing method and electrical equipment Pending CN112785511A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010613931.4A CN112785511A (en) 2020-06-30 2020-06-30 Image anti-aliasing processing method and electrical equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010613931.4A CN112785511A (en) 2020-06-30 2020-06-30 Image anti-aliasing processing method and electrical equipment

Publications (1)

Publication Number Publication Date
CN112785511A true CN112785511A (en) 2021-05-11

Family

ID=75750137

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010613931.4A Pending CN112785511A (en) 2020-06-30 2020-06-30 Image anti-aliasing processing method and electrical equipment

Country Status (1)

Country Link
CN (1) CN112785511A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114067004A (en) * 2021-11-11 2022-02-18 长视科技股份有限公司 Image processing method, image processing device, computer equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103531177A (en) * 2013-10-08 2014-01-22 康佳集团股份有限公司 Anti-aliasing display method and system for dot matrix font library
US20150071531A1 (en) * 2013-09-06 2015-03-12 Imatte, Inc. Conversion of an image to a transparency retaining readability and clarity of detail while automatically maintaining color information of broad areas
CN104715454A (en) * 2013-12-14 2015-06-17 中国航空工业集团公司第六三一研究所 Anti-aliasing graph overlapping algorithm
CN106657813A (en) * 2016-12-08 2017-05-10 苏州长风航空电子有限公司 Implementation method for video superposition algorithm
CN108848325A (en) * 2018-06-26 2018-11-20 蒋大武 A kind of image synthesizing method for scratching picture based on natural image
CN109389558A (en) * 2017-08-03 2019-02-26 广州汽车集团股份有限公司 A kind of method and device for eliminating image border sawtooth
CN111223108A (en) * 2019-12-31 2020-06-02 上海影卓信息科技有限公司 Method and system based on backdrop matting and fusion

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20150071531A1 (en) * 2013-09-06 2015-03-12 Imatte, Inc. Conversion of an image to a transparency retaining readability and clarity of detail while automatically maintaining color information of broad areas
CN103531177A (en) * 2013-10-08 2014-01-22 康佳集团股份有限公司 Anti-aliasing display method and system for dot matrix font library
CN104715454A (en) * 2013-12-14 2015-06-17 中国航空工业集团公司第六三一研究所 Anti-aliasing graph overlapping algorithm
CN106657813A (en) * 2016-12-08 2017-05-10 苏州长风航空电子有限公司 Implementation method for video superposition algorithm
CN109389558A (en) * 2017-08-03 2019-02-26 广州汽车集团股份有限公司 A kind of method and device for eliminating image border sawtooth
CN108848325A (en) * 2018-06-26 2018-11-20 蒋大武 A kind of image synthesizing method for scratching picture based on natural image
CN111223108A (en) * 2019-12-31 2020-06-02 上海影卓信息科技有限公司 Method and system based on backdrop matting and fusion

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114067004A (en) * 2021-11-11 2022-02-18 长视科技股份有限公司 Image processing method, image processing device, computer equipment and storage medium

Similar Documents

Publication Publication Date Title
US11244591B2 (en) Gamma correction method, gamma correction device and gamma correction system
US8199146B2 (en) Processing of computer graphics
WO2008049110A2 (en) Programmable blending in a graphics processing unit
CN108615499A (en) Display optimization and display drive method and device, display device, storage medium
CA2678536A1 (en) Efficient 2-d and 3-d graphics processing
CN110248242B (en) Image processing and live broadcasting method, device, equipment and storage medium
CN108038897A (en) Shadow map generation method and device
CN105574918A (en) Material adding method and apparatus of 3D model, and terminal
CN111292236B (en) Method and computing system for reducing aliasing artifacts in foveal gaze rendering
CN108664454A (en) E-book page display method, device and terminal device
CN106454303B (en) RGBW image processing methods and device
CN102768625B (en) Resurfacing method and device of Windows user interface
CN108230407A (en) A kind for the treatment of method and apparatus of image
CN112419465B (en) Virtual model rendering method and device
JP2002298154A (en) Image processing program, computer readable recording medium with image processing program recorded thereon, program execution device, image processor and image processing method
US9530237B2 (en) Interpolation circuitry and techniques for graphics processing
US8797325B2 (en) Method and system for decomposing complex shapes into curvy RHTs for rasterization
CN114527980A (en) Display rendering method and device, electronic equipment and readable storage medium
CN112785511A (en) Image anti-aliasing processing method and electrical equipment
CN109920381B (en) Method and equipment for adjusting backlight value
KR20240009512A (en) Point-of-view (POV) image warp systems and methods
CN104700788B (en) The drive device and display panel of a kind of display panel
CN112884661A (en) Image processing apparatus, display apparatus, computer-readable storage medium, and image processing method
US20150054843A1 (en) Color-correct alpha blending texture filter and method of use thereof
CN115761100A (en) Scene rendering method and device, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20210511