CN113551768B - Method and device for determining ambient brightness - Google Patents

Method and device for determining ambient brightness Download PDF

Info

Publication number
CN113551768B
CN113551768B CN202110797441.9A CN202110797441A CN113551768B CN 113551768 B CN113551768 B CN 113551768B CN 202110797441 A CN202110797441 A CN 202110797441A CN 113551768 B CN113551768 B CN 113551768B
Authority
CN
China
Prior art keywords
image
screen
target
target image
determining
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
Application number
CN202110797441.9A
Other languages
Chinese (zh)
Other versions
CN113551768A (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.)
Beijing Xiaomi Mobile Software Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software 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 Beijing Xiaomi Mobile Software Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN202110797441.9A priority Critical patent/CN113551768B/en
Publication of CN113551768A publication Critical patent/CN113551768A/en
Application granted granted Critical
Publication of CN113551768B publication Critical patent/CN113551768B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01JMEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
    • G01J1/00Photometry, e.g. photographic exposure meter
    • G01J1/42Photometry, e.g. photographic exposure meter using electric radiation detectors
    • G01J1/4204Photometry, e.g. photographic exposure meter using electric radiation detectors with determination of ambient light
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01JMEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
    • G01J1/00Photometry, e.g. photographic exposure meter
    • G01J1/02Details
    • G01J1/0295Constructional arrangements for removing other types of optical noise or for performing calibration
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T7/00Image analysis
    • G06T7/90Determination of colour characteristics
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T2207/00Indexing scheme for image analysis or image enhancement
    • G06T2207/10Image acquisition modality
    • G06T2207/10024Color image

Abstract

The present disclosure provides a method and apparatus for determining ambient brightness. The method is applied to electronic equipment, the electronic equipment comprises a screen and a light sensor, the light sensor is positioned below the screen, and the method comprises the following steps: the method comprises the steps of determining color information of an image currently displayed on a screen, obtaining a target image which is close to the color information of the image currently displayed on the screen in a preset image set, displaying the target image above a light sensor, and determining the ambient brightness according to light data and target interference data detected by the light sensor, wherein the target interference data is determined according to interference data generated by the target image on a detection result of the light sensor. The method removes or reduces the interference of the screen display content on the detection result of the light sensor, more accurately determines the ambient brightness, and has the characteristics of simple method, high accuracy of the determination result and the like.

Description

