High-quality information superposition display method
Through the pixel processing method of prefabricated base map and pre-stored character library, combined with the double buffering processing mode, the problems of character edge transition abrupt and font library limitation in the existing technology are solved, and high-quality and real-time character overlay display is achieved, suitable for embedding system.
Patent Information
- Application Number
- CN202310944139.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-28
- Publication Date
- 2025-02-18
AI Technical Summary
The existing character overlay method has flaws in the transition at the edge of the character, relying on the font library that runs the device, and updating the overlay character requires modifying the underlying code, especially in embedded systems with limited resources.
Using prefabricated base map and pre-stored character library, the prefabricated base map and the source image are superimposed through pixel processing to form a preliminary fusion map, and based on the prefabricated character library, parameter information is converted into text images and instruction information into symbol images, and finally through double buffering Processing mode performs image overlay.
Without increasing computing power, it effectively solves the problems of abrupt character edge transition and insufficient anti-aliasing capabilities, improves the quality and real-time character display, supports arbitrary font styles and character overlays, and does not require modification of the underlying code. It is suitable for Embedded system.
Smart Images

Figure CN119484930A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of video image processing, and in particular to a high-quality information superposition display method. Background Art
[0002] In recent years, the technology in the field of computer video imaging has been continuously developed, and information superposition has been widely used in the field of video imaging, and has been applied to many fields such as monitoring, remote sensing, and medical treatment. Therefore, high-quality information superposition methods are of great significance.
[0003] Information overlay is to overlay text, data, symbols and other information onto video images for display. Users can quickly and accurately understand the current situation by directly observing the information on the image. The current existing character overlay method is to overlay bitmap fonts or vector fonts onto video images. In the case of different resolutions, in order to ensure a uniform transition of character edges, bitmap fonts need to use interpolation methods to scale the characters and then complete the overlay. Vector fonts need to complete the description of the characters through point and line conversion and perform multiple processing such as rasterization, coloring, and stroking on the character pixels before completing the overlay. It can be seen that both bitmap fonts and vector fonts require a lot of computing resources to solve the problem of abrupt character edge transitions, which brings huge challenges to the application of information overlay in resource-limited embedded systems.
[0004] The existing technology mainly has the following defects. First, the existing font overlay method based on bitmap fonts or vector fonts either has abrupt transitions of character edges and does not have anti-aliasing capabilities, or requires a large amount of computing resources to solve the problem of abrupt transitions of character edges; second, the existing font overlay method needs to rely on the font library of the running device, and the font library of the running device, especially the embedded device, often has a single font style and may lack certain characters, thereby limiting the available font styles or characters; third, updating the overlay characters requires modifying the underlying code, which is not conducive to code reuse and rapid product iteration. Summary of the invention
[0005] In view of the above analysis, the present invention aims to provide an information overlay display method, which is used to solve the problems of abrupt character edge transitions, dependence on the font library of the running device, and the need to modify the underlying code to update the overlay characters in the existing character overlay method without increasing computing power.
[0006] The present invention provides a high-quality information superposition display method, the method comprising the following steps:
[0007] Get pre-made base map and source image;
[0008] Based on pixel processing, the prefabricated base map is superimposed with the source image to form a preliminary fusion image;
[0009] Obtain parameter information at fixed intervals, and convert the parameter information into text images based on a pre-stored character library;
[0010] Receive instruction information and convert the instruction information into a displayed symbol image;
[0011] Based on pixel processing, the text image is superimposed on the preliminary fusion image to form an intermediate fusion image, and the symbol image is superimposed on the intermediate fusion image to form a final fusion image.
[0012] Furthermore, the obtaining of the prefabricated base map includes:
[0013] Select characters that do not need to be changed from the characters to be displayed, determine the size, font, color, and position information of the characters, draw a base map using mapping software, and set the base map size to match the final fusion Figure 1 To.
[0014] Further, the base map is drawn using mapping software, including:
[0015] The interpolation or Gaussian blur method is used to smoothly transition the boundaries of the characters in the base image, so that the oblique edges of the characters have no jagged effect.
[0016] Furthermore, for areas in the base image without characters, their pixel values are filled with 0.
[0017] Furthermore, the pixel-based processing to superimpose the prefabricated base map with the source image to form a preliminary fusion image includes:
[0018] Traverse all pixels of the prefabricated base map, obtain the pixel values and coordinate positions of non-zero pixels, and use the obtained pixel values to replace the pixel values at the same coordinate positions in the source image to achieve the superposition of the prefabricated base map and the source image to form a preliminary fusion image.
[0019] Furthermore, the converting of parameter information into a text image based on a pre-stored character library includes:
[0020] The obtained parameter information is converted into a string, each character in the string is traversed, a text image matching the character in the string is found in a pre-stored character library, and the parameter information is converted into a text image.
[0021] Furthermore, the pre-stored character library is a set of pre-made character libraries, including text images of numbers, common symbols, and common characters, and the text images have been subjected to edge jagged processing.
[0022] Furthermore, converting the instruction information into a displayed symbolic image includes:
[0023] According to the preset instructions, the image that needs to be added for display is determined, and the acquired instruction information is converted into a symbolic image for display.
[0024] Furthermore, the pixel-based processing, superimposing the text image with the preliminary fusion image to form an intermediate fusion image, and superimposing the symbol image with the intermediate fusion image to form a final fusion image includes:
[0025] Obtain the display position of the parameter information, obtain the pixel values of the non-zero pixels in the text image, replace the pixel values of the corresponding positions in the preliminary fusion image with the obtained pixel values, superimpose the text image with the preliminary fusion image to form an intermediate fusion image; obtain the display position of the instruction information, obtain the pixel values of the non-zero pixels in the symbol image, replace the pixel values of the corresponding positions in the intermediate fusion image with the obtained pixel values, superimpose the symbol image with the intermediate fusion image to form a final fusion image.
[0026] Furthermore, a double buffer processing mode is adopted when the images are superimposed, and the double buffer processing mode includes:
[0027] Two identical buffers are reserved, and the image reading thread and the image overlay thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing ends, the buffer is unlocked; the image reading thread fills the read data into the first buffer, and at the same time, the image overlay thread reads the data in the second buffer and performs image overlay; when the first buffer is filled with data and the second buffer is in an unlocked state, the image reading thread fills the read data into the second buffer, and when the data in the second buffer is read out and the first buffer is in an unlocked state, the image overlay thread reads the data in the first buffer and performs image overlay, and this process is repeated.
[0028] Compared with the prior art, the present invention can achieve at least one of the following beneficial effects:
[0029] 1. The present invention performs smooth transition processing on the boundaries of characters in the base map by prefabricating the base map, and performs edge jagged processing on the text images in the character library by pre-storing the character library. Therefore, the problem of abrupt transition of the edges of superimposed characters and lack of anti-aliasing ability can be effectively solved without increasing computing power, which significantly improves the quality of character display and effectively enhances the user experience.
[0030] 2. The present invention pre-makes a base map and uses the font library of the host machine or a drawing method. It is not limited by the font library of the running device and can use any font style or character for superposition. It supports the superposition of rare characters and custom symbols, significantly expands the range of character display, and effectively improves the user experience.
[0031] 3. The present invention pre-makes a base map, selects characters that do not need to be changed from the characters to be displayed, and pre-makes them into a base map to directly superimpose on the source image. It is not necessary to draw all the characters to be displayed in real time, which greatly improves the real-time performance of character superposition.
[0032] 4. The present invention realizes the superposition of characters, parameters, symbols and video images based on pixel processing through prefabricated base maps and pre-stored character libraries. Therefore, it is not necessary to modify the code to modify or update the superimposed characters, which improves the code reuse rate, improves the development efficiency, and is conducive to the rapid iteration of products.
[0033] 5. The present invention adopts a double buffer processing mode for image overlay, and reserves two identical buffers. The image reading thread and the image overlay thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing is completed, the buffer is unlocked. On the one hand, the efficiency of image overlay is improved and efficient use of data is achieved. On the other hand, the integrity of the data is ensured and data loss is prevented.
[0034] In the present invention, the above-mentioned technical solutions can also be combined with each other to achieve more preferred combination solutions. Other features and advantages of the present invention will be described in the subsequent description, and some advantages can become obvious from the description, or can be understood by practicing the present invention. The purpose and other advantages of the present invention can be realized and obtained through the contents particularly pointed out in the description and the drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0035] The drawings are only for the purpose of illustrating particular embodiments and are not to be considered limiting of the present invention. Like reference symbols denote like components throughout the drawings.
[0036] Figure 1 The figure is a flow chart of a high-quality information overlay display method according to an embodiment of the present invention.
[0037] Figure 2 A base map is prefabricated for the embodiment of the present invention.
[0038] Figure 3 This is a preliminary fusion diagram of an embodiment of the present invention.
[0039] Figure 4 It is the middle fusion diagram in the embodiment of the present invention.
[0040] Figure 5 This is the final fusion diagram of the embodiment of the present invention.
[0041] Figure 6 Schematic diagram of a double buffer processing mode according to an embodiment of the present invention. DETAILED DESCRIPTION
[0042] The preferred embodiments of the present invention are described in detail below in conjunction with the accompanying drawings. Figure 1 It constitutes a part of this application and is used to illustrate the principle of the present invention together with the embodiments of the present invention, but is not used to limit the scope of the present invention.
[0043] A specific embodiment of the present invention discloses a high-quality information overlay display method.
[0044] like Figure 1 As shown, the method comprises the following steps:
[0045] Step S1, obtaining a prefabricated base map and a source image.
[0046] Step S2: Based on pixel processing, the prefabricated base map is superimposed with the source image to form a preliminary fusion image.
[0047] Step S3: Acquire parameter information at fixed intervals, and convert the parameter information into a text image based on a pre-stored character library.
[0048] Step S4: receiving instruction information, and converting the instruction information into a displayed symbol image.
[0049] Step S5: Based on pixel processing, the text image is superimposed on the preliminary fusion image to form an intermediate fusion image, and the symbol image is superimposed on the intermediate fusion image to form a final fusion image.
[0050] In step S1, obtaining a prefabricated base map includes selecting characters that do not need to be changed from the characters to be displayed, determining the size, font, color, and position information of the characters, and drawing the base map using mapping software. The size of the base map is set to match the final fusion size. Figure 1 The source image is the image acquired at the current moment.
[0051] Specifically, the interpolation or Gaussian blur method is used to perform smooth transition processing on the boundaries of the characters in the base image, so that the oblique edges of the characters have no jagged effect. For areas without characters in the base image, their pixel values are filled with 0.
[0052] For example, the company's logo and parameter information do not need to be changed and can be drawn in the base map, such as "time", "date", "system status", "target status" and other names. Any characters, graphics, and symbols can be manually drawn by the host's drawing software. Any color, style, and position can be set for the characters, graphics, and symbols, and the character boundaries can be smoothly transitioned by interpolation or Gaussian blur method. Therefore, the characters in the base map are not limited by the font library of the running device, avoiding the disadvantage of a single superimposed character style; the character boundaries in the base map have been smoothly transitioned, ensuring that the edges of the characters are smooth and free of jagged effects under high-resolution conditions.
[0053] The background of the base map adopts a black and white contrast scheme, that is, the characters, graphics, and symbols are white and gray, and their pixel values are any number between 1 and 255. The rest of the base map is all black, and its pixel values are filled with 0, such as Figure 2 shown.
[0054] The size and resolution of the base map are set to be consistent with the source image. For example, if the resolution of the source image is 1920*1080, the drawn base map is exported as a 1920*1080 image. The position of the parameter information name in the base map determines the position of the subsequent parameter information overlay.
[0055] In step S2, the pixel-based processing to superimpose the prefabricated base map with the source image to form a preliminary fusion image includes:
[0056] Traverse all pixels of the prefabricated base map, obtain the pixel values and coordinate positions of non-zero pixels, and use the obtained pixel values to replace the pixel values at the same coordinate positions in the source image to achieve the superposition of the prefabricated base map and the source image to form a preliminary fusion image.
[0057] Specifically, in the process of overlaying the base map, if it is determined that the pixel of the prefabricated base map is greater than zero, the pixel value at the same coordinate position in the source image is replaced with the obtained pixel value, otherwise no replacement is performed.
[0058] For example, the prefabricated base image is O, the source image is A, for all x∈[0,1920), y∈[0,1080), if O(x,y)>0, then let A(x,y)=O(x,y), that is, replace the pixel values of the same position in the source image with all non-zero pixels in the prefabricated base image, otherwise keep A(x,y) unchanged. After traversing all pixels of the prefabricated base image, a preliminary fusion image is formed, such as Figure 3 shown.
[0059] A double buffer processing mode is used when the images are superimposed, and the double buffer processing mode includes:
[0060] Two identical buffers are reserved, and the image reading thread and the image overlay thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing ends, the buffer is unlocked. The thread can only process the buffer in the unlocked state. When the buffer to be processed is in the locked state, the thread waits until the buffer is unlocked.
[0061] The image reading thread fills the read data into the first buffer, and at the same time the image overlay thread reads the data in the second buffer and performs image overlay; when the first buffer is filled with data and the second buffer is in an unlocked state, the image reading thread fills the read data into the second buffer; when the data in the second buffer is all read out and the first buffer is in an unlocked state, the image overlay thread reads the data in the first buffer and performs image overlay, and this process is repeated.
[0062] Exemplarily, the prefabricated base map reading thread fills the read data into the first buffer, and the image overlay thread reads the data in the second buffer and overlays it onto the source image. When the first buffer is filled with data and the second buffer is in an unlocked state, the prefabricated base map reading thread fills the read data into the second buffer. When the data in the second buffer is read out and the first buffer is in an unlocked state, the image overlay thread reads the data in the first buffer and overlays it onto the source image, and so on and so forth, to achieve parallel processing of the two buffers, such as Figure 6 shown.
[0063] Because the present invention is based on pixel processing, in the process of character superposition, the source image is replaced with non-zero pixels of the prefabricated base map, rather than the 0, 1 dot matrix replacement of the prior art, so the smooth transition area of the character edge is effectively retained, with anti-aliasing effect, and the quality of character display is improved. Secondly, the present invention adopts the method of comparing pixel values for pixel replacement, which is simple to calculate and very suitable for character superposition processing of low computing power embedded systems, and the modification and update of superimposed characters do not require code modification, which improves the code reuse rate and is conducive to the rapid iteration of products. Thirdly, the prefabricated base map replaces the prior art of drawing all the characters to be displayed in real time, and only the characters with changes need to be drawn in real time, so the real-time performance of character superposition is greatly improved. Finally, the double buffer processing mode is adopted for image superposition, and two identical buffers are reserved. The image reading thread and the image superposition thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing is completed, the buffer is unlocked, which improves the efficiency of image superposition and realizes the efficient use of data on the one hand, and ensures the integrity of the data and prevents data loss on the other hand.
[0064] In step S3, the following steps are performed to convert the parameter information into a text image.
[0065] Step S3.1, converting the acquired parameter information into a character string, including:
[0066] Obtain parameter information at regular intervals, actively query the main control system, read relevant parameters of the main control system, and convert the parameter information into corresponding strings.
[0067] For example, the time read is "14:30", the date is "20230303", the system state is "self-check completed", and the target state is "exercise". "14:30", "20230303", "self-check completed", and "exercise" are converted into corresponding strings String_time, String_date, String_system_state, and String_object_state, respectively.
[0068] Step S3.2: traverse each character in the string, find a text image that matches the character in the string in the pre-stored character library, and convert the parameter information into a text image.
[0069] The pre-stored character library is a set of pre-made character libraries, including text images of numbers, common symbols, and common characters, and the text images are processed with edge jagged edges. By traversing each character in the string and finding a matching text image in the pre-stored character library, the string can be converted into the corresponding text image.
[0070] For example, the content of the string String_time is "14:30", and the string is traversed to convert "1", "4", ":", "3", and "0" into text images respectively.
[0071] Because the text images have undergone edge anti-aliasing processing, the problem of abrupt edge transitions and lack of anti-aliasing capabilities of superimposed characters can be effectively solved without increasing computing power, which significantly improves the quality of character display and effectively enhances the user experience.
[0072] In step S4, the image to be displayed is determined according to the preset instruction, and the acquired instruction information is converted into a symbol image to be displayed.
[0073] The instruction is a predefined command that specifies the content and position of the symbol image display. Each instruction specifies the corresponding symbol image. When the instruction information of the main control system is received, the instruction information is converted into the symbol image to be displayed.
[0074] Exemplarily, for example, if the instruction information is "display grid lines in the image area", the position where the grid lines are displayed and the symbol image of the grid lines are obtained, and the image includes information on the thickness, shape, and length of the grid lines.
[0075] In step S5, the following steps are performed to form a final fusion image.
[0076] Step S5.1, superimposing the text image and the preliminary fusion image to form an intermediate fusion image, including:
[0077] The display position of the parameter information is obtained, the pixel values of non-zero pixels in the text image are obtained, the pixel values at the corresponding positions in the preliminary fusion image are replaced with the obtained pixel values, and the text image is superimposed on the preliminary fusion image to form an intermediate fusion image.
[0078] For example, the initial fusion image is OA, and the text image corresponding to the first character of the string String_time is B. Get the display position of the character, traverse all the pixels of the character, and if B(x,y)>0, set OA(x,y)=B(x,y), that is, replace the pixel values at the same position in the initial fusion image with all non-zero pixels in the text image, otherwise keep OA(x,y) unchanged. After traversing all the pixels of all characters in all strings, form an intermediate fusion image, such as Figure 4 shown.
[0079] Step S5.2, superimposing the symbol image and the intermediate fusion image to form a final fusion image, including:
[0080] Obtain the display position of the instruction information, obtain the pixel values of non-zero pixels in the symbol image, replace the pixel values of the corresponding positions in the intermediate fusion image with the obtained pixel values, and superimpose the symbol image and the intermediate fusion image to form a final fusion image.
[0081] For example, if the instruction information is "display image area grid lines", the grid line display position and the grid line symbol image are obtained according to the instruction information. Based on the displayed position, all pixels in the symbol image are traversed. If the pixel value is greater than zero, the pixel value at the corresponding position in the intermediate fusion image is replaced with the obtained pixel value, otherwise the pixel value of the intermediate fusion image remains unchanged. After traversing all pixels of the symbol image, the final fusion image is formed, such as Figure 5 shown.
[0082] Because the present invention is based on pixel processing, in the process of text image superposition, the preliminary fusion image is replaced with the non-zero pixels of the pre-stored characters, rather than the 0, 1 dot matrix replacement of the prior art, so the smooth transition area of the character edge is effectively retained, with an anti-aliasing effect, and the quality of character display is improved. In addition, the text image and symbol image superposition also adopts a double buffer processing mode. Through thread control, on the one hand, the efficiency of image superposition is greatly improved, and the efficient use of data is achieved, and on the other hand, the integrity of the data is ensured and data loss is prevented.
[0083] Compared with the prior art, the present invention provides a high-quality information overlay display method. First, a smooth transition process is performed on the boundaries of the characters in the base map by pre-fabricating the base map, and an edge jagged process is performed on the text images in the character library by pre-storing the character library. Therefore, the problem of abrupt transition of the edges of the superimposed characters and lack of anti-aliasing ability can be effectively solved without increasing the computing power, thereby significantly improving the quality of character display and effectively improving the user experience. Secondly, by pre-fabricating the base map and using the font library or drawing method of the host machine, it is not restricted by the font library of the running device, and any font style or character can be used for overlay, supporting the overlay of rare characters and custom symbols, significantly expanding the range of character display and effectively improving the user experience. Thirdly, by pre-fabricating the base map, characters that do not need to be changed are selected from the characters to be displayed. The characters are pre-made into a base map and directly superimposed on the source image. There is no need to draw all the characters to be displayed in real time, which greatly improves the real-time performance of character superposition. Then, through the pre-made base map and the pre-stored character library, the superposition of characters, parameters, symbols and video images is realized based on pixel processing. Therefore, it is not necessary to modify the code to modify or update the superimposed characters, which improves the code reuse rate, improves the development efficiency, and is conducive to the rapid iteration of products. Finally, the double buffer processing mode is adopted for image superposition, and two identical buffers are reserved. The image reading thread and the image superposition thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing is completed, the buffer is unlocked. On the one hand, the efficiency of image superposition is improved and the efficient use of data is realized. On the other hand, the integrity of the data is ensured and the loss of data is prevented.
[0084] Those skilled in the art will appreciate that all or part of the processes of the above-mentioned embodiments can be implemented by instructing related hardware through a computer program, and the program can be stored in a computer-readable storage medium, wherein the computer-readable storage medium is a disk, an optical disk, a read-only storage memory, or a random access memory, etc.
[0085] The above description is only a preferred specific implementation manner of the present invention, but the protection scope of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by any technician familiar with the technical field within the technical scope disclosed by the present invention should be covered within the protection scope of the present invention.
Claims
1. A high-quality information overlay display method, characterized in that: The method comprises the following steps: Get pre-made base map and source image; Based on pixel processing, the prefabricated base map is superimposed with the source image to form a preliminary fusion image; Obtain parameter information at fixed intervals, and convert the parameter information into text images based on a pre-stored character library; Receive instruction information and convert the instruction information into a displayed symbol image; Based on pixel processing, the text image is superimposed on the preliminary fusion image to form an intermediate fusion image, and the symbol image is superimposed on the intermediate fusion image to form a final fusion image.
2. The high-quality information superposition display method according to claim 1, characterized in that: The obtaining of the prefabricated base map comprises: Select characters that do not need to be changed from the characters to be displayed, determine the size, font, color, and position information of the characters, draw a base map using mapping software, and set the base map size to be consistent with the final fusion map.
3. The high-quality information superposition display method according to claim 2, characterized in that: The base map drawn with mapping software comprises: The interpolation or Gaussian blur method is used to smoothly transition the boundaries of the characters in the base image, so that the oblique edges of the characters have no jagged effect.
4. The high-quality information superposition display method according to claim 3, characterized in that: For areas in the base map where there are no characters, their pixel values are filled with 0.
5. The high-quality information superposition display method according to claim 4, characterized in that: The pixel-based processing to superimpose the prefabricated base map with the source image to form a preliminary fusion image includes: Traverse all pixels of the prefabricated base map, obtain the pixel values and coordinate positions of non-zero pixels, and use the obtained pixel values to replace the pixel values at the same coordinate positions in the source image to achieve the superposition of the prefabricated base map and the source image to form a preliminary fusion image.
6. The high-quality information superposition display method according to claim 1, characterized in that: The converting of parameter information into a text image based on a pre-stored character library includes: The obtained parameter information is converted into a string, each character in the string is traversed, a text image matching the character in the string is found in a pre-stored character library, and the parameter information is converted into a text image.
7. The high-quality information superposition display method according to claim 1, characterized in that: The pre-stored character library is a set of pre-made character libraries, including text images of numbers, common symbols, and common characters, and the text images are subjected to edge jagged processing.
8. The high-quality information superposition display method according to claim 1, characterized in that: The step of converting the instruction information into a displayed symbolic image comprises: According to the preset instructions, the image that needs to be added for display is determined, and the acquired instruction information is converted into a symbolic image for display.
9. The high-quality information superposition display method according to claim 1, characterized in that: The pixel-based processing, superimposing the text image with the preliminary fusion image to form an intermediate fusion image, and superimposing the symbol image with the intermediate fusion image to form a final fusion image comprises: Obtain the display position of the parameter information, obtain the pixel values of the non-zero pixels in the text image, replace the pixel values of the corresponding positions in the preliminary fusion image with the obtained pixel values, superimpose the text image with the preliminary fusion image to form an intermediate fusion image; obtain the display position of the instruction information, obtain the pixel values of the non-zero pixels in the symbol image, replace the pixel values of the corresponding positions in the intermediate fusion image with the obtained pixel values, superimpose the symbol image with the intermediate fusion image to form a final fusion image.
10. The high-quality information superposition display method according to claim 1, characterized in that: A double buffer processing mode is used when the images are superimposed, and the double buffer processing mode includes: Two identical buffers are reserved, and the image reading thread and the image overlay thread process the two buffers in turn. When the processing starts, the processed buffer is locked, and when the processing ends, the buffer is unlocked; the image reading thread fills the read data into the first buffer, and at the same time, the image overlay thread reads the data in the second buffer and performs image overlay; when the first buffer is filled with data and the second buffer is in an unlocked state, the image reading thread fills the read data into the second buffer, and when the data in the second buffer is read out and the first buffer is in an unlocked state, the image overlay thread reads the data in the first buffer and performs image overlay, and this process is repeated.