A display method, a method of generating correction data, and an electronic device

By generating calibration data and using color coordinates and mapping relationships to calibrate the display screen colors, the color difference problem when different displays are shown on the same interface is solved, and the consistency of display effect is achieved.

CN119274511BActive Publication Date: 2025-12-30HONOR DEVICE CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202410487838.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-04-22
Publication Date
2025-12-30
Estimated Expiration
2044-04-22

AI Technical Summary

Technical Problem

Color differences exist when displaying the same interface on different terminal devices, mainly due to inconsistencies in color caused by differences in display materials and manufacturing processes.

Method used

By generating calibration data and using color coordinates and mapping relationships to calibrate the colors of the display screen, the same display effect is ensured when different displays show the same interface under the same screen parameters.

Benefits of technology

This achieves consistent color display across all displays with the same screen parameters, thus improving display consistency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119274511B_ABST
    Figure CN119274511B_ABST
Patent Text Reader

Abstract

Embodiments of the present application relate to the technical field of terminals, and in particular to a display method, a method for generating correction data, and an electronic device, which can calibrate the color when a display screen displays an interface. The method comprises: under a current screen parameter, a first electronic device displays an interface based on an output color value; the output color value is a color value obtained by correcting a target color value of a pixel in the interface based on target correction data corresponding to the current screen parameter; the color coordinates of the output color value are consistent with the color coordinates of the target color value; and the target correction data comprises a mapping relationship between the output color value and the target color value under the current screen parameter.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of terminal technology, and in particular to a display method, a method for generating correction data, and an electronic device. Background Technology

[0002] With the continuous development of display technology, users have increasingly higher requirements for the display effect of terminal devices.

[0003] However, currently, different terminal devices, such as different mobile phones, exhibit color differences when displaying the same interface. Alternatively, mobile phones with multiple displays may show color differences when displaying the same interface across different screens. The main reason for this is the difference in the displays themselves, such as variations in materials, manufacturing processes, and tolerances, which lead to inconsistent colors when different displays show the same interface. Summary of the Invention

[0004] This application provides a display method, a method for generating calibration data, and an electronic device for calibrating the colors of a display screen when displaying an interface, thereby avoiding color differences between different display screens.

[0005] To achieve the above objectives, the embodiments of this application adopt the following technical solutions:

[0006] Firstly, a display method is provided for calibrating the colors of a first electronic device's display interface. The method includes: under current screen parameters, the first electronic device displays an interface based on output color values. The output color values ​​are color values ​​obtained by correcting the target color values ​​of pixels in the interface based on target correction data corresponding to the current screen parameters. The color coordinates of the output color values ​​are consistent with the color coordinates of the target color values. The target correction data includes the mapping relationship between the output color values ​​and the target color values ​​under the current screen parameters.

[0007] Since color coordinates can precisely define a color, the corrected first electronic device, when displaying an interface based on the output color value under the current screen parameters, can display the corresponding display effect. Under the same screen parameters, different first electronic devices have the same display effect when displaying the same interface based on the display method provided in this application embodiment.

[0008] In one possible implementation of the first aspect, the first electronic device stores a plurality of calibration data corresponding one-to-one with a plurality of preset screen parameters. Each calibration data includes a mapping relationship between an output color value and a target color value under the corresponding preset screen parameters. Before displaying the interface based on the output color value, the first electronic device can obtain the target calibration data based on the current screen parameters and the plurality of calibration data corresponding one-to-one with the plurality of preset screen parameters.

[0009] In one possible implementation of the first aspect, before displaying the interface based on the output color value, the first electronic device can find a preset screen parameter that matches the current screen parameter from among multiple preset screen parameters. The correction data corresponding to this preset screen parameter is the target correction data. In other words, the first electronic device can store correction data corresponding to multiple preset screen parameters, and can find the correction data corresponding to the current screen parameter from among these preset screen parameters. While this implementation can quickly find the correction data corresponding to the current screen parameter, it requires storing a large amount of correction data, thus occupying excessive storage space.

[0010] In one possible implementation of the first aspect, the current screen parameters include the current backlight brightness, and multiple preset screen parameters correspond to multiple preset brightnesses. The multiple preset screen parameters correspond to at least two preset brightnesses, such as a first preset brightness and a second preset brightness. When the current screen parameters meet a first preset condition, the correction data corresponding to the preset screen parameters related to the current screen parameters is used as the target correction data. When the current screen parameters do not meet the first preset condition, the target correction data is determined based on the correction data corresponding to the preset screen parameters related to the current screen parameters. The first preset condition is that the multiple preset brightnesses include the current backlight brightness, or the current backlight brightness is less than the first preset brightness, or the current backlight brightness is greater than the second preset brightness, wherein the first preset brightness is the minimum value among the multiple preset brightnesses, and the second preset brightness is the maximum value among the multiple preset brightnesses. In this implementation, the first electronic device may include the correction data corresponding to the preset screen parameters. When the current backlight brightness meets the first condition, the correction data corresponding to the preset screen parameters related to the current screen parameters is directly used as the target correction data. When the current backlight brightness does not meet the first condition, the target correction data needs to be calculated. In this implementation, the first electronic device only needs to store the calibration data corresponding to the preset screen parameters, which can reduce the storage space occupied and the cost of generating calibration data.

[0011] In one possible implementation of the first aspect, when multiple preset screen parameters include the current screen parameter, the correction data corresponding to the preset screen parameter that matches the current screen parameter is used as the first target correction data. The current screen parameter can be the current backlight brightness. If the current backlight brightness is less than or equal to the first preset brightness, the correction data corresponding to the preset screen parameter related to the current screen parameter is used as the second target correction data, which is the correction data corresponding to the first preset brightness. If the current backlight brightness is greater than or equal to the second preset brightness, the correction data corresponding to the preset screen parameter related to the current screen parameter is used as the third target correction data, which is the correction data corresponding to the second preset brightness. This implementation provides a possible way to generate target correction data.

[0012] In one possible implementation of the first aspect, when the current backlight brightness does not meet the first condition, target correction data needs to be calculated. Specifically, first candidate correction data and second candidate correction data are obtained; the first candidate correction data is the correction data corresponding to a third preset brightness that is less than the current backlight brightness among multiple preset brightnesses; the second candidate correction data is the correction data corresponding to a fourth preset brightness that is greater than the current backlight brightness among multiple preset brightnesses. For the same target color value, the output color value corresponding to the target color value in the first candidate correction data and the output color value corresponding to the target color value in the second candidate correction data are interpolated to obtain the output color value in the target correction data. A correspondence between the target color value and the output color value in the target correction data is established to obtain the target correction data. This implementation provides a possible way to generate target correction data.

[0013] In one possible implementation of the first aspect, the current screen parameters also include the current color mode, and the multiple preset screen parameters also correspond to the first color mode and the second color mode. The current color mode is either the first color mode or the second color mode, and the color modes corresponding to the first target correction data, the second target correction data, and the third target correction data are all the current color mode.

[0014] That is, when multiple preset screen parameters include the current screen parameter, the calibration data corresponding to the preset screen parameter that matches the current screen parameter is used as the first target calibration data. The current screen parameter can be the current backlight brightness and the current color mode. When the current backlight brightness is less than or equal to the first preset brightness, the calibration data corresponding to the preset screen parameter related to the current screen parameter is used as the second target calibration data, which is the calibration data corresponding to the first preset brightness of the current color mode. When the current backlight brightness is greater than or equal to the second preset brightness, the calibration data corresponding to the preset screen parameter related to the current screen parameter is used as the third target calibration data, which is the calibration data corresponding to the second preset brightness of the current color mode. The current color mode is either the first color mode or the second color mode. This implementation provides a possible way to generate target calibration data.

[0015] In one possible implementation of the first aspect, the current screen parameters also include the current color mode, and multiple preset screen parameters correspond to the first color mode and the second color mode. The current color mode is either the first color mode or the second color mode, and the color modes corresponding to the first candidate correction data and the second candidate correction data are both the current color mode.

[0016] That is, when the current backlight brightness does not meet the first condition, target correction data needs to be calculated. Specifically, first candidate correction data and second candidate correction data are obtained; the first candidate correction data is the correction data corresponding to the third preset brightness among multiple preset brightnesses of the current color mode that is less than the current backlight brightness; the second candidate correction data is the correction data corresponding to the fourth preset brightness among multiple preset brightnesses of the current color mode that is greater than the current backlight brightness. For the same target color value, the output color value corresponding to the target color value in the first candidate correction data and the output color value corresponding to the target color value in the second candidate correction data are interpolated to obtain the output color value in the target correction data. The correspondence between the target color value and the output color value in the target correction data is established to obtain the target correction data. This implementation provides a possible way to generate target correction data.

[0017] In one possible implementation of the first aspect, the third preset brightness is less than the current backlight brightness and is the preset brightness that is closest to the current backlight brightness among a plurality of preset brightnesses, and the fourth preset brightness is greater than the current backlight brightness and is the preset brightness that is closest to the current backlight brightness among a plurality of preset brightnesses.

[0018] In one possible implementation of the first aspect, when the first electronic device does not support spectral correction, the multiple correction data corresponding one-to-one with multiple preset screen parameters are multiple first correction data; each of the multiple first correction data includes a mapping relationship between the output color value and the target color value under the corresponding preset screen parameters. The first correction data may be, for example, a first LUT. When the first electronic device supports spectral correction, the multiple correction data corresponding one-to-one with multiple preset screen parameters are multiple second correction data. The second correction data may be, for example, a second LUT. The multiple second correction data are obtained by replacing the first target color value in the multiple first correction data with a second target color value. The second target color value is generated based on spectral distribution data, which is the spectral data when the display outputs the image corresponding to the first color value under the preset screen parameters corresponding to the first correction data. Due to manufacturing tolerances, material differences, etc., the spectral distribution data of the first color value emitted by the light-emitting diodes in different display backlight modules are different. Based on the spectral distribution data, the color of the display when showing the first color value can be specifically corrected, further calibrating the display color. The first color value may be, for example, (255.255.255).

[0019] Secondly, a method for generating color calibration data is provided, applied to a second electronic device. The second electronic device instructs the display screen of a first electronic device to display multiple color values ​​under preset screen parameters. The second electronic device acquires the color coordinates of each color value when the display screen displays the multiple color values ​​under the preset screen parameters. Based on the multiple color coordinates, the second electronic device establishes a mapping relationship between the multiple output color values ​​of the display screen and multiple target color values ​​under the preset screen parameters, obtaining calibration data. This calibration data is used to correct the output color values ​​of the display screen; the color coordinates of the calibrated output color values ​​of the display screen are consistent with the color coordinates of the target color values ​​under the preset screen parameters.

[0020] In this application, the second electronic device can obtain multiple color coordinates when the first electronic device displays multiple color values ​​under preset screen parameters. The second electronic device can establish correction data based on the color coordinates. Since color coordinates can precisely define a color, using the correction data generated by the method provided in this application to correct the color of the image displayed by the first electronic device can display a display effect corresponding to the preset screen parameters. Under the same preset parameters, different first electronic devices displaying the same interface based on the display method provided in the embodiments of this application have the same display effect.