Method and device for determining ambient brightness
Technical Field
The disclosure relates to the technical field of computer communication, and in particular relates to a method and a device for determining ambient brightness.
Background
The electronic device is provided with a light sensor, determines the ambient brightness according to the light data detected by the light sensor, and performs operations such as screen brightness adjustment or exposure adjustment according to the determined ambient brightness.
However, some factors may interfere with the detection result of the light sensor, resulting in inaccurate ambient brightness determined from the light data, and thus, subsequent operations cannot be accurately performed according to the determined ambient brightness.
Disclosure of Invention
To overcome the problems in the related art, the present disclosure provides a method and apparatus for determining ambient brightness.
According to a first aspect of embodiments of the present disclosure, there is provided a method of determining ambient brightness, applied to an electronic device, the electronic device including a screen and a light sensor, the light sensor being located below the screen, the method comprising:
determining color information of an image currently displayed by the screen;
Acquiring a target image in a preset image set, wherein the difference between the color information of the target image and the color information of the image meets a preset difference condition;
displaying the target image on the screen, the target image being displayed above the light sensor;
and determining the ambient brightness according to the light data detected by the light sensor and the target interference data, wherein the target interference data is determined according to the interference data generated by the target image on the detection result of the light sensor.
Optionally, the acquiring the target image in the preset image set includes:
and determining an image with the smallest difference with the color information of the image in the preset image set as the target image.
Optionally, the light sensor is located below a target screen area of the screen; the displaying the target image on the screen includes any one of:
Displaying the target image in the whole area of the screen;
and displaying the target image in the target screen area of the screen.
Optionally, the determining the color information of the image currently displayed by the screen includes:
when the screen displays the image, obtaining a picture through screen capturing;
and carrying out color recognition on the picture to obtain the color information of the image.
Optionally, the determining the color information of the image currently displayed by the screen includes any one of the following:
Determining color information of the image in response to a preset duration of a current time and a historical time interval for last determining of ambient brightness;
and determining color information of the image in response to the frame number of the image refreshed by the screen reaches a preset frame number after the environment brightness is determined last time.
Optionally, the method further comprises:
Determining the brightness of a screen currently used by the screen;
And determining total interference data generated by the target image and the screen brightness on the detection result, wherein the target interference data comprises the total interference data.
Optionally, the determining total interference data generated by the target image and the screen brightness on the detection result includes:
Acquiring an interference curve drawn for the target image, wherein the interference curve takes screen brightness as an abscissa, and the interference curve takes total interference data generated by the target image and the screen brightness as an ordinate;
and determining the total interference data corresponding to the screen brightness on the interference curve.
Optionally, the method further comprises:
Determining total interference data generated by each frame of image and screen brightness under different screen brightness aiming at each frame of image in the preset image set;
and drawing an interference curve corresponding to each frame of image by taking the screen brightness as an abscissa and taking the total interference data generated by each frame of image and the screen brightness as an ordinate.
According to a second aspect of embodiments of the present disclosure, there is provided an apparatus for determining ambient brightness, applied to an electronic device, the electronic device including a screen and a light sensor, the light sensor being located below the screen, the apparatus comprising:
a color information determining module configured to determine color information of an image currently displayed by the screen;
A target image acquisition module configured to acquire a target image in a preset image set, wherein a difference between color information of the target image and color information of the image satisfies a preset difference condition;
A target image display module configured to display the target image on the screen, the target image being displayed above the light sensor;
And the environment brightness determining module is configured to determine the environment brightness according to the light ray data detected by the light ray sensor and target interference data, wherein the target interference data is determined according to the interference data generated by the target image on the detection result of the light ray sensor.
Optionally, the target image obtaining module is configured to determine an image with the smallest difference from the color information of the image in the preset image set as the target image.
Optionally, the light sensor is located below a target screen area of the screen; the target image display module comprises any one of the following:
a first image display sub-module configured to display the target image in an entire area of the screen;
A second image display sub-module configured to display the target image within the target screen area of the screen.
Optionally, the color information determining module includes:
a picture obtaining sub-module configured to obtain a picture through screen capturing when the screen displays the image;
and the color recognition sub-module is configured to perform color recognition on the picture to obtain color information of the image.
Optionally, the color information determining module includes any one of the following:
A first information determining sub-module configured to determine color information of the image in response to a current time and a historical time interval preset duration of last determination of ambient brightness;
And a second information determination sub-module configured to determine color information of the image in response to the number of frames of the image refreshed by the screen after the previous determination of the ambient brightness reaching a preset number of frames.
Optionally, the apparatus further comprises:
A screen brightness determination module configured to determine a screen brightness currently used by the screen;
And a data determining module configured to determine total interference data generated by the target image and the screen brightness on the detection result, wherein the target interference data comprises the total interference data.
Optionally, the data determining module includes:
An interference curve acquisition sub-module configured to acquire an interference curve drawn for the target image, the interference curve taking screen brightness as an abscissa, the interference curve taking total interference data generated by the target image and the screen brightness as an ordinate;
a data determination sub-module configured to determine the total interference data corresponding to the screen brightness on the interference curve.
Optionally, the apparatus further comprises:
The total interference data determining module is configured to determine total interference data generated by each frame of image and screen brightness under different screen brightness for each frame of image in the preset image set;
And the interference curve drawing module is configured to draw an interference curve corresponding to each frame of image by taking the screen brightness as an abscissa and taking the total interference data generated by each frame of image and the screen brightness as an ordinate.
According to a third aspect of embodiments of the present disclosure, there is provided a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the method of any of the first aspects.
According to a fourth aspect of embodiments of the present disclosure, there is provided an electronic device, comprising:
A processor;
A memory for storing processor-executable instructions;
Wherein the processor is configured to execute the instructions to implement the method of any of the first aspects.
The technical scheme provided by the embodiment of the disclosure can comprise the following beneficial effects:
In the embodiment of the disclosure, a light sensor in an electronic device is located below a screen, the electronic device obtains a target image in a preset image set, the target image is close to color information of an image currently displayed on the screen, the target image is displayed above the light sensor, and ambient brightness is determined according to light data and target interference data detected by the light sensor, wherein the target interference data is determined according to interference data generated by the target image on a detection result of the light sensor. The method removes or reduces the interference of the screen display content on the detection result of the light sensor, more accurately determines the ambient brightness, and has the characteristics of simple method, high accuracy of the determination result and the like.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
FIG. 1 is a flowchart illustrating a method of determining ambient brightness according to an exemplary embodiment;
FIG. 2 is a schematic diagram of a partial structure of an electronic device, according to an example embodiment;
FIG. 3 is a diagram illustrating a method of plotting interference curves, according to an exemplary embodiment;
FIG. 4 is a block diagram of an apparatus for determining ambient brightness, according to an example embodiment;
Fig. 5 is a schematic diagram of an electronic device according to an exemplary embodiment.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure as detailed in the accompanying claims.
The terminology used in the present disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in this disclosure and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used in this disclosure to describe various information, these information should not be limited to these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present disclosure. The word "if" as used herein may be interpreted as "at … …" or "at … …" or "in response to a determination" depending on the context.
Fig. 1 is a flowchart illustrating a method for determining ambient brightness according to an exemplary embodiment, where the method illustrated in fig. 1 is applied to an electronic device, the electronic device including a screen and a light sensor, the light sensor being located below the screen, and the method illustrated in fig. 1 includes:
in step 101, color information of an image currently displayed on a screen is determined.
The color information of the image is used to indicate the color of the image. For example, the color information of an image includes which color the image displays, which color the dominant color is, which color the non-dominant color includes, and so on. As another example, the color information of an image includes only which color the dominant color of the image is.
In an alternative embodiment, the color information of the image currently displayed by the screen may be determined by: when the screen displays the image, the picture is obtained through screen capturing, and the color identification is carried out on the picture, so that the color information of the image is obtained.
When the color information of the image includes all the color information of the image, all the colors in the image are identified, and all the color information of the image is obtained.
When the color information of the image only includes the dominant color information of the image, the dominant color in the image is identified, and the dominant color information of the image is acquired.
In an alternative embodiment, there are various opportunities to determine the color information of the image currently displayed on the screen, for example, the first: if the current time and the historical time interval for last determining the ambient brightness are preset for a long time, starting to execute the operation for determining the color information of the image; second kind: if the number of frames of the image screen-refreshed after the previous determination of the ambient brightness reaches a preset number of frames, the operation of determining the color information of the image is started to be performed.
For the first, the preset time period may be set as needed and empirically. For example, the refresh rate of the screen is 120 frames/second, and the preset time period is 1s.
For the second, the preset number may be set as needed and empirically. For example, the refresh rate of the screen is 120 frames/second, the preset number of frames is 120, or the preset number of frames is 60, etc.
In step 102, a target image in a preset image set is acquired, and a difference between color information of the target image and color information of an image currently displayed on a screen satisfies a preset difference condition.
The preset image set comprises at least one preset image. The preset images in the preset image set may be solid images, for example, the preset image set includes solid light green images, solid dark green images, solid light pink images, solid dark pink images, and the like. The more preset images included in the preset image set, the finer the color division.
After determining the color information of the image currently displayed on the screen, determining the difference between the color information of the preset image in the preset image set and the color information of the image currently displayed on the screen, and determining the preset image (hereinafter referred to as a target image) of which the difference satisfies the preset difference condition, thereby determining the target image close to the color information of the image currently displayed on the screen from the preset image set.
For example, an image having the smallest difference in color information from an image currently displayed on the screen in the preset image set may be determined as the target image.
In step 103, a target image is displayed on the screen, the target image being displayed above the light sensor.
The screen includes a target screen area and a non-target screen area, and the light sensor is located below the target screen area of the screen.
In an alternative embodiment, displaying the target image on the screen may include: the target image is displayed in the entire area of the screen or in the target screen area of the screen.
The target image is displayed on the whole screen, and the method has the characteristics of simplicity in operation, high efficiency and the like. But compared with the target image displayed in the target screen area of the screen, the target image is displayed on the whole screen, so that more influence is brought to the viewing experience of the user, and the viewing experience of the user is reduced to a certain extent.
In an alternative embodiment, assuming that the display time of each frame of image on the screen is T, the start display time of the image currently displayed on the screen is T1, the target image is displayed on the screen at a certain time from T1 to (t1+t), and when the time reaches t1+t, the display of the target image is canceled, and the next frame of image obtained continuously with the image currently displayed on the screen is displayed.
The image currently displayed by the screen includes a first partial image displayed in the target screen area and a second partial image displayed in the non-target screen area. When step 102 is performed, the target image is displayed in the target screen area of the screen and the second partial image is continuously displayed in the non-target screen area of the screen, or the target image is displayed in the target screen area of the screen, and the image display is not performed in the non-target screen area of the screen.
Fig. 2 is a schematic view showing a partial structure of an electronic device according to an exemplary embodiment, referring to fig. 2, the electronic device includes a screen a including a screen area a1 and a screen area a2, and a light sensor b located below the screen area a 1.
The electronic device determines color information of an image (hereinafter referred to as a first image) currently displayed on a screen, acquires a target image which is close to the color information of the first image in a preset image set, displays a target image with a pure color in a screen area a1, and continuously displays a local image in the first image in the screen area a 1.
In an alternative embodiment, assuming that the display time of each frame of image on the screen is T, the target image may be displayed on the screen after the display time T of the image currently displayed on the screen is finished.
For example, when the display of the image currently displayed on the screen is ended, the target image is displayed in the target screen area of the screen, and the image display is not performed in the non-target screen area of the screen.
In another example, at the end of the display of the image currently displayed on the screen, the target image is displayed in the target screen area of the screen, while the partial image in the next frame image obtained continuously with the image currently displayed on the screen is displayed in the non-target screen area of the screen.
In an alternative embodiment, the operations of displaying the target image on the screen, collecting the light data by using the light sensor and determining the ambient brightness may be completed within the display time of one frame of image, and after the display time of one frame of image is finished, the following image is displayed normally. For higher screen refresh rate, the method is adopted to replace the image, so that the influence on the viewing experience of the user is small, and the user can not even perceive that the image is replaced.
In step 104, the ambient brightness is determined based on the light data detected by the light sensor and the target disturbance data determined based on disturbance data generated by the target image on the detection result of the light sensor.
The light data detected by the light sensor may include light brightness, and the object disturbance data may include brightness data.
The screen display content can interfere with the detection result of the light sensor, so that the ambient brightness determined according to the detection result of the light sensor has deviation from the real ambient brightness. In order to solve the above problems, the interference data generated by the detection result of the light sensor due to the screen display content may be used to correct the light data detected by the light sensor, and according to the corrected light data, the ambient brightness is determined, so as to improve the accuracy of the ambient brightness.
In an alternative embodiment, for each preset image in the preset image set, a corresponding relationship between the preset image and the interference data is established in advance, where the interference data only includes interference data generated by the preset image on a detection result of the light sensor. In the process of executing the method for determining the ambient brightness, after determining the target image, determining target interference data corresponding to the target image according to a pre-established corresponding relation.
In an alternative embodiment, the screen brightness may also interfere with the detection result of the light sensor. The electronic device may determine a screen brightness currently used by the screen, determine total interference data generated by the target image and the screen brightness currently used by the screen on a detection result of the light sensor, where the target interference data includes the total interference data. And correcting the sensing data detected by the sensor by using the total interference data, and determining the ambient brightness according to the corrected light data, so that the accuracy of the determination result of the ambient brightness is further improved.
In an alternative embodiment, fig. 3 is a method of plotting interference curves, according to an exemplary embodiment, referring to fig. 3, the method of plotting interference curves includes:
In step 201, for each frame of image in the preset image set, total interference data generated at different screen brightnesses and per frame of image is determined.
For any one frame image (hereinafter referred to as a preset image) in the preset image set, there are various ways of determining total interference data generated by the preset image and the screen brightness. For example, the interference data generated by the screen brightness is determined, the interference data generated by the preset image is determined, and statistics is performed on the interference data generated by the screen brightness and the interference data generated by the preset image to obtain total interference data generated by the preset image and the screen brightness.
There are various methods of counting two kinds of interference data, for example: the two kinds of interference data are directly added, or the two kinds of interference data are weighted and added, etc.
For another example, the control screen displays a preset image and controls the brightness of the screen, the difference between the light data detected by the light sensor and the standard light data is determined, and the total interference data generated by the preset image and the brightness of the screen is determined according to the difference.
In step 202, the screen brightness is taken as an abscissa, and the total interference data generated by each frame of image and the screen brightness is taken as an ordinate, so as to draw an interference curve corresponding to each frame of image.
In an alternative embodiment, for each frame of image in the preset image set, an interference curve is drawn, the interference curve takes the screen brightness as an abscissa, and the interference curve takes the total interference data generated by the image and the screen brightness as an ordinate.
The determining of the total interference data generated by the target image and the screen brightness currently used by the screen on the detection result of the light sensor may include: and acquiring an interference curve drawn for the target image, and determining total interference data corresponding to the brightness of the screen currently used by the screen on the interference curve.
In the embodiment of the disclosure, a light sensor in an electronic device is located below a screen, the electronic device obtains a target image in a preset image set, the target image is close to color information of an image currently displayed on the screen, the target image is displayed above the light sensor, and ambient brightness is determined according to light data and target interference data detected by the light sensor, wherein the target interference data is determined according to interference data generated by the target image on a detection result of the light sensor. The method removes or reduces the interference of the screen display content on the detection result of the light sensor, more accurately determines the ambient brightness, and has the characteristics of simple method, high accuracy of the determination result and the like.
For the foregoing method embodiments, for simplicity of explanation, the methodologies are shown as a series of acts, but one of ordinary skill in the art will appreciate that the present disclosure is not limited by the order of acts described, as some steps may occur in other orders or concurrently in accordance with the disclosure.
Further, those skilled in the art will also appreciate that the embodiments described in the specification are all alternative embodiments, and that the acts and modules referred to are not necessarily required by the present disclosure.
Corresponding to the embodiment of the application function implementation method, the disclosure also provides an embodiment of the application function implementation device and corresponding electronic equipment.
Fig. 4 is a block diagram illustrating an apparatus for determining ambient brightness, the apparatus being applied to an electronic device including a screen and a light sensor located under the screen, the apparatus may include:
a color information determination module 31 configured to determine color information of an image currently displayed by the screen;
A target image acquisition module 32 configured to acquire a target image in a preset image set, wherein a difference between color information of the target image and color information of the image satisfies a preset difference condition;
A target image display module 33 configured to display the target image on the screen, the target image being displayed above the light sensor;
An ambient brightness determination module 34 configured to determine an ambient brightness from light data detected by the light sensor and target disturbance data determined from disturbance data generated by the target image on the detection result of the light sensor.
In some alternative embodiments, the target image obtaining module 32 may be configured to determine, as the target image, an image having the smallest difference from the color information of the image in the preset image set, based on the apparatus for determining the ambient brightness shown in fig. 4.
In some alternative embodiments, based on the means for determining ambient brightness shown in fig. 4, the light sensor is located below a target screen area of the screen; the target image display module 33 may include any one of the following:
a first image display sub-module configured to display the target image in an entire area of the screen;
A second image display sub-module configured to display the target image within the target screen area of the screen.
In some alternative embodiments, based on the apparatus for determining ambient brightness shown in fig. 4, the color information determining module 31 may include:
a picture obtaining sub-module configured to obtain a picture through screen capturing when the screen displays the image;
and the color recognition sub-module is configured to perform color recognition on the picture to obtain color information of the image.
In some alternative embodiments, based on the apparatus for determining ambient brightness shown in fig. 4, the color information determining module 31 may include any one of the following:
A first information determining sub-module configured to determine color information of the image in response to a current time and a historical time interval preset duration of last determination of ambient brightness;
And a second information determination sub-module configured to determine color information of the image in response to the number of frames of the image refreshed by the screen after the previous determination of the ambient brightness reaching a preset number of frames.
In some alternative embodiments, the apparatus may further include, on the basis of the apparatus for determining ambient brightness shown in fig. 4:
A screen brightness determination module configured to determine a screen brightness currently used by the screen;
And a data determining module configured to determine total interference data generated by the target image and the screen brightness on the detection result, wherein the target interference data comprises the total interference data.
In some alternative embodiments, the data determining module may include:
An interference curve acquisition sub-module configured to acquire an interference curve drawn for the target image, the interference curve taking screen brightness as an abscissa, the interference curve taking total interference data generated by the target image and the screen brightness as an ordinate;
a data determination sub-module configured to determine the total interference data corresponding to the screen brightness on the interference curve.
In some alternative embodiments, the apparatus further comprises:
The total interference data determining module is configured to determine total interference data generated by each frame of image and screen brightness under different screen brightness for each frame of image in the preset image set;
And the interference curve drawing module is configured to draw an interference curve corresponding to each frame of image by taking the screen brightness as an abscissa and taking the total interference data generated by each frame of image and the screen brightness as an ordinate.
Fig. 5 is a schematic diagram illustrating a configuration of an electronic device 1600, according to an example embodiment. For example, electronic device 1600 may be a user device, which may be embodied as a mobile phone, computer, digital broadcast electronic device, messaging device, game console, tablet device, medical device, fitness device, personal digital assistant, wearable device such as a smart watch, smart glasses, smart bracelet, smart running shoe, and the like.
Referring to fig. 5, the electronic device 1600 may include one or more of the following components: a processing component 1602, a memory 1604, a power component 1606, a multimedia component 1608, an audio component 1610, an input/output (I/O) interface 1612, a sensor component 1614, and a communication component 1616.
The processing component 1602 generally controls overall operation of the electronic device 1600, such as operations associated with display, telephone call, data communication, camera operation, and recording operation. The processing component 1602 may include one or more processors 1620 to execute instructions to perform all or part of the steps of the methods described above. In addition, the processing component 1602 may include one or more modules that facilitate interactions between the processing component 1602 and other components. For example, the processing component 1602 may include a multimedia module to facilitate interactions between the multimedia component 1608 and the processing component 1602.
The memory 1604 is configured to store various types of data to support operations at the electronic device 1600. Examples of such data include instructions for any application or method operating on the electronic device 1600, contact data, phonebook data, messages, pictures, video, and so forth. The memory 1604 may be implemented by any type of volatile or nonvolatile memory device or combination of volatile or nonvolatile memory devices such as Static Random Access Memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic or optical disk.
The power supply component 1606 provides power to the various components of the electronic device 1600. Power supply component 1606 can include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for electronic device 1600.
The multimedia component 1608 includes a screen that provides an output interface between the electronic device 1600 and the user. In some embodiments, the screen may include a Liquid Crystal Display (LCD) and a Touch Panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only a boundary of a touch or a sliding action but also a duration and a pressure related to the touch or the sliding operation. In some embodiments, the multimedia component 1608 includes a front-facing camera and/or a rear-facing camera. When the electronic device 1600 is in an operational mode, such as an adjustment mode or a video mode, the front-facing camera and/or the rear-facing camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 1610 is configured to output and/or input audio signals. For example, the audio component 1610 includes a Microphone (MIC) configured to receive external audio signals when the electronic device 1600 is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 1604 or transmitted via the communication component 1616. In some embodiments, the audio component 1610 further includes a speaker for outputting audio signals.
The I/O interface 1612 provides an interface between the processing component 1602 and peripheral interface modules, which may be keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 1614 includes one or more sensors for providing status assessment of various aspects of the electronic device 1600. For example, the sensor assembly 1614 may detect an on/off state of the electronic device 1600, a relative positioning of the components, such as a display and keypad of the electronic device 1600, the sensor assembly 1614 may also environmentally detect a change in position of the electronic device 1600 or a component of the electronic device 1600, the presence or absence of a user's contact with the electronic device 1600, an orientation or acceleration/deceleration of the electronic device 1600, and a change in temperature of the electronic device 1600. The sensor assembly 1614 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 1614 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 1614 may also include an acceleration sensor, a gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 1616 is configured to facilitate communication between the electronic device 1600 and other devices, either wired or wireless. The electronic device 1600 may access a wireless network based on a communication standard, such as WiFi,2G, or 3G, or a combination thereof. In one exemplary embodiment, the communication component 1616 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, the communication component 1616 described above further includes a Near Field Communication (NFC) module to facilitate short range communications. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, infrared data association (IrDA) technology, ultra Wideband (UWB) technology, bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the electronic device 1600 may be implemented by one or more Application Specific Integrated Circuits (ASICs), digital Signal Processors (DSPs), digital Signal Processing Devices (DSPDs), programmable Logic Devices (PLDs), field Programmable Gate Arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic elements for executing the methods described above.
In an exemplary embodiment, there is also provided a non-transitory computer readable storage medium, such as memory 1604 including instructions that, when executed by processor 1620 of electronic device 1600, enable electronic device 1600 to perform a method of determining ambient brightness, the method comprising: determining color information of an image currently displayed by the screen; acquiring a target image in a preset image set, wherein the difference between the color information of the target image and the color information of the image meets a preset difference condition; displaying the target image on the screen, the target image being displayed above the light sensor; and determining the ambient brightness according to the light data detected by the light sensor and the target interference data, wherein the target interference data is determined according to the interference data generated by the target image on the detection result of the light sensor.
The non-transitory computer readable storage medium may be a ROM, random-access memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, etc.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any adaptations, uses, or adaptations of the disclosure following the general principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (16)

