CN110880164B - Image processing method, device, equipment and computer storage medium - Google Patents

Image processing method, device, equipment and computer storage medium Download PDF

Info

Publication number
CN110880164B
CN110880164B CN201811039845.6A CN201811039845A CN110880164B CN 110880164 B CN110880164 B CN 110880164B CN 201811039845 A CN201811039845 A CN 201811039845A CN 110880164 B CN110880164 B CN 110880164B
Authority
CN
China
Prior art keywords
image
color
value
target
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.)
Active
Application number
CN201811039845.6A
Other languages
Chinese (zh)
Other versions
CN110880164A (en
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.)
ZTE Corp
Original Assignee
ZTE Corp
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 ZTE Corp filed Critical ZTE Corp
Priority to CN201811039845.6A priority Critical patent/CN110880164B/en
Publication of CN110880164A publication Critical patent/CN110880164A/en
Application granted granted Critical
Publication of CN110880164B publication Critical patent/CN110880164B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/90Dynamic range modification of images or parts thereof
    • 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
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/20Special algorithmic details
    • G06T2207/20024Filtering details
    • G06T2207/20032Median filtering

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 processing method, which comprises the following steps: generating a first image and a second image based on an object to be displayed, wherein the first image comprises: the target having a first color; the second image includes: the target having a second color; generating a third image in combination with the first image and the background image, wherein in the third image, the target with the first color is reserved at least in a region with a color difference with the background image being above a preset threshold value; generating a fourth image in combination with the second image and the background image, wherein in the fourth image, image elements of the background image appear in areas other than the target having the second color; and superposing the third image on the fourth image to generate an output image. The invention also discloses an image processing device.

Description