[0021] In one possible implementation of the second aspect, the calibration data is the first calibration data. Specifically, the second electronic device can convert each of the multiple color coordinates into an output color value within the color gamut space corresponding to the display screen. The second electronic device converts each of the multiple color coordinates into a target color value within the color gamut space corresponding to preset screen parameters. The second electronic device establishes a one-to-one correspondence between the multiple output color values ​​and the multiple target color values ​​to obtain the first calibration data corresponding to the preset screen parameters. This implementation provides a specific method for the second electronic device to generate calibration data based on color coordinates.

[0022] In one possible implementation of the second aspect, the calibration data is second calibration data. Specifically, the second electronic device can convert each color coordinate in the multiple color coordinates into an output color value within the color gamut space corresponding to the display screen. The second electronic device converts each color coordinate in the multiple color coordinates into a target color value within the color gamut space corresponding to preset screen parameters. The second electronic device establishes a one-to-one correspondence between multiple output color values ​​and multiple target color values ​​to obtain first correction data corresponding to the preset screen parameters. Then, the second electronic device acquires the spectral distribution data of the display screen when displaying the first color value under the preset screen parameters, obtains the second target color value based on the spectral distribution data, and replaces the first target color value corresponding to the first color value in the first correction data with the second target color value to obtain the second correction data. Due to manufacturing tolerances, material differences, etc., the spectral distribution data of the first color value emitted by the light-emitting diodes in different display screen backlight modules are different. Based on the spectral distribution data, the color of the display screen when displaying the first color value can be specifically corrected, further calibrating the display color of the display screen. This implementation provides a method for generating calibration data based on spectral distribution data.

[0023] Thirdly, this application provides an electronic device comprising: a memory, a display screen, and one or more processors; the memory, the display screen, and the processors are coupled; wherein the memory is used to store computer program code, the computer program code including computer instructions; when the computer instructions are executed by the processor, the electronic device performs the method as described in any of the first aspects.

[0024] Fourthly, this application provides an electronic device comprising: a memory and one or more processors; the memory being coupled to the processors; wherein the memory is used to store computer program code, the computer program code including computer instructions; and when the computer instructions are executed by the processor, the electronic device performs the method as described in any of the second aspects.

[0025] Fifthly, this application provides a chip system applicable to electronic devices including memory. The chip system includes one or more interface circuits and one or more processors. The interface circuits and processors are interconnected via lines. The interface circuits are used to receive signals from the aforementioned memory and send the signals to the processors, the signals including computer instructions stored in the memory. When the processor executes the computer instructions, the electronic device performs the method as described in the first aspect and any of its possible design embodiments.

[0026] Sixthly, this application provides a computer-readable storage medium including computer instructions. When the computer instructions are executed on an electronic device, they cause the electronic device to perform the method as described in the first aspect and any of its possible design embodiments.

[0027] In a seventh aspect, this application provides a computer program product that, when run on a computer, causes the computer to perform a method as described in the first aspect and any of its possible design methods.

[0028] Understandably, the beneficial effects that can be achieved by the electronic devices of any of the possible designs of the third and fourth aspects, the chip system of the fifth aspect, the computer-readable storage medium of the sixth aspect, and the computer program product of the fifth aspect can be referred to as the beneficial effects of the first and second aspects and any of their possible designs, which will not be repeated here. Attached Figure Description

[0029] Figure 1 A color diagram illustrating an image displayed on a different display screen, provided as an embodiment of this application;

[0030] Figure 2 A schematic diagram of color coordinates provided in an embodiment of this application;

[0031] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;

[0032] Figure 4 A schematic diagram of the software architecture of an electronic device provided in an embodiment of this application;

[0033] Figure 5 A flowchart illustrating a method for generating color calibration data provided in an embodiment of this application;

[0034] Figure 6 A schematic diagram illustrating another color coordinate system provided in an embodiment of this application;

[0035] Figure 7 This application provides a schematic diagram of color difference statistics.

[0036] Figure 8 A schematic flowchart illustrating a display method provided in an embodiment of this application;

[0037] Figure 9 A schematic diagram of the interface of an electronic device provided in an embodiment of this application;

[0038] Figure 10 A schematic diagram of a fusion algorithm provided in an embodiment of this application;

[0039] Figure 11 This is a schematic flowchart illustrating a method for generating a mapping relationship between screen parameters and correction data, provided in an embodiment of this application. Detailed Implementation

[0040] Color distortion in the display screens of terminal devices can lead to significant color differences when displaying the same interface on different screens. These different screens can be displays of different terminal devices, such as different mobile phone screens. Different mobile phones can be of the same brand, model, and production batch. Different mobile phones can also be of the same brand and model but from different production batches. Alternatively, different mobile phones can be of the same brand but different models. This application does not impose specific limitations on these variations. Different screens can also be different displays of the same terminal device. Taking a mobile phone as an example, a mobile phone can include only one display screen, or it can include at least two display screens. For example, if a mobile phone includes at least two display screens, it can be a foldable phone, such as an inward-folding or outward-folding foldable phone. Optionally, the phone can also be a non-foldable phone, such as having display screen one on the front and display screen two on the back.

[0041] Taking different mobile phone screens as an example, such as Figure 1 As shown, when three phones display the same interface, their screens exhibit different display effects. Specifically, phone B's display appears whiter compared to phone A's. Phone C's display appears more yellow compared to phone A's.

[0042] The inconsistency in display effects between different displays is mainly related to the display itself. For example, differences in materials, manufacturing processes, and manufacturing tolerances can lead to differences in color coordinates between different displays.

[0043] Color coordinates are the coordinates of a color. Color coordinates can be represented as (x, y, z), where x is the coordinate on the horizontal axis and y is the coordinate on the vertical axis. Since x + y + z = 1, color coordinates are often also represented as (x, y). Based on color coordinates, a point can be determined on a chromaticity diagram that precisely represents a color. A chromaticity diagram can be, for example, the CIE 1931 chromaticity diagram. The CIE 1931 chromaticity diagram is a two-dimensional planar diagram of colors, and the x and y coordinates are used to specify colors on the chromaticity diagram.

[0044] Different displays have different color gamut spaces, which represent the range of colors the display can show. The color gamut space of a display can be represented on a chromaticity diagram. For example... Figure 2 As shown, the red color coordinates R1 of display screen b are (0.67, 0.3), and the red color coordinates R2 of display screen a are (0.59, 0.35). The green color coordinates G1 of display screen b are (0.25, 0.7), and the green color coordinates G2 of display screen a are (0.3, 0.6). The blue color coordinates B1 of display screen b are (0.18, 0.6), and the blue color coordinates B2 of display screen a are (0.15, 0.07). The area enclosed by R1, G1, and B1 constitutes the color gamut of display screen b, meaning display screen b can display colors corresponding to the color coordinates within the area enclosed by R1, G1, and B1. The area enclosed by R2, G2, and B2 constitutes the color gamut of display screen a, meaning display screen a can display colors corresponding to the color coordinates within the area enclosed by R2, G2, and B2.

[0045] Different color gamuts correspond to different color conversion matrices. The color conversion matrix of a display screen can be calculated by measuring the color coordinates of the three primary colors (red, green, and blue) and white. This color conversion matrix converts the RGB values ​​output by the display screen into XYZ values ​​in the XYZ color space. The XYZ values ​​can then be used to calculate the color coordinates of the RGB values ​​within the display screen's color gamut. For example... M is the color conversion matrix. The RGB values ​​output on a display screen correspond to the color coordinates (xyz) in the color gamut space of that display screen as x = X / X + Y + Zy = Y / X + Y + Zz = 1 - xy.

[0046] Therefore, for the same pixel RGB value, the color coordinates in the color gamut space of different displays are not the same. Since color coordinates can precisely define a color, even if different displays show the same pixel RGB value, there will still be color differences.

[0047] For example, even when displaying the same color such as RGB, the color coordinates of the color in the color gamut space of display a and display b are different because the color conversion matrices of display a and display b are not consistent. Therefore, there is a color difference when display a and display b display the same color.

[0048] Therefore, this application provides a display method, a method for generating correction data, and an electronic device for calibrating the colors of the electronic device's display interface. Before displaying the interface, the electronic device can correct the target color values ​​of pixels in the interface to output color values ​​based on target correction data, and then display the interface based on the output color values. The target correction data includes the mapping relationship between the output color values ​​and the target color values ​​under the current screen parameters. After calibration, the color coordinates of the target color values ​​are consistent with the color coordinates of the output color values. Since color coordinates can precisely define a color, the first electronic device, after calibration, can display the target display effect corresponding to the current screen parameters when displaying the interface based on the output color values ​​under the current screen parameters. Under the same screen parameters, different first electronic devices displaying the same interface using the display method provided in this application have the same display effect.

[0049] For example, the target calibration data can be a calibration lookup table (LUT), and the color values ​​can be RGB values. The calibration LUT includes mappings between multiple output RGB values ​​and target RGB values ​​under the current screen parameters. Based on the calibration LUT, the first electronic device can map the target RGB values ​​to the output RGB values ​​of the display screen. The display screen must display the output RGB values ​​to show the correct color of the target RGB values ​​under the current screen parameters. The color coordinates of the output RGB values ​​in the color space corresponding to the display screen are consistent with the color coordinates of the target RGB values ​​in the color space corresponding to the current screen parameters; that is, after calibration, the color coordinates of the output RGB values ​​of the display screen are consistent with the color coordinates of the target RGB values ​​under the current screen parameters. Thus, when different calibrated displays show the same target RGB values ​​under the same screen parameters, the different displays have the same display effect.

[0050] The method provided in this application can be applied to electronic devices with data processing capabilities and a display screen. These electronic devices may include mobile phones, tablets, laptops, personal computers (PCs), ultra-mobile personal computers (UMPCs), handheld computers, netbooks, smart home devices (e.g., smart TVs, smart screens, large screens, smart speakers, smart air conditioners, etc.), personal digital assistants (PDAs), wearable devices (e.g., smartwatches, smart bracelets, etc.), in-vehicle devices, virtual reality devices, etc., and this application does not impose any limitations on these. In this application, the aforementioned electronic device is an electronic device capable of running an operating system and installing applications. Optionally, the operating system running on the electronic device may be... system, system, Systems, etc.

[0051] For example, please refer to Figure 3 The diagram illustrates the structure of an electronic device 300. The electronic device 300 may include a processor 310, an external memory interface 320, an internal memory 321, a speaker 330A, a microphone 330B, a display screen 340, a communication module 350, a power module 360, an input device 370, a sensor module 380, a camera 390, etc. The sensor module 380 may include a pressure sensor, a touch sensor, etc.

[0052] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device 300. In other embodiments of this application, the electronic device 300 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0053] Processor 310 may include one or more processing units. For example, processor 310 may include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), and / or a neural network processing unit (NPU). Different processing units may be independent components or integrated into one or more processors. In some embodiments, electronic device 300 may also include one or more processors 310.