1. A method of determining ambient brightness, for use with an electronic device, the electronic device including a screen and a light sensor, the light sensor positioned below the screen, the method comprising:
determining color information of an image currently displayed by the screen;
Acquiring a target image in a preset image set, wherein the difference between the color information of the target image and the color information of the image meets a preset difference condition;
displaying the target image on the screen, the target image being displayed above the light sensor;
Determining ambient brightness according to light data and target interference data detected by the light sensor, wherein the target interference data is determined according to interference data generated by the target image on the detection result of the light sensor;
the obtaining the target image in the preset image set includes:
and determining an image with the smallest difference with the color information of the image in the preset image set as the target image.
2. The method of claim 1, wherein the light sensor is located below a target screen area of the screen; the displaying the target image on the screen includes any one of:
Displaying the target image in the whole area of the screen;
and displaying the target image in the target screen area of the screen.
3. The method of claim 1, wherein the determining color information of the image currently displayed by the screen comprises:
when the screen displays the image, obtaining a picture through screen capturing;
and carrying out color recognition on the picture to obtain the color information of the image.
4. The method of claim 1, wherein the determining color information of the image currently displayed by the screen comprises any one of:
Determining color information of the image in response to a preset duration of a current time and a historical time interval for last determining of ambient brightness;
and determining color information of the image in response to the frame number of the image refreshed by the screen reaches a preset frame number after the environment brightness is determined last time.
5. The method according to claim 1, wherein the method further comprises:
Determining the brightness of a screen currently used by the screen;
And determining total interference data generated by the target image and the screen brightness on the detection result, wherein the target interference data comprises the total interference data.
6. The method of claim 5, wherein said determining total interference data generated by said target image and said screen brightness for said detection result comprises:
Acquiring an interference curve drawn for the target image, wherein the interference curve takes screen brightness as an abscissa, and the interference curve takes total interference data generated by the target image and the screen brightness as an ordinate;
and determining the total interference data corresponding to the screen brightness on the interference curve.
7. The method of claim 6, wherein the method further comprises:
Determining total interference data generated by each frame of image and screen brightness under different screen brightness aiming at each frame of image in the preset image set;
and drawing an interference curve corresponding to each frame of image by taking the screen brightness as an abscissa and taking the total interference data generated by each frame of image and the screen brightness as an ordinate.
8. An apparatus for determining ambient brightness, characterized in that it is applied to an electronic device, said electronic device comprising a screen and a light sensor, said light sensor being located below said screen, said apparatus comprising:
a color information determining module configured to determine color information of an image currently displayed by the screen;
A target image acquisition module configured to acquire a target image in a preset image set, wherein a difference between color information of the target image and color information of the image satisfies a preset difference condition;
A target image display module configured to display the target image on the screen, the target image being displayed above the light sensor;
An ambient brightness determination module configured to determine ambient brightness from light data detected by the light sensor and target disturbance data, wherein the target disturbance data is determined from disturbance data generated by the target image on a detection result of the light sensor;
The target image acquisition module is configured to determine an image with the smallest difference from the color information of the image in the preset image set as the target image.
9. The apparatus of claim 8, wherein the light sensor is located below a target screen area of the screen; the target image display module comprises any one of the following:
a first image display sub-module configured to display the target image in an entire area of the screen;
A second image display sub-module configured to display the target image within the target screen area of the screen.
10. The apparatus of claim 8, wherein the color information determination module comprises:
a picture obtaining sub-module configured to obtain a picture through screen capturing when the screen displays the image;
and the color recognition sub-module is configured to perform color recognition on the picture to obtain color information of the image.
11. The apparatus of claim 8, wherein the color information determination module comprises any one of:
A first information determining sub-module configured to determine color information of the image in response to a current time and a historical time interval preset duration of last determination of ambient brightness;
And a second information determination sub-module configured to determine color information of the image in response to the number of frames of the image refreshed by the screen after the previous determination of the ambient brightness reaching a preset number of frames.
12. The apparatus of claim 8, wherein the apparatus further comprises:
A screen brightness determination module configured to determine a screen brightness currently used by the screen;
And a data determining module configured to determine total interference data generated by the target image and the screen brightness on the detection result, wherein the target interference data comprises the total interference data.
13. The apparatus of claim 12, wherein the data determination module comprises:
An interference curve acquisition sub-module configured to acquire an interference curve drawn for the target image, the interference curve taking screen brightness as an abscissa, the interference curve taking total interference data generated by the target image and the screen brightness as an ordinate;
a data determination sub-module configured to determine the total interference data corresponding to the screen brightness on the interference curve.
14. The apparatus of claim 13, wherein the apparatus further comprises:
The total interference data determining module is configured to determine total interference data generated by each frame of image and screen brightness under different screen brightness for each frame of image in the preset image set;
And the interference curve drawing module is configured to draw an interference curve corresponding to each frame of image by taking the screen brightness as an abscissa and taking the total interference data generated by each frame of image and the screen brightness as an ordinate.
15. A non-transitory computer readable storage medium having stored thereon a computer program, characterized in that the program, when executed by a processor, implements the method of any of claims 1-7.
16. An electronic device, comprising:
A processor;
A memory for storing processor-executable instructions;
wherein the processor is configured to execute the instructions to implement the method of any of claims 1-7.
CN202110797441.9A 2021-07-14 2021-07-14 Method and device for determining ambient brightness Active CN113551768B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110797441.9A CN113551768B (en) 2021-07-14 2021-07-14 Method and device for determining ambient brightness

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110797441.9A CN113551768B (en) 2021-07-14 2021-07-14 Method and device for determining ambient brightness