Image processing method, device, equipment and computer storage medium
Technical Field
The present invention relates to the field of image processing technologies, and in particular, to an image processing method, apparatus, device, and computer storage medium.
Background
At present, people commonly use electronic screen devices such as computers, mobile phones and movable tablets to read characters, and some pictures are set as display backgrounds when reading common characters according to the demands of users such as individuality or visual beautification.
However, the text is displayed superimposed on the background, and the text is usually displayed at a position on the background with similar color, so that the display is unclear.
Disclosure of Invention
The embodiment of the invention provides an image processing method and device.
An image processing method, comprising:
generating a first image and a second image based on an object to be displayed, wherein the first image comprises: the target having a first color; the second image includes: the target having a second color.
And generating a third image by combining the first image and the currently displayed background image, wherein in the third image, the target with the first color is reserved at least in a region with the color difference with the background image being above a preset threshold value.
And generating a fourth image by combining the second image and the background image, wherein in the fourth image, image elements of the background image appear in a region except the target with the second color.
And superposing the third image on the fourth image to generate an output image, wherein the output image contains the target with the first color reserved on the third image, and the image elements of the fourth image appear in the area, reserved on the third image, outside the target with the first color.
An image processing apparatus comprising:
a first processing unit, configured to generate a first image and a second image based on an object to be displayed, where the first image includes: the target having a first color; the second image includes: the target having a second color;
a second processing unit, configured to combine the first image and a background image that is currently displayed, and generate a third image, where in the third image, the target having the first color remains at least in a region where a color difference with the background image is above a preset threshold;
a third processing unit configured to combine the second image and the background image to generate a fourth image in which image elements of the background image appear in a region other than the target having the second color;
a fourth processing unit, configured to superimpose the third image on the fourth image to generate an output image, where the output image includes the target with the first color remaining on the third image, and image elements of the fourth image appear in a region other than the target with the first color remaining on the third image.
An image processing apparatus comprising:
a processor and a memory for storing a computer program capable of running on the processor;
wherein the processor is configured to execute the steps of any one of the image processing methods described above when running the computer program.
A computer storage medium, comprising:
a computer program stored thereon, characterized in that the computer program, when executed by a processor, implements the steps of any of the above-mentioned image processing methods.
According to the technical scheme, the area, which is above the threshold value, of the target with the first color and is overlapped on the fourth image is reserved, so that the finally obtained display effect is that the target displays the first color at the part, above the threshold value, of the target with the first color and the color difference of the background image, the rest part of the target displays the second color, the effect of increasing the color difference of the target when the target is displayed on the background image is achieved, different areas of the same target are divided into two different colors according to the threshold value of the color difference to be displayed, the problem that the color of the target display position of a single color is similar to the color of the corresponding position of the background image and cannot be distinguished is avoided, and the visual recognition degree of the target is improved.
Drawings
The drawings generally illustrate by way of example, and not by way of limitation, the various embodiments discussed in the subject.
FIG. 1 is a schematic flow chart of an image processing method according to an embodiment of the invention;
FIG. 2 is a block diagram showing constituent units of an image processing apparatus according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of an original view of a background diagram of an embodiment of the present invention;
FIG. 4 is a schematic diagram showing the effect of displaying white text on the original image of the background image according to an embodiment of the present invention;
FIG. 5 is a schematic diagram showing the effect of black text on the original image of the background image according to an embodiment of the present invention;
FIG. 6 is a schematic diagram showing the effect of binarizing a background image according to an embodiment of the present invention;
FIG. 7 is a diagram showing an optimized display effect according to an embodiment of the present invention;
FIG. 8 is a schematic diagram illustrating the effect of converting a background image into a gray image according to another embodiment of the present invention;
FIG. 9 is a schematic diagram showing an optimized display effect according to another embodiment of the present invention;
fig. 10 is a schematic diagram of a hardware structure of an apparatus according to an embodiment of the present invention.
Detailed Description
For a more complete understanding of the nature and the technical content of the embodiments of the present invention, reference should be made to the following detailed description of embodiments of the invention, taken in conjunction with the accompanying drawings, which are meant to be illustrative only and not limiting of the embodiments of the invention.
An embodiment of the present invention provides an image processing method, as shown in fig. 1, where the method includes:
step 11, generating a first image and a second image based on an object to be displayed, wherein the first image comprises: the target having a first color; the second image includes: the target having a second color.
An image is a visual effect picture that may be composed of multiple layers stacked together in some computer image formats. A layer is also understood to be an image, for example, where an image is made up of 1 layer, the image and layer may be equivalent.
The first color and the second color may include colors that can be identified or set by a display device (e.g., a display, a cell phone display screen, a smart mobile device display screen, an LED electronic presentation device, etc.).
The target to be displayed may refer to a content that may be highlighted at a preset position on the currently displayed background image, including, but not limited to: text, symbols, patterns, icons, or any combination of the above elements, and the like. The background image displayed at present may refer to a desktop background image, an incoming call interface background image, or other operation interface background images currently displayed on a display device (not shown in the drawings), and may of course also be an interface image of an application program, etc.
In one embodiment, generating the first image refers to: generating a layer comprising the target with the first color according to the preset position of the target to be displayed on the background image; generating the second image means: generating a layer comprising the target with the second color according to the preset position of the target to be displayed on the background image. Thus, the position of the object in the first layer is the same as the position in the second layer, but the colors are different. Furthermore, in the first layer, the other pixels are transparent, i.e. content-free, except for the object having the first color. Also in the second layer, the other pixels are transparent, i.e. content-free, except for the object having the second color.
The first color and the second color may be opposite colors to each other, and for example, a Red Green Blue (RGB) color mode, the result of adding the RGB color of the first color to the RGB color of the second color is white (255, 255, 255). In practical applications, a common combination of opposite colors may be selected as the first color and the second color, for example: if the first color is white (255, 255, 255), the second color is black (0, 0); if the first color is red (255, 0), the second color is (0, 255, 255); if the first color is magenta (255, 0, 255), the second color is green (0, 255, 0).
And step 12, combining the first image and the currently displayed background image to generate a third image, wherein in the third image, the target with the first color is reserved at least in a region with the color difference with the background image being above a preset threshold value.
And in the third image, the area except the area where the color difference between the target with the first color and the background image is above a preset threshold value is completely transparent or no other display content is displayed.
And 13, combining the second image and the background image to generate a fourth image, wherein in the fourth image, image elements of the background image appear in a region except the target with the second color.
And 14, superposing the third image on the fourth image to generate an output image, wherein the output image contains the target with the first color reserved on the third image, and the image elements of the fourth image appear in the area, reserved on the third image, outside the target with the first color.
The image display effect is realized in such a way that the image elements of the background image are displayed in the area except the target, the target displays the first color in the area with the color difference between the first color and the background image being above a preset threshold value, and the rest areas of the target display the second color.
In some embodiments, the first color may be black and the second color may be white.
In some embodiments, the target may be text.
The color difference may include a numerical difference between picture pixels in a color mode, where common color modes include: RGB mode, printing color (cyan magenta yellow black, CMYK) mode, color model (Lab) mode, etc. Taking an RGB mode as an example, the color difference between the pixel points can be obtained by comparing the values of the pixel points in the R/G/B color channels, the brightness of the pixel points can be calculated by a brightness general calculation formula, and the direct color difference of the pixel points can be obtained by comparing the brightness of the pixel points.
In one embodiment, the step 12 includes:
performing binarization processing on the background image to obtain a fifth image;
and generating the third image by combining the first image and the fifth image, wherein the target with the first color is reserved at least in a region with the color difference of the fifth image being above a preset threshold value.
In some embodiments, generating the third image in combination with the first image and the fifth image comprises: and masking the first image by using the fifth image to generate the third image.
In some embodiments, when the background image is subjected to binarization processing, parameters such as a binarization radius may be optimized, including: setting a binarization radius according to the line (such as character strokes) width of the target; the minimum/maximum binarization radius is set according to the maximum/minimum width of a target line (e.g., a text stroke). Wherein, the binarized radius refers to that when the binarization process is executed, image optimization processing can be further performed, and the image optimization processing comprises: and (5) denoising the image. For example, in order to avoid that the black-and-white variation of the image pixels is too severe, mean filtering, median filtering, gaussian filtering and other modes are used, noise points with the radius/width smaller than n pixels after binarization are filtered, that is, the areas with severe color variation are filtered, and the noise points are removed; the method can reduce the area with severe brightness change, and make the color transition of the target more natural, thereby making the visual effect better.
In one embodiment, the step 12 includes:
performing gray level transformation on the background image to obtain a sixth image;
the gray scale transformation refers to converting a color image into a gray scale image. The optional gray scale transformation methods include a weighting method, a mean method and a maximum method. Taking the RGB color mode as an example: the weighting method is to calculate the average number of the weighted arithmetic to obtain the GRAY value by the RGB value of each pixel point of the image, and the general formula can be expressed as GRAY= 0.3 x R+0.59 x G+0.11 x B; the mean value method is to calculate the arithmetic mean of RGB values of each pixel point of the image to obtain a GRAY value, and the formula can be expressed as GRAY= = (R+G+B)/3; the maximum value method is to select the maximum value of the RGB values of the pixel point as a gray value, and the formula can be expressed as max (R, G, B).
Determining a transparency value of at least part of pixels in the sixth image according to the gray value of the at least part of pixels;
and generating the third image by combining the first image and the gray value, wherein the target with the first color is reserved at least in a region with the color difference of the sixth image being above a preset threshold value.
The preset threshold, for example, an RGB color mode, may be 255. For example, when the gray value of the sixth image is 255, a region where the gray value of the object having the first color is 0 remains; alternatively, when the gray value of the sixth image is 0, the region having the gray value of 255 of the object of the first color remains.
In some embodiments, the determining the transparency value of at least some pixels in the sixth image according to the gray value of the at least some pixels further includes:
and determining a transparency value of a target pixel according to the gray value of the target pixel in the sixth image, wherein the target pixel is a pixel with the color difference between the gray value and the target with the first color below the preset threshold.
The transparency value is used for representing the transparency of the target pixel. Taking the RGB color mode as an example, the transparency values can be divided into 256 levels, namely 0-255, where 0 is transparent and 255 is opaque. And the range of gray values can also be expressed as 0-255, where black is 0 and white is 255. Thus, as the gray value of a target pixel in the sixth image approaches white, the transparency of the target pixel approaches opacity.
In some embodiments, the combining the first image and the transparency value generates the third image, comprising:
and introducing the transparency value into the first image to generate the third image.
The step of introducing the transparency value into the first image means that the transparency of the first image is determined according to the transparency, for example, the transparency value is substituted into an Alpha channel of the first image. Such that the first color of the region of the first image having the first color that is closer to white in the background image is closer to opaque, and the first color of the region of the first image having the first color that is closer to black in the background image is closer to transparent.
An embodiment of the present invention provides an image processing apparatus 21, as shown in fig. 2, including:
a first processing unit 201, configured to generate a first image and a second image based on an object to be displayed, where the first image includes: the target having a first color; the second image includes: the target having a second color.
A second processing unit 202, configured to combine the first image and a currently displayed background image, and generate a third image, where in the third image, the target having the first color remains at least in a region where a color difference with the background image is above a preset threshold;
a third processing unit 203, configured to combine the second image and the background image, and generate a fourth image, where in the fourth image, image elements of the background image appear in a region other than the target having the second color;
a fourth processing unit 204, configured to superimpose the third image on the fourth image to generate an output image, where the output image includes the target with the first color remaining on the third image, and the image elements of the fourth image appear in a region other than the target with the first color remaining on the third image.
In an embodiment, the second unit 202 is further configured to:
performing binarization processing on the background image to obtain a fifth image;
and generating the third image by combining the first image and the fifth image, wherein the target with the first color is reserved at least in a region with the color difference of the fifth image being above a preset threshold value.
In an embodiment, the second processing unit 202 is further configured to: and masking the first image by using the fifth image to generate the third image.
In an embodiment, the second processing unit 202 is further configured to:
performing gray level transformation on the background image to obtain a sixth image;
determining a transparency value of at least part of pixels in the sixth image according to the gray value of the at least part of pixels;
and generating the third image by combining the first image and the transparency value, wherein the target with the first color is reserved at least in a region with the color difference of the sixth image being above a preset threshold value.
In an embodiment, the second processing unit 202 is further configured to: and determining a transparency value of a target pixel according to the gray value of the target pixel in the sixth image, wherein the target pixel is a pixel with the color difference between the gray value and the target with the first color below the preset threshold.
In an embodiment, the second processing unit 202 is further configured to: and introducing the transparency value into the first image to generate the third image.
The invention is described below by means of a specific example:
the embodiment specifically comprises the following steps:
the first step: the goal is to display text content on a background map and to ensure visual readability.
Fig. 3 is an original view of the background image, fig. 4 is an effect image of white characters displayed on the original view of the background image, and fig. 5 is an effect image of black characters displayed on the original view of the background image. It is very obvious that the text of a single color is displayed on the original image with a part which is difficult to visually recognize.
And a second step of: the whole image content of the background image is binarized, and the effect after binarization is shown in fig. 6, the binarization threshold is set to 160 (160 is the brightness value of the RGB image, the binarization threshold can be adjusted according to the brightness contrast degree of the background image), and the general empirical formula pix_color=red is 0.299+green is 0.587+blue is 0.114.
And a third step of: and performing AND operation with the black text layer image by using the binarized background image as a mask to obtain a black text layer image part with the reserved brightness exceeding a specified threshold.
Fourth step: and displaying the black text layer after masking on the original white text layer to obtain a processed text layer.
Fifth step: and displaying the processed text layer on the original image of the background image to finish the display, wherein the effect is shown in fig. 7.
The invention also provides a specific embodiment, which specifically comprises the following steps:
the effect of converting the background image into a gray image by gray processing is shown in fig. 8.
The background picture converted into the gray picture is used as a transparency mask layer of the black text picture layer, each pixel value of any one color channel of red (R), green (G) and blue (B) of the background picture converted into the gray picture is copied to a transparency (Alpha) channel of the black text picture layer, and the black text picture layer with transparent dark part, opaque bright part and semitransparent middle part can be obtained, namely, the black text picture layer with white background image can be completely displayed, the black text picture layer with black background image can be completely transparent and not displayed.
Then, the processed black text layer is superimposed and displayed on the background image and the white text layer, and the result shown in fig. 9 is obtained, in which the black-and-white variation of the text is not abrupt but continuously gradual.
In one embodiment, when the background image is subjected to gradation processing, contrast adjustment is performed on an intermediate-luminance region, a gray region having a luminance close to white is adjusted to white, a region having a luminance close to black is adjusted to black, and the intermediate-luminance adjustment is adjusted to gray. For example: the gradation value is represented by 0 to 255, the region having a luminance of 170 or more is adjusted to white, the region having a luminance of 85 or less is adjusted to black, and the other region is adjusted to gray of the gradation 127 (only one reference, and the parameter may be actually adjusted according to the luminance change degree of the background picture). Thus, the gray area only retains the text of one color, thereby further clearing the final display result.
In order to implement the image processing method according to the embodiment of the present invention, the embodiment of the present invention further provides an image processing apparatus implemented based on hardware, as shown in fig. 10, an image processing apparatus 610 includes: a processor 61 and a memory 62 for storing a computer program capable of running on the processor, wherein,
the processor 61 is configured to execute, when executing the computer program:
generating a first image and a second image based on an object to be displayed, wherein the first image comprises: the target having a first color; the second image includes: the target having a second color.
And generating a third image by combining the first image and the currently displayed background image, wherein in the third image, the target with the first color is reserved at least in a region with the color difference with the background image being above a preset threshold value.
And generating a fourth image by combining the second image and the background image, wherein in the fourth image, image elements of the background image appear in a region except the target with the second color.
And superposing the third image on the fourth image to generate an output image, wherein the output image contains the target with the first color reserved on the third image, and the image elements of the fourth image appear in the area, reserved on the third image, outside the target with the first color.
In an embodiment, the generating a third image by combining the first image and the currently displayed background image includes:
performing binarization processing on the background image to obtain a fifth image;
and generating the third image by combining the first image and the fifth image, wherein the target with the first color is reserved at least in a region with the color difference of the fifth image being above a preset threshold value.
In an embodiment, the combining the first image and the fifth image to generate the third image includes:
and masking the first image by using the fifth image to generate the third image.
In an embodiment, the combining the first image and the background image generates a third image, including:
performing gray level transformation on the background image to obtain a sixth image;
determining a transparency value of at least part of pixels in the sixth image according to the gray value of the at least part of pixels;
and generating the third image by combining the first image and the transparency value, wherein the target with the first color is reserved at least in a region with the color difference of the sixth image being above a preset threshold value.
In an embodiment, the determining the transparency value of at least part of the pixels in the sixth image according to the gray value of the at least part of the pixels further includes:
and determining a transparency value of a target pixel according to the gray value of the target pixel in the sixth image, wherein the target pixel is a pixel with the color difference between the gray value and the target with the first color below the preset threshold.
In an embodiment, the combining the first image and the transparency value generates the third image, including:
and introducing the transparency value into the first image to generate the third image.
In an embodiment, the color value of the first color is a first value;
the color value of the second color is a second value;
the sum of the first value and the second value is: and the maximum value of the color channel corresponding to the background image.
In one embodiment, the first color is black; the second color is white.
In one embodiment, the target is text.
The image processing apparatus and the image processing method provided in the foregoing embodiments belong to the same concept, and specific implementation processes thereof are detailed in the method embodiments and are not described herein.
Of course, in practical application, as shown in fig. 10, the information push control device may further include at least one communication interface 63. The various components in the image processing device are coupled together by a bus system 64. It is understood that the bus system 64 is used to enable connected communications between these components. The bus system 64 includes a power bus, a control bus, and a status signal bus in addition to the data bus. But for clarity of illustration the various buses are labeled as bus system 64 in fig. 10.
Wherein the communication interface 63 is for interacting with other devices.
Specifically, the processor 61 may send an operation result query request to an application server corresponding to the callee application through the communication interface 63, and obtain an operation result of the callee application sent by the application server.
It will be appreciated that the memory 62 may be volatile memory or nonvolatile memory, and may include both volatile and nonvolatile memory. Wherein the nonvolatile Memory may be Read Only Memory (ROM), programmable Read Only Memory (PROM, programmable Read-Only Memory), erasable programmable Read Only Memory (EPROM, erasable Programmable Read-Only Memory), electrically erasable programmable Read Only Memory (EEPROM, electrically Erasable Programmable Read-Only Memory), magnetic random access Memory (FRAM, ferromagnetic random access Memory), flash Memory (Flash Memory), magnetic surface Memory, optical disk, or compact disk Read Only Memory (CD-ROM, compact Disc Read-Only Memory); the magnetic surface memory may be a disk memory or a tape memory. The volatile memory may be random access memory (RAM, random Access Memory), which acts as external cache memory. By way of example, and not limitation, many forms of RAM are available, such as static random access memory (SRAM, static Random Access Memory), synchronous static random access memory (SSRAM, synchronous Static Random Access Memory), dynamic random access memory (DRAM, dynamic Random Access Memory), synchronous dynamic random access memory (SDRAM, synchronous Dynamic Random Access Memory), double data rate synchronous dynamic random access memory (ddr SDRAM, double Data Rate Synchronous Dynamic Random Access Memory), enhanced synchronous dynamic random access memory (ESDRAM, enhanced Synchronous Dynamic Random Access Memory), synchronous link dynamic random access memory (SLDRAM, syncLink Dynamic Random Access Memory), direct memory bus random access memory (DRRAM, direct Rambus Random Access Memory). The memory 62 described in embodiments of the present invention is intended to comprise, without being limited to, these and any other suitable types of memory.
In an embodiment of the present invention, a computer readable storage medium is further provided, for storing the computer program provided in the foregoing embodiment, to complete the steps of the foregoing method. The computer readable storage medium may be FRAM, ROM, PROM, EPROM, EEPROM, flash Memory, magnetic surface Memory, optical disk, or CD-ROM; but may be various devices including one or any combination of the above memories, such as a mobile phone, a computer, a smart home appliance, a server, etc.
It should be noted that: the technical schemes described in the embodiments of the present invention may be arbitrarily combined without any collision.