[0054] The processor 310 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 310 is a cache memory. This memory can store instructions or data that the processor 310 has just used or that are used repeatedly. If the processor 310 needs to use the instruction or data again, it can retrieve it directly from the memory. This avoids repeated accesses, reduces the waiting time of the processor 310, and thus improves the efficiency of the system.

[0055] The external storage interface 320 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 300. The external memory card communicates with the processor 310 through the external storage interface 320 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.

[0056] Internal memory 321 can be used to store one or more computer programs, which include instructions. Processor 310 can execute the instructions stored in internal memory 321, thereby causing electronic device 300 to perform application running methods, various applications, and data management, etc., as provided in some embodiments of this application. In some embodiments, processor 310 can execute instructions stored in internal memory 321 and / or instructions stored in memory disposed in processor 310 to cause electronic device 300 to perform color calibration methods provided in embodiments of this application.

[0057] Electronic device 300 can implement audio functions through internal memory 321, speaker 330A, microphone 330B, and application processor, such as music playback and recording. Speaker 330A, also known as a "loudspeaker," is used to convert audio electrical signals into sound signals.

[0058] Microphone 330B, also known as a "microphone" or "voice transducer," is used to convert sound signals into electrical signals. Users can speak by bringing their mouth close to microphone 330B, inputting sound signals into microphone 330B.

[0059] The communication function of electronic device 300 can be realized through antenna 1, antenna 2 and communication module 350, etc.

[0060] The communication module 350 can provide solutions for wireless communication applications on the electronic device 300, including cellular, Wi-Fi, Bluetooth (BT), and wireless data transmission modules (e.g., 433MHz, 868MHz, 915MHz). The communication module 350 can be one or more devices integrating at least one communication processing module. The communication module 350 receives electromagnetic waves via antenna 1 or antenna 2, filters and frequency-modulates the electromagnetic wave signals, and sends the processed signal to the processor 310. The communication module 350 can also receive signals to be transmitted from the processor 310, frequency-modulate and amplify them, and then convert them into electromagnetic waves for radiation via antenna 1 or antenna 2.

[0061] Electronic device 300 implements display functions through a GPU, display screen 340, and application processor. The GPU is a microprocessor for image processing, connected to the display screen 340 and the application processor. The GPU performs mathematical and geometric calculations and is used for graphics rendering. Processor 310 may include one or more GPUs, which execute program instructions to generate or modify display information.

[0062] The display screen 340 is used to display images, videos, etc. The display screen 340 includes a display panel. In some embodiments, the electronic device 300 may include one or N display screens 340, where N is a positive integer greater than 1. In this embodiment, the display screen 340 can be used to display a user interface (UI) and receive user actions on the UI.

[0063] The power module 360 ​​can be used to supply power to the various components included in the electronic device 300. In some embodiments, the power module 360 ​​can be a battery, such as a rechargeable battery.

[0064] Input device 370 may include keyboard, mouse, etc. The keyboard is used to input English letters, numbers, punctuation marks, etc. into electronic device 300, thereby issuing commands to electronic device 300 and inputting data, etc.

[0065] Electronic device 300 can implement shooting functions through an ISP, camera 390, video codec, GPU, display screen 340, and application processor. The ISP processes data fed back by the camera 390. The camera 390 captures still images or videos. In some embodiments, electronic device 300 may include one or N cameras 390, where N is a positive integer greater than 1. The digital signal processor processes digital signals, including digital image signals and other digital signals. For example, when the electronic device 300 selects a frequency, the digital signal processor performs Fourier transforms on the frequency energy. The video codec compresses or decompresses digital video.

[0066] Taking the aforementioned electronic device 300 as an example, which is a mobile phone, the software system of the electronic device 300 can adopt a layered architecture, event-driven architecture, microkernel architecture, microservice architecture, or cloud architecture. This embodiment of the invention uses the layered architecture Android system as an example to exemplify the software structure of the electronic device 300. This software structure is as follows... Figure 3 As shown.

[0067] A layered architecture divides software into several layers, each with a clear role and function. Layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: application layer, application framework layer, system library layer, and kernel layer.

[0068] The application layer can include a series of application packages.

[0069] like Figure 4 As shown, the application package may include applications such as camera, gallery, calendar, call, map, navigation, WLAN, Bluetooth, music, video, SMS, and social networking.

[0070] The application framework layer provides application programming interfaces (APIs) and a programming framework for applications in the application layer. The application framework layer includes some predefined functions. For example... Figure 4 As shown, the application framework layer may include a content provider, a view system, a resource manager, a notification manager, an input system, a color mapping module, a data generation module, etc.

[0071] The input system is used to monitor the phone's input modules (such as touchscreen drivers) and convert the parameters input by the input modules into usable events, which are then passed to the relevant upper-layer modules. For example, the input system is used to monitor the phone's touchscreen through the touchscreen driver and convert the touch parameters generated by the touchscreen input into usable events, which are then passed to the upper-layer APP.

[0072] Content providers store and retrieve data, making that data accessible to applications. This data can include videos, images, audio, phone calls made and received, browsing history and bookmarks, phone books, and more.

[0073] A view system includes visual controls, such as controls for displaying text and controls for displaying images. View systems can be used to build the display interface of an application.

[0074] The color mapping module is used to map the output RGB values ​​of the display screen based on the calibration LUT. The data generation module is used to generate the calibration LUT.

[0075] The notification manager allows applications to display notification information in the status bar. It can be used to convey informational messages and can disappear automatically after a short time without user interaction.

[0076] The Android Runtime comprises the core libraries and the virtual machine. The Android Runtime is responsible for the scheduling and management of the Android system. The core libraries consist of two parts: one part contains the functionalities that Java calls, and the other part is the core Android library itself. The application layer and application framework layer run in the virtual machine. The virtual machine executes the Java files of the application layer and application framework layer as binary files. The virtual machine is used to perform functions such as object lifecycle management, stack management, thread management, security and exception management, and garbage collection.

[0077] System libraries can include multiple functional modules. For example: surface manager, media libraries, 3D graphics processing libraries (e.g., OpenGL ES), 2D graphics engines (e.g., SGL), etc.

[0078] The Surface Manager is used to manage the display subsystem and provides the blending of 2D and 3D layers for multiple applications.

[0079] The media library supports playback and recording of various common audio and video formats, as well as still image files. It supports multiple audio and video encoding formats, such as MPEG4, H.264, MP3, AAC, AMR, JPG, and PNG.

[0080] The 3D graphics processing library is used to implement 3D graphics drawing, image rendering, compositing, and layer processing.

[0081] A 2D graphics engine is a graphics engine for 2D drawing.

[0082] The kernel layer can include touchscreen drivers, display drivers, sensor drivers, and audio drivers, etc.

[0083] The following uses a mobile phone as an example to illustrate a display method provided by an embodiment of this application, with reference to the accompanying drawings. In this embodiment, the mobile phone can calibrate the colors of its display screen's interface based on calibration data. During factory testing, the mobile phone can acquire calibration data and pre-store it in the phone. When a user uses the mobile phone, it can read the calibration data and calibrate the colors of its display screen's interface. The following description uses RGB values ​​as an example to illustrate this solution. It should be understood that color values ​​can also be color values ​​from different color models. For example, the color values ​​in this solution can be HSV values ​​in the HSV color model, Lab values ​​in the Lab color model, YUV values ​​in the YUV color model, etc. This embodiment does not specifically limit these values.

[0084] The calibration data can be a color lookup table (LUT). The calibration data includes multiple LUTs, such as the first LUT. Each of the multiple first LUTs includes a mapping relationship between the display output RGB values ​​and target RGB values ​​under a preset screen parameter. The preset screen parameter includes at least two preset color modes and at least two preset backlight brightness levels. The color mode is the display mode of the screen. The preset color mode can include a first color mode and a second color mode. The first color mode can be a standard mode, and the second color mode can be a vivid mode. Alternatively, the first color mode can be a standard mode, and the second color mode can be an eye-care mode, etc. The preset backlight brightness includes a first preset brightness and a second preset brightness, where the first preset brightness is less than the second preset brightness. For example, the first preset brightness is 120 nits, and the second preset brightness is 800 nits.

[0085] For example, multiple preset screen parameters may include: a preset color mode of standard mode and a backlight brightness of 120 nits, a preset color mode of standard mode and a backlight brightness of 800 nits, a preset color mode of vivid mode and a backlight brightness of 120 nits, and a preset color mode of vivid mode and a backlight brightness of 800 nits. The mobile phone stores multiple first LUTs corresponding one-to-one with the multiple preset screen parameters, as shown in Tables a, b, c, and d. Table a includes the mapping relationship between the RGB values ​​output by the display and the target RGB values ​​under the preset color mode of standard mode and a backlight brightness of 120 nits. Table b includes the mapping relationship between the RGB values ​​output by the display and the target RGB values ​​under the preset color mode of standard mode and a backlight brightness of 800 nits. Table c includes the mapping relationship between the RGB values ​​output by the display and the target RGB values ​​under the preset color mode of vivid mode and a backlight brightness of 120 nits. Table d includes the mapping relationship between the RGB values ​​output by the display and the target RGB values ​​under the preset color mode of vivid mode and a backlight brightness of 800 nits.

[0086] In a multi-layered first LUT, each first LUT can have multiple output RGB values, such as 24, 48, 96, or 104 output RGB values. Correspondingly, the number of target RGB values ​​and the number of output RGB values ​​are the same in the first LUT.

[0087] During the factory testing phase, the mobile phone can obtain LUTs corresponding to different preset screen parameters, as shown in Tables a, b, c, and d. The following example, using preset backlight brightness of 120 nits and 800 nits, and preset color modes including standard and vivid modes, illustrates the method for obtaining calibration data.

[0088] For example, Figure 5 A method for generating color correction data is illustrated. Exemplarily, this method is executed by a second electronic device, a mobile phone under test (MTBT), and a color analyzer. The second electronic device is connected to both the MTBT and the color analyzer. The second electronic device is used to fix the MTBT in place. The second electronic device is also used to send various test commands to the MTBT, which can respond to these commands and perform various operations. The second electronic device can also receive test data output by the color analyzer. The MTBT is the mobile phone tested at the factory stage, and this is the same mobile phone mentioned earlier.

[0089] Specifically, the second electronic device stores multiple RGB values, such as 24, 48, 96, or 104 RGB values. The following section uses an example of a second electronic device storing 104 RGB values ​​to illustrate this solution.

[0090] S501, the second electronic device sends 104 RGB values ​​to the mobile phone under test.

[0091] For example, the second electronic device can send RGB values ​​(255.0.0), (0.255.0), (0.0.255), (255.255.255), (128.0.128), etc. to the mobile phone under test.

[0092] In another implementation, the phone under test can have multiple RGB values ​​pre-installed, so the second electronic device does not need to send multiple RGB values ​​to the phone under test. That is, in this implementation, S501 is an optional step.

[0093] S502, the second electronic device sends a test command to the phone under test. This test command instructs the phone under test to sequentially display 104 RGB values ​​as output images under preset screen parameters.

[0094] The preset screen parameters can be one of several combinations of different color modes and different backlight brightness. Alternatively, the preset screen parameters can be multiple different backlight brightness levels.