Publications (2)

Publication Number Publication Date
CN113551768A CN113551768A (en) 2021-10-26
CN113551768B true CN113551768B (en) 2024-04-23

Family

ID=78103185

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110797441.9A Active CN113551768B (en) 2021-07-14 2021-07-14 Method and device for determining ambient brightness

Country Status (1)

Country Link
CN (1) CN113551768B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104535178A (en) * 2014-12-10 2015-04-22 广东欧珀移动通信有限公司 Light strength value detecting method and terminal
JP2017083396A (en) * 2015-10-30 2017-05-18 東芝ライテック株式会社 Lighting environment evaluation method
CN109238460A (en) * 2018-08-24 2019-01-18 维沃移动通信有限公司 A kind of method and terminal device obtaining ambient light intensity
CN112229507A (en) * 2020-10-15 2021-01-15 Tcl通讯(宁波)有限公司 Ambient light detection method and device, storage medium and mobile terminal

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102486625B1 (en) * 2018-09-21 2023-01-11 삼성전자주식회사 Display apparatus and control method thereof
CN112748814A (en) * 2019-10-29 2021-05-04 北京小米移动软件有限公司 Ambient light detection method and device and terminal

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104535178A (en) * 2014-12-10 2015-04-22 广东欧珀移动通信有限公司 Light strength value detecting method and terminal
JP2017083396A (en) * 2015-10-30 2017-05-18 東芝ライテック株式会社 Lighting environment evaluation method
CN109238460A (en) * 2018-08-24 2019-01-18 维沃移动通信有限公司 A kind of method and terminal device obtaining ambient light intensity
CN112229507A (en) * 2020-10-15 2021-01-15 Tcl通讯(宁波)有限公司 Ambient light detection method and device, storage medium and mobile terminal