Claims (15)

1. An image processing method, comprising:
generating a first image and a second image based on an object to be displayed, wherein the first image comprises: the target having a first color; the second image includes: the target having a second color;
generating a third image by combining the first image and a currently displayed background image, wherein in the third image, the target with the first color is reserved at least in a region with the color difference with the background image being above a preset threshold value;
generating a fourth image by combining the second image and the background image, wherein in the fourth image, image elements of the background image appear in a region other than the target with the second color;
superimposing the third image on the fourth image to generate an output image, wherein the output image contains the target with the first color reserved on the third image, and image elements of the fourth image appear in areas, reserved on the third image, except for the target with the first color;
the color value of the first color is a first value;
the color value of the second color is a second value;
the sum of the first value and the second value is: and the maximum value of the color channel corresponding to the background image.
2. The method of claim 1, wherein the step of determining the position of the substrate comprises,
the step of generating a third image by combining the first image and the currently displayed background image comprises the following steps:
performing binarization processing on the background image to obtain a fifth image;
and generating the third image by combining the first image and the fifth image, wherein the target with the first color is reserved at least in a region with the color difference of the fifth image being above a preset threshold value.
3. The method of claim 2, wherein the step of determining the position of the substrate comprises,
the combining the first image and the fifth image to generate the third image includes:
and masking the first image by using the fifth image to generate the third image.
4. The method of claim 1, wherein the step of determining the position of the substrate comprises,
the combining the first image and the background image generates a third image, including:
performing gray level transformation on the background image to obtain a sixth image;
determining a transparency value of at least part of pixels in the sixth image according to the gray value of the at least part of pixels;
and generating the third image by combining the first image and the transparency value, wherein the target with the first color is reserved at least in a region with the color difference of the sixth image being above a preset threshold value.
5. The method of claim 4, wherein the step of determining the position of the first electrode is performed,
the determining the transparency value of at least part of pixels in the sixth image according to the gray level value of the at least part of pixels further comprises:
and determining a transparency value of a target pixel according to the gray value of the target pixel in the sixth image, wherein the target pixel is a pixel with the color difference between the gray value and the target with the first color below the preset threshold.
6. The method of claim 4, wherein the step of determining the position of the first electrode is performed,
said combining said first image and said transparency value generating said third image comprises:
and introducing the transparency value into the first image to generate the third image.
7. An image processing apparatus, comprising:
a first processing unit, configured to generate a first image and a second image based on an object to be displayed, where the first image includes: the target having a first color; the second image includes: the target having a second color;
the second processing unit is used for combining the first image and the currently displayed background image to generate a third image, wherein in the third image, at least the color difference between the third image and the background image is reserved in a region above a preset threshold value;
a third processing unit configured to combine the second image and the background image to generate a fourth image in which image elements of the background image appear in a region other than the target having the second color;
a fourth processing unit configured to superimpose the third image on the fourth image to generate an output image, where the output image includes the target with the first color remaining on the third image, and image elements of the fourth image appear in an area other than the target with the first color remaining on the third image;
the color value of the first color is a first value;
the color value of the second color is a second value;
the sum of the first value and the second value is: and the maximum value of the color channel corresponding to the background image.
8. The apparatus of claim 7, wherein the second processing unit is further configured to:
performing binarization processing on the background image to obtain a fifth image;
and generating the third image by combining the first image and the fifth image, wherein the target with the first color is reserved at least in a region with the color difference of the fifth image being above a preset threshold value.
9. The apparatus of claim 8, wherein the second processing unit is further configured to: and masking the first image by using the fifth image to generate the third image.
10. The apparatus of claim 7, wherein the second processing unit is further configured to:
performing gray level transformation on the background image to obtain a sixth image;
determining a transparency value of at least part of pixels in the sixth image according to the gray value of the at least part of pixels;
and generating the third image by combining the first image and the transparency value, wherein the target with the first color is reserved at least in a region with the color difference of the sixth image being above a preset threshold value.
11. The apparatus of claim 10, wherein the second processing unit is further configured to: and determining a transparency value of a target pixel according to the gray value of the target pixel in the sixth image, wherein the target pixel is a pixel with the color difference between the gray value and the target with the first color below the preset threshold.
12. The apparatus of claim 10, wherein the second processing unit is further configured to: and introducing the transparency value into the first image to generate the third image.
13. The device according to any one of claims 7 to 12, wherein,
the color value of the first color is a first value;
the color value of the second color is a second value;
the sum of the first value and the second value is: and the maximum value of the color channel corresponding to the background image.
14. An image processing apparatus comprising: a processor and a memory for storing a computer program capable of running on the processor;
wherein the processor is adapted to perform the steps of the method of any of claims 1 to 6 when the computer program is run.
15. A computer storage medium, comprising: a computer program stored thereon, which, when executed by a processor, implements the steps of the method according to any of claims 1 to 6.
CN201811039845.6A 2018-09-06 2018-09-06 Image processing method, device, equipment and computer storage medium Active CN110880164B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811039845.6A CN110880164B (en) 2018-09-06 2018-09-06 Image processing method, device, equipment and computer storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811039845.6A CN110880164B (en) 2018-09-06 2018-09-06 Image processing method, device, equipment and computer storage medium