[0095] S503, the phone under test controls the display screen to show 104 RGB values ​​sequentially according to preset screen parameters.

[0096] Taking a preset screen with standard mode and a backlight brightness of 120 nits as an example, specifically, the phone under test responds to the test command from the second electronic device, sets the display's color mode to standard mode, and the display's backlight brightness to 120 nits. Then, the phone under test's display sequentially displays the image corresponding to each of the 104 RGB values; that is, it uses 104 RGB values ​​as output RGB values ​​and displays the corresponding images sequentially. For example, each pixel in the display uses 104 RGB values ​​as output RGB values ​​and displays the corresponding image sequentially.

[0097] The S504 color analyzer sequentially acquires the color coordinates of 104 RGB values ​​displayed on the screen.

[0098] The S505 color analyzer sends 104 color coordinates to the second electronic device.

[0099] The display screen, with the preset color mode set to standard mode and a backlight brightness of 120 nits, sequentially displays images based on 104 RGB values. Color analysis sequentially obtains the color coordinates of these 104 RGB values ​​displayed on the screen. Thus, the color analyzer can obtain the 104 color coordinates corresponding to the 104 RGB values ​​displayed on the screen under the preset color mode set to standard mode and a backlight brightness of 120 nits. The color analyzer can then send these 104 color coordinates to a second electronic device.

[0100] S506, the second electronic device establishes a mapping relationship between the output RGB value and the target RGB value under preset screen parameters based on the color coordinates, and obtains the first LUT.

[0101] Because color coordinates can precisely represent a color, a second electronic device can establish a mapping relationship based on color coordinates. For example, for color coordinates (xy), the second electronic device can convert the color coordinates into color values ​​(XYZ) in the XYZ color space. Then, the second electronic device... Calculate the target R1G1B1 corresponding to the color coordinates under preset screen parameters. Here, M1 is the color conversion matrix corresponding to the preset screen parameters. This color conversion matrix M1 is used to convert color values ​​in the XYZ color space to color values ​​in the RGB color space. The second electronic device is based on... Calculate the output R2G2B2 value corresponding to this color coordinate in the color gamut space of the display screen. Here, M2 is the color transformation matrix corresponding to the display screen.

[0102] Generally, the color conversion matrix M1 corresponding to the preset screen parameters is a fixed value and can be pre-stored in the second electronic device. The color conversion matrix M2 of the display screen can be calculated by the second electronic device. For example, the second electronic device can calculate the color conversion matrix M2 based on the color coordinates when the display screen displays the three primary colors (such as red, blue, and green) and white. The second electronic device can calculate the color conversion matrix M2 of the display screen based on the following formula, and the calculation process is briefly described.

[0103]

[0104] First of all, let in, Where, x r y r , z r It refers to the color coordinate of red displayed on the screen. x g y g , z g It is the color coordinate for the green color displayed on the screen. x b y b , z b It refers to the color coordinates of the blue color displayed on the screen. Where, x w y w , z w The color coordinates for displaying white on the screen. After obtaining the matrix... sum matrix The second electronic device can then derive the color conversion matrix M2. It can be seen that because different displays show different color coordinates for the three primary colors and white, the color conversion matrices differ between displays.

[0105] Therefore, this mapping relationship could be, for example, mapping the target R1G1B1 to the output R2G2B2.

[0106] For example, based on one of the 104 color coordinates obtained, such as (0.64.0.3), the second electronic device obtains the target RGB value (250.0.0) corresponding to this color coordinate under the preset color mode of standard mode and a backlight brightness of 120 nits. The output RGB value of this color coordinate in the color gamut of the display screen is (251.0.0). The second electronic device can establish a mapping relationship between the target RGB (250.0.0) and the output RGB (251.0.0), that is, map the target RGB (250.0.0) to the output RGB (251.0.0). In other words, when the screen parameters are set to standard mode and backlight brightness of 120 nits, and the desired output color is target RGB (250.0.0), the screen maps target RGB (250.0.0) to output RGB (251.0.0) based on the mapping relationship. Only when the screen displays the color according to the output RGB (251.0.0) can the color corresponding to target RGB (250.0.0) under the given screen parameters be displayed correctly.

[0107] In other words, the second electronic device, based on a color coordinate, can obtain the target RGB value corresponding to that color coordinate in the color gamut space corresponding to the preset screen parameters. The second electronic device can also obtain the output RGB value corresponding to that color coordinate in the color gamut space of the display screen, based on the same color coordinate. Thus, the second electronic device can obtain multiple output color values ​​and multiple target color values ​​based on 104 color coordinates. The second electronic device establishes a one-to-one correspondence between the multiple output color values ​​and the multiple target colors, obtaining the first LUT. When the display screen is displaying the interface, it can map the target RGB values ​​to the corresponding output RGB values ​​and display the interface according to the output RGB values, thus displaying the correct color corresponding to the target RGB values ​​under the preset screen parameters.

[0108] Generally, different displays have different color conversion matrices. The color conversion matrices are the same for the same preset screen parameters, but different for different preset screen parameters. Therefore, under the same preset screen parameters, the second electronic device can determine the corresponding target RGB value based on the acquired color coordinates, and then find the corresponding mapped output RGB value in the color gamut space of different displays based on the color coordinates, thereby obtaining the mapping relationship for different displays, i.e., obtaining the first LUT for different displays. Different displays have different first LUTs. In the first LUTs of different displays under the same screen parameters, the output RGB values ​​may be the same or different, and the target RGB values ​​may be the same or different.

[0109] As an example, the same color coordinates (0.64.0.33) correspond to the target R1G1B1 (255.0.0) in a color gamut space with the preset color mode set to standard mode and a backlight brightness of 120 nits. However, due to the different color conversion matrices of different displays, these color coordinates correspond to RGB (251.0.0) in the color gamut space of display a, and RGB (255.5.0) in the color gamut space of display b. In other words, when displaying an interface with the preset color mode set to standard mode and a backlight brightness of 120 nits, display a outputs RGB (251.0.0), and display b outputs RGB (255.5.0). The colors displayed on display a and display b are consistent, both displaying the color corresponding to R1G1B1 (255.0.0) in the preset color mode set to standard mode and a backlight brightness of 120 nits.

[0110] It is understandable that the purpose of color calibration is to make the color coordinates of different displays as consistent as possible with the color coordinates under preset screen parameters, thereby avoiding color differences in display. For example, such as... Figure 6 As shown in Figure 'a', the color coordinates corresponding to the screen parameters are different from those of both display screens a and b. Therefore, before correction, even when displaying the same RGB value under the same screen parameters, display screens a and b will have a color difference. In this embodiment, a mapping relationship is established between the output RGB value of the display screen and the target RGB value corresponding to the screen parameters based on the same color coordinates, bringing the color coordinates of the display screen closer to the color coordinates corresponding to the screen parameters. That is, the output RGB value of the display screen is the color coordinates obtained by transformation and calculation through the display screen's transformation matrix, and is the color coordinates corresponding to the target RGB value of the screen parameters. In other words, in this embodiment, the color coordinates of each target RGB value under the screen parameters are used to find the corresponding output RGB value in the display screen's color gamut space, that is, the color coordinates of the display screen are corrected based on the color coordinates of the screen parameters. For example, as shown in Figure 'a'. Figure 6 As shown in b, after correction, the color coordinates of display screen b are consistent with the color coordinates corresponding to the screen parameters. It should be understood that the color coordinates of the display screen being consistent with the color coordinates corresponding to the screen parameters can be interpreted as the color coordinates of the display screen being exactly the same as the color coordinates corresponding to the screen parameters, or the color coordinates of the display screen being close to the color coordinates corresponding to the screen parameters, for example, the distance between the color coordinates of the display screen and the color coordinates corresponding to the screen parameters being less than a threshold.

[0111] The second electronic device can establish a first LUT to store the mapping relationship obtained based on the above method. The first LUT includes the mapping relationship between the RGB values ​​output by the display screen and the target RGB values ​​under preset screen parameters. For example, the first LUT established by the second electronic device corresponding to the preset color mode being standard mode and the backlight brightness being 120 nits is shown in Table a. This Table a can be as shown in Table 1.

[0112] Table 1

[0113] Target RGB value Output RGB values Target RGB value Output RGB values Target RGB value Output RGB values (50.50.50) (70.70.70) (50.60.50) (75.80.70)) (50.70.50) (85.90.70) (50.50.60) (70.70.75) (50.60.60) (80.80.75) (50.70.60) (90.95.80)

[0114] The first LUT is used to calibrate the output color values ​​of the display. The color coordinates of the calibrated output color values ​​of the display are consistent with the color coordinates of the target color values ​​under the preset screen parameters. For example, when a mobile phone's display needs to output the target RGB (50.50.50) under the preset color mode of standard mode and a backlight brightness of 120 nits, the phone maps the output RGB of the display to (70.70.70) after mapping according to Table 1. The phone uses the RGB (70.70.70) mapped by the first LUT as the final output RGB value of the display. Only when the display shows the interface according to the target RGB (70.70.70) can it display the color corresponding to RGB (50.50.50) under the preset color mode of standard mode and a backlight brightness of 120 nits.

[0115] Similarly, the second electronic device can sequentially send test commands to the phone under test, instructing the phone to control its display screen to show the 104 RGB values ​​under multiple preset screen parameters. The second electronic device can obtain multiple sets of color coordinates for the display screen to show these 104 RGB values ​​under multiple preset screen parameters. Each set of color coordinates includes the 104 color coordinates for the display screen to show these 104 RGB values ​​under one preset screen parameter. The second electronic device can generate a first LUT corresponding to multiple preset screen parameters based on these multiple sets of color coordinates. Specifically, the second electronic device, the phone under test, and the color analyzer can repeatedly execute S501-S506 until the second electronic device generates a first LUT corresponding to other preset screen parameters, such as generating Tables b, c, and d above.

[0116] Specifically, Table b may include the mapping relationship between 104 output RGB values ​​and the target RGB values ​​under the preset color mode of standard mode and a backlight brightness of 800 nits. Table c may include the mapping relationship between 104 output RGB values ​​and the target RGB values ​​under the preset color mode of vivid mode and a backlight brightness of 120 nits. Table d may include the mapping relationship between 104 output RGB values ​​and the target RGB values ​​under the preset color mode of vivid mode and a backlight brightness of 800 nits.

[0117] The preset screen parameters mentioned above are preset backlight brightness and preset color mode. Optionally, the preset screen parameters can also be only preset backlight brightness. When the preset screen parameters are preset backlight brightness, the second electronic device can obtain multiple first LUTs that correspond one-to-one with multiple preset backlight brightness. Each of these multiple first LUTs specifically includes the mapping relationship between the output RGB values ​​of the display screen and the target color values ​​under the preset backlight brightness.

[0118] Optionally, after obtaining multiple first LUTs as described above, if the display supports spectral correction, the second electronic device can perform another correction on the target RGB value corresponding to the first color value in the first LUT based on the spectral distribution data to obtain the second LUT.