Also Published As

Publication number Publication date
CN113551768A (en) 2021-10-26

Similar Documents

Publication Publication Date Title
CN110796988B (en) Backlight adjusting method and device
EP3182716A1 (en) Method and device for video display
US20170103733A1 (en) Method and device for adjusting and displaying image
EP3163884A1 (en) Image acquiring method and apparatus, computer program and recording medium
CN112714205A (en) Method and device for determining ambient illumination intensity and storage medium
EP3629318B1 (en) Method and apparatus for compensating operating parameter of display circuit
CN110286813B (en) Icon position determining method and device
CN112331158B (en) Terminal display adjusting method, device, equipment and storage medium
CN111131596B (en) Screen brightness adjusting method and device
CN113551768B (en) Method and device for determining ambient brightness
CN106775246B (en) Screen brightness adjusting method and device
CN112925466B (en) Touch control method and device
CN111383568B (en) Display control method and device, electronic equipment and computer readable storage medium
CN115134516A (en) Shooting method and device
CN108769513B (en) Camera photographing method and device
CN112781832A (en) Method, apparatus, device and medium for determining ambient light for terminal device
CN114268743A (en) Image acquisition method, device, equipment and storage medium
CN112951162A (en) Display screen and control method and device thereof
CN107783704B (en) Picture effect adjusting method and device and terminal
CN111385400A (en) Backlight brightness adjusting method and device
CN112689047A (en) Display control method and device and electronic equipment
CN112087539A (en) Screen light adjusting method for terminal equipment and terminal equipment
CN115118950B (en) Image processing method and device
CN110874829A (en) Image processing method and device, electronic device and storage medium
CN111462284B (en) Animation generation method, animation generation device and electronic equipment

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