Publications (2)

Publication Number Publication Date
CN110880164A CN110880164A (en) 2020-03-13
CN110880164B true CN110880164B (en) 2024-02-27

Family

ID=69727936

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811039845.6A Active CN110880164B (en) 2018-09-06 2018-09-06 Image processing method, device, equipment and computer storage medium

Country Status (1)

Country Link
CN (1) CN110880164B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112055247B (en) * 2020-09-11 2022-07-08 北京爱奇艺科技有限公司 Video playing method, device, system and storage medium
CN112286471B (en) * 2020-09-27 2023-04-21 通彩视听科技(上海)有限公司 Conference whiteboard image printing method, printing equipment and storage medium
CN112669638A (en) * 2020-12-14 2021-04-16 中国联合网络通信集团有限公司 Vehicle safety passing method, system, terminal equipment and computer storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2005210200A (en) * 2004-01-20 2005-08-04 Ricoh Co Ltd Color image processing apparatus and color image processing program
JP2008113446A (en) * 2002-09-05 2008-05-15 Ricoh Co Ltd Image processing device, image processing program and recording medium
JP2010045537A (en) * 2008-08-11 2010-02-25 Sharp Corp Image processor, image forming device, image processing method, computer program and recording medium
CN104778047A (en) * 2015-04-29 2015-07-15 魅族科技(中国)有限公司 Content display method and terminal
CN108206917A (en) * 2017-12-29 2018-06-26 中兴通讯股份有限公司 The method and device of image procossing, storage medium, electronic device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2008113446A (en) * 2002-09-05 2008-05-15 Ricoh Co Ltd Image processing device, image processing program and recording medium
JP2005210200A (en) * 2004-01-20 2005-08-04 Ricoh Co Ltd Color image processing apparatus and color image processing program
JP2010045537A (en) * 2008-08-11 2010-02-25 Sharp Corp Image processor, image forming device, image processing method, computer program and recording medium
CN104778047A (en) * 2015-04-29 2015-07-15 魅族科技(中国)有限公司 Content display method and terminal
CN108206917A (en) * 2017-12-29 2018-06-26 中兴通讯股份有限公司 The method and device of image procossing, storage medium, electronic device

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
基于边缘和颜色的视频文本图像分割方法;朱成军;欧阳元新;盛浩;熊璋;;系统仿真学报(23);全文 *
高速公路场景图像的二值化及交通标志定位检测方法;初秀民;严新平;毛喆;章先阵;;中国公路学报(06);全文 *