[0119] For example, the second electronic device can be connected to a spectrometer. The spectrometer is used to acquire spectral distribution data when the display shows a first color value. The spectral distribution data includes data such as wavelength, intensity, and peak value. Based on the spectral distribution data, the second electronic device can obtain the target RGB value when the display shows the first color value. The spectral distribution data is related to the display backlight source; for example, it is related to the light-emitting diodes (LEDs) in the display backlight module. Due to manufacturing tolerances, material differences, etc., the spectral distribution data of white light emitted by LEDs in different display backlight modules varies. Based on the spectral distribution data, the color of the first color value displayed on the display can be specifically corrected, further calibrating the display's color. The first color value is one of multiple color values. For example, the first color value is one of the 104 RGB values. The first color value is the color value corresponding to white among multiple color values; for example, the first color value is (255.255.255) among the 104 RGB values.

[0120] For example, after S506, the above method may also include S507-S510.

[0121] S507, the spectrometer acquires spectral analysis data when the display shows the first color value under preset screen parameters.

[0122] S508, the spectrometer sends spectral distribution data to the second electronic device.

[0123] The second electronic device acquires spectral distribution data of the display screen when displaying the first color value under preset screen parameters, such as the preset color mode being standard mode and the backlight brightness being 120 nits.

[0124] S509, the second electronic device obtains the corresponding second target RGB value based on the spectral distribution data.

[0125] The second electronic device can obtain a second target RGB value when the display screen shows the first color value under the screen parameters, based on spectral distribution data. For example, the second electronic device stores a mapping relationship between spectral distribution data and RGB values, and can obtain the second target RGB value when the display screen shows the first color value under the screen parameters based on the mapping relationship and the obtained spectral distribution data.

[0126] S510, the second electronic device modifies the first target RGB value corresponding to the first color value in the first LUT to the second target RGB value obtained above, and obtains the second LUT.

[0127] The second electronic device can repeatedly execute S507-S510. The electronic device acquires spectral distribution data of the display screen sequentially displaying the first color value under different color modes and backlight intensities. The second electronic device can sequentially calculate the second target RGB value of the display screen when displaying the first color value under different color modes and backlight intensities. The second electronic device can update the first target RGB value of the first color value among the multiple target RGB values ​​in the aforementioned multiple first LUTs to the second target RGB value calculated by the second electronic device based on the spectral distribution data under the same color mode and backlight intensity, thus completing the correction of the target RGB value corresponding to the first color value.

[0128] The second electronic device can store the aforementioned calibration data (first calibration data such as a first LUT and / or second calibration data such as a second LUT) in the phone under test. For example, if the phone under test supports spectral calibration, the second electronic device can generate a second LUT and store both the first and second LUTs in the phone. If the phone under test does not support spectral calibration, the second electronic device will neither generate nor store a second LUT; it will only store the first LUT.

[0129] For example, the second electronic device can store calibration files including the aforementioned multiple LUTs in a data storage area of ​​the phone under test. This data storage area can be, for example, a persist partition. The persist partition is used to store persistent data of the phone, such as phone configuration data, system settings data, and application preference settings data. The persist partition can maintain data integrity after the device restarts. The calibration file can also include identification information for the display screen, which is used to uniquely identify the display screen. For example, the identification information can be the display screen's serial number (SN). If the phone under test includes multiple displays, the phone under test can store multiple calibration files. Each calibration file can include a LUT for calibrating one display screen and the display screen's SN. The LUT for the display screen can include a first LUT, or a first LUT and a second LUT.

[0130] Then, the second electronic device can verify whether multiple LUTs are valid. Taking the multiple LUTs as the first LUT as an example, the verification method includes S511-S517.

[0131] S511, the second electronic device sends a test command to the mobile phone under test.

[0132] The test instruction instructs the mobile phone under test to acquire the first LUT under preset screen parameters, map the color of the test image based on the first LUT, and display the mapped test image under preset screen parameters.

[0133] S512, in response to the test command, the phone under test obtains the first LUT based on preset screen parameters to map the test image, and obtains the mapped test image.

[0134] For example, the verification command instructs the phone under test to obtain Table a with a preset color mode of standard mode and a backlight brightness of 120 nits, map the color of the test image based on Table a, and display the mapped test image. The test image can be a solid color image. Taking a red test image as an example, in response to the verification command, the phone under test first obtains Table a from the data storage area. Then, the phone under test maps the target RGB values ​​of the test image to Table a using the first LUT, obtaining the output RGB values ​​of the test image. For example, if the target R1G1B1 to be output is (255.0.0), the mapped output R2G2B2 is (251.0.0). The phone under test re-inputs this output R2G2B2 (251.0.0) into the display screen to drive the display. In other words, the display screen must display the test image according to the mapped output RGB values ​​to display the correct target RGB values ​​under the preset screen parameters.

[0135] S513, the test phone controls the display screen to show the mapped test image under preset screen parameters.

[0136] Taking the preset screen parameters as follows: the preset color mode is standard mode and the backlight brightness is 120 nits, the phone under test can adjust the display color mode to standard mode, adjust the display backlight brightness to 120 nits, and display the mapped test image.

[0137] S514, the second electronic device calculates the color difference ΔE of the mapped test image displayed on the screen of the mobile phone under test under preset screen parameters.

[0138] Commonly used formulas for calculating color difference ΔE include the CIE1976 color difference formula, the DE*cmc1984 color difference formula, and the CIE94 color difference formula.

[0139] For example, in the CIE 1976 color difference formula, color difference The second electronic device can convert the output RGB values ​​of the test image into Lab values ​​in the Lab color space, convert the RGB values ​​of the test image under preset screen parameters into Lab values ​​in the Lab color space, and calculate the color based on the above formula. In the above formula, ΔL is the difference of the L components, Δa is the difference of the a components, and Δb is the difference of the b components.

[0140] The color difference ΔE value represents the color difference between the test image displayed on the screen and the test image under preset screen parameters. A lower ΔE value indicates that the test image displayed on the screen is closer to the test image under preset screen parameters, meaning a better LUT mapping effect. A higher ΔE value indicates that the test image displayed on the screen is further away from the test image under preset screen parameters, meaning a poorer LUT mapping effect.

[0141] S515, the second electronic device determines whether the color difference ΔE is within the first threshold.

[0142] If the color difference ΔE is less than the first threshold, it indicates that the test image displayed on the screen is only slightly different from the test image under the preset screen parameters, meaning the LUT is effective. If the color difference ΔE is greater than or equal to the first threshold, it indicates that the test image displayed on the screen is significantly different from the test image under the preset screen parameters, meaning the LUT is ineffective. For example, the first threshold can be any value between 0 and 1. For instance, when the color difference ΔE is less than 1, the human eye can hardly distinguish the difference between the test image displayed on the screen and the test image under the preset screen parameters.

[0143] S516, the first LUT test is passed when the color difference ΔE is less than the first threshold.

[0144] S517, the first LUT test fails when the color difference ΔE is greater than or equal to the first threshold.

[0145] If the color difference ΔE is greater than or equal to the first threshold, the second electronic device can re-execute the following: Figure 5 The method shown regenerates the calibration file and verifies the correction data. Optionally, if the color difference ΔE is greater than or equal to the first threshold, the tester can further determine whether the execution code of the second electronic device is defective. If the code is defective, the second electronic device can be re-executed after the defect is corrected. Figure 5 The method shown is used to regenerate and verify the correction data.

[0146] Figure 7This is a color difference ΔE distribution chart for the internal and external displays of 300 foldable phones, compiled by the Second Electronic Devices team, showing the color difference at ΔE values ​​when displaying test images in standard color mode with a backlight brightness of 120 nits and 800 nits, respectively. It can be seen that when the external display displays test images in standard color mode with a backlight brightness of 120 nits, the color difference ΔE distribution is between 0.15 and 0.3, all less than the color difference values ​​that the human eye can distinguish. When displaying test images in standard color mode with a backlight brightness of 800 nits, the color difference ΔE distribution is between 0.15 and 0.5, all less than the color difference values ​​that the human eye can distinguish. When the internal display displays test images in standard color mode with a backlight brightness of 120 nits, the color difference ΔE distribution is between 0.15 and 0.35, all less than the color difference values ​​that the human eye can distinguish. When the test image was displayed in standard color mode with a backlight brightness of 800 nits, the color difference ΔE ranged from 0.1 to 0.3, all less than the color difference values ​​that the human eye can distinguish. That is, using multiple LUTs generated according to the calibration data generation method provided above, the display colors of the inner and outer displays of a foldable phone can be calibrated, effectively reducing the color difference between the inner and outer displays of the same phone, as well as the color difference between different displays (different inner displays, different outer displays).

[0147] The above S511-S517, using the first LUT as an example, introduces a method for the second electronic device to verify the LUT. The method for the second electronic device to verify the second LUT is similar to... Figure 5 The methods shown in S511-S517 are similar and will not be repeated here.

[0148] Optionally, if the phone under test includes multiple displays, for each display, the second electronic device, the phone under test, the color analyzer, and / or the spectrometer can perform the following: Figure 5 The method shown generates calibration data for each display screen under preset screen parameters and verifies the calibration data.

[0149] The above combination Figure 5 The process of generating calibration data has been introduced. It should be understood that the phone in question is the same phone under test mentioned earlier. Calibration data can be generated during the factory testing phase of the phone, and the phone can use the calibration data to calibrate the displayed colors during user use.

[0150] Under the current screen parameters, the mobile phone can correct the target color values ​​of pixels in the interface based on the target correction data corresponding to the current screen parameters, obtaining the output color values ​​of the pixels. The mobile phone can then display the interface based on these output color values. The color coordinates of the output color value and the target color value are consistent. The target correction data can include the mapping relationship between the output color value and the target color under the current screen parameters. It should be understood that the color coordinates of the output color value and the target color value being consistent can be interpreted as the color coordinates of the output color value and the target color value being completely identical, or the distance between the color coordinates of the output color value and the target color value being less than a preset threshold.

[0151] The target correction data can be either a first LUT or a second LUT. Alternatively, the target correction data can be calculated from either the first LUT or the second LUT. For example, if the phone supports spectral correction, the target correction data can be either the second LUT or calculated from the second LUT. If the phone does not support spectral correction, the target correction data can be either the first LUT or calculated from the first LUT.

[0152] The following is combined Figure 8 This paper describes a method for calibrating the display colors of a mobile phone using calibration data. For example, when the screen brightness changes or the color mode switches, the mobile phone can perform the following... Figure 8 The method shown. This method may include:

[0153] The S801a identifies whether the display supports color calibration when the display screen changes or the color mode is switched.

[0154] The mobile phone may include at least one display screen, and when the screen of one of the displays changes or the color mode is switched, the mobile phone can identify whether the display screen supports color calibration.

[0155] Changes in the display screen include changes in whether the screen is on or off, such as switching from off to on, and changes in screen brightness.

[0156] For example, when the phone is locked, the screen is off; in response to the user's unlocking action, the screen switches from off to on. As another example, after the phone is powered on, the screen brightness switches from off to on.

