CN111179882A - Display screen brightness adjusting method and device, electronic equipment and storage medium - Google Patents

Display screen brightness adjusting method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN111179882A
CN111179882A CN202010144263.5A CN202010144263A CN111179882A CN 111179882 A CN111179882 A CN 111179882A CN 202010144263 A CN202010144263 A CN 202010144263A CN 111179882 A CN111179882 A CN 111179882A
Authority
CN
China
Prior art keywords
light sensation
value
terminal
target
display screen
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.)
Granted
Application number
CN202010144263.5A
Other languages
Chinese (zh)
Other versions
CN111179882B (en
Inventor
林进全
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Oppo Chongqing Intelligent Technology Co Ltd
Original Assignee
Oppo Chongqing Intelligent Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo Chongqing Intelligent Technology Co Ltd filed Critical Oppo Chongqing Intelligent Technology Co Ltd
Priority to CN202010144263.5A priority Critical patent/CN111179882B/en
Publication of CN111179882A publication Critical patent/CN111179882A/en
Application granted granted Critical
Publication of CN111179882B publication Critical patent/CN111179882B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G5/00Control arrangements or circuits for visual indicators common to cathode-ray tube indicators and other visual indicators
    • G09G5/10Intensity circuits
    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G2320/00Control of display operating conditions
    • G09G2320/06Adjustment of display parameters
    • G09G2320/0626Adjustment of display parameters for control of overall brightness

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Controls And Circuits For Display Device (AREA)

Abstract

The application discloses a display screen brightness adjusting method and device, electronic equipment and a storage medium, and belongs to the technical field of screen display. The method is used in a terminal with a display screen, and comprises the following steps: acquiring a first light sensation value; detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, and the target state is that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value and the target light sensation value is smaller than a second preset threshold value; when the first light sensation value is within the target light sensation interval, acquiring a target light sensation value; and adjusting the brightness of the display screen according to the target light sensation value. The stroboscopic phenomenon that the terminal is direct to be brought according to the luminance of the first light sense value regulation display screen that acquires can be avoided to this application, has improved the adjustting of the lighteness effect of display screen.

Description

Display screen brightness adjusting method and device, electronic equipment and storage medium
Technical Field
The embodiment of the application relates to the technical field of screen display, in particular to a display screen brightness adjusting method and device, electronic equipment and a storage medium.
Background
With the advancement of technology, a display screen is one of indispensable components in most terminals, and the terminals can display application interfaces of various applications in the display screen.
At present, in a terminal, a user can manually adjust the brightness of a display screen, or the terminal can automatically adjust the brightness of the display screen when starting a function of automatically adjusting the brightness of the display screen. Wherein, in the aspect of the luminance of automatically regulated display screen, most terminals all realize the regulation to display screen luminance through setting up fixed light sense anti-shake interval. For example, the brightness of the display screen is 100nit (nit), the light-sensing anti-shake interval corresponding to the brightness is 80 to 140lx (lux), when the light-sensing value detected by the terminal is within the light-sensing anti-shake interval, the terminal does not adjust the brightness of the display screen, and when the light-sensing value detected by the terminal is outside the light-sensing anti-shake interval, the terminal automatically adjusts the brightness of the display screen.
Wherein, when the light sense anti-shake interval's that the luminance of display screen corresponds scope is less, the terminal detects the light sense value constantly changing inside and outside this light sense anti-shake interval easily to constantly adjust the luminance of display screen, lead to the stroboscopic phenomenon to appear in the display screen.
Disclosure of Invention
The embodiment of the application provides a display screen brightness adjusting method and device, electronic equipment and a storage medium, which can prevent the problem that stroboscopic phenomenon occurs on a display screen due to the fact that acquired light sensation values of the display screen change on two sides of the boundary value of a light sensation anti-shake interval at a terminal. The technical scheme is as follows:
in one aspect, an embodiment of the present application provides a method for adjusting brightness of a display screen, where the method is used in a terminal having the display screen, and the method includes:
acquiring a first light sensation value, wherein the first light sensation value is the illumination intensity of ambient light received by the display screen at the current moment by the terminal;
detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to a target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained by the terminal last time before the current moment is smaller than the second preset threshold value;
when the first light sensation value is within the target light sensation interval, acquiring the target light sensation value;
and adjusting the brightness of the display screen according to the target light sensation value.
In another aspect, an embodiment of the present application provides a display screen brightness adjusting apparatus, where the apparatus is used in a terminal having a display screen, and the apparatus includes:
the terminal comprises a first acquisition module, a second acquisition module and a control module, wherein the first acquisition module is used for acquiring a first light sensation value, and the first light sensation value is the illumination intensity of the ambient light received by the display screen at the current moment;
the first detection module is used for detecting whether the first light sensation value is in a target light sensation interval, the target light sensation interval is a light sensation interval obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value and the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is a light sensation value recorded when the light sensation value obtained by the terminal at the last time before the current moment is smaller than the second preset threshold value;
the second acquisition module is used for acquiring the target light sensation value when the first light sensation value is in the target light sensation interval;
and the brightness adjusting module is used for adjusting the brightness of the display screen according to the target light sensation value.
In another aspect, an embodiment of the present application provides an electronic device, where the terminal includes a processor and a memory, where the memory stores at least one instruction, at least one program, a code set, or a set of instructions, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by the processor to implement the display screen brightness adjustment method according to the above aspect.
In another aspect, the present application provides a computer-readable storage medium, in which at least one instruction, at least one program, a code set, or a set of instructions is stored, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by a processor to implement the display screen brightness adjustment method according to the above aspect.
The technical scheme provided by the embodiment of the application can at least comprise the following beneficial effects:
acquiring a first light sensation value, wherein the first light sensation value is the illumination intensity of ambient light received by a display screen at the current moment; detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in a display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained last time before the current moment by the terminal is smaller than the second preset threshold value; when the first light sensation value is within the target light sensation interval, acquiring a target light sensation value; and adjusting the brightness of the display screen according to the target light sensation value. This application is through acquireing target light sense interval according to target light sense value, when the first light sense value that the terminal acquireed is in target light sense interval, adjusts the luminance of display screen according to target light sense value, has avoided the terminal directly to adjust the stroboscopic phenomenon that the luminance of display screen brought according to the first light sense value that acquires, has improved the luminance regulation effect of display screen.
Drawings
FIG. 1 is a schematic interface diagram of display screens with different brightness in a terminal according to an exemplary embodiment of the present application;
FIG. 2 is a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application;
FIG. 3 is a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application;
FIG. 4 is a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application;
fig. 5 is a block diagram illustrating a structure of a display screen brightness adjusting apparatus according to an exemplary embodiment of the present disclosure;
fig. 6 is a schematic structural diagram of a terminal according to an exemplary embodiment of the present application.
Detailed Description
Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, like numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present application. Rather, they are merely examples of apparatus and methods consistent with certain aspects of the present application, as detailed in the appended claims.
Reference herein to "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, meaning that there may be three relationships, e.g., a and/or B, which may mean: a exists alone, A and B exist simultaneously, and B exists alone. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship.
According to the scheme, when people use the terminal in daily life, after the automatic brightness adjusting function of the display screen is set in the terminal, the terminal realizes the real scene of automatic brightness adjustment of the display screen, and for convenience of understanding, a few nouns and application scenes related to the embodiment of the application are firstly and simply introduced below.
The illumination intensity is as follows: refers to the luminous flux of visible light received per unit area. For short, illuminance is expressed in Lux (Lux or lx). Which may indicate the intensity of the illumination and the degree to which the surface of the object is illuminated.
Light sensation under the screen: the light sensor is arranged below the display screen and is a hardware design scheme.
Brightness: the intensity of light and shade of an object is defined as the luminous intensity per unit area, and the unit is nit (nit), 1 nit is 1 kantera per square meter (cd/m)2)。
With the development of science and technology, more and more terminals appear in people's daily life, and people can work, amusement, study etc. through the terminal. Among them, the display screen is an important component in most terminals, and the adjustment of brightness thereof is one of important aspects of people's attention.
Referring to fig. 1, a schematic interface diagram of a display screen with different brightness in a terminal according to an exemplary embodiment of the present application is shown. As shown in fig. 1, which includes a terminal 110.
Alternatively, the terminal 110 is a terminal mounted with a display screen. For example, the terminal may be a mobile phone, a tablet computer, an e-book reader, smart glasses, a smart watch, an MP3 player (Moving Picture Experts Group audio Layer III, motion Picture Experts Group audio Layer IV, motion Picture Experts Group audio Layer 4), an MP4 player, a notebook computer, a laptop computer, a desktop computer, and the like.
Optionally, the user may adjust the brightness of the display screen in the terminal 110 by controlling the brightness control, or the terminal 110 may also have a function of automatically adjusting the brightness of the display screen, and when the user opens the function of automatically adjusting the brightness of the display screen in the terminal, the terminal 110 may also adjust the brightness of the display screen by collecting the illumination intensity of the ambient light by itself.
In the related art, the terminal automatically adjusts the brightness of the display screen as follows. The terminal is divided into different brightness levels corresponding to different display screen brightness in advance, and a light sensation anti-shake interval is set for each brightness level and can indicate the change range of the illumination intensity of the ambient light received by the display screen supported by the terminal under a certain brightness level. The terminal can control the brightness change of the display screen through the acquired illumination intensity of the ambient light received by the display screen and the light sensation anti-shake interval. If the illumination intensity of the ambient light received by the display screen acquired by the terminal is within the light sensation anti-shake interval, the terminal cannot adjust the brightness of the display screen, namely, the brightness of the display screen cannot be changed. If the illumination intensity of the ambient light received by the display screen acquired by the terminal is not in the light sensation anti-shake interval, the terminal can adjust the brightness of the display screen, namely, the brightness of the display screen can be changed.
For example, the current brightness of the display screen is 100nit, the light-sensing anti-shake interval corresponding to the brightness value is 80 to 140Lux, and at this time, if the illumination intensity of the ambient light received by the display screen acquired by the terminal is 100Lux, the brightness of the display screen does not change. However, if the illumination intensity of the ambient light received by the display screen acquired by the terminal is 70Lux or 150Lux, the terminal searches for the corresponding brightness according to the illumination intensity of the ambient light received by the display screen acquired here, and sets the brightness of the display screen to the brightness found here.
Under the scheme, the sizes of the light-sensing anti-shake areas set by the terminals are different in the scenes that the display screen is at higher brightness (for example, the brightness of the display screen is not less than 20Lux) and higher brightness (for example, the brightness of the display screen is less than 20 Lux). For example, the current brightness of the display screen is 500nit, the light-sensing anti-shake interval corresponding to 500nit may be 1200 to 2000Lux, the current brightness of the display screen is 16nit, and the light-sensing anti-shake interval corresponding to 16nit may be 20 to 35 Lux.
Wherein, when the brightness of the display screen is 500nit, the probability that the illumination intensity of the ambient light received by the display screen acquired by the terminal jumps repeatedly around the boundary value of the light-sensing anti-shake interval is low, and when the brightness of the display screen is 16nit, the probability that the illumination intensity of the ambient light received by the display screen acquired by the terminal jumps repeatedly around the boundary value of the light-sensing anti-shake interval is high, that is, the illumination intensity of the ambient light received by the display screen acquired by the terminal is influenced by the variation of the illumination intensity in the ambient environment when the brightness of the display screen is 16nit more greatly than the illumination intensity of the ambient light received by the display screen acquired by the terminal when the brightness of the display screen is 500nit, so that the illumination intensity of the ambient light received by the display screen acquired by the terminal is easy to change continuously at the boundary of the light-sensing anti-shake interval, therefore, the brightness of the display screen is continuously adjusted, so that the stroboscopic phenomenon of the display screen is caused, and the display effect of the display screen is reduced.
In order to prevent the problem that the stroboscopic phenomenon occurs to the display screen due to the fact that the acquired light sensation value of the display screen changes on two sides of the boundary value of the light sensation anti-shake interval, the display screen brightness adjusting method can record the light sensation interval corresponding to the illumination intensity through detecting the size relation between the illumination intensity of the display screen acquired by the terminal and the second preset threshold value, and therefore the display effect of the display screen of the terminal is improved.
Referring to fig. 2, a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application is shown. The method can be used in the terminal with the display screen shown in fig. 1, and as shown in fig. 2, the display screen brightness adjusting method can include the following steps.
Step 201, a first light sensation value is obtained, where the first light sensation value is an illumination intensity of ambient light received by a display screen of the terminal at a current time.
The current time may be a current time of a display screen of the terminal in a normal working process when the display screen is turned on. Ambient light may refer to light received by the light sensor other than the light of the terminal's own display.
Optionally, in the process that the display screen is lighted up, the terminal may obtain, in real time, the illumination intensity of the ambient light received by the display screen through the optical sensor below the display screen.
Step 202, detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained last time before the current time by the terminal is smaller than the second preset threshold value.
The terminal can periodically acquire the light sensation value, when the acquired light sensation value is smaller than a second preset threshold value, the terminal can record a light sensation value, and the target light sensation value can be the light sensation value acquired at this time.
In step 203, when the first light sensation value is within the target light sensation interval, a target light sensation value is obtained.
When the terminal detects that the acquired first light sensation value is within the target light sensation interval, the terminal can acquire the light sensation value recorded when the second light sensation value detected before is smaller than the second preset threshold value. Optionally, the recorded light sensation value is a second light sensation value, that is, when the terminal detects that the second light sensation value is smaller than a second preset threshold, the terminal records the second light sensation value.
And 204, adjusting the brightness of the display screen according to the target light sensation value.
The terminal can use the target light sensation value as a first light sensation value acquired at the current moment, and judge whether the brightness of the display screen needs to be adjusted according to the target light sensation value.
In summary, by acquiring the first light sensation value, the first light sensation value is the illumination intensity of the ambient light received by the display screen at the current moment; detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in a display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained last time before the current moment by the terminal is smaller than the second preset threshold value; when the first light sensation value is within the target light sensation interval, acquiring a target light sensation value; and adjusting the brightness of the display screen according to the target light sensation value. This application is through acquireing target light sense interval according to target light sense value, when the first light sense value that the terminal acquireed is in target light sense interval, adjusts the luminance of display screen according to target light sense value, has avoided the terminal directly to adjust the stroboscopic phenomenon that the luminance of display screen brought according to the first light sense value that acquires, has improved the luminance regulation effect of display screen.
In a possible implementation manner, the terminal may indicate whether the terminal is currently in the target state by setting a status flag bit. The above embodiment is described by taking as an example that the terminal needs to detect whether the terminal is in the target state before detecting whether the acquired first light sensation value is within the target light sensation interval.
Referring to fig. 3, a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application is shown. The method can be used in the terminal with the display screen shown in fig. 1, and as shown in fig. 3, the display screen brightness adjusting method can include the following steps.
Step 301, a first light sensation value is obtained.
The first light sensation value is the illumination intensity of the environment light received by the display screen at the current moment.
In practical application, the illumination intensity that the terminal can acquire through the optical sensor is the sum of the illumination intensity of the light emitted by the display screen and the illumination intensity of the ambient light, and if the terminal needs to obtain the illumination intensity of the ambient light, the illumination intensity of the light emitted by the display screen needs to be subtracted from the illumination intensity directly received by the optical sensor. Optionally, the terminal may obtain the brightness of its own display screen, and calculate the illumination intensity of the display screen to the light sensor, so as to obtain the illumination intensity of the ambient light received by the display screen through calculation.
Step 302, detecting whether the terminal is in a target state.
The target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is a light sensation value recorded when a light sensation value acquired by the terminal last time before the current moment is smaller than the second preset threshold value.
Optionally, in this embodiment of the application, a light sensation value that is obtained by the terminal last time before the current time may be referred to as a second light sensation value, that is, the terminal may obtain the second light sensation value before the current time in a manner similar to the manner of obtaining the first light sensation value, and compare the second light sensation value with a second preset threshold, if the terminal detects that the second light sensation value is smaller than the second preset threshold, the terminal may record the second light sensation value, and use the second light sensation value as the target light sensation value. For example, the second preset threshold is 20Lux, and when the second light sensitivity value acquired by the terminal is 16Lux, the terminal may record the second light sensitivity value (16Lux) as the target light sensitivity value.
In a possible implementation manner, the terminal may also detect a magnitude relationship between pixel values of a predetermined number of pixels in the display screen and the first preset threshold when detecting a magnitude relationship between the second light sensation value and the second preset threshold. Optionally, the terminal may acquire, through the image acquisition assembly, an image in the display screen of the terminal at the same time as the second light sensation value, acquire a pixel value of each pixel point in the image, compare the pixel value of each pixel point with a first preset threshold, and count a first number, where the first number is the number of pixel points whose pixel values are greater than the first preset threshold, and when the first number counted by the terminal is greater than the preset number, it may be determined that the pixel values of the pixel points of the preset number in the display screen are greater than the first preset threshold.
For example, the pixel value of each pixel of the display screen in the terminal is represented by an RGB (Red Green Blue ) color mode, and the first preset threshold may be 224. Then, after the terminal collects the image in the terminal display screen at the same time as the second light sensation value through the image collection assembly, the value of each pixel point is obtained and compared with 224, the number of the pixel points which are larger than 224 is counted, and then whether the number of the pixel points which are larger than 224 is larger than the preset number is judged, so that whether the pixel values of the pixel points with the preset number in the display screen are larger than a first preset threshold value is determined.
The first preset threshold, the second preset threshold and the preset number can be set in the terminal in advance by a developer or an operation and maintenance person.
Optionally, when the terminal determines that the pixel values of the preset number of pixel points in the display screen are greater than a first preset threshold and the target light sensation value is smaller than a second preset threshold, the terminal may determine that the terminal is currently in the target state.
Optionally, the terminal may further include a status flag bit, and the status flag bit indicates whether the terminal is in the target state. For example, when the terminal determines that the pixel values of the preset number of pixels in the display screen are greater than a first preset threshold and the target light sensation value is less than a second preset threshold, the terminal may write a first confirmation value in the status flag bit, where the first confirmation value may indicate that the terminal is in the target state, and if the terminal determines that the above condition is not satisfied, the terminal may also write a second confirmation value in the status flag bit, where the first confirmation value may indicate that the terminal is not in the target state.
Optionally, in this step, whether the detection terminal is in the target state may be detected by detecting a value of the status flag. That is, the terminal may acquire a value in the status flag, and detect whether the terminal is in the target state by detecting whether the value in the status flag is equal to the first confirmation value. Optionally, if the terminal is identified as being in the target state by 1, 0 indicates that the terminal is not in the target state. Then, if the value in the state flag acquired by the terminal is 1, it can be detected that the terminal is in the target state, and if the value in the state flag acquired by the terminal is 0, it can be detected that the terminal is not in the target state.
Note that, the recording of the second photosensitive value may be performed after the first confirmation value is written in the status flag bit in the terminal, which is not limited in the embodiment of the present application.
Optionally, when the terminal is in the target state, step 303 is executed, and when the terminal is not in the target state, step 306 is executed.
Step 303, detecting whether the first light sensation value is within a target light sensation interval, where the target light sensation interval is a light sensation interval obtained according to the target light sensation value when the terminal is in the target state.
That is, after the terminal is in the target state, the terminal may acquire the target light sensation section from the target light sensation value when determining that the terminal is in the target state. Taking the target light sensation value as the second light sensation value as an example, after the terminal records the second light sensation value, the terminal may further obtain a second light sensation interval according to the second light sensation value, record the obtained second light sensation interval, and use the second light sensation interval as the target light sensation interval. In a possible implementation manner, a first correspondence table may be set in the terminal, where the first correspondence table includes a correspondence table between the light sensation value and the light sensation section.
Light sensing value Light-sensitive section
Light sensitivity value of one Light sensing section one
Light sensitivity value two Light sensing interval two
…… ……
TABLE 1
Optionally, after the terminal acquires the second light sensing section, the terminal may query the table 1 to acquire the light sensing section corresponding to the second light sensing section. For example, if the size of the second light sensing section is light sensing section two, the terminal can obtain the second light sensing section as light sensing section two through the table 1, so that the second light sensing section two is recorded in the terminal corresponding to the second light sensing value, and the second light sensing section is used as the target light sensing section.
In a possible implementation manner, the terminal may also calculate the second light sensation interval directly according to the second light sensation value. For example, the terminal may have a preset calculation rule, and the second light sensation section may be calculated by using the second light sensation value of 0.5 times as the lower limit of the second light sensation section and the second light sensation value of 1.5 times as the upper limit of the second light sensation section. For example, the second light sensation value acquired by the terminal is 14Lux, and the second light sensation interval obtained by the terminal through calculation may be 7 to 21 Lux.
Optionally, after acquiring the first light sensation value, the terminal may compare the first light sensation value with a previously recorded target light sensation interval, and determine a relationship between the first light sensation value and the target light sensation interval. When the first light sensation value is within the target light sensation interval, step 304 is executed.
In step 304, when the first light sensation value is within the target light sensation interval, a target light sensation value is obtained.
That is, when the terminal determines that the first light sensation value is in the target light sensation zone, the terminal may obtain the target light sensation value corresponding to the target light sensation zone recorded previously. For example, if the terminal records the target light sensation interval corresponding to the second light sensation value according to the implementation manner of table 1, and the terminal is in the target state at this time, and the currently recorded target light sensation interval is the second light sensation interval in table 1, then the target light sensation value acquired by the terminal at this time is also the second light sensation value.
In a possible implementation manner, when the first light sensation value is determined not to be within the target light sensation interval in step 303, the terminal may further detect whether the first light sensation value is smaller than a second preset threshold; when the first light sensation value is smaller than a second preset threshold value, acquiring a first light sensation interval according to the first light sensation value; the target light sensation value is replaced by the first light sensation value, and the target light sensation interval is replaced by the first light sensation interval.
For example, the target light sensation interval is 7 to 21Lux, and if the first light sensation value acquired by the terminal is 6Lux, the terminal may detect a magnitude relationship between the first light sensation value and the second preset threshold. If the second predetermined threshold is still 20Lux, the terminal determines that the first light sensation value is smaller than the second predetermined threshold, and the terminal can obtain the first light sensation interval according to the first light sensation value. And recording the first light sensation value as a target light sensation value, and recording the first light sensation interval as a target light sensation interval. Optionally, the obtaining manner of the first light sensing section may refer to the obtaining manner of the second light sensing section, and details are not repeated here.
It should be noted that, before the terminal records the first light sensation value and the first light sensation interval, it may also be determined whether the terminal is still in the target state, if the terminal is not in the target state, the terminal may not need to record the first light sensation value and the first light sensation interval, and if the terminal is in the target state, the terminal may record the first light sensation value and the first light sensation interval, which is not limited in the embodiment of the present application.
Optionally, when the first light sensitivity value is not smaller than the second preset threshold, a second confirmation value is written in the status flag bit. That is, if the terminal obtains the result that the first photosensitivity value is not less than the second preset threshold value when judging the first photosensitivity value and the second preset threshold value, the terminal may determine that the terminal is not in the target state at this time, and may write the second confirmation value in the state flag bit. Still taking the second preset threshold as 20Lux for example, if the first preset threshold is 30Lux, the terminal may write 0 in the status flag bit at this time, thereby indicating that the terminal is not in the target state.
And 305, adjusting the brightness of the display screen according to the target light sensation value.
Optionally, the terminal may replace the size of the first light sensation value acquired in step 301 with the size of the target light sensation value, and use the target light sensation value as the illumination intensity of the display screen received the ambient light acquired at the current time, so as to adjust the brightness of the display screen according to the target light sensation value. That is, if the target light sensation value is 14Lux, the target light sensation interval is 7 to 21Lux, and the first light sensation value is 8Lux, the terminal still adjusts the brightness of the display screen according to the light sensation value of 14Lux, and at this time, the terminal can keep the brightness of the display screen corresponding to the light sensation value of 14Lux unchanged.
Step 306, when the terminal is not in the target state, detecting whether the first light sensation value is smaller than a second preset threshold value.
Step 307, when the first light sensation value is smaller than the second preset threshold, recording the first light sensation value.
In step 308, a second light sensing interval is obtained according to the first light sensing value.
In step 309, the first photosensitive section is recorded.
Optionally, the description of steps 306 to 309 can refer to the step executed when the first light sensation value is not within the target light sensation interval in step 304, and the description thereof is omitted here. The second light sensing section may be the same light sensing section as the first light sensing section.
It should be noted that, in the process of executing the above step 301 to step 309, the terminal may obtain, in real time, an image in the display screen through the image acquisition component under the condition of display by the display screen, and obtain a pixel value of each pixel point in the display screen; detecting whether the pixel values of a preset number of pixel points are larger than a first preset threshold value or not; and writing a second confirmation value into the state flag bit when the pixel values of the pixel points with the preset number are not greater than the first preset threshold value. That is, the terminal may determine in real time whether itself is in the target state, and if not, may write the second confirmation value in the status flag bit. The details of the implementation herein can refer to the related contents in step 302, and are not described herein again.
In summary, by acquiring the first light sensation value, the first light sensation value is the illumination intensity of the ambient light received by the display screen at the current moment; detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in a display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained last time before the current moment by the terminal is smaller than the second preset threshold value; when the first light sensation value is within the target light sensation interval, acquiring a target light sensation value; and adjusting the brightness of the display screen according to the target light sensation value. This application is through acquireing target light sense interval according to target light sense value, when the first light sense value that the terminal acquireed is in target light sense interval, adjusts the luminance of display screen according to target light sense value, has avoided the terminal directly to adjust the stroboscopic phenomenon that the luminance of display screen brought according to the first light sense value that acquires, has improved the luminance regulation effect of display screen.
The embodiment shown in fig. 2 or fig. 3 is described by taking an example that an operating system framework layer in a terminal reports a light-sensing value to an operating system upper layer (which may also be regarded as an application layer), and the brightness of a display screen is adjusted by the operating system upper layer.
Referring to fig. 4, a flowchart of a method for adjusting brightness of a display screen according to an exemplary embodiment of the present application is shown. The method can be used in the terminal with the display screen shown in fig. 1, and as shown in fig. 4, the display screen brightness adjusting method can include the following steps.
Step 401, a first light sensation value is obtained.
The operating system framework layer can obtain the first light sensation value by calculating the compensation light sensation. The compensated light sensation is the illumination intensity obtained by subtracting the illumination intensity of the light emitted by the display screen from the illumination intensity directly received by the light sensor.
Step 402, detecting whether the terminal is in a target state.
If the terminal is in the target state, step 403 is executed, and if the terminal is not in the target state, step 407 is executed.
Optionally, in this step, the terminal may detect whether it is in the target state according to the first light sensation value, and the detection manner may refer to the manner of detecting according to the second light sensation value in step 302, which is not described herein again.
Step 403, detecting whether the terminal enters the target state for the first time after being turned on.
If the target state is the target state that the terminal enters for the first time after being powered on, step 404 is executed, and if the target state is the target state that the terminal does not enter for the first time after being powered on, step 408 is executed.
That is, if the terminal determines that the target state is in the target state in step 402, the terminal may further determine whether the terminal is in the target state for the first time after the terminal is turned on, and if so, it indicates that the terminal has not recorded the first light sensation value, and acquires the corresponding light sensation interval according to the first light sensation value, and the terminal needs to use the first light sensation value as the target light sensation value and acquire the light sensation interval corresponding to the first light sensation value as the target light sensation interval. The manner of obtaining the corresponding light sensation interval according to the second light sensation value in step 302 can be referred to, and details are not repeated here.
Step 404, updating the target light sensitivity value.
The terminal can update the first light sensation value to the target light sensation value.
In step 405, the target light sensation interval is updated.
The terminal can also obtain the target light sensation interval according to the target light sensation value, so that the target light sensation interval is updated. Or, the terminal directly acquires the corresponding light sensing section according to the first light sensing value, and updates the acquired light sensing section to the target light sensing section.
And step 406, reporting the updated target light sensitivity value.
And the framework layer of the operating system reports the updated target light sensation value to the upper layer of the operating system.
Step 407, reporting the first light sensitivity value.
And the framework layer of the operating system directly reports the acquired first light sensation value to the upper layer of the operating system.
Step 408, detect whether the first light sensation value is within the target light sensation interval.
If the first light sensation value is not within the target light sensation interval, step 404 is executed, and if the first light sensation value is within the target light sensation interval, step 409 is executed.
And step 409, reporting the target light sensation value corresponding to the target light sensation interval.
Optionally, the terminal may obtain a target light sensation value corresponding to the target light sensation interval, and obtain the target light sensation value corresponding to the upper target light sensation interval of the operating system through the framework layer of the operating system.
To sum up, this application is through acquireing target light sense interval according to target light sense value, when the first light sense value that the terminal acquireed was in target light sense interval, according to the luminance of target light sense value regulation display screen, avoided the terminal directly to adjust the stroboscopic phenomenon that the luminance of display screen brought according to the first light sense value that acquires, improved the luminance regulation effect of display screen.
The following are embodiments of the apparatus of the present application that may be used to perform embodiments of the method of the present application. For details which are not disclosed in the embodiments of the apparatus of the present application, reference is made to the embodiments of the method of the present application.
Referring to fig. 5, a block diagram of a display screen brightness adjusting apparatus according to an exemplary embodiment of the present application is shown. The display screen brightness adjusting device can be used in a terminal with a display screen to execute all or part of the steps executed by the terminal in the method provided by the embodiment shown in fig. 2, fig. 3 or fig. 4. The display screen brightness adjusting device can comprise the following modules: a first obtaining module 501, a first detecting module 502, a second obtaining module 503 and a brightness adjusting module 504;
the first obtaining module 501 is configured to obtain a first light sensation value, where the first light sensation value is an illumination intensity of ambient light received by the display screen at the current time by the terminal;
the first detecting module 502 is configured to detect whether the first light sensation value is within a target light sensation interval, where the target light sensation interval is a light sensation interval obtained according to a target light sensation value when the terminal is in a target state, the target state is a state where pixel values of a preset number of pixels in the display screen are greater than a first preset threshold and the target light sensation value is smaller than a second preset threshold, and the target light sensation value is a light sensation value recorded when a light sensation value obtained by the terminal last time before the current time is smaller than the second preset threshold;
the second obtaining module 503 is configured to obtain the target light sensation value when the first light sensation value is within the target light sensation interval;
the brightness adjusting module 504 is configured to adjust the brightness of the display screen according to the target light sensation value.
In summary, by acquiring the first light sensation value, the first light sensation value is the illumination intensity of the ambient light received by the display screen at the current moment; detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in a display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained last time before the current moment by the terminal is smaller than the second preset threshold value; when the first light sensation value is within the target light sensation interval, acquiring a target light sensation value; and adjusting the brightness of the display screen according to the target light sensation value. This application is through acquireing target light sense interval according to target light sense value, when the first light sense value that the terminal acquireed is in target light sense interval, adjusts the luminance of display screen according to target light sense value, has avoided the terminal directly to adjust the stroboscopic phenomenon that the luminance of display screen brought according to the first light sense value that acquires, has improved the luminance regulation effect of display screen.
Optionally, the apparatus further comprises:
the second detection module is used for detecting whether the first light sensation value is smaller than the second preset threshold value or not when the first light sensation value is not in the target light sensation interval;
the third obtaining module is used for obtaining a first light sensation interval according to the first light sensation value when the first light sensation value is smaller than the second preset threshold value;
and the replacing module is used for replacing the target light sensation value with the first light sensation value and replacing the target light sensation interval with the first light sensation interval.
Optionally, the apparatus further comprises:
the third detection module is used for detecting whether the terminal is in the target state before the first detection module detects whether the first light sensation value is in the target light sensation interval;
and the execution module is used for executing the step of detecting whether the first light sensation value is in the target light sensation interval or not when the terminal is in the target state.
Optionally, the third detecting module includes: a first acquisition unit and a first detection unit;
the first obtaining unit is configured to obtain a value in a status flag bit, where the status flag bit is used to indicate whether the terminal is in the target state;
the first detecting unit is configured to detect whether the terminal is in the target state by detecting whether a value in the status flag is equal to a first acknowledgement value, where the first acknowledgement value is used to indicate that the terminal is in the target state.
Optionally, the apparatus further comprises:
the fourth detection module is used for detecting whether the first light sensation value is smaller than the second preset threshold value or not when the terminal is not in the target state;
the first recording module is used for recording the first light sensation value when the first light sensation value is smaller than the second preset threshold value;
the fourth acquisition module is used for acquiring a second light sensing interval according to the first light sensing value;
the second recording module is used for recording the second light sensing interval.
Optionally, the apparatus further comprises:
and a first writing module, configured to write a second confirmation value in the status flag bit when the first light sensation value is not smaller than the second preset threshold, where the second confirmation value is used to indicate that the terminal is not in the target state.
Optionally, the apparatus further comprises:
a fifth obtaining module, configured to obtain a pixel value of each pixel point in the display screen;
a fifth detection module, configured to detect whether the pixel values of the preset number of pixel points are greater than the first preset threshold;
and the second writing module is used for writing the second confirmation value into the state flag bit when the pixel values of the preset number of pixel points are not greater than the first preset threshold value.
Referring to fig. 6, which shows a schematic structural diagram of a terminal provided in an exemplary embodiment of the present application, as shown in fig. 6, the terminal includes a processor 610, a memory 620, a display component 630 and a sensor component 640, the display component 630 is used for displaying an interface of a program running in a foreground in the terminal, and the sensor component 640 is used for collecting data of each sensor. The memory 620 stores at least one instruction, and the instruction is loaded and executed by the processor 610 to implement some or all of the steps performed by the terminal in the display screen brightness adjustment method according to the above embodiments.
The present embodiments also provide a computer-readable storage medium, in which at least one instruction, at least one program, a code set, or a set of instructions is stored, and the at least one instruction, the at least one program, the code set, or the set of instructions is loaded and executed by a processor to implement the display screen brightness adjustment method according to the above embodiments.
The embodiment of the present application further provides a computer program product, where at least one instruction is stored, and the at least one instruction is loaded and executed by the processor to implement the display screen brightness adjustment method according to the above embodiments.
It should be noted that: in the display screen brightness adjusting method provided by the foregoing embodiment, the steps executed by the terminal are only illustrated in the foregoing embodiments, and in practical applications, the functions may be distributed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. In addition, the apparatus and method embodiments provided by the above embodiments belong to the same concept, and specific implementation processes thereof are described in the method embodiments for details, which are not described herein again.
The above-mentioned serial numbers of the embodiments of the present application are merely for description and do not represent the merits of the embodiments.
Those skilled in the art will recognize that, in one or more of the examples described above, the functions described in the embodiments of the present application may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable storage medium. Computer-readable storage media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer.
The above description is only exemplary of the present application and should not be taken as limiting, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (10)