Also Published As

Publication number Publication date
CN110880164A (en) 2020-03-13

Similar Documents

Publication Publication Date Title
CN104778047B (en) A kind of content display method and terminal
CN108701351B (en) Image display enhancement method and device
CN110880164B (en) Image processing method, device, equipment and computer storage medium
CN105574866A (en) Image processing method and apparatus
CA3154893C (en) Image color transferring method, device, computer equipment and storage medium
CN107204034B (en) A kind of image processing method and terminal
TW201723930A (en) Generation method of color QR code
CN106713696B (en) Image processing method and device
CN106339224B (en) Readability enhancing method and device
CN105138317A (en) Window display processing method and device applied to terminal equipment
US20090135266A1 (en) System for scribing a visible label
CN101360250A (en) Immersion method and system, factor dominating method, content analysis method and scaling parameter prediction method
US20230074060A1 (en) Artificial-intelligence-based image processing method and apparatus, electronic device, computer-readable storage medium, and computer program product
CN113436284B (en) Image processing method, device, computer equipment and storage medium
CN107113411A (en) A kind of method for displaying image and equipment and its recording medium based on metadata
CN111627399A (en) Method, terminal and computer readable storage medium capable of locally transforming display colors
CN111090384B (en) Soft keyboard display method and device
JP2024099753A (en) Display method, apparatus, and storage medium
CN111968605A (en) Exposure adjusting method and device
CN111681187A (en) Color noise reduction method and device, electronic equipment and readable storage medium
CN111462158A (en) Image processing method and device, intelligent device and storage medium
CN117218213A (en) Image processing method, training method and device of image processing model
CN115115503A (en) Image display method, device, processor and nonvolatile storage medium
CN112132919A (en) Electronic seal presenting method for simulating inkpad effect
US11657187B2 (en) Method for displaying screen information, display device, 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
GR01 Patent grant
GR01 Patent grant