[0157] Changes in screen brightness include the screen brightness changing from bright to dim, or from dim to bright. These changes can be triggered by the phone in response to a user's action, or they can be performed automatically by the phone. For example, ... Figure 9As shown, the phone displays interface 901. Interface 901 can be the display interface of the phone's control center, which displays a screen brightness adjustment control. In response to the user sliding the control to the right, the screen brightness increases. In response to the user sliding the control to the left, the screen brightness decreases. Optionally, after the phone's automatic screen brightness adjustment function is enabled, the phone can also automatically adjust the screen brightness. For example, the phone can automatically adjust the screen brightness based on the ambient light level. For example, when the ambient light level is low, the phone can decrease the screen brightness to avoid excessive brightness. When the ambient light level is high, the phone can increase the screen brightness to avoid excessive brightness. In other words, the phone can automatically or in response to user triggers adjust the screen brightness.

[0158] The display includes at least two color modes: a first color mode and a second color mode. The display effect differs depending on the color mode. For example, the first and second color modes could be a standard mode and a vivid mode. In vivid mode, the color saturation and contrast of the interface are higher when the display shows the screen. The mobile phone can switch the display's color mode in response to the user's operation of switching color modes. For example, such as... Figure 9 As shown, the phone displays interface 902, which can be the color adjustment interface in the settings application. Interface 902 displays a color mode selection control. The first color mode can be standard mode, and the second color mode can be vivid mode. For example, the currently displayed color mode is standard mode, and in response to the user selecting vivid mode, the phone switches the display's color mode from standard mode to vivid mode.

[0159] When the display changes or the color mode switches, the phone can first identify whether the display supports color calibration. For example, the phone can read a first preset flag within a first preset flag bit. This first preset flag may be written by the developers during the phone's development phase. The first preset flag can be 1 or 0. A first preset flag of 1 indicates that the display supports color calibration. A first preset flag of 0 indicates that the display does not support color calibration.

[0160] Optionally, when switching color modes, the phone can identify whether the display supports color mode switching. For example, the phone can identify whether it supports color mode switching by reading a second preset identifier within a second preset flag. If the display supports color mode switching, the phone can respond to the user's switching operation and switch the display's color mode. The phone can further identify whether the display supports color calibration. If the display does not support color mode switching, the phone may not respond to the user's switching operation. Alternatively, the phone may not display... Figure 9 The interface shown is 902.

[0161] If the S801b display supports color calibration, the phone will obtain the current screen parameters of the display.

[0162] The current screen parameters may include the current backlight brightness. Alternatively, the current screen parameters may include the current backlight brightness and the current color mode, where the current color mode is one of the at least two preset color modes mentioned above.

[0163] Optionally, if the display does not support color calibration, the process ends.

[0164] Optionally, after recognizing that the display supports color calibration, the phone can further identify whether the display supports spectral correction.

[0165] S802, the phone identifies whether the display screen supports spectral correction.

[0166] For example, the mobile phone can read a third preset identifier within a third preset flag. This third preset identifier may be written by the developers during the mobile phone's development phase. This third preset identifier can be 1 or 0. If the third preset identifier is 1, it indicates that the display supports color calibration. If the third preset identifier is 0, it indicates that the display does not support color calibration.

[0167] In the case that the display does not support spectral correction, the S803 mobile phone obtains target correction data based on the first LUT, according to the current screen parameters of the display and the first LUT that corresponds one-to-one with multiple preset screen parameters.

[0168] The phone stores a first LUT that corresponds one-to-one with multiple preset screen parameters. The phone also stores a first mapping relationship between multiple screen parameters and the first LUT. The phone can obtain the target correction data corresponding to the current screen parameters based on the current screen parameters and the first mapping relationship.

[0169] When the current screen parameters only include the current backlight brightness, and the preset screen parameters only include multiple preset brightness levels, the first mapping relationship can be as shown in Table 2.

[0170] Table 2

[0171] Preset brightness Correction data 120nit First LUT1 500nit First LUT2 800nit First LUT3

[0172] The mobile phone can obtain the first LUT corresponding to the current screen parameters based on the current backlight brightness and the preset brightness. Specifically, if the current screen parameters meet the first preset condition, the correction data corresponding to the preset screen parameters related to the current screen parameters is used as the target correction data. If the current screen parameters do not meet the first preset condition, the target correction data is determined based on the correction data corresponding to the preset screen parameters related to the current screen parameters.

[0173] The first preset condition is a plurality of preset brightness values, including the current backlight brightness, or the current backlight brightness is less than the first preset brightness, or the current backlight brightness is greater than the second preset brightness. The first preset brightness is the minimum value among the plurality of preset brightness values, and the second preset brightness is the maximum value among the plurality of preset brightness values.

[0174] Taking Table 2 as an example, when the current backlight brightness is 120 nits, 500 nits, or 800 nits, the calibration data corresponding to the preset screen parameters related to the current screen parameters is used as the target calibration data. When the current backlight brightness is less than the first preset brightness of 120 nits, or when the current backlight brightness is greater than the second preset brightness of 800 nits, the calibration data corresponding to the preset screen parameters related to the current screen parameters is used as the target calibration data. When the current backlight brightness is 350 nits, the target calibration data needs to be calculated based on the first LUT corresponding to multiple preset screen parameters and the current backlight brightness.

[0175] When multiple preset brightness levels are available, including the current backlight brightness, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the first target calibration data. The first target calibration data is the calibration data corresponding to the preset brightness that matches the current backlight brightness among the multiple preset brightness levels. When the current backlight brightness is less than or equal to the first preset brightness, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the second target calibration data. The second target calibration data is the calibration data corresponding to the first preset brightness. When the current backlight brightness is greater than or equal to the second preset brightness, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the third target calibration data. The third target calibration data is the calibration data corresponding to the second preset brightness.

[0176] Taking Table 2 as an example, when the current backlight brightness is 120 nits, 500 nits, or 800 nits, the target calibration data is the first target calibration data, which is the first LUT1 corresponding to 120 nits, the first LUT2 corresponding to 500 nits, or the first LUT3 corresponding to 800 nits. When the current backlight brightness is less than the first preset brightness of 120 nits, the target calibration data is the second target calibration data, which is the first LUT1 corresponding to 120 nits. When the current backlight brightness is greater than the second preset brightness of 800 nits, the target calibration data is the third target calibration data, which is the first LUT3 corresponding to 800 nits.

[0177] When the current backlight brightness does not meet the first condition, for example, when the current backlight brightness is 350 nits, it is necessary to calculate the target correction data based on the first LUT corresponding to multiple preset screen parameters and the current backlight brightness. An example of calculating the target correction data is given below.

[0178] The mobile phone can first obtain first candidate correction data and second candidate correction data. For example, when the current backlight brightness is 350 nits, the first candidate correction data can be the correction data corresponding to a third preset brightness that is less than the current backlight brightness among multiple preset brightnesses. The third preset brightness can be 120 nits. The first candidate correction data can be the first LUT1 corresponding to the third preset brightness of 120 nits. The second candidate correction data is the correction data corresponding to a fourth preset brightness that is greater than the current backlight brightness among multiple preset brightnesses. The fourth preset brightness can be 500 nits or 800 nits. The second candidate correction data can be the first LUT2 corresponding to the fourth preset brightness of 500 nits, or the first LUT3 corresponding to the fourth preset brightness of 800 nits.

[0179] Then, the phone can calculate a first ratio. The first ratio is the ratio of a first difference to a second difference, where the first difference is the difference between the current backlight brightness and a third preset brightness, and the second difference is the difference between a fourth preset brightness and a third preset brightness. For example, the third preset brightness could be 120 nits, and the fourth preset brightness could be 800 nits, then the first ratio = (350-120) / (800-120). Or, for another example, the third preset brightness could be 120 nits, and the fourth preset brightness could be 500 nits, then the first ratio = (350-120) / (500-120).

[0180] Subsequently, for the same target color value, the output color value corresponding to the target color value in the first candidate correction data and the output color value corresponding to the target color value in the second candidate correction data are interpolated to obtain the output color value in the target correction data, and a mapping relationship is established. For example, for the target RGB1 and output RGB1 in the first LUT corresponding to the third preset brightness, and the target RGB1 and output RGB2 in the first LUT corresponding to the fourth preset brightness, the mobile phone can calculate the output RGB3 in the target correction data corresponding to the current backlight brightness based on the first ratio, the output RGB1 in the first LUT corresponding to the third preset brightness, and the output RGB2 in the first LUT corresponding to the fourth preset brightness. For example, the output RGB... 3= Output RGB1 + (Output RGB2 - Output RGB1) * First ratio. Afterwards, the phone can establish a mapping relationship between the target RGB1 and the output RGB3 to obtain the target correction data.

[0181] Optionally, the third preset brightness is less than the current backlight brightness and is the preset brightness closest to the current backlight brightness among multiple preset brightnesses, and the fourth preset brightness is greater than the current backlight brightness and is the preset brightness closest to the current backlight brightness among multiple preset brightnesses. For example, when the current backlight brightness is 350 nits, the third preset brightness is 120 nits and the fourth preset brightness is 500 nits.

[0182] When the current screen parameters include the current backlight brightness and the current color mode, and the preset screen parameters include multiple preset brightness and multiple color modes, the first mapping relationship can be as shown in Table 3 for example.

[0183] Table 3

[0184]

[0185] The mobile phone can obtain target calibration data corresponding to the current screen parameters based on the current backlight brightness, preset brightness, and current color mode. Similarly, if the current backlight brightness meets a first preset condition, the calibration data corresponding to the preset screen parameters related to the current screen parameters is used as the target calibration data. If the current backlight brightness does not meet the first preset condition, the target calibration data is determined based on the calibration data corresponding to the preset screen parameters related to the current screen parameters.

[0186] Specifically, when multiple preset brightness levels, including the current backlight brightness, are considered, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the first target calibration data. The first target calibration data is the calibration data corresponding to the preset brightness that matches the current backlight brightness among the multiple preset brightness levels in the current color mode. When the current backlight brightness is less than or equal to the first preset brightness, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the second target calibration data. The second target calibration data is the calibration data corresponding to the first preset brightness in the current color mode. When the current backlight brightness is greater than or equal to the second preset brightness, the calibration data corresponding to the preset screen parameters related to the current screen parameters is the third target calibration data. The third target calibration data is the calibration data corresponding to the second preset brightness in the current color mode.

[0187] Taking Table 3 as an example, when the current color mode is standard mode and the current backlight brightness is 120 nit, 500 nit, or 800 nit, the target calibration data is the first target calibration data. This first target calibration data is the first LUT1 corresponding to the preset color mode of standard mode and preset brightness of 120 nit, or the first target calibration data is the first LUT2 corresponding to the preset color mode of standard mode and preset brightness of 500 nit, or the first target calibration data is the first LUT3 corresponding to the preset color mode of standard mode and preset brightness of 800 nit. When the current color mode is standard mode and the current backlight brightness is less than the first preset brightness, such as 120 nit, the target calibration data is the second target calibration data. This second target calibration data is the first LUT1 corresponding to the preset color mode of standard mode and preset brightness of 120 nit. When the current color mode is standard mode and the current backlight brightness is greater than the second preset brightness of 800 nit, the target calibration data is the third target calibration data. This third target calibration data is the first LUT3 corresponding to the preset color mode of standard mode and preset brightness of 800 nit. It can be seen that when the current screen parameters include the current color mode and the current backlight brightness, the color modes corresponding to the first target correction data, the second target correction data, and the third target correction data are all the current color mode.

