CN114441033B - Ambient light intensity calibration method, device, electronic device and storage medium - Google Patents
Ambient light intensity calibration method, device, electronic device and storage medium Download PDFInfo
- Publication number
- CN114441033B CN114441033B CN202210089928.6A CN202210089928A CN114441033B CN 114441033 B CN114441033 B CN 114441033B CN 202210089928 A CN202210089928 A CN 202210089928A CN 114441033 B CN114441033 B CN 114441033B
- Authority
- CN
- China
- Prior art keywords
- light leakage
- brightness
- compensation
- color
- display
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 42
- 238000001514 detection method Methods 0.000 claims abstract description 118
- 238000004364 calculation method Methods 0.000 claims description 13
- 238000004590 computer program Methods 0.000 claims description 9
- 241001270131 Agaricus moelleri Species 0.000 claims description 2
- 230000007613 environmental effect Effects 0.000 description 16
- 238000004891 communication Methods 0.000 description 8
- 238000012545 processing Methods 0.000 description 8
- 230000001276 controlling effect Effects 0.000 description 6
- 238000012360 testing method Methods 0.000 description 5
- 238000010586 diagram Methods 0.000 description 4
- 238000002834 transmittance Methods 0.000 description 4
- 239000003086 colorant Substances 0.000 description 3
- 238000005516 engineering process Methods 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000009434 installation Methods 0.000 description 3
- 230000003993 interaction Effects 0.000 description 3
- 230000001105 regulatory effect Effects 0.000 description 3
- ORFSSYGWXNGVFB-UHFFFAOYSA-N sodium 4-amino-6-[[4-[4-[(8-amino-1-hydroxy-5,7-disulfonaphthalen-2-yl)diazenyl]-3-methoxyphenyl]-2-methoxyphenyl]diazenyl]-5-hydroxynaphthalene-1,3-disulfonic acid Chemical compound COC1=C(C=CC(=C1)C2=CC(=C(C=C2)N=NC3=C(C4=C(C=C3)C(=CC(=C4N)S(=O)(=O)O)S(=O)(=O)O)O)OC)N=NC5=C(C6=C(C=C5)C(=CC(=C6N)S(=O)(=O)O)S(=O)(=O)O)O.[Na+] ORFSSYGWXNGVFB-UHFFFAOYSA-N 0.000 description 3
- 238000011161 development Methods 0.000 description 2
- 102000006822 Agouti Signaling Protein Human genes 0.000 description 1
- 108010072151 Agouti Signaling Protein Proteins 0.000 description 1
- 238000002474 experimental method Methods 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 230000002452 interceptive effect Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000011160 research Methods 0.000 description 1
- 230000008054 signal transmission Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01J—MEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
- G01J1/00—Photometry, e.g. photographic exposure meter
- G01J1/42—Photometry, e.g. photographic exposure meter using electric radiation detectors
- G01J1/4204—Photometry, e.g. photographic exposure meter using electric radiation detectors with determination of ambient light
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01J—MEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
- G01J1/00—Photometry, e.g. photographic exposure meter
- G01J1/42—Photometry, e.g. photographic exposure meter using electric radiation detectors
- G01J1/44—Electric circuits
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01J—MEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
- G01J3/00—Spectrometry; Spectrophotometry; Monochromators; Measuring colours
- G01J3/46—Measurement of colour; Colour measuring devices, e.g. colorimeters
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01J—MEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
- G01J1/00—Photometry, e.g. photographic exposure meter
- G01J1/42—Photometry, e.g. photographic exposure meter using electric radiation detectors
- G01J1/44—Electric circuits
- G01J2001/444—Compensating; Calibrating, e.g. dark current, temperature drift, noise reduction or baseline correction; Adjusting
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02B—CLIMATE CHANGE MITIGATION TECHNOLOGIES RELATED TO BUILDINGS, e.g. HOUSING, HOUSE APPLIANCES OR RELATED END-USER APPLICATIONS
- Y02B20/00—Energy efficient lighting technologies, e.g. halogen lamps or gas discharge lamps
- Y02B20/40—Control techniques providing energy savings, e.g. smart controller or presence detection
Landscapes
- Physics & Mathematics (AREA)
- Spectroscopy & Molecular Physics (AREA)
- General Physics & Mathematics (AREA)
- Life Sciences & Earth Sciences (AREA)
- Sustainable Development (AREA)
- Controls And Circuits For Display Device (AREA)
Abstract
The embodiment of the invention provides an environment light intensity calibration method, an environment light intensity calibration device, electronic equipment and a storage medium, and relates to the technical field of display. According to the embodiment of the invention, after the detection environment light intensity detected by the detection device arranged in the display screen and the display brightness and color information of the display area corresponding to the detection device are obtained, a target light leakage compensation value corresponding to the color information is determined according to a preset calibration relation library, a brightness compensation coefficient is obtained according to the display brightness and the maximum display brightness of the display screen, the compensation brightness of the display area is determined according to the target light leakage compensation value and the brightness compensation coefficient, and the detection environment light intensity is calibrated according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
Description
Technical Field
The invention relates to the technical field of display, in particular to an environment light intensity calibration method, an environment light intensity calibration device, electronic equipment and a storage medium.
Background
Electronic equipment such as cell-phone, panel computer are provided with the function of automatically regulated display brightness in order to improve user experience, in the use, can adjust display brightness according to environment light intensity. However, with the progress of technology, electronic devices continuously pursue an extremely comprehensive screen visual effect, and simultaneously continuously increase the screen occupation ratio and continuously squeeze the installation space of each device in the display screen. For the detection device for detecting the ambient light intensity, the distance between the detection device and the display screen is more and more shorter, when the ambient light intensity is detected, the light leakage of the backlight of the display screen can be doped into the actual ambient light intensity, so that the detection device cannot accurately detect the actual ambient light intensity of the current environment.
Disclosure of Invention
Based on the above-mentioned research, the embodiment of the invention provides an environment light intensity calibration method, an environment light intensity calibration device, an electronic device and a storage medium, which can calibrate the detection environment light intensity detected by a detection device according to the display brightness and color information of a display screen, and improve the accuracy of the detection environment light intensity detected by the detection device.
In a first aspect, an embodiment of the present invention provides a method for calibrating environmental light intensity, where the method includes:
Acquiring the light intensity of a detection environment detected by a detection device arranged in a display screen, and the display brightness and color information of a display area corresponding to the detection device;
determining and obtaining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library; the calibration relation library comprises the color information and target light leakage compensation values corresponding to the color information;
Obtaining a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
and determining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrating the light intensity of the detection environment according to the compensation brightness.
In an optional embodiment, the calibration relation library includes a gray scale calibration relation library and a color calibration relation library, and the step of determining, according to a preset calibration relation library, a target light leakage compensation value corresponding to the color information includes:
Detecting whether all color channel values included in the color information are smaller than or equal to a preset gray detection value or larger than or equal to a preset gray detection value;
if not, determining the target light leakage compensation value corresponding to the color information in the color calibration relation library;
if yes, determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relation library.
In an alternative embodiment, the step of determining the target light leakage compensation value corresponding to the color information in the color calibration relation library includes:
determining a target sub-color space corresponding to the color information in the color calibration relation library; the color calibration relation library comprises light leakage compensation values corresponding to each target sub-color space;
Setting a light leakage compensation value corresponding to the target sub-color space as a target light leakage compensation value corresponding to the color information;
the step of determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library comprises the following steps:
determining a target gray level corresponding to the color information in the gray calibration relation library; the gray scale calibration relation library comprises light leakage compensation values corresponding to each target gray scale;
and setting the light leakage compensation value corresponding to the target gray level as a target light leakage compensation value corresponding to the color information.
In an optional embodiment, before determining the target light leakage compensation value corresponding to the color information in the color calibration relation library, the method further includes:
dividing a preset RGB color space into a plurality of sub-color spaces according to a preset threshold value;
aiming at each sub-color space, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen in the sub-color space, wherein the color of the display screen is the sub-color space;
And establishing an association relation between each sub-color space and a corresponding light leakage compensation value, and obtaining the color calibration relation library according to the association relation.
In an optional embodiment, before determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library, the method further includes:
Aiming at each preset gray level, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen at the gray level, wherein the color of the display screen is the gray level;
And establishing association relations between the gray scales and the corresponding light leakage compensation values, and obtaining the gray scale calibration relation library according to the association relations.
In an alternative embodiment, the step of determining the compensated luminance of the display area according to the target light leakage compensation value and the luminance compensation coefficient includes:
Obtaining the maximum light leakage value of the display screen and presetting a standard light leakage value;
obtaining a screen compensation coefficient according to the maximum light leakage value of the display screen and the ratio of the preset standard light leakage value;
and determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient.
In an alternative embodiment, the step of determining the compensated luminance according to the target light leakage compensation value, the luminance compensation coefficient, and the screen compensation coefficient includes:
acquiring transparency information of a display area corresponding to the detection device;
Determining and obtaining a transparency compensation coefficient according to the transparency information and a preset corresponding relation;
and determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient, the screen compensation coefficient and the transparency compensation coefficient.
In a second aspect, an embodiment of the present invention provides an ambient light intensity calibration device, including:
the acquisition module is used for acquiring the detection environment light intensity detected by the detection device arranged in the display screen, and the display brightness and the color information of the display area corresponding to the detection device;
the searching module is used for determining and obtaining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library; the calibration relation library comprises the color information and target light leakage compensation values corresponding to the color information;
the first calculation module is used for obtaining a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
And the second calculation module is used for determining and obtaining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrating the light intensity of the detection environment according to the compensation brightness.
In a third aspect, an embodiment of the present invention provides an electronic device, where the electronic device includes a memory, a processor, and a computer program stored on the memory and capable of running on the processor, and when the processor executes the computer program, the processor implements the ambient light intensity calibration method according to any one of the foregoing embodiments.
In a fourth aspect, an embodiment of the present invention provides a storage medium having stored thereon a computer program, which when executed by a processor, implements the ambient light intensity calibration method according to any of the previous embodiments.
According to the environment light intensity calibration method, the environment light intensity calibration device, the electronic equipment and the storage medium, after the detected environment light intensity detected by the detection device arranged in the display screen and the display brightness and color information of the display area corresponding to the detection device are obtained, a target light leakage compensation value corresponding to the color information is determined according to a preset calibration relation library, a brightness compensation coefficient is obtained according to the display brightness and the maximum display brightness of the display screen, then the compensation brightness of the display area is determined according to the target light leakage compensation value and the brightness compensation coefficient, and the detected environment light intensity is calibrated according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present invention, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Fig. 2 is a flow chart of an environmental light intensity calibration method according to an embodiment of the invention.
Fig. 3 is a block diagram of an environmental light intensity calibration device according to an embodiment of the invention.
Icon: 100-an electronic device; 10-an ambient light intensity calibration device; 11-an acquisition module; 12-a search module; 13-a first calculation module; 14-a second calculation module; 20-memory; 30-a processor; a 40-communication unit; 50-display unit.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to fall within the scope of the invention.
In the description of the present invention, it should be understood that the terms "center", "longitudinal", "lateral", "length", "width", "thickness", "upper", "lower", "front", "rear", "left", "right", "vertical", "horizontal", "top", "bottom", "inner", "outer", etc. indicate orientations or positional relationships based on the drawings are merely for convenience in describing the present invention and simplifying the description, and do not indicate or imply that the apparatus or elements referred to must have a specific orientation, be configured and operated in a specific orientation, and thus should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and the like, are used for descriptive purposes only and are not to be construed as indicating or implying a relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more of the described features. In the description of the present invention, the meaning of "a plurality" is two or more, unless explicitly defined otherwise.
In the present invention, the term "exemplary" is used to mean "serving as an example, instance, or illustration. Any embodiment described as "exemplary" in this disclosure is not necessarily to be construed as preferred or advantageous over other embodiments. The following description is presented to enable any person skilled in the art to make and use the invention. In the following description, details are set forth for purposes of explanation. It will be apparent to one of ordinary skill in the art that the present invention may be practiced without these specific details. In other instances, well-known structures and processes have not been described in detail so as not to obscure the description of the invention with unnecessary detail. Thus, the present invention is not intended to be limited to the embodiments shown, but is to be accorded the widest scope consistent with the principles and features disclosed herein.
With the development of technology, electronic devices such as mobile phones and tablet computers all have the function of automatically adjusting display brightness, and can be adjusted according to the light intensity of the environment. However, with the development of the full screen technology, the installation space of each device inside the mobile phone is smaller and smaller, and the device is closer to the screen for detecting the environmental light intensity, and when the screen is displayed, backlight light leakage can be doped into the actual environmental light intensity, so that the accuracy of the environmental light intensity detected by the detection device is affected.
Based on the above problems, the method, the device, the electronic equipment and the storage medium for calibrating the environmental light intensity according to the embodiments of the present invention determine, after obtaining the detected environmental light intensity detected by the detecting device disposed in the display screen and the display brightness and color information of the display area corresponding to the detecting device, a target light leakage compensation value corresponding to the color information according to a preset calibration relational library, obtain a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen, and then determine the compensation brightness of the obtained display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrate the detected environmental light intensity according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
Referring to fig. 1, fig. 1 is a schematic structural diagram of an electronic device according to the present embodiment. As shown in fig. 1, the electronic device 100 includes an ambient light intensity calibration apparatus 10, a memory 20, a processor 30, a communication unit 40, and a display unit 50. The memory 20, the processor 30, the communication unit 40 and the display unit 50 are electrically connected to each other directly or indirectly, so as to realize signal transmission or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines.
In this embodiment, the ambient light intensity calibration device 10 includes at least one software functional module that may be stored in the memory 20 in the form of software or firmware (firmware). The processor 30 is configured to execute executable modules (e.g., software functional modules or computer programs included in the ambient light intensity calibration device 10) stored in the memory 20. When the electronic device 100 is running, the processor 30 and the memory 20 communicate with each other through a bus, and the processor 30 executes an executable module or a computer program to implement the ambient light intensity calibration method described in this embodiment.
The Memory 20 may be, but is not limited to, a random access Memory (Random Access Memory, RAM), a Read Only Memory (ROM), a programmable Read Only Memory (Programmable Read-Only Memory, PROM), an erasable Read Only Memory (Erasable Programmable Read-Only Memory, EPROM), an electrically erasable Read Only Memory (Electric Erasable Programmable Read-Only Memory, EEPROM), etc.
The processor 30 is operative to perform one or more functions described in the present embodiments. In some embodiments, processor 30 may include one or more processing cores (e.g., a single core processor (S) or a multi-core processor (S)). By way of example only, processor 30 may include a central processing unit (Central Processing Unit, CPU), application-specific integrated Circuit (ASIC), application-specific instruction set Processor (Application Specific Instruction set Processor, ASIP), graphics processing unit (Graphics Processing Unit, GPU), physical processing unit (Physics Processing Unit, PPU), digital signal Processor (DIGITAL SIGNAL Processor, DSP), field-programmable gate array (Field Programmable GATE ARRAY, FPGA), programmable logic device (Programmable Logic Device, PLD), controller, microcontroller unit, reduced instruction set computer (Reduced Instruction Set Computing, RISC), or microprocessor, or the like, or any combination thereof.
For ease of illustration, only one processor is depicted in the electronic device 100. It should be noted, however, that the electronic device 100 in the present embodiment may also include a plurality of processors, and thus the steps performed by one processor described in the present embodiment may also be performed jointly by a plurality of processors or performed separately. For example, if the processor of the electronic device performs step a and step B, it should be understood that step a and step B may also be performed by two different processors together or performed separately in one processor. For example, the processor performs step a, the second processor performs step B, or the processor and the second processor together perform steps a and B.
In this embodiment, the method of defining a flow disclosed in any embodiment may be applied to the processor 30 or implemented by the processor 30.
The communication unit 40 is used for establishing a communication connection between the electronic device 100 and other devices through a network, and for transceiving data through the network.
In some embodiments, the network may be any type of wired or wireless network, or a combination thereof. By way of example only, the network may include a wired network, a wireless network, a fiber optic network, a telecommunications network, an intranet, the internet, a local area network (Local Area Network, LAN), a wide area network (Wide Area Network, WAN), a wireless local area network (Wireless Local Area Networks, WLAN), a metropolitan area network (Metropolitan Area Network, MAN), a wide area network (Wide Area Network, WAN), a public switched telephone network (Public Switched Telephone Network, PSTN), a bluetooth network, a ZigBee network, a near field Communication (NEAR FIELD Communication, NFC) network, or the like, or any combination thereof.
In this embodiment, the display unit 50 provides an interactive interface (e.g., a user operation interface) between the electronic device 100 and the user for displaying image information. In this embodiment, the display unit 50 may be a liquid crystal display or a touch display. In the case of a touch display, the touch display may be a capacitive touch screen or a resistive touch screen, etc. supporting single-point and multi-point touch operations. Supporting single-point and multi-point touch operations means that the touch display can sense touch operations generated from one or more locations on the touch display and communicate the sensed touch operations to the processor 30 for computation and processing.
To facilitate interaction between the user and the display unit 50, in this embodiment, the electronic device 100 may further include an input/output unit for providing input data to the user, so as to implement interaction between the user and the electronic device 100. The input/output unit may be, but is not limited to, a mouse, a keyboard, and the like.
In some embodiments, the electronic device 100 may include 1 or N display units 50, N being a positive integer greater than 1.
In this embodiment, the electronic device may be a device having a display screen and a detection device for detecting the intensity of ambient light, such as a mobile phone, a tablet computer, etc., and the specific type thereof is not limited.
It will be appreciated that the structure shown in fig. 1 is merely illustrative. The electronic device 100 may also have more or fewer components than shown in fig. 1, or have a different configuration than shown in fig. 1. The components shown in fig. 1 may be implemented in hardware, software, or a combination thereof.
Based on the implementation architecture of fig. 1, the present embodiment provides an ambient light intensity calibration method, which is executed by the electronic device of fig. 1, and the ambient light intensity calibration method provided by the present embodiment is described in detail below based on the block diagram of the electronic device 100 provided in fig. 1. Referring to fig. 2 in combination, the method for calibrating the ambient light intensity according to the present embodiment includes steps S101 to S104.
S101: and acquiring the light intensity of the detection environment detected by the detection device arranged in the display screen, and the display brightness and the color information of the display area corresponding to the detection device.
The method for calibrating the environmental light intensity provided by the embodiment can calibrate the environmental light intensity detected by the detection device of the electronic equipment such as a mobile phone, a tablet computer, a palm computer and the like. The detection device may be a detection device disposed in the electronic device, may be disposed below the display screen, and in this embodiment, the detection device may be a light sensor or the like, and is used for detecting the light intensity of the environment, and the embodiment is not limited specifically.
In this embodiment, since the area where the light leakage of the display screen has the greatest influence on the detection device is the area directly above the detection device, only the display brightness and the color information of the display area corresponding to the detection device in the display screen are obtained in consideration of minimizing the operation amount. The display area is determined according to the size and the installation position of the detection device, and may be an area with a fixed size centered on the detection device, which is not specifically limited in this embodiment. Such as: the display area may select a 200 by 200 pixel area directly above the light sensor.
The color information in this embodiment characterizes the color of the display area of the display screen corresponding to the detection device.
Optionally, in this embodiment, the step of acquiring color information of a display area corresponding to the detection device in the display screen includes:
reading RGB values of each pixel point in the display area;
A reference value is calculated according to RGB values of each pixel point in the display area, and the reference value is color information of the display area.
Specifically, the reference value may be an average value, a median value, a mode value, or the like of RGB values of each pixel in the display area, so long as the reference value can represent a display color of the display area, and the embodiment is not limited.
The display brightness is integrally adjusted by the display screen, so in the embodiment, the display brightness of the display area is the current display brightness of the display screen, and the current display brightness of the display screen can be directly read.
S102: determining and obtaining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library; the calibration relation library comprises color information and target light leakage compensation values corresponding to the color information.
In this embodiment, the target light leakage compensation value corresponding to the color information may be obtained from a preset calibration relation library. The calibration relation library may be stored in a memory of the electronic device and may be stored in the form of a file or the like. The calibration relation library comprises color information and target light leakage compensation values corresponding to the color information.
In this embodiment, the target light leakage compensation value corresponding to the color information is represented as follows: when the display screen is in a dark environment, the display brightness of the display screen is the maximum display brightness, and the display color of the display screen corresponds to the color information, the light leakage brightness is detected by the detection device. For example: the color information of the display area is the average value of RGB values of all pixel points of the display area, the average value is 100,135,232, the display screen is placed in darkness, the display content of the display screen is regulated, the RGB values of all pixel points of the display screen are 100,135,232, the brightness of the display screen is regulated to the maximum brightness of 120Lux, at the moment, the light leakage brightness detected by the detection device is 10Lux, and the RGB (100,135,232) is in a calibration relation library, and the determined target light leakage compensation value corresponding to the color information is 10Lux.
In this embodiment, since the display screen transmittance of different electronic devices is different, the corresponding relationship between the color information and the target light leakage compensation value in the calibration relationship library of different electronic devices is different. Before the electronic equipment leaves the factory, the display screen of each electronic equipment can be tested respectively to determine the corresponding calibration relation library, and the corresponding calibration relation library is stored in the memory of the electronic equipment for subsequent use. It can be understood that, for easy operation, a standard calibration relation library can be constructed based on the display screen of the test electronic device, and when other electronic devices use the standard calibration relation library to calibrate the detection environment light intensity of the detection device, the display screen difference between different devices is taken into consideration for calibration.
S103: obtaining a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
In this embodiment, the target light leakage compensation value corresponding to the color information is the light leakage brightness detected by the detection device when the display screen is in the dark environment, the display brightness of the display screen is the maximum display brightness, and the display color of the display screen corresponds to the color information. The target light leakage compensation value corresponds to the light leakage brightness when the display brightness of the display screen is the maximum display brightness, but the current display brightness of the display screen is not necessarily the maximum display brightness, so calibration is required according to the current display brightness and the maximum display brightness of the display screen. When calculating the brightness compensation coefficient, the ratio of the current display brightness to the maximum display brightness can be directly taken, and the influence of the change of the display brightness on the light leakage brightness can be pre-calculated to determine and obtain the brightness compensation coefficient.
In this embodiment, for simplicity of calculation, the ratio of the current display brightness of the display screen to the maximum display brightness of the display screen is directly calculated to obtain the brightness compensation coefficient.
S104: and determining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrating the light intensity of the detection environment according to the compensation brightness.
In this embodiment, after the target light leakage compensation value and the brightness compensation coefficient are obtained, the current display brightness of the display screen and the compensation brightness corresponding to the color information, that is, the brightness doped into the actual environmental light intensity, can be determined. Therefore, the detected ambient light intensity detected by the detecting device needs to be subtracted by the compensation brightness, which is the actual ambient light intensity. For example: and detecting the light intensity of the environment to be L, wherein the target light leakage compensation value is L 1, the brightness compensation coefficient is C 1 = current display brightness/maximum display brightness, and determining the obtained compensation brightness to be L C=L1*C1, and then determining the actual light intensity of the environment to be L F=L-LC.
In this embodiment, a target light leakage compensation value corresponding to color information of a display area is determined by using a preset calibration relation library, and then the target light leakage compensation value is calibrated according to current display brightness, so as to obtain the current display brightness of the display area and compensation brightness corresponding to the color information, namely, light leakage brightness doped in actual environment light intensity is obtained, the detection environment light intensity detected by a detection device can be calibrated, and the accuracy of automatically adjusting brightness of electronic equipment according to the detection environment light intensity is ensured.
Optionally, in this embodiment, the calibration relation library includes a gray calibration relation library and a color calibration relation library, and the step of determining, according to the preset calibration relation library, the target light leakage compensation value corresponding to the color information includes:
detecting whether all color channel values included in the color information are smaller than or equal to a preset gray detection value or larger than or equal to a preset gray detection value;
if not, determining a target light leakage compensation value corresponding to the color information in a color calibration relation library;
if yes, determining a target light leakage compensation value corresponding to the color information in a gray scale calibration relation library.
In this embodiment, the calibration relational library includes a gray calibration relational library and a color calibration relational library, where the gray calibration relational library and the color calibration relational library correspond to different color information respectively. When determining the target light leakage compensation value corresponding to the color information, it is necessary to determine whether each color channel value of the color information accords with the preset gray detection value, if so, the target light leakage compensation value corresponding to the color information is considered to be similar to the target light leakage compensation value corresponding to the equivalent gray value, and for simple calculation, the target light leakage compensation value corresponding to the equivalent gray value can be set as the target light leakage compensation value corresponding to the color information. Wherein, the determination of the equivalent gray value can utilize the color psychology formula: gray value=r×0.299+g×0.587+b×0.114, wherein R, G, B is a value corresponding to R, G, B color channels (red, green, and blue color channels) of the color information, respectively.
In this embodiment, the preset gray detection value can be determined by a person skilled in the art through experiments, and when the RGB value corresponding to the color information is equal to or greater than or equal to the gray detection value at the same time; the target light leakage compensation value corresponding to the RGB value is relatively close to the target light leakage compensation value corresponding to the equivalent gray value calculated by using the color psychology formula. For example: the preset gray detection value is 128, the RGB value corresponding to the color information of the display area is (100,120,90), the value of the R, G, B color channel is less than or equal to 128, when the target light leakage compensation value corresponding to the RGB value is determined in the gray calibration relation library, the gray value y=100×0.299+120×0.587+90×0.114=110.6×111 corresponding to the RGB value is calculated, the equivalent gray value corresponding to the RGB value is (111 ), and the target light leakage compensation value corresponding to the equivalent gray value is found in the gray calibration relation library to be the target light leakage compensation value corresponding to the color information.
In this embodiment, when determining the target light leakage compensation value corresponding to the color information, it is first determined whether the color information accords with the preset gray detection value, if so, the target light leakage compensation value corresponding to the color information is determined in the gray calibration relation library, and if not, the target light leakage compensation value corresponding to the color information is determined in the color calibration relation library, so that the efficiency can be improved, and the target light leakage compensation value corresponding to the color information can be quickly determined.
Optionally, in this embodiment, in the color calibration relation library, the step of determining the target light leakage compensation value corresponding to the color information includes:
Determining a target sub-color space corresponding to the color information in a color calibration relation library; the color calibration relation library comprises light leakage compensation values corresponding to each target sub-color space;
setting a light leakage compensation value corresponding to the target sub-color space as a target light leakage compensation value corresponding to the color information;
in the gray scale calibration relation library, the step of determining the target light leakage compensation value corresponding to the color information comprises the following steps:
Determining a target gray level corresponding to the color information in a gray calibration relation library; the gray scale calibration relation library comprises light leakage compensation values corresponding to each target gray scale;
and setting the light leakage compensation value corresponding to the target gray level as the target light leakage compensation value corresponding to the color information.
When determining the corresponding target light leakage compensation value of the color information in the color calibration relation library, determining the target sub-color space corresponding to the color information, and determining the light leakage compensation value corresponding to the target sub-color space in the color calibration relation library, namely, determining the target light leakage compensation value corresponding to the color information.
Correspondingly, in this embodiment, when determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library, the target gray scale corresponding to the color information needs to be determined first, and in the gray scale calibration relational library, the light leakage compensation value corresponding to the target gray scale is determined, that is, the target light leakage compensation value corresponding to the color information.
In this embodiment, when determining the target gray level corresponding to the color information, the corresponding equivalent gray value is calculated according to the color information by using the color psychology formula described in the foregoing embodiment, and the calculation method is the same as that of the foregoing embodiment, and will not be repeated here. After the equivalent gray level corresponding to the color information is obtained, determining the target gray level corresponding to the equivalent gray level, and setting the light leakage compensation value corresponding to the target gray level in the gray level calibration relation library as the target light leakage compensation value corresponding to the color information.
In this embodiment, the color information is determined by using the preset gray detection value to determine the target light leakage compensation value corresponding to the color information in the gray calibration relation library or the color calibration relation library, so that the efficiency of determining the target light leakage compensation value corresponding to the color information can be improved.
Optionally, in this embodiment, before determining the target light leakage compensation value corresponding to the color information in the color calibration relational library, the method further includes:
dividing a preset RGB color space into a plurality of sub-color spaces according to a preset threshold value;
Aiming at each sub-color space, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen for the sub-color space to obtain a light leakage compensation value of the display screen in the sub-color space;
and establishing an association relation between each sub-color space and the corresponding light leakage compensation value, and obtaining a color calibration relation library according to the association relation.
In this embodiment, the preset RGB color space indicates that: in the cartesian coordinate system, the color space established by taking R, G, B color channels (red, green and blue color channels) as axes is set to 256 for each gray level R, G, B, so that the color space is 256 by 256, and the red, green and blue components are all combined to represent tens of millions of colors, if each color needs to calculate the corresponding light leakage compensation value, the calculation amount is very large. Therefore, in the present embodiment, when the color calibration relation library is established, in order to reduce the amount of calculation, the RGB color space is divided into a plurality of sub-color spaces according to the preset threshold value, and the light leakage compensation value of each sub-color space is calculated.
In this embodiment, when determining the light leakage luminance corresponding to each sub-color space, the display screen is placed in a dark environment for each sub-color space, the display luminance of the display screen is adjusted to be the maximum display luminance, and the display color of the display screen is the sub-color space, and at this time, the light leakage luminance detected by the detection device is the light leakage compensation value corresponding to the feature value. The display color of the display screen is an RGB value corresponding to the characteristic value of the sub-color space, where the characteristic value is a value that can represent each sub-color space, such as a mean value, a mode value, a median value, etc. of each RGB value in each sub-color space, and the embodiment is not specifically limited. After the light leakage compensation value corresponding to the RGB value of each characteristic value is determined, the association relation between each sub-color space and the corresponding light leakage compensation value is determined, and a color calibration relation library can be constructed according to the association relation. Such as: the preset threshold value is 32 x 32, after the space of 256 x 256 is divided, 512 sub-color spaces can be obtained, and the light leakage brightness corresponding to the RGB value of the central point of each sub-color space is used as the target light leakage compensation value corresponding to each sub-color space.
In this embodiment, the RGB color space is divided according to the preset threshold value to obtain a plurality of sub-color spaces, and the light leakage compensation value corresponding to each sub-color space is represented by the light leakage brightness corresponding to the characteristic value of each sub-color space, so that the color calibration relation library can be simply and conveniently calculated and quickly constructed.
Optionally, in this embodiment, before determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library, the method further includes:
Aiming at each preset gray level, controlling the display brightness of the display screen to be the maximum display brightness and the color of the display screen to be the gray level in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen at the gray level;
and establishing an association relation between each gray level and the corresponding light leakage compensation value, and obtaining a gray calibration relation library according to the association relation.
When the R, G, B color channel values are equal, gray is displayed, and the three color channel values are different, the gray level is different. In this embodiment, the number of color channels R, G, B is 0-255, and the preset gray levels are 256, the display screen is placed in a dark environment, the display brightness of the display screen is adjusted to the maximum display brightness, the colors of 256 gray levels are displayed respectively, so that the light leakage brightness corresponding to 256 gray levels can be detected, the light leakage compensation value corresponding to each gray level is obtained, the association relation between the gray level and the light leakage compensation value is established, and the gray calibration relation library can be constructed according to the association relation.
In this embodiment, in order to simplify the operation, when a standard calibration relation library is constructed based on testing the display screen of the electronic device, since light leakage of the display screens of different electronic devices is different, it is necessary to determine the screen compensation coefficient between different electronic devices.
Optionally, in this embodiment, the step of determining the compensated luminance of the display area according to the target light leakage compensation value and the luminance compensation coefficient includes:
Obtaining a maximum light leakage value of a display screen and presetting a standard light leakage value;
obtaining a screen compensation coefficient according to the maximum light leakage value of the display screen and the ratio of the preset standard light leakage value;
And determining to obtain the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient.
Wherein, because the transmittance of the display screens of different electronic devices is different, even if the same picture and brightness are displayed, the light leakage brightness of the display screens is also different. If the corresponding calibration relation library is built according to each electronic device, the workload is huge, so in this embodiment, for the sake of simple calculation, a standard calibration relation library is built based on the display screen of the test electronic device. When other electronic equipment uses the standard calibration relation library to correct the ambient light intensity, the calibration is carried out according to the screen compensation coefficients among the display screens of different electronic equipment.
Based on the above, the present embodiment calculates the ratio of the maximum light leakage value of the current display screen to the preset standard light leakage value to obtain the screen compensation coefficient, so as to calibrate the transmittance difference between the display screens of different electronic devices. The preset standard light leakage value represents the maximum light leakage value of the display screen of the test electronic device, and in the embodiment, the maximum light leakage value is that the display screen is placed in a dark environment, the display brightness of the display screen is adjusted to be maximum brightness, and when the display colors are pure white, pure red, pure green and pure blue respectively, the detection device detects each light leakage brightness.
Optionally, in this embodiment, the step of obtaining the screen compensation coefficient according to the ratio of the maximum light leakage value of the display screen to the preset standard light leakage value includes:
according to the maximum light leakage value of the display screen and a preset standard light leakage value, respectively determining the light leakage brightness ratio when the display color of the display screen is pure white, pure red, pure green or pure blue;
And determining and obtaining a screen compensation coefficient according to the color information and the light leakage brightness ratio corresponding to each display color.
When different display screens display the same color, the light leakage brightness is different due to the difference of the display screens. Therefore, in order to calibrate the differences between different devices more accurately, in this embodiment, in the gray scale calibration relation library, when determining the target light leakage compensation value corresponding to the color information, only the light leakage brightness ratio corresponding to the pure white display color needs to be considered, and the light leakage brightness ratio corresponding to the pure white display color is the screen compensation coefficient. In the color calibration relation library, when determining the target light leakage compensation value corresponding to the color information, the weight of the brightness ratio of each display color is required to be determined according to the color information of the display screen, and then the weight is weighted to obtain the screen compensation coefficient. For example: the calibration relation library corresponding to the RGB value of the color information of the display area is a color calibration relation library, the calculated light leakage brightness ratio corresponding to the pure red display color is r, the calculated light leakage brightness ratio corresponding to the pure green display color is g, the calculated light leakage brightness ratio corresponding to the pure blue display color is b, weights obtained according to the RGB value corresponding to the color information of the display area are 0.5, 0.3 and 0.2 respectively, and then the screen compensation coefficient P=0.5r+0.3g+0.2b.
After the screen compensation coefficient of the calibrated electronic equipment is determined, the compensation brightness of the display area can be determined according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient. For example: the screen compensation coefficient is C 2, the target light leakage compensation value is L 1, the brightness compensation coefficient is C 1 =current display brightness/maximum display brightness, and the compensation brightness lc=l 1*C1*C2.
In this embodiment, the screen compensation coefficient is obtained through the maximum light leakage value of the display screen and the preset standard light leakage value, the target light leakage compensation value is calibrated, and the influence of the transmittance between different display screens is considered, so that the detection environment light intensity detected by the detection device can be calibrated more accurately.
Optionally, in this embodiment, the step of determining the compensated luminance according to the target light leakage compensation value, the luminance compensation coefficient and the screen compensation coefficient includes:
acquiring transparency information of a display area corresponding to the detection device;
according to the transparency information and a preset corresponding relation, determining and obtaining a transparency compensation coefficient;
And determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient, the screen compensation coefficient and the transparency compensation coefficient.
In this embodiment, when calibrating the intensity of the detection environment of the detection device, the transparency of the display area is also considered. In this embodiment, when transparency information corresponding to the detection device is obtained, the transparency information of the whole display area is represented by reading the alpha value of each pixel point in the display area, and calculating the mean value, the mode value, the median value, and the like of the alpha value of each pixel point. In this embodiment, the alpha channel is 8 bits, and has 256 levels of translucence, the value of alpha is 0-255, and the greater the value of the alpha channel, the lower the brightness.
In this embodiment, the influence of the transparency information on the light leakage is approximately equal to the gamma coefficient, and the preset corresponding relationship in this embodiment is [ (255-current alpha value)/255 ]. Times.2.2.
In this embodiment, when the calibration relation library corresponding to the test electronic device is used to calibrate the light intensity of the detection environment of other electronic devices, the compensation brightness is obtained according to the target light leakage compensation value, the brightness compensation coefficient, the screen compensation coefficient and the transparency compensation coefficient, and the detection environment light intensity detected by the detection device is calibrated by using the compensation brightness, so that the detection environment light intensity detected by the detection device can be calibrated more accurately. For example: the transparency calibration coefficient is C 3, the screen compensation coefficient is C 2, the target light leakage compensation value is L 1, the brightness compensation coefficient is C 1 =current display brightness/maximum display brightness, and the compensation brightness lc=l 1*C1*C2*C3.
It can be understood that when the calibration relation library corresponds to the calibrated electronic device one by one, the screen calibration coefficient is not needed, and the compensation brightness is obtained directly according to the light leakage compensation value, the brightness compensation coefficient and the transparency compensation coefficient. For example: the transparency calibration coefficient is C 3, the target light leakage compensation value is L 1, the brightness compensation coefficient is C 1 =current display brightness/maximum display brightness, and the compensation brightness lc=l 1*C1*C3.
According to the environment light intensity calibration method provided by the embodiment of the invention, after the detected environment light intensity detected by the detection device arranged in the display screen and the display brightness and color information of the display area corresponding to the detection device are obtained, a target light leakage compensation value corresponding to the color information is determined according to the preset calibration relation library, a brightness compensation coefficient is obtained according to the display brightness and the maximum display brightness of the display screen, the compensation brightness of the display area is determined according to the target light leakage compensation value and the brightness compensation coefficient, and the detected environment light intensity is calibrated according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
Based on the same inventive concept, please refer to fig. 3 in combination, the present embodiment further provides an environmental light intensity calibration device 10, which is applied to the electronic device shown in fig. 1, as shown in fig. 3, and includes:
An obtaining module 11, configured to obtain the detected ambient light intensity detected by the detecting device disposed in the display screen, and display brightness and color information of a display area corresponding to the detecting device;
the searching module 12 is configured to determine, according to a preset calibration relation library, a target light leakage compensation value corresponding to the color information; the calibration relation library comprises color information and target light leakage compensation values corresponding to the color information;
the first calculation module 13 is configured to obtain a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
the second calculating module 14 is configured to determine a compensation luminance of the display area according to the target light leakage compensation value and the luminance compensation coefficient, and calibrate the detected ambient light intensity according to the compensation luminance.
In an alternative embodiment, the lookup module 12 is further configured to:
detecting whether all color channel values included in the color information are smaller than or equal to a preset gray detection value or larger than or equal to a preset gray detection value;
if not, determining a target light leakage compensation value corresponding to the color information in a color calibration relation library;
if yes, determining a target light leakage compensation value corresponding to the color information in a gray scale calibration relation library.
In an alternative embodiment, the lookup module 12 is further configured to:
Determining a target sub-color space corresponding to the color information in a color calibration relation library; the color calibration relation library comprises light leakage compensation values corresponding to each target sub-color space;
setting a light leakage compensation value corresponding to the target sub-color space as a target light leakage compensation value corresponding to the color information;
Determining a target gray level corresponding to the color information in a gray calibration relation library; the gray scale calibration relation library comprises light leakage compensation values corresponding to each target gray scale;
and setting the light leakage compensation value corresponding to the target gray level as the target light leakage compensation value corresponding to the color information.
In an alternative embodiment, the lookup module 12 is further configured to:
dividing a preset RGB color space into a plurality of sub-color spaces according to a preset threshold value;
Aiming at each sub-color space, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen for the sub-color space to obtain a light leakage compensation value of the display screen in the sub-color space;
and establishing an association relation between each sub-color space and the corresponding light leakage compensation value, and obtaining a color calibration relation library according to the association relation.
In an alternative embodiment, the lookup module 12 is further configured to:
Aiming at each preset gray level, controlling the display brightness of the display screen to be the maximum display brightness and the color of the display screen to be the gray level in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen at the gray level;
and establishing an association relation between each gray level and the corresponding light leakage compensation value, and obtaining a gray calibration relation library according to the association relation.
In an alternative embodiment, the second computing module 14 is further configured to:
Obtaining a maximum light leakage value of a display screen and presetting a standard light leakage value;
obtaining a screen compensation coefficient according to the maximum light leakage value of the display screen and the ratio of the preset standard light leakage value;
And determining to obtain the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient.
In an alternative embodiment, the second computing module 14 is further configured to:
acquiring transparency information of a display area corresponding to the detection device;
according to the transparency information and a preset corresponding relation, determining and obtaining a transparency compensation coefficient;
And determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient, the screen compensation coefficient and the transparency compensation coefficient.
According to the environment light intensity calibration device provided by the embodiment of the invention, after the detected environment light intensity detected by the detection device arranged in the display screen and the display brightness and color information of the display area corresponding to the detection device are obtained, a target light leakage compensation value corresponding to the color information is determined according to the preset calibration relation library, a brightness compensation coefficient is obtained according to the display brightness and the maximum display brightness of the display screen, the compensation brightness of the display area is determined according to the target light leakage compensation value and the brightness compensation coefficient, and the detected environment light intensity is calibrated according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
It will be clear to those skilled in the art that, for convenience and brevity of description, the specific operation of the above-described ambient light intensity calibration device 10 may refer to the corresponding procedure in the above-described method, and will not be described in detail herein.
On the basis of the above, the present embodiment provides a readable storage medium, on which a computer program is stored, which when executed by a processor implements the ambient light intensity calibration method of any of the foregoing embodiments.
It will be clear to those skilled in the art that, for convenience and brevity of description, reference may be made to corresponding procedures in the foregoing method for the specific working procedure of the readable storage medium described above, and thus, redundant description is not necessary.
In summary, according to the method, the device, the electronic equipment and the storage medium for calibrating the environmental light intensity provided by the embodiment of the invention, after the detected environmental light intensity detected by the detecting device arranged in the display screen and the display brightness and color information of the display area corresponding to the detecting device are obtained, the target light leakage compensation value corresponding to the color information is determined according to the preset calibration relational library, the brightness compensation coefficient is obtained according to the display brightness and the maximum display brightness of the display screen, the compensation brightness of the display area is determined according to the target light leakage compensation value and the brightness compensation coefficient, and the detected environmental light intensity is calibrated according to the compensation brightness. Therefore, the compensation brightness is obtained according to the color information and the display brightness of the display area corresponding to the detection device, the detection environment light intensity detected by the detection device is calibrated, and the accuracy of the detection environment light intensity detected by the detection device is improved.
The above description is merely illustrative of various embodiments of the present invention, but the scope of the present invention is not limited thereto, and any person skilled in the art can easily think about variations or substitutions within the scope of the present invention, and the invention is intended to be covered by the scope of the present invention. Therefore, the protection scope of the invention is subject to the protection scope of the claims.
Claims (9)
1.A method of calibrating ambient light intensity, the method comprising:
Acquiring the light intensity of a detection environment detected by a detection device arranged in a display screen, and the display brightness and color information of a display area corresponding to the detection device;
determining and obtaining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library; the calibration relation library comprises the color information and target light leakage compensation values corresponding to the color information;
Obtaining a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
determining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrating the light intensity of the detection environment according to the compensation brightness;
The step of determining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient comprises the following steps:
Obtaining the maximum light leakage value of the display screen and presetting a standard light leakage value;
obtaining a screen compensation coefficient according to the maximum light leakage value of the display screen and the ratio of the preset standard light leakage value;
and determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient.
2. The method according to claim 1, wherein the calibration relation library includes a gray scale calibration relation library and a color calibration relation library, and the step of determining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library includes:
Detecting whether all color channel values included in the color information are smaller than or equal to a preset gray detection value or larger than or equal to a preset gray detection value;
if not, determining the target light leakage compensation value corresponding to the color information in the color calibration relation library;
if yes, determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relation library.
3. The method according to claim 2, wherein the step of determining the target light leakage compensation value corresponding to the color information in the color calibration relational library comprises:
determining a target sub-color space corresponding to the color information in the color calibration relation library; the color calibration relation library comprises light leakage compensation values corresponding to each target sub-color space;
Setting a light leakage compensation value corresponding to the target sub-color space as a target light leakage compensation value corresponding to the color information;
the step of determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library comprises the following steps:
determining a target gray level corresponding to the color information in the gray calibration relation library; the gray scale calibration relation library comprises light leakage compensation values corresponding to each target gray scale;
and setting the light leakage compensation value corresponding to the target gray level as a target light leakage compensation value corresponding to the color information.
4. The method according to claim 2, wherein before determining the target light leakage compensation value corresponding to the color information in the color calibration relation library, the method further comprises:
dividing a preset RGB color space into a plurality of sub-color spaces according to a preset threshold value;
aiming at each sub-color space, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen in the sub-color space, wherein the color of the display screen is the sub-color space;
And establishing an association relation between each sub-color space and a corresponding light leakage compensation value, and obtaining the color calibration relation library according to the association relation.
5. The method according to claim 2, wherein before determining the target light leakage compensation value corresponding to the color information in the gray scale calibration relational library, the method further comprises:
Aiming at each preset gray level, controlling the display brightness of the display screen to be the maximum display brightness in a dark environment, and detecting the light leakage brightness of the display screen to obtain a light leakage compensation value of the display screen at the gray level, wherein the color of the display screen is the gray level;
And establishing association relations between the gray scales and the corresponding light leakage compensation values, and obtaining the gray scale calibration relation library according to the association relations.
6. The method according to claim 1, wherein the step of determining the compensation luminance according to the target light leakage compensation value, the luminance compensation coefficient, and the screen compensation coefficient comprises:
acquiring transparency information of a display area corresponding to the detection device;
Determining and obtaining a transparency compensation coefficient according to the transparency information and a preset corresponding relation;
and determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient, the screen compensation coefficient and the transparency compensation coefficient.
7. An ambient light intensity calibration device, comprising:
the acquisition module is used for acquiring the detection environment light intensity detected by the detection device arranged in the display screen, and the display brightness and the color information of the display area corresponding to the detection device;
the searching module is used for determining and obtaining a target light leakage compensation value corresponding to the color information according to a preset calibration relation library; the calibration relation library comprises the color information and target light leakage compensation values corresponding to the color information;
the first calculation module is used for obtaining a brightness compensation coefficient according to the display brightness and the maximum display brightness of the display screen;
The second calculation module is used for determining and obtaining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient, and calibrating the light intensity of the detection environment according to the compensation brightness;
The step of determining the compensation brightness of the display area according to the target light leakage compensation value and the brightness compensation coefficient comprises the following steps:
Obtaining the maximum light leakage value of the display screen and presetting a standard light leakage value;
obtaining a screen compensation coefficient according to the maximum light leakage value of the display screen and the ratio of the preset standard light leakage value;
and determining and obtaining the compensation brightness according to the target light leakage compensation value, the brightness compensation coefficient and the screen compensation coefficient.
8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the processor implementing the ambient light intensity calibration method of any one of claims 1 to 6 when the computer program is executed by the processor.
9. A storage medium having stored thereon a computer program which, when executed by a processor, implements the ambient light intensity calibration method of any one of claims 1 to 6.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210089928.6A CN114441033B (en) | 2022-01-25 | 2022-01-25 | Ambient light intensity calibration method, device, electronic device and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210089928.6A CN114441033B (en) | 2022-01-25 | 2022-01-25 | Ambient light intensity calibration method, device, electronic device and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114441033A CN114441033A (en) | 2022-05-06 |
CN114441033B true CN114441033B (en) | 2024-11-22 |
Family
ID=81369209
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210089928.6A Active CN114441033B (en) | 2022-01-25 | 2022-01-25 | Ambient light intensity calibration method, device, electronic device and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114441033B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN115657992B (en) * | 2022-10-10 | 2024-03-19 | 荣耀终端有限公司 | Screen display method, device, equipment and storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107945769A (en) * | 2017-11-22 | 2018-04-20 | 广东欧珀移动通信有限公司 | Ambient light intensity detection method and device, storage medium and electronic equipment |
CN109817152A (en) * | 2019-04-09 | 2019-05-28 | Oppo广东移动通信有限公司 | screen brightness adjusting method and related product |
CN113763856A (en) * | 2021-07-19 | 2021-12-07 | 荣耀终端有限公司 | Method and device for determining ambient illumination intensity and storage medium |
Family Cites Families (21)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP3719411B2 (en) * | 2001-05-31 | 2005-11-24 | セイコーエプソン株式会社 | Image display system, projector, program, information storage medium, and image processing method |
US7595811B2 (en) * | 2001-07-26 | 2009-09-29 | Seiko Epson Corporation | Environment-complaint image display system, projector, and program |
JP3894302B2 (en) * | 2002-03-25 | 2007-03-22 | セイコーエプソン株式会社 | Image display system, image processing method, program, and information storage medium |
US8847972B2 (en) * | 2010-01-20 | 2014-09-30 | Intellectual Ventures Fund 83 Llc | Adapting display color for low luminance conditions |
EP2403223B1 (en) * | 2010-06-30 | 2017-08-16 | BlackBerry Limited | Adaptation of display illumination depending on ambient light |
US9489918B2 (en) * | 2013-06-19 | 2016-11-08 | Lenovo (Beijing) Limited | Information processing methods and electronic devices for adjusting display based on ambient light |
CN106157926A (en) * | 2015-03-23 | 2016-11-23 | 中兴通讯股份有限公司 | A kind of method and device regulating brightness of display screen |
KR102139751B1 (en) * | 2015-04-21 | 2020-07-31 | 삼성전자주식회사 | Display apparatus and control method thereof |
CN105070269B (en) * | 2015-08-17 | 2017-12-22 | 惠州Tcl移动通信有限公司 | The color display and system of a kind of mobile terminal |
CN108716950A (en) * | 2018-05-16 | 2018-10-30 | 北京小米移动软件有限公司 | Environmental light brightness acquisition methods and device |
CN108648700B (en) * | 2018-05-18 | 2020-02-18 | 京东方科技集团股份有限公司 | Dynamic dimming display control method and device for backlight source |
CN108917921B (en) * | 2018-06-15 | 2020-06-09 | 江西合力泰科技有限公司 | Ambient light intensity detection method |
EP3864645A1 (en) * | 2018-10-08 | 2021-08-18 | Google LLC | Systems and methods for adjusting light emitted from a display |
WO2020191707A1 (en) * | 2019-03-28 | 2020-10-01 | 华为技术有限公司 | Method and apparatus for displaying image |
CN110535997B (en) * | 2019-08-12 | 2021-03-19 | 上海创功通讯技术有限公司 | Method, device and equipment for calibrating terminal screen light leakage and storage medium |
CN111179861B (en) * | 2019-12-11 | 2021-06-15 | Tcl移动通信科技(宁波)有限公司 | Brightness calibration method and device, storage medium and terminal |
CN111613176B (en) * | 2020-05-18 | 2021-07-13 | 维沃移动通信有限公司 | Ambient light detection method and electronic device |
CN112289280B (en) * | 2020-11-18 | 2022-03-22 | 深圳市锐尔觅移动通信有限公司 | Screen brightness adjusting method and device, computer readable medium and electronic equipment |
CN112599088B (en) * | 2020-12-02 | 2022-04-12 | 深圳市汇顶科技股份有限公司 | Screen light leakage and ambient light detection method, chip, terminal and storage medium |
CN112781832A (en) * | 2021-01-26 | 2021-05-11 | 北京小米移动软件有限公司 | Method, apparatus, device and medium for determining ambient light for terminal device |
CN113838436B (en) * | 2021-09-27 | 2023-01-20 | 惠州Tcl移动通信有限公司 | Color temperature adjusting method, device, storage medium and electronic equipment |
-
2022
- 2022-01-25 CN CN202210089928.6A patent/CN114441033B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107945769A (en) * | 2017-11-22 | 2018-04-20 | 广东欧珀移动通信有限公司 | Ambient light intensity detection method and device, storage medium and electronic equipment |
CN109817152A (en) * | 2019-04-09 | 2019-05-28 | Oppo广东移动通信有限公司 | screen brightness adjusting method and related product |
CN113763856A (en) * | 2021-07-19 | 2021-12-07 | 荣耀终端有限公司 | Method and device for determining ambient illumination intensity and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN114441033A (en) | 2022-05-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US11015973B2 (en) | Method and apparatus for acquiring ambient light brightness based on the luminance value of the screen of a terminal device | |
CN111613176B (en) | Ambient light detection method and electronic device | |
CN109238460B (en) | Method for obtaining ambient light intensity and terminal equipment | |
CN112289280B (en) | Screen brightness adjusting method and device, computer readable medium and electronic equipment | |
US11348507B2 (en) | Method and apparatus for identifying current | |
CN110648626A (en) | Method and system for correcting bright and dark lines of LED display screen and storage medium thereof | |
TWI413101B (en) | Control method for improving the luminous uniformity and related luminosity calibrating controller and display device | |
CN112017577B (en) | Screen display calibration method and device | |
CN108920007B (en) | Touch reporting threshold setting method and system | |
CN109819088B (en) | Light sensation calibration method and related device | |
US20200154003A1 (en) | Gamma Value Tuning Method and Device of Display Panel | |
KR102634812B1 (en) | Method, apparatus and electronic device for estimating screen light leakage amount | |
CN114441033B (en) | Ambient light intensity calibration method, device, electronic device and storage medium | |
CN113495709A (en) | Color correction method, AP chip, terminal and storage medium | |
CN111459233A (en) | Display method, electronic device, and storage medium | |
CN117316082A (en) | Display control method, device, equipment, medium and product | |
CN110896466B (en) | White balance adjustment method and system of display device | |
CN105976746A (en) | Flicker adjustment method and device | |
CN115979419B (en) | Ambient light detection method, device, equipment and storage medium | |
CN112365833B (en) | Method for detecting and correcting brightness adjustment value of light sensation under screen | |
CN112504442B (en) | Parameter determination method, device, equipment and storage medium | |
US20230410706A1 (en) | Method for image rendering, terminal device and non-transitory computer-readable storage medium | |
CN113763893A (en) | Backlight adjustment method, apparatus, system and computer program product | |
US11375084B2 (en) | Measurement method for measuring a physical property value of light output of a display device | |
CN113243030A (en) | Image processing method and device |
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 |