Shadow area contrast gain method and related device
By adaptively calculating the gain coefficient of the shadowed area, the problem of low contrast in the shadowed area is solved, and the display effect and detailed performance of the image are improved.
Patent Information
- Application Number
- CN202510457881.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-11
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2045-04-11
AI Technical Summary
In the prior art, the shadowed area is affected by uneven lighting, resulting in low contrast, loss of details, and poor display effect.
By obtaining the shadow center position of the shadow area, calculating the direction vector and boundary point position, obtaining the gain coefficient, adaptive contrast adjustment, and enhancing the contrast of the shadow area.
Significantly improve image quality in shadowed areas, enhance detail performance, while keeping the contrast of non-shaded areas unchanged, ensuring that the overall visual effect is not affected.
Smart Images

Figure CN119993090B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of graphic display technology, and in particular to a shadow area contrast gain method and related equipment. Background Art
[0002] With the continuous development of display technology, people's requirements for visual effects are constantly increasing. Whether watching videos, playing games or doing other visual activities, they hope to obtain more realistic, clear and smooth picture effects.
[0003] In many practical applications, such as photography, images are often affected by uneven lighting, resulting in low contrast in shadow areas, loss of details, and poor display effects. In the existing technology, there is no good way to solve the above problems.
[0004] Therefore, it is hoped that there will be a new shadow area contrast gain method and related equipment that can overcome the above problems. Summary of the Invention
[0005] In view of the above problems, the object of the present invention is to provide a shadow area contrast gain method and related equipment, in particular, a convex hull area shadow adaptive contrast gain method, so as to adaptively adjust the contrast of the shadow area of the shadow scene.
[0006] According to one aspect of the present invention, a shadow area contrast gain method is provided, comprising:
[0007] Get the shadow center position of the shadow area;
[0008] Obtaining a direction vector of the area to be gained according to the position of the area to be gained in the shadow area and the center position of the shadow;
[0009] Obtaining the position of the boundary point of the shadow area in the direction of the direction vector;
[0010] A gain coefficient of the area to be gained is obtained according to the position of the boundary point, the position of the area to be gained, and the position of the center of the shadow.
[0011] Optionally, the shadow area contrast gain method further includes:
[0012] Obtaining the brightness of the area to be gained in the shadow area;
[0013] The brightness of the area to be gained is obtained according to the gain coefficient and the brightness.
[0014] Optionally, the shadow center position is ;
[0015] The position of the area to be gained is ;
[0016] The direction vector ;
[0017] The boundary point position is ,in, ;
[0018] The gain factor ;
[0019] The shadow area contrast gain method further includes:
[0020] Get the contrast adjustment base curve of the shadow center position ,
[0021]
[0022] in, is the basic contrast coefficient, For The brightness value at the position, is the original global mapping curve;
[0023] According to the gain coefficient and the contrast adjustment base curve, the contrast mapping curve of the area to be gained is obtained. .
[0024] Optionally, the shadow area contrast gain method further includes:
[0025] Get the display screen to be gained;
[0026] The shadow area is obtained according to the display picture to be gained.
[0027] Optionally, the shadow area contrast gain method further includes:
[0028] extracting the shadow area from the display picture to be gained according to the shadow segmentation mask;
[0029] The to-be-gained display picture is gained according to the gain coefficient to obtain a display picture.
[0030] Optionally, the shadow area contrast gain method further includes:
[0031] The shadow area and the shadow center position are acquired from the display picture to be gained according to a priori.
[0032] Optionally, the shadow area contrast gain method further includes:
[0033] Get the display screen to be gained;
[0034] Converting the display image to be gained from the RGB domain to the YUV domain;
[0035] After obtaining the gain coefficient, obtaining a contrast mapping curve of the area to be gained;
[0036] After mapping the area to be gained according to the contrast mapping curve, the YUV domain is converted to the RGB domain for output.
[0037] Optionally, the shadow area is a convex hull area.
[0038] According to another aspect of the present invention, there is provided a shadow area contrast gain system, comprising:
[0039] An acquisition unit, used for acquiring the shadow center position of the shadow area;
[0040] a vector operation unit, configured to obtain a direction vector of the area to be gained according to a position of the area to be gained in the shadow area and a center position of the shadow;
[0041] A boundary point calculation unit, configured to obtain a boundary point position of the shadow area in the direction of the direction vector;
[0042] The gain coefficient calculation unit is used to obtain the gain coefficient of the area to be gained according to the position of the boundary point, the position of the area to be gained and the position of the center of the shadow.
[0043] According to another aspect of the present invention, there is provided a chip, comprising:
[0044] Shadow area contrast gain system as described above.
[0045] According to yet another aspect of the present invention, there is provided a display panel, comprising:
[0046] As described above, the shadow area contrast gain system
[0047] The display panel includes at least one selected from a cathode ray tube display panel, a digital light processing display panel, a liquid crystal display panel, a light emitting diode display panel, an organic light emitting diode display panel, a quantum dot display panel, a Mirco-LED display panel, a Mini-LED display panel, a field emission display panel, a plasma display panel, an electrophoretic display panel or an electrowetting display panel.
[0048] According to another aspect of the present invention, there is provided a display device comprising:
[0049] A shadow area contrast enhancement system as described above; and
[0050] A display panel is connected to the shadow area contrast gain system to display a display image after being enhanced by the shadow area contrast gain system.
[0051] According to another aspect of the present invention, a computer-readable storage medium is provided, on which a computer program is stored, wherein when the program is executed by a processor, the shadow area contrast gain method described above is implemented.
[0052] The shadow area contrast gain method and related devices provided by the present invention obtain the gain coefficient of the area to be gained according to the position of the boundary point, the position of the area to be gained and the position of the shadow center, and can adaptively adjust the contrast of the shadow area of the shadow scene.
[0053] Furthermore, by enhancing the contrast of the shadow area of the display image according to the gain coefficient, the image quality can be significantly improved, and the details of the shadow area can be enhanced.
[0054] Furthermore, by identifying the shadow area based on a priori knowledge, the shadow area can be obtained efficiently and accurately, thereby achieving picture gain.
[0055] Furthermore, by calculating the shadow center position, the adaptability and contrast gain effect of the gain method can be effectively improved.
[0056] Furthermore, the contrast of non-shadow areas remains unchanged during the processing, ensuring that the overall visual effect of the image is not affected.
[0057] Furthermore, the image is converted from the RGB domain to the YUV domain and then subjected to gain processing to separate the brightness and chromaticity, thereby reducing the amount of data calculation and improving processing efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0058] The above and other objects, features and advantages of the present invention will become more apparent through the following description of the embodiments of the present invention with reference to the accompanying drawings, in which:
[0059] Figure 1 A flowchart of a method for gaining contrast in a shadow area according to an embodiment of the present invention is shown;
[0060] Figure 2 FIG2 shows a schematic diagram showing the principle of a method for contrast gain in a shadow area according to an embodiment of the present invention;
[0061] Figure 3 shows a schematic structural diagram of a chip according to an embodiment of the present invention;
[0062] Figure 4 FIG. 1 is a schematic structural diagram of a display device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0063] Various embodiments of the present invention will be described in more detail below with reference to the accompanying drawings. In each of the accompanying drawings, identical elements are represented by identical or similar reference numerals. For clarity, the various parts in the accompanying drawings are not drawn to scale. In addition, certain well-known parts may not be shown in the drawings.
[0064] Specific embodiments of the present invention are described in further detail below with reference to the accompanying drawings and examples. Numerous specific details of the present invention, such as component structures, materials, dimensions, processing techniques, and technologies, are described below to facilitate a clearer understanding of the present invention. However, as those skilled in the art will appreciate, the present invention may be practiced without these specific details.
[0065] It should be understood that when describing the structure of a component, when a layer or a region is referred to as being "on" or "over" another layer or region, it may mean that it is directly on the other layer or region, or that other layers or regions are included between it and the other layer or region. Furthermore, if the component is turned over, the layer or region will be "below" or "beneath" the other layer or region.
[0066] Figure 1 FIG. 4 shows a flow chart of a method for shadow area contrast gain according to an embodiment of the present invention. Figure 1 As shown, the shadow area contrast gain method according to an embodiment of the present invention includes the following steps:
[0067] In step S101, the shadow center position of the shadow area is obtained;
[0068] Obtain the center position of the shadow area. For display panel applications, a shadow area is, for example, an area in an image where the local brightness is significantly lower than that of the surrounding area due to an object blocking a light source (such as the sun or lights). Shadow areas can include self-shadows (shadows formed by the object's own structure blocking light) and projected shadows (shadows cast by the object on other surfaces). The center position of the shadow can be at least one of the geometric center, optical center, and lowest brightness point of the shadow area. Optionally, the shadow area and the center position of the shadow are obtained from the display screen (image) to be gained based on prior knowledge or assumptions.
[0069] Optionally, the shaded area is a convex hull region. If the shaded area is not a convex hull region, it can be partitioned to obtain multiple convex hull regions, which can then be processed separately. A convex hull is the smallest convex polygon that contains all given points, where the line connecting any two points lies inside or on the edge of the polygon. In image processing, a convex hull region is a geometric operation that converts the outline of a target region in an image into a minimum convex polygon. The convex hull eliminates concave portions of the original outline to create a completely convex closed region, making it an important tool for shape analysis and feature extraction.
[0070] In step S102, a direction vector of the area to be gained is obtained according to the position of the area to be gained in the shadow area and the center position of the shadow;
[0071] The direction vector of the area to be gained is obtained based on the position of the area to be gained in the shadow area and the center position of the shadow. The area to be gained is, for example, at least a part of the shadow area, which can be a single pixel in the shadow area or a set of adjacent pixels.
[0072] In step S103, the position of the boundary point of the shadow area in the direction of the direction vector is obtained;
[0073] The position of the boundary point of the shadow area in the direction of the direction vector is obtained. In other words, the position of the boundary point is located on the boundary of the shadow area.
[0074] In step S104, a gain coefficient of the area to be gained is obtained according to the position of the boundary point, the position of the area to be gained, and the position of the center of the shadow.
[0075] A gain coefficient for the area to be gained is obtained based on the position of the boundary point, the position of the area to be gained, and the center position of the shadow. Furthermore, the display of the area to be gained can be adjusted based on the obtained gain coefficient. It should be noted that the gain described in this application, in terms of the contrast of the final display image, is not limited to a method of increasing the contrast, but may also include a method of reducing the contrast.
[0076] Image contrast refers to the difference in brightness between the brightest and darkest parts of an image. It determines the layering, detail, and overall visual impact of the bright and dark areas of an image. The higher the contrast, the greater the difference between bright and dark areas, making the image appear more vivid and sharper, enhancing the sense of three-dimensionality and clarity. The shadow area contrast gain method according to an embodiment of the present invention achieves adaptive contrast gain in shadow areas, with an adjustable gain coefficient, while preserving the original contrast in non-shadow areas.
[0077] Optionally, the shadow area contrast gain method further includes: acquiring the brightness of the area to be gained in the shadow area; and obtaining the brightness of the area to be gained after gain according to the gain coefficient and the brightness.
[0078] In an optional embodiment of the present invention, the shadow area contrast gain method further includes: obtaining a display image to be gained; obtaining the shadow area based on the display image to be gained; optionally, extracting the shadow area from the display image to be gained based on a shadow segmentation mask; and gaining the display image to be gained based on the gain coefficient to obtain a display image.
[0079] In an optional embodiment of the present invention, the shadow area contrast gain method further includes:
[0080] Get the display screen to be gained;
[0081] Converting the display image to be gained from the RGB domain to the YUV domain;
[0082] After obtaining the gain coefficient, obtaining a contrast mapping curve of the area to be gained;
[0083] After mapping the area to be gained according to the contrast mapping curve, the YUV domain is converted to the RGB domain for output.
[0084] In the RGB domain, RGB stands for the three colors red, green, and blue. The RGB color model produces a variety of colors by superimposing red, green, and blue light of varying intensities. YUV (domain) is a color encoding method, where Y represents brightness (Luma), and U and V correspond to Cb (blue chromaticity component) and Cr (red chromaticity component), respectively, representing chromaticity (Chroma), used to describe image color and saturation.
[0085] Figure 2 The schematic diagram of the principle of the shadow area contrast gain method according to the embodiment of the present invention is shown. Figure 2 , taking a specific embodiment as an example, the shadow area contrast gain method of the present application is described.
[0086] The shadow area contrast gain method described in this application can first obtain the shadow area and the shadow center position through the shadow adaptive contrast gain algorithm. The shadow adaptive contrast gain algorithm, for example, includes a priori, and can obtain the shadow area (shadow area segmentation prior mask) and the shadow center position based on the priori In image shadow processing, priors refer to prior knowledge or assumptions derived from experience, physical laws, or statistical data, which guide algorithms to more efficiently and accurately detect, remove, or enhance shadows. These priors are typically based on observation and modeling of shadow characteristics (such as brightness, color, shape, and distribution).
[0087] Known shadow center position , set the contrast adjustment base curve of the shadow center position , and at the same time satisfy:
[0088]
[0089] in, is the basic contrast factor; For The brightness value at the position; is the original global mapping curve. Optionally, the original global mapping curve is, for example, an S-shaped curve mapping.
[0090] Of course, the above is only one specific way to obtain the shadow area and the shadow center position, and is not limited thereto. The shadow area and the shadow center position can also be obtained by other ways.
[0091] like Figure 2 As shown, according to the priori and the original image (the image to be displayed after gain processing), the display image (the image after gain processing) can be obtained.
[0092] Specifically, the shadow area contrast gain method includes the following steps:
[0093] Step 1: Color gamut conversion.
[0094] Convert the original image (the image to be displayed) color space from RGB to YUV domain.
[0095] Step 2: Shadow area segmentation.
[0096] According to the shadow mask and the original image, the shadow (local) area is obtained.
[0097] Step 3: Calculate the shadow center position.
[0098] Get the shadow center position through the shadow area If the center of the shadow is known, this step can be omitted.
[0099] Step 4: Calculate the adaptive gain parameters of each pixel in the shadow area (area to be gained).
[0100] Assume that the current pixel (area to be gained) is located at , current pixel brightness , calculate the current pixel direction vector .
[0101] Get the boundary point position of the current direction in the shadow area through the direction vector ,in, .
[0102] The adaptive gain coefficient is calculated by the shadow area boundary point position of the current pixel position and the current pixel point. The gain coefficient .
[0103] Step 5: Calculate the contrast mapping curve of the current pixel position.
[0104] According to the adaptive gain coefficient of the current position and the contrast adjustment base curve of the shadow center position, the contrast mapping curve of the current pixel position is calculated:
[0105] .
[0106] Step 6: Color gamut conversion.
[0107] After mapping, the YUV domain is converted to the RGB domain for output.
[0108] According to another aspect of the present invention, a shadow area contrast gain system is provided, for example, for implementing the shadow area contrast gain method described above. The shadow area contrast gain system includes an acquisition unit, a vector operation unit, a boundary point operation unit, and a gain coefficient operation unit.
[0109] Specifically, the acquiring unit is used to acquire the shadow center position of the shadow area.
[0110] The vector operation unit is used to obtain a direction vector of the area to be gained according to the position of the area to be gained in the shadow area and the center position of the shadow.
[0111] The boundary point operation unit is used to obtain the boundary point position of the shadow area in the direction of the direction vector.
[0112] The gain coefficient calculation unit is used to obtain the gain coefficient of the area to be gained according to the position of the boundary point, the position of the area to be gained and the position of the center of the shadow.
[0113] According to another aspect of the present invention, a (display) chip is provided, which includes the shadow area contrast gain system described above.
[0114] Figure 3 FIG. 1 shows a schematic diagram of the structure of a chip according to an embodiment of the present invention. Figure 3 As shown, the chip according to the embodiment of the present invention includes an acquisition unit 801 , a vector operation unit 802 , a boundary point operation unit 803 and a gain coefficient operation unit 804 .
[0115] Specifically, the acquisition unit 801 acquires the shadow center position of the shadow area. The vector operation unit 802 obtains the direction vector of the area to be gained based on the position of the area to be gained in the shadow area and the shadow center position. The boundary point operation unit 803 obtains the boundary point position of the shadow area in the direction of the direction vector. The gain coefficient operation unit 804 obtains the gain coefficient of the area to be gained based on the boundary point position, the position of the area to be gained and the shadow center position. According to another aspect of the present invention, a display panel is provided. The display panel includes the shadow area contrast gain system as described above. The display panel includes at least one selected from a cathode ray tube display panel, a digital light processing display panel, a liquid crystal display panel, a light emitting diode display panel, an organic light emitting diode display panel, a quantum dot display panel, a Mirco-LED display panel, a Mini-LED display panel, a field emission display panel, a plasma display panel, an electrophoretic display panel or an electrowetting display panel.
[0116] According to another aspect of the present invention, a display device is provided. The display device includes the shadow region contrast gain system described above and a display panel. The display panel is connected to the shadow region contrast gain system to display a display image after being enhanced by the shadow region contrast gain system.
[0117] Figure 4 FIG. 1 shows a schematic structural diagram of a display device according to an embodiment of the present invention. Figure 4 As shown, the display device 9 according to an embodiment of the present invention includes a display panel 901 , a processor 902 and a memory 903 .
[0118] One or more computer programs are stored in the memory 903. When executed by the processor 902, the processor 902 implements the shadow area contrast gain method described above. The display panel 901 displays the image processed by the shadow area contrast gain method.
[0119] According to another aspect of the present invention, a computer-readable storage medium is provided, storing a computer program. When executed by a processor, the program implements the shadow area contrast gain method described above. The computer-readable storage medium according to embodiments of the present invention includes, but is not limited to, the aforementioned memory 903. It can be a unit directly connected to the chip (processor 902) or a standalone unit whose primary function is storage. The computer storage medium of embodiments of the present disclosure can be any combination of one or more computer-readable media. The computer-readable medium can be a computer-readable signal medium or a computer-readable storage medium. The computer-readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. The computer program code for performing the operations of embodiments of the present disclosure can be written in one or more programming languages, or a combination thereof, including object-oriented programming languages (such as Java, Smalltalk, and C++), as well as conventional procedural programming languages such as "C" or similar programming languages.
[0120] It should be noted that, in this document, relational terms such as first and second, etc., are used only to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "comprises," "comprising," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not exclude the presence of additional identical elements in the process, method, article, or apparatus comprising the element.
[0121] While embodiments of the present invention have been described above, these embodiments do not exhaustively describe all details and do not limit the invention to the specific embodiments described. Obviously, many modifications and variations are possible based on the above description. These embodiments are selected and described in detail in this specification in order to better explain the principles and practical applications of the present invention, thereby enabling those skilled in the art to better utilize the present invention and its modifications. The present invention is limited only by the claims and their full scope and equivalents.
Claims
1. A method for increasing contrast in shadow areas, comprising: Get the shadow center position of the shadow area; Obtaining a direction vector of the area to be gained according to the position of the area to be gained in the shadow area and the center position of the shadow; Obtaining the position of the boundary point of the shadow area in the direction of the direction vector; Obtaining a gain coefficient of the area to be gained according to the position of the boundary point, the position of the area to be gained, and the center position of the shadow; Adjust the display of the area to be gained according to the gain coefficient, The shaded area is a convex hull area, which is a completely convex closed area. A line connecting any two points on the convex hull area is located inside or on the edge of the convex hull area.
2. The shadow area contrast gain method according to claim 1, wherein: The shadow area contrast gain method further includes: Obtaining the brightness of the area to be gained in the shadow area; The brightness of the area to be gained is obtained according to the gain coefficient and the brightness.
3. The shadow area contrast gain method according to claim 1, wherein: The center position of the shadow is ; The position of the area to be gained is ; The direction vector ; The boundary point position is ,in, ; The gain factor ; The shadow area contrast gain method further includes: Get the contrast adjustment base curve of the shadow center position , in, is the basic contrast coefficient, For The brightness value at the position, is the original global mapping curve; According to the gain coefficient and the contrast adjustment base curve, the contrast mapping curve of the area to be gained is obtained. .
4. The shadow area contrast gain method according to claim 1, wherein: The shadow area contrast gain method further includes: Get the display screen to be gained; The shadow area is obtained according to the display picture to be gained.
5. The shadow area contrast gain method according to claim 4, wherein: The shadow area contrast gain method further includes: extracting the shadow area from the display picture to be gained according to the shadow segmentation mask; The to-be-gained display picture is gained according to the gain coefficient to obtain a display picture.
6. The shadow area contrast gain method according to claim 1, wherein: The shadow area contrast gain method further includes: The shadow area and the shadow center position are acquired from the display picture to be gained according to a priori.
7. The shadow area contrast gain method according to claim 1, wherein: The shadow area contrast gain method further includes: Get the display screen to be gained; Converting the display image to be gained from the RGB domain to the YUV domain; After obtaining the gain coefficient, obtaining a contrast mapping curve of the area to be gained; After mapping the area to be gained according to the contrast mapping curve, the YUV domain is converted to the RGB domain for output.
8. A shadow area contrast enhancement system comprising: An acquisition unit, used for acquiring the shadow center position of the shadow area; A vector operation unit, configured to obtain a direction vector of the area to be gained according to a position of the area to be gained in the shadow area and a center position of the shadow; A boundary point calculation unit, configured to obtain a boundary point position of the shadow area in the direction of the direction vector; a gain coefficient calculation unit, configured to obtain a gain coefficient of the area to be gained according to the position of the boundary point, the position of the area to be gained, and the position of the center of the shadow, wherein, the display of the area to be gained is adjusted according to the gain coefficient; The shaded area is a convex hull area, which is a completely convex closed area. The line connecting any two points on the convex hull area is located inside or on the edge of the convex hull area.
9. A chip comprising: The shadow area contrast enhancement system of claim 8.
10. A display panel comprising: The shadow area contrast enhancement system according to claim 8, The display panel includes at least one selected from a cathode ray tube display panel, a digital light processing display panel, a liquid crystal display panel, a light emitting diode display panel, an organic light emitting diode display panel, a quantum dot display panel, a Mirco-LED display panel, a Mini-LED display panel, a field emission display panel, a plasma display panel, an electrophoretic display panel or an electrowetting display panel.
11. A display device comprising: The shadow area contrast enhancement system according to claim 8; as well as A display panel is connected to the shadow area contrast gain system to display a display image after being enhanced by the shadow area contrast gain system.
12. A computer-readable storage medium having a computer program stored thereon, wherein: When the program is executed by a processor, the shadow area contrast gain method according to any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Program capable of improving contrast of shading portion, and improvement method of contrast of shading portion
JP2005348081A