[0188] When the current backlight brightness is 350 nits, the target correction data needs to be calculated based on the first LUT corresponding to multiple preset screen parameters and the current backlight brightness. This calculation method is the same as the calculation method described above, and will not be repeated here.

[0189] When the current screen parameters include the current color mode and the current backlight brightness, the color mode corresponding to both the first candidate correction data and the second candidate correction data is the current color mode. For example, when the current backlight brightness is 300 nits, the first candidate correction data can be the correction data corresponding to the third preset brightness (less than the current backlight brightness) among multiple preset brightness levels for the current color mode, such as the first LUT1 corresponding to 120 nits in Table 3. The second candidate correction data can be the correction data corresponding to the fourth preset brightness (greater than the current backlight brightness) among multiple preset brightness levels for the current color mode, such as the first LUT3 corresponding to 800 nits in Table 3. Optionally, the second candidate correction data can be the first LUT2 corresponding to the preset color mode being standard mode and the preset brightness being 500 nits.

[0190] The following example, using the standard color mode as an example and referring to Table 3, provides a specific illustration. When the current backlight brightness of the display is less than or equal to 120 nits, the phone uses the first LUT1 to calibrate the display's color; that is, the first LUT1 is the target calibration data. In standard mode, when the current backlight brightness of the display is greater than 800 nits, the phone uses the first LUT3 to calibrate the display's color; that is, the first LUT3 is the target calibration data. In standard mode, when the current backlight brightness of the display is greater than 120 nits but less than 800 nits, the phone can generate target calibration data corresponding to the current color mode and the current backlight brightness. For example, the current backlight brightness could be 350 nits, then the first ratio = (350-120) / (800-120). Afterwards, based on the first LUT1 and the first LUT3, the phone calculates each output RGB value in the target calibration data corresponding to the current backlight brightness of the current color mode. For example, regarding the target RGB and output RGB1 in the first LUT1 and the target RGB and output RGB2 in the first LUT3, the mobile phone can calculate the output RGB3 in the target correction data corresponding to the current backlight brightness of the current color mode based on the first ratio, the output RGB1 in the first LUT1 and the output RGB2 in the first LUT3. For example, the output RGB... 3= Output RGB1 + (Output RGB2 - Output RGB1) * First ratio. Afterwards, the phone can establish a mapping relationship between the target RGB1 and the output RGB3 to obtain the target correction data.

[0191] Optionally, the first ratio = (350-120) / (500-120). Based on the first ratio, the mobile phone can calculate the output RGB3 in the target correction data corresponding to the current backlight brightness of the current color mode.

[0192] In this way, the mobile phone can establish a mapping relationship between multiple target RGB values ​​and output RGB values ​​in the target correction data corresponding to the current backlight brightness and the current color mode.

[0193] S804: Before the display screen shows the interface, the phone calibrates the output RGB of each pixel in the interface based on the target correction data corresponding to the current screen parameters.

[0194] Specifically, the phone calibrates the display colors by calibrating the output RGB values ​​of each pixel on the display using target calibration data corresponding to the current screen parameters. For example, for each pixel, the phone can map the pixel's target RGB value to the output RGB value in the target calibration data and drive the pixel to display the interface according to the output RGB value.

[0195] In S805, if the display supports spectral correction, the phone uses a second LUT to obtain target correction data based on the current screen parameters of the display and the second LUT that corresponds one-to-one with multiple preset screen parameters.

[0196] The phone stores a second LUT that corresponds one-to-one with multiple preset screen parameters. The phone also stores a first mapping relationship between multiple screen parameters and the second LUT. The phone can obtain the target correction data corresponding to the current screen parameters based on the current screen parameters and the first mapping relationship.

[0197] When the current screen parameters only include the current backlight brightness, and the preset screen parameters only include multiple preset brightness levels, the first mapping relationship can be as shown in Table 4.

[0198] Table 4

[0199] Preset brightness Correction data 120nit Second LUT1 500nit Second LUT2 800nit Second LUT3

[0200] When the current screen parameters include the current backlight brightness and the current color mode, and the preset screen parameters include multiple preset brightness and multiple preset color modes, the first mapping relationship can be as shown in Table 5 for example.

[0201] Table 5

[0202]

[0203]

[0204] The method by which the mobile phone obtains target calibration data based on the second LUT according to the current screen parameters of the display screen and the second LUT corresponding one-to-one with multiple preset screen parameters is similar to the method by which the mobile phone obtains target calibration data based on the first LUT according to the current screen parameters of the display screen and the first LUT corresponding one-to-one with multiple preset screen parameters, and will not be described in detail here.

[0205] Below is a specific example. When the display's current color mode is standard mode and the display's current backlight brightness is less than or equal to 120 nits, the phone uses the second LUT1 to calibrate the display's color; that is, the second LUT1 is the target calibration data. When the display's current color mode is standard mode and the display's current backlight brightness is greater than or equal to 800 nits, the phone uses the second LUT3 to calibrate the display's color; that is, the second LUT3 is the target calibration data. When the display's current color mode is standard mode and the display's current backlight brightness is 500 nits, the phone uses the second LUT2 to calibrate the display's color; that is, the second LUT2 is the target calibration data. When the display's current color mode is standard mode and the display's current backlight brightness is 350 nits, the phone uses the first candidate calibration data and the second candidate calibration data to calculate the target calibration data. The specific calculation method is similar to that described above and will not be repeated here.

[0206] The first candidate correction data can be the correction data corresponding to the third preset brightness, which is less than the current backlight brightness, among multiple preset brightnesses of the current color mode, such as the second LUT1 corresponding to 120 nits in Table 5. The second candidate correction data can be the correction data corresponding to the fourth preset brightness, which is greater than the current backlight brightness, among multiple preset brightnesses of the current color mode, such as the second LUT3 corresponding to 800 nits in Table 5. Alternatively, the second candidate correction data can be the correction data corresponding to the fourth preset brightness, which is greater than the current backlight brightness, among multiple preset brightnesses of the current color mode, such as the second LUT2 corresponding to 500 nits in Table 5.

[0207] Similarly, the third preset brightness is a preset brightness that is less than the current backlight brightness and closest to the current backlight brightness. The fourth preset brightness is a preset brightness that is greater than the current backlight brightness and closest to the current backlight brightness.

[0208] Optional, such as Figure 10 As shown, the mobile phone has a built-in fusion algorithm that has the ability to generate target correction data based on a first LUT. This fusion algorithm also has the ability to generate target correction data based on a second LUT. For example, using the first LUT corresponding to the third preset brightness of the current color mode and the first LUT corresponding to the fourth preset brightness of the current color mode as inputs to the algorithm, the algorithm can output target correction data corresponding to the current backlight brightness of the current color mode. For instance, using the second LUT corresponding to the third preset brightness of the current color mode and the second LUT corresponding to the fourth preset brightness of the current color mode as inputs to the algorithm, the algorithm can output a second correction LUT corresponding to the current backlight brightness of the current color mode.

[0209] In the S806, before the phone's display screen shows the interface, the phone outputs RGB values ​​for each pixel in the second calibration LUT interface based on the current screen parameters.

[0210] Specifically, the phone calibrates the display colors by calibrating the output RGB values ​​of each pixel on the display using a second calibration LUT. For example, for each pixel, the phone can map the target RGB value of that pixel to the output RGB value in the second calibration LUT, and drive the pixel to display the interface according to the output RGB values.

[0211] The mobile phone can automatically establish a first mapping relationship and a second mapping relationship as shown in Table 2 or Table 3. For example, the mobile phone can establish the first mapping relationship and the second mapping relationship as shown in Table 2 or Table 3 when the user uses it for the first time after leaving the factory. The following is an illustration of a method by which the mobile phone establishes a mapping relationship between screen parameters and calibration data. For example, as shown... Figure 11 As shown, the method includes S1101-S1108.

[0212] The S1101, after being powered on, identifies whether the display supports color calibration.

[0213] After powering on, the phone can first determine whether the display supports color calibration. The identification method is similar to that in the S801a and will not be described further here.

[0214] Optionally, the process ends if the display does not support color calibration.

[0215] S1102, when the display supports color calibration, the phone identifies whether the display supports spectral calibration.

[0216] If the display supports spectral calibration, the phone executes steps S1103-S1106. If the display does not support spectral calibration, the phone executes steps S1106-S1108.

[0217] S1103: If the display supports color calibration and spectral calibration, the phone determines whether the second LUT and brightness mapping table exist.

[0218] The second LUT is stored in the persist partition during the phone's factory testing phase. The phone determines whether the persist partition contains the second LUT. Specifically, the phone includes a calibration data list, which contains table names of multiple LUTs before and after spectral calibration. The LUT table name can include the corresponding color mode and backlight brightness, as well as a preset identifier. This preset identifier can indicate whether the LUT is the first LUT or the second LUT. The phone compares the table names of the multiple LUTs in the persist partition with the table names in the calibration data list one by one to identify whether the persist partition contains the second LUT.

[0219] A brightness mapping table establishes the mapping between display backlight brightness and display screen brightness. This table maps the display screen brightness to the display backlight brightness. In this way, the phone can determine the backlight brightness based on the display screen's brightness.

[0220] S1104, if the second LUT and brightness mapping table exist, the mobile phone verifies the correctness and integrity of the second LUT.

[0221] The mobile phone can verify the display's serial number (SN) to ensure that the second LUT stored in the phone is the calibration data generated for that display, thus ensuring that the calibration data used by the phone to calibrate the display is correct. When the phone includes multiple displays, it stores multiple sets of calibration files for each display. Each calibration file includes a first LUT or a second LUT, and the display's SN. The phone can obtain the display's SN and compare it with the display's SN in the calibration file to ensure that the calibration data is the correct calibration data for that display, avoiding the use of incorrect calibration data.

[0222] The mobile phone can also verify the correctness and integrity of the second LUT. For example, the mobile phone can calculate the Block Check Character (BCC) of the second LUT. Here, BCC is also known as XOR check. Specifically, during the factory testing phase, after the color test is passed, the mobile phone can perform an XOR calculation on all bytes within each second LUT to obtain multiple check values. After the mobile phone is powered on, if the second LUT and the brightness mapping table exist, the mobile phone performs an XOR calculation on all bytes within the second LUT stored in the persist partition to obtain multiple check values. The mobile phone compares the check value one with the check value two for each second LUT. If the first check value matches the second check value, the mobile phone recognizes that the second LUT is correct and complete. Optionally, to reduce the computational load, the mobile phone can calculate a check value based on the second LUT under the same color mode and compare this check value with the check value calculated by the mobile phone during the testing phase. This application embodiment does not specifically limit this.

[0223] S1105 After the verification is successful, the mobile phone establishes a mapping relationship between the backlight brightness and color mode and the second LUT.

