Search

CN-115509474-B - Question display method and device, storage medium and electronic equipment

CN115509474BCN 115509474 BCN115509474 BCN 115509474BCN-115509474-B

Abstract

The embodiment of the application provides a method, a device, a storage medium and electronic equipment for displaying a title, wherein the method comprises the steps of obtaining a first image, wherein the first image is a color image comprising the title and a written mark, determining a pixel point where the written mark is located according to a color mark corresponding to the pixel point of the first image and a preset written mark color mark, replacing a color value of the pixel point where the written mark is located in the first image with a background color value of the first image in the first image, obtaining a second image, and outputting the second image to an ink screen for display. The embodiment of the application can remove the writing marks and reserve the questions, further avoid displaying writing marks with different gray colors on the questions or around the questions when the ink screen is displayed, and reduce interference.

Inventors

  • PAN XIAO

Assignees

  • 广州视源电子科技股份有限公司
  • 广州视睿电子科技有限公司

Dates

Publication Date
20260508
Application Date
20210607

Claims (9)

  1. 1. The title display method is characterized by comprising the following steps: acquiring a first image, wherein the first image is a color image comprising a title and a written mark; Traversing color values corresponding to all pixel points in the first image, wherein the color values comprise a red primary color value, a green primary color value and a blue primary color value; when the value obtained by subtracting the preset threshold value from one of the primary color values is larger than the other two primary color values, determining the primary color mark where the one of the primary color values is located as the color mark corresponding to the pixel point; if the color mark corresponding to the pixel point is a preset writing mark color mark, determining the pixel point as the pixel point where the writing mark is located; in the first image, replacing the color value of the pixel point where the writing mark is positioned with the background color value of the first image to obtain a second image; and outputting the second image to an ink screen for display.
  2. 2. The method for displaying a title according to claim 1, wherein, The preset written mark color mark is the same as the corresponding color mark of the written mark, or The color mark identification of the preset writing mark is different from the color mark corresponding to the writing mark, and the color mark of the preset writing mark is one or more of the color marks corresponding to the writing mark.
  3. 3. The method for displaying a title according to claim 1, wherein, The primary color marks corresponding to the red primary color value, the green primary color value and the blue primary color value in the color value are respectively red marks, green marks and blue marks, the color marks corresponding to the writing marks comprise one or more of red marks, green marks and blue marks, and the preset writing mark color marks comprise one or more of red marks, green marks and blue marks.
  4. 4. The method for displaying a title according to claim 1, wherein, Before traversing the color values corresponding to all the pixel points in the first image, performing image enhancement processing on the first image.
  5. 5. The method for displaying a title according to claim 4, wherein, The image enhancement processing of the first image comprises contrast enhancement processing of the first image.
  6. 6. The method for displaying a title according to any one of claim 1 to 5, In the first image, replacing the color value of the pixel point where the writing mark is located with the background color value of the first image to obtain a second image, including: And in the first image, acquiring coordinates of a pixel point where the writing mark is located, and replacing a color value stored on the coordinates of the pixel point with a background color value of the first image.
  7. 7. A title display device, comprising: The first image acquisition module is used for acquiring a first image, wherein the first image is a color image comprising a title and a written mark; The pixel point determining module is used for traversing color values corresponding to all pixel points in the first image, wherein the color values comprise a red primary color value, a green primary color value and a blue primary color value, and when one of the primary color values minus a preset threshold value is larger than the other two primary color values, the primary color mark where the one primary color value is located is determined to be the color mark corresponding to the pixel point; the second image acquisition module is used for replacing the color value of the pixel point where the writing mark is positioned with the background color value of the first image in the first image to obtain a second image; and the display module is used for outputting the second image to an ink screen for display.
  8. 8. An electronic device comprising a display, a processor and a memory, wherein the memory stores a computer program adapted to be loaded by the processor and to perform the method of displaying a title as claimed in any one of claims 1 to 6.
  9. 9. A computer-readable storage medium, on which a computer program is stored, which, when executed by a processor, implements the title display method according to any one of claims 1 to 6.

Description

Question display method and device, storage medium and electronic equipment Technical Field The embodiment of the application relates to the field of testing of touch screens, in particular to a method and a device for displaying questions, a storage medium and electronic equipment. Background When students do the questions in books or exercise books, red or blue pens are usually used for marking key points or marking the question solving process on the questions or around the questions. The inventor finds that at least the following problems exist in the prior art in the process of realizing the invention, when the problems are displayed on the ink screen after photographing and recording, only black and white and different gray colors are displayed in the displayed photo due to the physical characteristics of the ink screen, and the problems are mixed with the written marks due to the fact that the problems can display a plurality of different gray colors at the periphery of the problems, so that interference is caused to the identification of the problems. Disclosure of Invention In order to overcome the problems in the related art, the application provides a method, a device, a storage medium and an electronic device for displaying the questions, which have the advantages of removing written marks, reserving the questions and reducing the interference of the question identification. According to a first aspect of an embodiment of the present application, there is provided a method for displaying a title, including the steps of: acquiring a first image, wherein the first image is a color image comprising a title and a written mark; Traversing color values corresponding to all pixel points in the first image, wherein the color values comprise a red primary color value, a green primary color value and a blue primary color value; when the value obtained by subtracting the preset threshold value from one of the primary color values is larger than the other two primary color values, determining the primary color mark where the one of the primary color values is located as the color mark corresponding to the pixel point; if the color mark corresponding to the pixel point is a preset writing mark color mark, determining the pixel point as the pixel point where the writing mark is located; in the first image, replacing the color value of the pixel point where the writing mark is positioned with the background color value of the first image to obtain a second image; and outputting the second image to an ink screen for display. According to a second aspect of an embodiment of the present application, there is provided a title display apparatus including: The first image acquisition module is used for acquiring a first image, wherein the first image is a color image comprising a title and a written mark; The pixel point determining module is used for traversing color values corresponding to all pixel points in the first image, wherein the color values comprise a red primary color value, a green primary color value and a blue primary color value, and when one of the primary color values minus a preset threshold value is larger than the other two primary color values, the primary color mark where the one primary color value is located is determined to be the color mark corresponding to the pixel point; the second image acquisition module is used for replacing the color value of the pixel point where the writing mark is positioned with the background color value of the first image in the first image to obtain a second image; and the display module is used for outputting the second image to an ink screen for display. According to a third aspect of embodiments of the present application there is provided an electronic device comprising a processor and a memory, the memory storing a computer program adapted to be loaded by the processor and to perform the method of displaying a title as described above. According to a fourth aspect of embodiments of the present application, there is provided a computer-readable storage medium having stored thereon a computer program, characterized in that the computer program, when executed by a processor, implements the subject display method as described above. According to the embodiment of the application, the pixel point where the writing mark is located is determined according to the color mark corresponding to the pixel point of the first image and the preset writing mark color mark, and then the color value of the pixel point where the writing mark is located is replaced by the background color value of the first image, so that the writing mark is removed, the title is reserved, and further, when the ink screen is displayed, the writing marks with different gray colors can be prevented from being displayed on the title or around the title, and the interference is reduced. It is to be understood that both the foregoing general description and the following detailed description are