1. A display screen brightness adjusting method is used in a terminal with a display screen, and comprises the following steps:
acquiring a first light sensation value, wherein the first light sensation value is the illumination intensity of ambient light received by the display screen at the current moment by the terminal;
detecting whether the first light sensation value is in a target light sensation interval, wherein the target light sensation interval is obtained according to a target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value, the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is recorded when the light sensation value obtained by the terminal last time before the current moment is smaller than the second preset threshold value;
when the first light sensation value is within the target light sensation interval, acquiring the target light sensation value;
and adjusting the brightness of the display screen according to the target light sensation value.
2. The method of claim 1, further comprising:
when the first light sensation value is not in the target light sensation interval, detecting whether the first light sensation value is smaller than a second preset threshold value;
when the first light sensation value is smaller than the second preset threshold value, acquiring a first light sensation interval according to the first light sensation value;
and replacing the target light sensation value with the first light sensation value, and replacing the target light sensation interval with the first light sensation interval.
3. The method as claimed in claim 2, further comprising, before the detecting whether the first light sensation value is within the target light sensation interval:
detecting whether the terminal is in the target state;
and when the terminal is in the target state, executing the step of detecting whether the first light sensation value is in the target light sensation interval.
4. The method of claim 3, wherein the detecting whether the terminal is in the target state comprises:
acquiring a value in a status flag bit, wherein the status flag bit is used for indicating whether the terminal is in the target state;
and detecting whether the terminal is in the target state by detecting whether the value in the status flag bit is equal to a first confirmation value, wherein the first confirmation value is used for indicating that the terminal is in the target state.
5. The method of claim 3, further comprising:
when the terminal is not in the target state, detecting whether the first light sensation value is smaller than a second preset threshold value;
when the first light sensation value is smaller than the second preset threshold value, recording the first light sensation value;
acquiring a second light sensing interval according to the first light sensing value;
recording the second photosensitive section.
6. The method of claim 4, further comprising:
and when the first light sensation value is not smaller than the second preset threshold value, writing a second confirmation value in the state flag bit, wherein the second confirmation value is used for indicating that the terminal is not in the target state.
7. The method according to any one of claims 4 to 6, further comprising:
acquiring the pixel value of each pixel point in the display screen;
detecting whether the pixel values of the pixel points with the preset number are larger than the first preset threshold value or not;
and writing the second confirmation value into the state flag bit when the pixel values of the pixel points with the preset number are not greater than the first preset threshold value.
8. A display screen brightness adjusting apparatus, wherein the apparatus is used in a terminal having a display screen, the apparatus comprising:
the terminal comprises a first acquisition module, a second acquisition module and a control module, wherein the first acquisition module is used for acquiring a first light sensation value, and the first light sensation value is the illumination intensity of the ambient light received by the display screen at the current moment;
the first detection module is used for detecting whether the first light sensation value is in a target light sensation interval, the target light sensation interval is a light sensation interval obtained according to the target light sensation value when the terminal is in a target state, the target state is a state that the pixel values of a preset number of pixel points in the display screen are larger than a first preset threshold value and the target light sensation value is smaller than a second preset threshold value, and the target light sensation value is a light sensation value recorded when the light sensation value obtained by the terminal at the last time before the current moment is smaller than the second preset threshold value;
the second acquisition module is used for acquiring the target light sensation value when the first light sensation value is in the target light sensation interval;
and the brightness adjusting module is used for adjusting the brightness of the display screen according to the target light sensation value.
9. An electronic device comprising a processor and a memory, wherein the memory has at least one instruction, at least one program, a set of codes, or a set of instructions stored therein, which are loaded and executed by the processor to implement the display screen brightness adjustment method according to any one of claims 1 to 7.
10. A computer readable storage medium having stored therein at least one instruction, at least one program, a set of codes, or a set of instructions, which is loaded and executed by a processor to implement the display screen brightness adjustment method of any of claims 1 to 7.
CN202010144263.5A 2020-03-04 2020-03-04 Display screen brightness adjusting method and device, electronic equipment and storage medium Active CN111179882B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010144263.5A CN111179882B (en) 2020-03-04 2020-03-04 Display screen brightness adjusting method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010144263.5A CN111179882B (en) 2020-03-04 2020-03-04 Display screen brightness adjusting method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN111179882A true CN111179882A (en) 2020-05-19
CN111179882B CN111179882B (en) 2021-07-16