[0224] The phone can identify the second LUT in the persist partition based on the preset identifier in the LUT's table name. Then, based on the color mode and backlight brightness in the LUT's table name, a mapping relationship is established between the backlight brightness and color mode and the second LUT.

[0225] Optionally, the process ends after verification fails.

[0226] S1106: If the display supports color calibration but not spectral calibration, the phone will determine whether the first LUT and the brightness mapping table exist.

[0227] S1107, if the first LUT and the brightness mapping table exist, the mobile phone verifies the correctness and integrity of the first LUT.

[0228] The method for verifying the correctness and completeness of the first LUT via mobile phone is similar to the method for verifying the correctness and completeness of the second LUT via mobile phone, and will not be repeated here. Please refer to the previous introduction.

[0229] S1108 After the verification is successful, the mobile phone establishes a mapping relationship between the backlight brightness and color mode and the first LUT.

[0230] The phone can identify the first LUT in the persist partition based on the preset identifier in the LUT's table name. Then, based on the color mode and backlight brightness in the LUT's table name, a mapping relationship is established between the backlight brightness and color mode and the first LUT.

[0231] Optionally, the process ends after verification fails.

[0232] Thus, when the phone is powered on for the first time, it can store the first mapping relationship or the second mapping relationship as shown in Tables 2-5. When the screen or color mode of the display changes, the appropriate calibration LUT is determined based on the first mapping relationship or the second mapping relationship, and the calibration LUT is used to calibrate the display color of the display.

[0233] This application provides an electronic device including a memory, a display screen, and one or more processors. The display screen is coupled to the processors. The memory stores computer program code. The computer program code includes computer instructions. When the processor executes the computer instructions, the electronic device can perform various functions or steps performed by the mobile phone in the above method embodiments. The structure of the electronic device can be referred to... Figure 3 The structure of the electronic device 300 shown.

[0234] This application provides an electronic device, which includes a memory and one or more processors. The memory stores computer program code. The computer program code includes computer instructions. When the processor executes the computer instructions, the electronic device can perform various functions or steps performed by the second electronic device in the above method embodiments.

[0235] This application embodiment also provides a computer storage medium, which includes computer instructions, when the computer instructions are executed in the aforementioned electronic device (such as...). Figure 3 When the electronic device 300 shown is run, it causes the electronic device to perform the various functions or steps in the above method embodiments.

[0236] This application also provides a computer program product that, when run on a computer, causes the computer to perform the various functions or steps described in the above method embodiments.

[0237] This application also provides a chip system including at least one processor and at least one interface circuit. The processor and the interface circuit are interconnected via lines. For example, the interface circuit can be used to receive signals from other devices (e.g., the memory of an electronic device). As another example, the interface circuit can be used to send signals to other devices (e.g., the processor). Exemplarily, the interface circuit can read instructions stored in the memory and send the instructions to the processor. When the instructions are executed by the processor, the electronic device can perform the steps in the above embodiments. Of course, the chip system may also include other discrete devices, and this application does not specifically limit this.

[0238] Through the above description of the embodiments, those skilled in the art can clearly understand that, for the sake of convenience and brevity, only the division of the above functional modules is used as an example. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.

[0239] In the several embodiments provided in this application, it should be understood that the disclosed apparatus and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another apparatus, or some features may be ignored or not executed. Furthermore, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0240] The units described as separate components may or may not be physically separate. A component shown as a unit can be one or more physical units; that is, it can be located in one place or distributed in multiple different locations. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0241] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0242] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solutions of the embodiments of this application, in essence, or the parts that contribute to the prior art, or all or part of the technical solutions, can be embodied in the form of a software product. This software product is stored in a storage medium and includes several instructions to cause a device (which may be a microcontroller, chip, etc.) or processor to execute all or part of the steps of the methods of the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0243] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any changes or substitutions within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. A display method characterized by comprising: The application discloses a method for calibrating color of a display interface of a display screen of a first electronic device, wherein the first electronic device stores a plurality of correction data corresponding to a plurality of preset screen parameters; Each of the plurality of correction data comprises a mapping relationship between an output color value and a target color value under a corresponding preset screen parameter, and the method comprises: Based on the current screen parameter and the plurality of correction data corresponding to the plurality of preset screen parameters, target correction data is obtained; In a case that the first electronic device does not support spectrum correction, the plurality of correction data is a plurality of first correction data, and each of the plurality of first correction data comprises a mapping relationship between an output color value and a target color value under a corresponding preset screen parameter; In a case that the first electronic device supports spectrum correction, the plurality of correction data is a plurality of second correction data, and the plurality of second correction data is obtained by replacing a first target color value in the plurality of first correction data with a second target color value, wherein the second target color value is generated according to spectrum distribution data, and the spectrum distribution data is spectrum data of the display screen when outputting an image corresponding to the first color value under the preset screen parameter corresponding to the first correction data; Under the current screen parameter, the display screen of the first electronic device displays an interface based on an output color value; The output color value is a color value of a pixel in the interface after a target color value of the pixel is corrected based on the target correction data corresponding to the current screen parameter, and color coordinates of the output color value are consistent with color coordinates of the target color value; and the target correction data comprises a mapping relationship between the output color value and the target color value under the current screen parameter.

2. The method of claim 1, wherein, The current screen parameter comprises a current backlight brightness, and the plurality of preset screen parameters correspond to a plurality of preset brightnesses; The target correction data is obtained based on the current screen parameter and the plurality of correction data corresponding to the plurality of preset screen parameters, and the method comprises: In a case that the current screen parameter satisfies a first preset condition, correction data corresponding to a preset screen parameter related to the current screen parameter is used as the target correction data; In a case that the current screen parameter does not satisfy the first preset condition, the target correction data is determined according to the correction data corresponding to the preset screen parameter related to the current screen parameter; The first preset condition is that the plurality of preset brightnesses comprise the current backlight brightness, or the current backlight brightness is less than a first preset brightness, or the current backlight brightness is greater than a second preset brightness, wherein the first preset brightness is a minimum value in the plurality of preset brightnesses, and the second preset brightness is a maximum value in the plurality of preset brightnesses.

3. The method of claim 2, wherein, The correction data corresponding to the preset screen parameter related to the current screen parameter is used as the target correction data, and the method comprises: In a case where the plurality of preset luminances include the current backlight luminance, the correction data corresponding to the preset screen parameter related to the current screen parameter is first target correction data, and the first target correction data is the correction data corresponding to the preset luminance consistent with the current backlight luminance among the plurality of preset luminances. In a case where the current backlight luminance is less than or equal to the first preset luminance, the correction data corresponding to the preset screen parameter related to the current screen parameter is second target correction data, and the second target correction data is the correction data corresponding to the first preset luminance. In a case where the current backlight luminance is greater than or equal to the second preset luminance, the correction data corresponding to the preset screen parameter related to the current screen parameter is third target correction data, and the third target correction data is the correction data corresponding to the second preset luminance.

4. The method according to claim 2 or 3, characterized in that, The determining of the target correction data according to the correction data corresponding to the preset screen parameter related to the current screen parameter comprises: obtaining first candidate correction data and second candidate correction data, the first candidate correction data being the correction data corresponding to a third preset luminance less than the current backlight luminance among the plurality of preset luminances, and the second candidate correction data being the correction data corresponding to a fourth preset luminance greater than the current backlight luminance among the plurality of preset luminances; performing interpolation calculation on the output color value corresponding to the target color value in the first candidate correction data and the output color value corresponding to the target color value in the second candidate correction data for the same target color value to obtain the output color value in the target correction data; and establishing a corresponding relationship between the target color value and the output color value in the target correction data to obtain the target correction data.

5. The method of claim 3, wherein, The current screen parameter further comprises a current color mode, the plurality of preset screen parameters correspond to a first color mode and a second color mode, the current color mode is the first color mode or the second color mode, and the color modes corresponding to the first target correction data, the second target correction data, and the third target correction data are all the current color mode.

6. The method of claim 4, wherein, The current screen parameter further comprises a current color mode, the plurality of preset screen parameters correspond to a first color mode and a second color mode, the current color mode is the first color mode or the second color mode, and the color modes corresponding to the first candidate correction data and the second candidate correction data are all the current color mode.

7. The method of claim 4, wherein, The third preset luminance is less than the current backlight luminance and is the preset luminance closest to the current backlight luminance among the plurality of preset luminances, and the fourth preset luminance is greater than the current backlight luminance and is the preset luminance closest to the current backlight luminance among the plurality of preset luminances.

8. A method of generating correction data, characterized by, The method is applied to a second electronic device, and the method comprises: instructing a display screen of a first electronic device to display a plurality of color values under preset screen parameters, the plurality of color values comprising a first color value; obtaining color coordinates of each color value when the display screen displays the plurality of color values under the preset screen parameters; and The mapping relationship between the output color values of the display screen and the target color values under the preset screen parameter is established based on the color coordinates, and first correction data corresponding to the preset screen parameter is obtained, the first correction data being used for correcting the output color values of the display screen; the color coordinates of the output color values of the display screen after calibration are consistent with the color coordinates of the target color values under the preset screen parameter; Spectrum distribution data of the display screen when displaying a first color value under the preset screen parameter is obtained; Second target color values are obtained according to the spectrum distribution data; The first target color values corresponding to the first color value in the first correction data are replaced by the second target color values, and second correction data is obtained.

9. The method of claim 8, wherein, The mapping relationship between the output color values of the display screen and the target color values under the preset screen parameter is established based on the color coordinates, and first correction data corresponding to the preset screen parameter is obtained, the first correction data being used for correcting the output color values of the display screen; the color coordinates of the output color values of the display screen after calibration are consistent with the color coordinates of the target color values under the preset screen parameter; Each color coordinate in the color coordinates is converted into an output color value in a color gamut space corresponding to the display screen; Each color coordinate in the color coordinates is converted into a target color value in a color gamut space corresponding to the preset screen parameter; A one-to-one correspondence relationship between the output color values and the target color values is established, and the first correction data corresponding to the preset screen parameter is obtained.

10. An electronic device comprising, characterized by The electronic device comprises a memory, a display screen, and one or more processors; the memory, the display screen, and the processors are coupled; wherein the memory is used for storing computer program codes, the computer program codes comprising computer instructions; when the computer instructions are executed by the processors, the electronic device executes the method as claimed in any one of claims 1-7.

11. An electronic device comprising, characterized by The electronic device comprises a memory, and one or more processors; the memory and the processors are coupled; wherein the memory is used for storing computer program codes, the computer program codes comprising computer instructions; when the computer instructions are executed by the processors, the electronic device executes the method as claimed in claim 8 or 9.

12. A computer-readable storage medium, characterized in that, The computer instructions, when executed on an electronic device, cause the electronic device to execute the method as claimed in any one of claims 1-9.

13. A computer program product comprising computer programs / instructions, characterized in that, The computer program / instructions, when executed by a processor, implement the steps of the method as claimed in any one of claims 1-9.

Citation Information

Patent Citations

  • Display screen calibration method and related equipment

    CN116052568A