Family

ID=70653389

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010144263.5A Active CN111179882B (en) 2020-03-04 2020-03-04 Display screen brightness adjusting method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN111179882B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111968597A (en) * 2020-08-12 2020-11-20 Oppo(重庆)智能科技有限公司 Screen brightness adjusting method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105118474A (en) * 2015-10-16 2015-12-02 青岛海信电器股份有限公司 LCD brightness control method and device as well as LCD equipment
CN105702228A (en) * 2014-11-28 2016-06-22 惠州市德赛西威汽车电子股份有限公司 Adaptive screen brightness adjusting method and system
CN109064971A (en) * 2018-08-24 2018-12-21 深圳市沃特沃德股份有限公司 The method and device thereof that OLED screen backlight is adjusted
CN109817152A (en) * 2019-04-09 2019-05-28 Oppo广东移动通信有限公司 Screen luminance adjustment method and Related product
CN109859689A (en) * 2019-04-09 2019-06-07 Oppo广东移动通信有限公司 Screen luminance adjustment method and Related product

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105702228A (en) * 2014-11-28 2016-06-22 惠州市德赛西威汽车电子股份有限公司 Adaptive screen brightness adjusting method and system
CN105118474A (en) * 2015-10-16 2015-12-02 青岛海信电器股份有限公司 LCD brightness control method and device as well as LCD equipment
CN109064971A (en) * 2018-08-24 2018-12-21 深圳市沃特沃德股份有限公司 The method and device thereof that OLED screen backlight is adjusted
CN109817152A (en) * 2019-04-09 2019-05-28 Oppo广东移动通信有限公司 Screen luminance adjustment method and Related product
CN109859689A (en) * 2019-04-09 2019-06-07 Oppo广东移动通信有限公司 Screen luminance adjustment method and Related product

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111968597A (en) * 2020-08-12 2020-11-20 Oppo(重庆)智能科技有限公司 Screen brightness adjusting method and device, electronic equipment and storage medium
CN111968597B (en) * 2020-08-12 2021-11-09 Oppo(重庆)智能科技有限公司 Screen brightness adjusting method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN111179882B (en) 2021-07-16

Similar Documents

Publication Publication Date Title
CN110767136B (en) Display panel brightness correction method, display panel brightness correction device and display device
KR102545813B1 (en) Display apparatus and method for displaying
US9672764B2 (en) Liquid crystal display device
CN108701439B (en) Image display optimization method and device
WO2019119847A1 (en) Dynamic tone mapping method, mobile terminal, and computer readable storage medium
WO2018021830A1 (en) Electronic device and operation control method of electronic device
CN105227858A (en) A kind of image processing method and mobile terminal
EP3046003B1 (en) Screen brightness regulation method and apparatus, and storage medium
CN108628564A (en) Eliminate method, apparatus, storage medium and the display terminal of display screen ghost
CN113077738A (en) Ambient light detection method and device, and storage medium
KR20120042004A (en) Image processing device, image processing method and flat panel display
JP2007310096A (en) Video display apparatus, and display brightness control method therefor
CN114093323B (en) Screen control method and device, electronic equipment and storage medium
WO2023143510A1 (en) Ambient light detection method and apparatus, and compensation display method and apparatus for display screen
CN104660766A (en) Backlight adjustment method and device of mobile terminal
CN111179882B (en) Display screen brightness adjusting method and device, electronic equipment and storage medium
CN104183216A (en) Method and device for controlling brightness of display screen of displayer
CN114119431A (en) Image processing method, image processing device, electronic equipment and storage medium
CN112289278A (en) Screen brightness adjusting method, screen brightness adjusting device and electronic equipment
CN106898332B (en) Method and system for adjusting screen brightness
CN110556080B (en) Method, device, terminal and storage medium for adjusting backlight
CN113096592B (en) Method and device for eliminating ghost shadow of display screen and display device
CN114255699B (en) Display screen picture compensation method and device and display equipment
CN108845784A (en) A kind of display screen Mura compensation method and device
TW201826250A (en) Display apparatus and display parameter adjustment method thereof

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