Display control method and device, electronic equipment and storage medium

By performing texture mapping conversion at the texture level, the problems of poor display effect and high memory consumption in the existing technology are solved, and high-precision display effect conversion and custom display adjustment are achieved.

CN120877677APending Publication Date: 2025-10-31GUANGZHOU XIBEISI INTELLIGENT TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410542466.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-04-30
Publication Date
2025-10-31

AI Technical Summary

Technical Problem

Existing technologies that use floating window overlays to switch display modes cannot achieve complex display adjustments, resulting in poor display quality. Furthermore, in high-security scenarios, this may lead to increased memory consumption and display distortion.

Method used

By obtaining the texture mapping set corresponding to the target effect mode, the initial texture values ​​of each pixel in the display page are extracted and texture mapping is performed. The display mode conversion is performed directly at the texture level, avoiding the use of overlay layers and improving conversion accuracy and display performance.

Benefits of technology

It enables effect transformation in complex display scenarios, improves display accuracy and performance, meets users' needs for customized display effects, and avoids memory consumption and security issues.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120877677A_ABST
    Figure CN120877677A_ABST
Patent Text Reader

Abstract

The invention provides a display control method and device, electronic equipment and a storage medium, a texture mapping set corresponding to a target effect mode is obtained by responding to a trigger operation for adjusting the display mode of a display page to the target effect mode, the texture mapping set is generated according to a color mapping set corresponding to the target effect mode, and the color mapping set corresponds to the target effect mode. The color mapping set comprises color mapping relation groups on a plurality of color components; extracting an initial texture value corresponding to each pixel in the display page, and performing texture mapping on each initial texture value according to the texture mapping set to obtain a target texture value corresponding to each pixel in the target effect mode; and rendering the target texture value corresponding to each pixel to obtain a target display page corresponding to the target effect mode, and displaying the target display page. A traditional display effect mode adjustment mode based on a layer superposition mode is abandoned, the target effect mode corresponding to the texture of each pixel is adjusted, the adjustment precision is ensured, and then the adjustment display precision of the effect mode is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of display technology, specifically to a display control method, device, electronic device, and storage medium. Background Technology

[0002] With the development of electronic devices, display modes have become increasingly diverse, such as eye-protection modes, night modes, or display modes corresponding to different filters. In related technologies, display effect switching generally employs a method of "overlaying a transparent floating window onto the top layer (this floating window is called an overlay layer)" to achieve color filtering and / or overlay. However, this method can only filter and attenuate some colors and / or overlay and enhance others; it cannot achieve complex display adjustments and thus reduces the overall display effect. Summary of the Invention

[0003] This application provides a display control method, device, electronic device, and storage medium, aiming to solve the problem of poor display effect caused by the conventional method of switching effect modes through floating window overlay.

[0004] In a first aspect, this application provides a display control method, comprising:

[0005] In response to a triggering operation that adjusts the display mode of the display page to the target effect mode, a texture mapping set corresponding to the target effect mode is obtained, wherein the texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components;

[0006] Extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode;

[0007] The target texture value corresponding to each pixel is rendered to obtain the target display page corresponding to the target effect mode and then displayed.

[0008] In one possible implementation of this application, the texture mapping set is generated based on the color mapping set corresponding to the target effect mode, including:

[0009] Obtain the color mapping set corresponding to the target effect mode;

[0010] A texture is created based on the texture size corresponding to the display page, and the texture is updated with data according to the color mapping set to obtain the texture mapping set.

[0011] In one possible implementation of this application, obtaining the color mapping set corresponding to the target effect mode includes:

[0012] Obtain the initial color mapping set corresponding to the target effect mode;

[0013] If the index value in the initial color mapping set includes at least three color components, then the first color component in the index value is sampled to obtain a first index sub-value, wherein the first color component is any one of the at least three color components;

[0014] For each first index sub-value, a color mapping subset corresponding to each first index sub-value is created based on the second index sub-value in the index values ​​including the first index sub-value and the output value corresponding to each index value, wherein the second index sub-value is the index sub-value corresponding to the other color components in the index values ​​other than the first index sub-value;

[0015] Each of the first index sub-values ​​and the color mapping subset corresponding to the first index sub-value are set as the color mapping set corresponding to the target effect mode.

[0016] By sampling the first color component to obtain the first index sub-value, performing dimensionality reduction processing, and creating a color mapping subset corresponding to each first index sub-value, the initial three-dimensional color mapping set is represented by a two-dimensional structure without affecting the lookup table function and the amount of color mapping information. This avoids the problems of more complex and memory-consuming three-dimensional data structures during application transmission, loading, and parsing, and when the shader program reads and parses textures.

[0017] In one possible implementation of this application, the step of creating a texture based on the texture size corresponding to the display page and updating the texture data according to the color mapping set to obtain a texture mapping set includes:

[0018] Based on the texture size corresponding to the display page, create a texture area with the same number of first index sub-values;

[0019] The binding relationship between the color mapping subset and the texture area is determined based on the size relationship between each of the first index sub-values ​​and the arrangement order between each texture area;

[0020] According to the preset binding function, the color mapping subset and the texture area with the binding relationship are data bound together to obtain the texture mapping set.

[0021] The texture map set includes multiple subsets of target color maps arranged sequentially according to the size of the first index sub-value to facilitate user preview.

[0022] In one possible implementation of this application, the step of extracting the initial texture value corresponding to each pixel in the display page and performing texture mapping on each of the initial texture values ​​according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode includes:

[0023] Create the association between the texture map set and the shader, and perform the following based on the shader:

[0024] Obtain the initial texture value corresponding to each pixel in the display page, and determine the texture mapping input based on the initial texture value;

[0025] The texture mapping set is searched based on the texture mapping input to obtain the target texture value corresponding to the texture mapping input.

[0026] In one possible implementation of this application, the shader includes a vertex shader unit and a fragment shader unit. The fragment shader unit includes a first variable and a second variable. The first variable is associated with an initial texture map set corresponding to the display page, and the second variable is associated with the texture map set.

[0027] The step of obtaining the initial texture value corresponding to each pixel in the display page and determining the texture mapping input based on the initial texture value includes:

[0028] Based on the vertex shading unit, the initial texture mapping input corresponding to each pixel in the display page is extracted, and the initial texture mapping input is sent to the fragment shading unit;

[0029] The fragment shader unit receives the initial texture map input, calls the first variable to perform a texture map lookup on the initial texture map set, obtains the initial texture value corresponding to the initial texture map input, and sets the initial texture value as the texture map input corresponding to the second variable.

[0030] In one possible implementation of this application, rendering the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode includes:

[0031] Based on the page size of the displayed page, create a frame buffer object area and bind the frame buffer object area to the display output interface;

[0032] Based on the position of each target texture value in the display page, the target texture value is rendered to the frame buffer object area to generate the target display page corresponding to the target effect mode;

[0033] The target display page is output and displayed based on the display output interface.

[0034] In one possible implementation of this application, the method further includes:

[0035] In response to a trigger operation that modifies the data corresponding to the target effect mode, obtain the color mapping set corresponding to the target effect mode;

[0036] The page is then adjusted based on the data generated from the color mapping set.

[0037] In response to a modification operation on the data adjustment page, obtain the modification parameters corresponding to the modification operation;

[0038] The color mapping set is updated according to the modified parameters.

[0039] Secondly, this application provides a display control device, the display control device comprising:

[0040] The response acquisition module is used to acquire the texture mapping set corresponding to the target effect mode in response to a trigger operation that adjusts the display mode of the display page to the target effect mode. The texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a color mapping relationship group on multiple color components.

[0041] The mapping module is used to extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode;

[0042] The output module is used to render the target texture value corresponding to each pixel, obtain the target display page corresponding to the target effect mode, and display it.

[0043] Thirdly, this application provides an electronic device, the electronic device comprising:

[0044] One or more processors;

[0045] Memory; and

[0046] One or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the processor to implement any of the display control methods described herein.

[0047] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, the computer program being loaded by a processor to perform the steps of any of the display control methods described herein.

[0048] This application provides a display control method, apparatus, electronic device, and storage medium. In response to a trigger operation that adjusts the display mode of a display page to a target effect mode, a texture mapping set corresponding to the target effect mode is obtained. This texture mapping set is generated based on a color mapping set corresponding to the target effect mode, and the color mapping set includes color mapping relationship groups on multiple color components. Initial texture values ​​corresponding to each pixel in the display page are extracted, and texture mapping is performed on each of the initial texture values ​​according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode. The target texture value corresponding to each pixel is then rendered to obtain and display the target display page corresponding to the target effect mode. This solution generates a corresponding texture mapping set based on the color mapping relationship corresponding to the target effect mode. Upon responding to the display mode adjustment of the display page, the texture mapping set corresponding to the target effect mode is directly obtained, and the texture information of the display page is mapped for each pixel to obtain the texture value corresponding to each pixel in the target effect mode. The target display page in the target effect mode is then re-rendered based on the texture value in the target effect mode. This approach performs target effect mode conversion at the texture level, improving conversion accuracy and meeting the effect conversion requirements of complex display scenarios, thereby improving display performance. Attached Figure Description

[0049] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0050] Figure 1 This is a schematic diagram of a conventional display adjustment implementation scheme provided in the embodiments of this application;

[0051] Figure 2 This is a schematic flowchart of an embodiment of the display control method provided in this application;

[0052] Figure 3 A schematic diagram of one embodiment of the 3D LUT effect file provided in this application;

[0053] Figure 4 A schematic diagram illustrating the stacking structure of page layers in one embodiment of the present application;

[0054] Figure 5 A flowchart illustrating one embodiment of the texture mapping set generation in the display control method provided in this application;

[0055] Figure 6A schematic diagram of the structure of the two-dimensional color effect image obtained by dimensionality reduction processing in dimension B in the display control method provided in the implementation scheme of this application;

[0056] Figure 7 A schematic flowchart of one embodiment of the color mapping set in the display control method provided in this application;

[0057] Figure 8 A schematic flowchart of one embodiment of texture mapping in the display control method provided in this application;

[0058] Figure 9 This is a schematic diagram of an embodiment of the display control device provided in this application.

[0059] Figure 10 This is a schematic diagram of an embodiment of the electronic device provided in this application. Detailed Implementation

[0060] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0061] In the description of this invention, it should be understood that the terms "center," "longitudinal," "lateral," "length," "width," "thickness," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientation or positional relationships based on the orientation or positional relationships shown in the accompanying drawings, are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include one or more of the stated features. In the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0062] In this embodiment, "and / or" describes the relationship between associated objects, indicating that three relationships can exist. For example, A and / or B can represent three cases: A alone, A and B simultaneously, and B alone. Additionally, the character " / ", unless otherwise specified, generally indicates that the preceding and following associated objects have an "or" relationship.

[0063] In this application, the term "exemplary" is used to mean "serving as an example, illustration, or description." Any embodiment described as "exemplary" in this application is not necessarily to be construed as being more preferred or advantageous than other embodiments. The following description is provided to enable any person skilled in the art to make and use the invention. Details are set forth in the following description for purposes of explanation. It should be understood that those skilled in the art will recognize that the invention can be made without using these specific details. In other instances, well-known structures and processes will not be described in detail to avoid obscuring the description of the invention with unnecessary detail. Therefore, the invention is not intended to be limited to the embodiments shown, but is consistent with the broadest scope of the principles and features disclosed in this application.

[0064] Understandably, with the advancement of electronic information technology and the widespread adoption of smartphones, Android applications are increasingly providing access to games, educational content, videos, work-related activities, and industrial applications. Visual experience is one of the most sensitive and important sensory inputs for humans, inextricably linked to screen display quality, software design, and color reproduction. Furthermore, due to individual differences, users have personalized preferences, and a single design is not universally accepted. Users expect to adjust the display effect like they would adjust a photograph. Features related to eye health, such as those designed to protect the eyes or simulate black and white text, are also included in display adjustments. Therefore, numerous display effect modes have emerged to allow users to customize the display experience.

[0065] See Figure 1 , Figure 1This is a schematic diagram of a conventional display adjustment implementation scheme provided in this application. Specifically, existing technical solutions generally use the method of "overlaying a transparent floating window on top (this floating window is called an overlay layer)" to achieve color filtering and / or overlay. However, this method can only filter and attenuate some colors and / or overlay and enhance some colors, but cannot perform color conversion, so it cannot achieve complex display adjustments. In addition, some scenarios with high security requirements, such as banking and financial apps (Applications), password and verification code input interfaces, often detect whether the device contains an overlay layer and refuse to use it when an overlay layer is present to prevent hackers from launching attacks, fraud, and information theft through the overlay layer. Furthermore, the overlay layer added by this method consumes additional memory. In addition, it is understandable that the current technical solution will sacrifice screen brightness to a certain extent, have poor display effect of low color levels, and may produce color deviation, etc. For example, 3. An overlay layer with color R'G'B' (R'G'B' value is not (0,0,0)) will have a color overlay function, and will have a color mixing and overlay effect on the color R1G1B1 below the overlay layer. However, the R1G1B1 values ​​of each pixel on the entire screen are superimposed with fixed-size R'G'B' values ​​to obtain the final displayed color value R2G2B2. This means that each pixel on the screen uses the same fixed values ​​for superposition and / or attenuation. However, if the color value R1G1B1 of a pixel is superimposed with each color component of R'G'B' separately, exceeding the bit depth, the resulting color value will be limited to the upper limit of the bit depth. This is equivalent to insufficient superposition of color values, potentially causing display distortion, loss of detail, and even affecting normal use.

[0066] Therefore, this application provides a display control method, device, electronic device, and computer-readable storage medium (hereinafter referred to as storage medium) that does not require overlay technology. It improves the conversion accuracy of the target effect mode and the display performance by performing texture mapping conversion through the texture level. It overcomes the disadvantages of high security requirements in App usage scenarios and additional memory occupation, while realizing the display adjustment function based on color conversion. This allows users to flexibly and customarily adjust the display effect of the Android terminal. The following are detailed descriptions of each.

[0067] The display control method in this embodiment of the invention is applied to a display control device, which is disposed in an electronic device. The electronic device is provided with one or more processors, a memory, and one or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the processor to implement the display control method. The electronic device can be a terminal, such as a mobile phone or a tablet computer. The electronic device can also be a server or a service cluster composed of multiple servers.

[0068] It is understood that the electronic devices in the scenario of the display control method, or the devices contained in the electronic devices, do not constitute a limitation on the embodiments of the present invention. That is, the number or type of devices in the scenario of the display control method, or the number or type of devices contained in each device, do not affect the overall implementation of the technical solution in the embodiments of the present invention, and can all be considered as equivalent substitutions or derivatives of the technical solutions claimed in the embodiments of the present invention.

[0069] In this embodiment of the invention, the electronic device is mainly used for: responding to a trigger operation that adjusts the display mode of a display page to a target effect mode, obtaining a texture mapping set corresponding to the target effect mode, wherein the texture mapping set is generated according to a color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components; extracting the initial texture value corresponding to each pixel in the display page, and performing texture mapping on each of the initial texture values ​​according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode; rendering the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode.

[0070] In this embodiment of the invention, the electronic device can be an independent electronic device, or it can be a network or cluster of electronic devices. For example, the electronic devices described in this embodiment include, but are not limited to, computers, network hosts, single network electronic devices, sets of multiple network electronic devices, or cloud electronic devices composed of multiple electronic devices. The cloud electronic device is composed of a large number of computers or network electronic devices based on cloud computing.

[0071] It is understood that the scenario of this display control method may also include one or more other electronic devices, which are not specifically limited here; the electronic device may also include a memory for storing data, such as storing information used by the display control method.

[0072] Furthermore, in the scenario of the display control method of this application, the electronic device may be equipped with a display device, or the electronic device may not have a display device but may communicate with an external display device. The display device is used to output the result of the execution of the display control method in the electronic device. The electronic device can access a background database (the background database may be in the local storage of the electronic device, or it may be located in the cloud), and the background database stores information related to display control.

[0073] The scenarios described in the embodiments of the present invention for display control methods are for the purpose of more clearly illustrating the technical solutions of the embodiments of the present invention, and do not constitute a limitation on the technical solutions provided in the embodiments of the present invention.

[0074] Based on the scenarios described above for display control methods, embodiments of the display control methods are proposed.

[0075] like Figure 2 The diagram shown is a flowchart of an embodiment of the display control method in this application. The display control method includes steps S201-S203:

[0076] S201. In response to the triggering operation of adjusting the display mode of the display page to the target effect mode, obtain the texture mapping set corresponding to the target effect mode.

[0077] The texture mapping set is generated based on the color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components.

[0078] The target effect mode may be an eye protection mode, a night mode, or a display mode corresponding to different color tones, etc. This application does not limit the specifics. It is understood that the names such as eye protection mode and night mode do not limit the target effect mode, but are only examples of names that exist in some scenarios to illustrate the target effect mode.

[0079] The color mapping set may be one-dimensional data including color mapping relationships of one color component, two-dimensional data including color mapping relationships of two color components, or three-dimensional data including color mapping relationships of three color components, etc.

[0080] For example, in some embodiments of this application, the color mapping set is stored as three-dimensional data in a 3D LUT effect file. The 3D LUT effect file is the actual carrier of the 3D LUT, and internally stores the mapping relationship data of the 3D LUT lookup table according to a certain format and structure. It should be noted that selecting or designing 3D LUTs with different structures and organization forms will result in different implementation methods for the application logic and shader program logic. The embodiment and corresponding 3D LUT structure proposed in this invention are not intended to limit the scope of the application. For specific details, please refer to... Figure 3 , Figure 3 This is a schematic diagram of one implementation scheme of the 3D LUT effect file provided in this application, wherein the coordinate axes of the three dimensions are represented by color components R, G, and B, respectively, with the unit being 1 unit of RGB color value, and the three dimensions correspond to the three color components.

[0081] It is understood that the LUT is a data lookup table, similar to a dictionary or map. It stores pre-set data and maps a value to an index. It uses external input as an index and looks up the value corresponding to the index by looking up the table, and outputs the result.

[0082] Furthermore, a 3D LUT is a type of LUT with three-dimensional input, i.e., a three-dimensional LUT. This can be understood as follows: an image generally includes color values ​​of three color components: R, G, and B. A 3D LUT includes mapping values / output values ​​corresponding to the color values ​​of each color component. An example is illustrated below:

[0083]

[0084] Specifically, in the implementation of this application, by creating a texture and uploading the color mapping set to the texture, a texture mapping set generated according to the color mapping set corresponding to the target effect mode is obtained. It can be understood that the texture mapping set can be a 3D texture, a 3D texture array, a 2D texture, or a 2D texture array, etc.

[0085] For example, in one embodiment of this application, the color mapping set is a three-dimensional 3D LUT data structure, that is, it includes a color mapping relationship group on three color components. When creating the texture mapping set, input sub-values ​​are sampled for the color value corresponding to any color component in the color mapping set, and corresponding two-dimensional lookup data is created for the input sub-value of that dimension. The input value in the two-dimensional lookup data is the input sub-value of other color components corresponding to the input sub-value, and the output value is the input sub-value of the other color components and the output color value corresponding to the input sub-value. A corresponding two-dimensional lookup data is created for each input sub-value, and the two-dimensional texture mapping set is formed based on the two-dimensional lookup data corresponding to the input sub-value.

[0086] It is understandable that if the color mapping set is a three-dimensional 3D LUT data structure, the transmission, loading, and parsing of the application, as well as the reading and parsing of textures by the shader program, are more complex and consume more memory. Therefore, in the embodiments of this application, the color mapping set is dimensionality reduced to reduce the amount of data and storage of the color mapping set and improve the data lookup rate.

[0087] It is understandable that the operation that triggers the adjustment of the display mode of the display page to the target effect mode is not specifically limited in this application.

[0088] For example, the operation of adjusting the display mode of the display page to the target effect mode is triggered by the user based on the display page displayed on the electronic device. Specifically, on the electronic device display page, the user clicks the display mode setting control corresponding to the display page to trigger the configuration of the display mode. At this time, the selectable effect modes can be displayed through a pop-up window. The user selects the target effect mode based on the pop-up window, then confirms the target effect mode and closes the pop-up window corresponding to the effect mode selection, thus completing the operation of triggering the adjustment of the display page's display mode to the target effect mode.

[0089] For example, in some other embodiments of this application, triggering the operation of adjusting the display mode of the display page to the target effect mode can also be an operation of starting up and displaying the display screen on an electronic device.

[0090] Specifically, in one embodiment of this application, the display control method is applied to an electronic device. The electronic device displays the display page, and in response to a triggering operation that adjusts the display mode of the display page to the target effect mode, it can capture the display page using a screenshot tool, or obtain the display page by performing layer fusion after obtaining the display layer, and access the storage address corresponding to the target effect mode to obtain the texture mapping set corresponding to the target effect mode.

[0091] In one embodiment of this application, the electronic device obtains a display page by acquiring display layers and performing layer fusion. It is understood that the display page comprises a stack of multiple interface layers. For example, see [link to relevant documentation]. Figure 4 , Figure 4This is a schematic diagram of the stacked structure of the display page layers in one embodiment of the present application. Specifically, the display page is a display page in the Android system. The labels 1, 2, 3, and 4 of the display layers on the display page represent the layers of the navigation bar, status bar, App interface, and quick operation floating window, respectively. It can be understood that there is a partial overlap between layer 4 and layer 3. When the screen displays the overlapping area, its color is the final color of the mixture of the colors of the layers above and below the overlapping area. In Android, a layer is the carrier of displayed content and the unit for compositing operations in SurfaceFlinger. It stores the display content of an application or floating window, participates in the SurfaceFlinger compositing process, and is then displayed on the display device. Essentially, Android's services composite the various display layers based on parameters such as Z-Order (a technique that compresses multi-dimensional data into one dimension, widely used in spatiotemporal indexing and image processing), transparency, size, and position. This composite is then passed to downstream processing to ultimately obtain the display page, which is then displayed on the display device. The downstream of SurfaceFlinger can be HWC or GPU (OpenGLES). HWC (hwcomposer) is the HAL layer module in Android for window (Layer) compositing and display. HWC is hardware compositing; it receives input layers and performs automatic hardware compositing on independent hardware, requiring and being unable to use software intervention. GPU compositing is performed by the GLESRenderEngine using the OpenGLES interface.

[0092] For example, in one embodiment of this application, each time the screen display refreshes (i.e., the display page refreshes), SurfaceFlinger traverses each display layer, obtains the visible layers, and decides to send the layers to HWC and / or GLESRenderEngine for compositing based on the layer type, size, compositing strategy, etc. After HWC and GLESRenderEngine complete their work, the compositing result is finally submitted through the Linux Framebuffer and ultimately displayed on the display device.

[0093] S202. Extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode.

[0094] Specifically, in the embodiments of this application, the color components include R dimension, G dimension and B dimension, and the dimension of the target color value is not limited in this application.

[0095] In one embodiment of this application, the texture mapping set includes a one-dimensional data lookup table corresponding to each color component. Then, by extracting the color value of the color component corresponding to each pixel in the display page, the one-dimensional data lookup table corresponding to the color component is searched to obtain the output color value corresponding to the color component. Similarly, the color value search of the three color components is completed to obtain the target color value of the three color components corresponding to each pixel.

[0096] In some other embodiments of this application, the texture mapping set is a texture created based on two-dimensional lookup data. For each pixel in the display page, texture sampling is performed using the vertex coordinates of each pixel to obtain the initial texture value corresponding to that pixel. Further, the initial texture value includes an R value, a G value, and a B value. If the two-dimensional lookup data is created based on sampling of the R value, then the target texture corresponding to the two-dimensional lookup data with the corresponding R value is determined based on the R value in the initial texture value. The target texture corresponding to the R value is found based on the G value and the B value, and the target texture value corresponding to the G value and the B value is obtained.

[0097] S203. Render the target texture value corresponding to each pixel to obtain the target display page corresponding to the target effect mode and display it.

[0098] Specifically, in the embodiments of this application, after obtaining the target color value corresponding to each pixel in the display page under the target effect mode, the electronic device further renders the display page according to the target color value corresponding to each pixel to obtain the target page under the target effect mode and displays it.

[0099] In this solution, the traditional layering process is abandoned to achieve display effect mode conversion, thereby improving the display accuracy of the target effect mode. Furthermore, texture mapping conversion is performed at the texture level to improve the conversion accuracy and display performance of the target effect mode.

[0100] Furthermore, in one embodiment of this application, a schematic flowchart of a target color value lookup implementation is also provided; for details, see [link to relevant documentation]. Figure 5 , Figure 5 A flowchart illustrating one embodiment of the texture mapping set generation in the display control method provided in this application is shown, specifically including steps S501-S502:

[0101] S501. Obtain the color mapping set corresponding to the target effect mode.

[0102] Specifically, in the embodiments of this application, the color mapping set can be obtained by accessing the corresponding preset storage address.

[0103] S502. Create a texture according to the texture size corresponding to the display page, and update the texture data according to the color mapping set to obtain the texture mapping set.

[0104] For example, the mainstream texture sizes are 256x256x256, 64x64x64, 32x32x32, 16x16x16, etc. In the implementation of this application, a texture with a size equal to or greater than the texture size corresponding to the display page is created to ensure texture lookup accuracy.

[0105] Specifically, in the implementation scheme, the CPU is invoked to activate the GPU to run the shader program and create a textureLUT. Furthermore, the binding operation is performed through the OpenGLES function glTexImage3D, that is, the contents of the aforementioned loaded 3DLUT effect file are uploaded to the textureLUT, so as to update the texture data according to the color mapping set, thereby obtaining the texture mapping set TextureLUT.

[0106] It is understood that generating a texture mapping set based on the color mapping set corresponding to the target effect mode can be triggered after a new target effect mode file is detected, or when the storage address of the texture mapping set corresponding to the target effect mode is detected to be empty. This application does not make any specific limitations on this.

[0107] This application can call the GPU to implement functions, and has stronger programmability, higher performance, and lower power consumption.

[0108] Furthermore, based on the above implementation scheme, this application also provides an implementation scheme for processing a color mapping set, specifically including the following steps:

[0109] (1) Obtain the initial color mapping set corresponding to the target effect mode;

[0110] (2) If the index value in the initial color mapping set includes at least three color components, then the first color component in the index value is sampled to obtain a first index sub-value, wherein the first color component is any one of the at least three color components;

[0111] (3) For each first index sub-value, create a color mapping subset corresponding to each first index sub-value based on the second index sub-value in the index value including the first index sub-value and the output value corresponding to each index value, wherein the second index sub-value is the index sub-value corresponding to other color components in the index value other than the first index sub-value;

[0112] (4) Set each of the first index sub-values ​​and the color mapping subsets corresponding to the first index sub-values ​​as the color mapping set corresponding to the target effect mode.

[0113] It is understood that the color mapping set is the data obtained by performing data dimensionality reduction processing on the initial color mapping set corresponding to the target effect mode. The texture mapping set also includes index values ​​and output values. The index value is the color value (representing the texture) corresponding to the color component, and the output value is the color value output in the target effect mode corresponding to the color value (representing the texture) of each color component.

[0114] Specifically, in the embodiments of this application, the color mapping subset is a two-dimensional color effect image. For example, the initial color mapping set is dimensionality-reduced by the B dimension; that is, the B values ​​in the initial color mapping set are sampled to obtain multiple different B values. Further, a corresponding two-dimensional color effect image is created for each B value. (See [reference needed]). Figure 6 , Figure 6 The diagram illustrates the structure of a two-dimensional color effect image obtained by dimensionality reduction in dimension B in the display control method provided in this application. Each B value corresponds to a two-dimensional color effect image, meaning that the B values ​​in a two-dimensional color effect image are equal. Specifically, the coordinate values ​​in the two-dimensional color effect image are R and G values. The points corresponding to the coordinates of the R and G values ​​store the R', G', and B' values ​​corresponding to the R, G, and B values ​​under the target effect mode. The two-dimensional color effect images corresponding to each B value form a color mapping set. Furthermore, in some other embodiments of this application, after creating a texture through a shader, each two-dimensional color effect image is bound to a different texture area to obtain a texture mapping set.

[0115] Furthermore, in application, for the first index sub-value of the first dimension corresponding to the pixel, the target two-dimensional color effect image to be searched is determined, that is, the target texture area in the texture mapping set is determined.

[0116] The second index sub-value is the index sub-value corresponding to other color components besides the first index sub-value. For example, if the first index sub-value is the B value, then the second index sub-value includes the R value and the G value.

[0117] For example, in one embodiment of this application, the two-dimensional color effect map is directly set as a texture mapping set. After determining the target color mapping subset, the two-dimensional color effect map corresponding to the B value is further searched according to the second index sub-value (i.e., R value and G value) corresponding to the pixel, and the R' value, G' value and B' value corresponding to the point corresponding to the R value and G value are obtained as the target color value.

[0118] Specifically, in the implementation scheme of this application, the initial color mapping set is the aforementioned three-dimensional 3D LUT data structure. This scheme reduces the dimensionality of the first index sub-value obtained by sampling the first color component and creates a color mapping subset corresponding to each first index sub-value. The 3D LUT is represented by a two-dimensional structure without affecting the lookup table function and the amount of color mapping information. This avoids the problem that the three-dimensional 3D LUT data structure is more complex and consumes more memory when the application transmits, loads, and parses the data, and when the shader program reads and parses the texture.

[0119] Furthermore, based on the above implementation scheme, this application also provides an implementation scheme for determining a texture mapping set, including the following steps:

[0120] (1) Create a texture area with the same number of first index sub-values ​​according to the texture size corresponding to the display page;

[0121] (2) Determine the binding relationship between the color mapping subset and the texture area based on the size relationship between each of the first index sub-values ​​and the arrangement order between each texture area;

[0122] (3) According to the preset binding function, the color mapping subset and the texture area with binding relationship are data bound to obtain the texture mapping set.

[0123] The preset binding function is the OpenGLES function glTexImage3D.

[0124] Specifically, in the implementation scheme of this application, by calling the CPU, the GPU is activated to run the shader program to create a TextureLUT, resulting in multiple texture regions. Each texture region can be arranged sequentially and its sequence number is determined, such as 1-2-3, etc. The first index sub-values ​​are sorted according to the size relationship between them, and the color mapping subset corresponding to the first index sub-value is bound to the texture region with sequence number 1. The content of the aforementioned color mapping subset is uploaded to the TextureLUT to obtain the TextureLUT.

[0125] For details, see Figure 7 , Figure 7 This is a flowchart illustrating one implementation of the color mapping set in the display control method provided in this application. Specifically, the texture mapping set includes multiple target color mapping subsets arranged sequentially according to the size of the first index sub-value, i.e., query effect diagrams. The target color value corresponding to each coordinate point in each query effect diagram is displayed in color so that the user can preview it.

[0126] Furthermore, based on any of the above embodiments, this application also provides a specific embodiment for texture mapping. In this embodiment, the mapping lookup is implemented based on shaders. Specifically, after creating a texture mapping set based on the shader, an association is created between the texture mapping set and the shader. That is, the texture mapping set is associated with the position LocLUT of the uniform variable lutTexture of type sampler2DArray in the shader. Further, texture mapping is performed based on the shader. For details, see [link to relevant documentation]. Figure 8 , Figure 8 A flowchart illustrating one embodiment of the texture mapping in the display control method provided in this application is shown, specifically including steps S801-S802:

[0127] S801. Obtain the initial texture value corresponding to each pixel in the display page, and determine the texture mapping input based on the initial texture value;

[0128] Specifically, in the embodiments of this application, the shader includes a vertex shader unit and a fragment shader unit. The fragment shader unit includes a first variable and a second variable. The first variable is associated with the initial texture map set corresponding to the display page. The first variable is the position (LocU) of a uniform variable uTexture of type sampler2D defined within the shader. The position (LocU) is associated with the initial texture map set of the display page. Specifically:

[0129] Based on the vertex shading unit, the initial texture mapping input corresponding to each pixel in the display page is extracted, and the initial texture mapping input is sent to the fragment shading unit;

[0130] Specifically, the initial texture mapping output is the vertex coordinates corresponding to the display page and pixels. After being obtained by the vertex shader, the vertex coordinates are sent to the fragment shader unit as the initial texture mapping input.

[0131] Specifically, this application does not impose specific limitations on the generation of the initial texture mapping set. For example, in some embodiments of this application, the generation of the initial texture mapping set includes: setting the composition mode of all layers to "Client Composition"; in conjunction with the above description, setting it to this composition mode means that the layers are handed over to GLESRenderEngine to call the GPU through OpenGLES to perform composition; further, creating a FrameBufferObject (FBO) FBO0; wherein, the creation of FBO can be implemented through the glGenFramebuffers function of the OpenGLES interface; further, generating a texture through the OpenGLES interface, initializing the texture, and attaching it to FBO0 in the form of color attachment (GL_COLOR_ATTACHMENT0), that is, obtaining the initial texture mapping set corresponding to the display page; wherein, the texture is initialized to a size consistent with the width and height of the display screen and filled with empty data; it can be understood that this operation will allocate memory space for FBO0 to match the size requirements of the display screen.

[0132] S802. Search the texture mapping set according to the texture mapping input to obtain the target texture value corresponding to the texture mapping input.

[0133] Furthermore, the fragment shader unit receives the initial texture map input, calls the first variable to perform a texture map lookup on the initial texture map set, obtains the initial texture value corresponding to the initial texture map input, and sets the initial texture value as the texture map input corresponding to the second variable.

[0134] Specifically, after receiving the initial texture mapping input, the fragment shader unit calls the first scalar, that is, it searches the first variable according to the initial texture mapping input to obtain the corresponding initial texture value. Further, it calls the second variable, that is, it searches the second variable according to the initial texture value to obtain the target texture value corresponding to the texture mapping input.

[0135] Furthermore, this application also provides a schematic flowchart of one embodiment for generating a target display page, specifically including the following steps:

[0136] (1) Create a frame buffer object area according to the page size of the display page, and bind the frame buffer object area to the display output interface.

[0137] It's understandable that an FBO (Framebuffer Object) is a buffer created through the OpenGLES interface. It can serve as the target canvas for OpenGLES rendering and store the rendering results. In other words, the rendering output from OpenGLES calls the GPU and is stored in the FBO. Specifically, the FBO is recreated using the OpenGLES interface function `glGenFramebuffers`, designated as FBO1. Further, FBO1 is bound to and enabled by the OpenGLES interface function `glBlitFramebuffer()` (the display output interface). This means that the content of the FBO is copied into a Framebuffer, which is an object in Android's original drawing process, and its stored content will be displayed on the display device. In short, if the content of the FBO is copied into the Framebuffer, the content of the FBO will be displayed on the display device.

[0138] (2) According to the position of each target texture value in the display page, render the target texture value to the frame buffer object area to generate the target display page corresponding to the target effect mode;

[0139] Furthermore, after the target texture value is found in the fragment shading unit, the target texture value is output to the GPU. At the same time, the OpenGLES drawing function is called to perform the rendering task on the GPU side, and the rendering result is stored in the newly created FBO.

[0140] (3) Output and display the target display page based on the display output interface.

[0141] Furthermore, after the target display page is copied to the Framebuffer based on the display output interface, it will be refreshed and displayed on the display device to achieve the display mode switching corresponding to the target effect mode.

[0142] Furthermore, in other embodiments of this application, an implementation scheme for adjusting the color mapping set corresponding to the target effect mode is also provided, specifically including the following steps:

[0143] (1) In response to a trigger operation that modifies the data corresponding to the target effect mode, obtain the color mapping set corresponding to the target effect mode;

[0144] (2) Adjust the page by generating data based on the color mapping set;

[0145] (3) In response to the modification operation on the data adjustment page, obtain the modification parameters corresponding to the modification operation;

[0146] (4) Update the color mapping set according to the modified parameters.

[0147] Specifically, in one embodiment of this application, a user can trigger modification of the data corresponding to a target effect mode based on adjustment controls on the display page or a specified gesture (double-tap, swipe, etc.) applied to the display page. After receiving the trigger operation, the electronic device further responds to the trigger operation of modifying the data corresponding to the target effect mode by obtaining the data adjustment page corresponding to the target effect mode. For example, the data adjustment page may include color component adjustment areas corresponding to R, G, and B values. Further, modification parameters are input based on the color component adjustment areas, and further, each color component corresponding to the color mapping set is updated according to the modification parameters.

[0148] It is understood that the data adjustment page may also include a color preview area, which can display... Figure 7 The page shown allows users to intuitively experience color changes by adjusting the page based on data.

[0149] Specifically, based on the above implementation scheme, this application provides a complete implementation scheme for a display control method, specifically:

[0150] (1) When the function switch is off, this function will not be started, will not operate or process the screen display, and will not produce the effects of display adjustment and color management.

[0151] (2) Preferably, the switch state of the storage function switch is used by default when the device is restarted or shut down and then started again.

[0152] Furthermore, after the function switch is turned on (i.e., the display mode of the display page is adjusted to the target effect mode), it checks whether the preset shader has been compiled; if the shader has not been compiled, it calls the standard interface provided by OpenGLES to compile it; the compiled shader program is stored as Gp.

[0153] The compilation principles and processes of shaders are well-known. Used to illustrate this patent, but not to limit it, the Gp compilation process links a pre-built vertex shader and a pre-built fragment shader.

[0154] The fragment shader contains two uniform variables, one of the key features of this technology, and its shader programming language definition is as follows:

[0155] (1) As those skilled in the relevant professional field know, the above defines two unified variables of type sampler2D(variable name uTexture) and sampler2DArray(variable name lutTexture) in the fragment shader;

[0156] (2) The key implementation point of this solution is the two specific types of unified variables mentioned above. The variable names of the unified variables are not limited, but are only used to illustrate this patent.

[0157] Furthermore, after the shader is compiled, the uniform locations of the two variables uTexture and lutTexture are obtained and stored as LocU and LocLUT respectively.

[0158] (1) As is well known, the uniform location of a variable can be obtained by calling the function getUniformLocation();

[0159] In response to the 3D LUT selection operation, determine the 3D LUT effect file used to implement color correction; for illustrative purposes only and not limiting, the order of compiling the preset shaders and obtaining uTexture and lutTexture can be interchanged with this step in the workflow and is not limited.

[0160] (1) The 3D LUT effect file can be empty, which means that no effect is applied, and the screen is operated and processed without display adjustment and color management effects.

[0161] (2) Among them, the 3D LUT effect file can be obtained from various means such as manufacturer preset, user customization, or Internet download, and imported into the device;

[0162] (3) Preferably, the currently selected 3D LUT effect file is stored, and the 3D LUT effect file is used by default when the device is restarted or shut down and then started again.

[0163] Furthermore, the 3D LUT effect file is parsed and read, the file content is stored in a memory buffer, and the memory address value of the buffer is stored in pointer P;

[0164] During the SurfaceFlinger composition stage, when the function switch is on and the selected 3D LUT effect file is not empty, set all layers to "Client Composition";

[0165] (1) In conjunction with the aforementioned background technology, as is well known, the compositing of Layer can be achieved by either HWC compositing or GPU compositing. Setting it to "Client Composition" means that the compositing is performed by GLESRenderEngine through GPU compositing.

[0166] During the compositing stage of GLESRenderEngine (drawLayers() function), when the function switch is turned on and the selected 3D LUT effect file is not empty, an FBO is created and stored as FBO0;

[0167] Further, bind and enable FBO0;

[0168] Further, the composition of each layer is performed, and each layer is rendered into FBO0;

[0169] (1) As is well known, after the synthesis step, the above layers will be synthesized and superimposed into the FBO0;

[0170] Further, activate Gp; shader program

[0171] Further, a TextureLUT of type GL_TEXTURE_2D_ARRAY is created; the CPU is invoked, the GPU is activated to run the shader program to create the texture, look up the table, and the conversion process is handled by the GPU conversion logic, using the original image.

[0172] Furthermore, the memory pointed to by pointer P is bound to TextureLUT and initialized;

[0173] (1) As is well known, binding operations can be achieved using the OpenGLES function glTexImage3D, which uploads the contents of the aforementioned loaded 3D LUT effect file to the TextureLUT; effect image

[0174] Furthermore, the TextureLUT is associated with the unified variable LocLUT; the effect file accesses the effect image through the unified variable;

[0175] (1) As is well known, this operation can be achieved by calling OpenGLES functions;

[0176] Furthermore, FBO0 (initial creation object, original graph) is associated with the unified variable LocU;

[0177] Further, create an FBO and record it as FBO1 (mapping diagram);

[0178] Further, bind and enable FBO1;

[0179] Furthermore, the OpenGLES drawing function is called, triggering the drawing process and color mapping logic;

[0180] Understandably, since Gp was previously activated, OpenGLES will use the shaders corresponding to Gp (i.e., the preset vertex shaders and fragment shaders in this method) for rendering, and will call the preset vertex shaders and fragment shaders.

[0181] The key execution flow of the fragment shader is as follows;

[0182] (1) Access FBO0 via LocU and extract the RGBU color of each pixel; extract the original image color.

[0183] (2) Wherein, those skilled in the relevant professional fields can understand that RGBU is the color of the image originally displayed on the screen;

[0184] (3) Further, access TextureLUT through LocLUT, take RGBU as input, and find and calculate the color RGBU' corresponding to the mapped RGBU;

[0185] (4) Further, RGBU' is used as the fragment shader color output;

[0186] (5) Those in relevant professional fields can understand that the color output of the fragment shader is the result of this OpenGLES rendering; in conjunction with the aforementioned binding of FBO1, this is a technical principle explanation rather than a limitation. At this time, FBO0 stores the original screen display (without color conversion), and FBO1 stores the new screen after conversion according to the search rules of the input 3D LUT effect file (the color conversion is completed).

[0187] Furthermore, bind the original drawing target FrameBuffer of GLESRenderEngine;

[0188] The FrameBuffer is provided by the existing process in the Android system, and its contents will be displayed on the screen.

[0189] Furthermore, bind FBO1 in read-only mode (call the function glBindFramebuffer(GL_READ_FRAMEBUFFER,FBO1));

[0190] Further, the contents of FBO1 are copied to the aforementioned drawing target FrameBuffer;

[0191] (1) As is well known, this step can be achieved by calling the OpenGLES function glBlitFramebuffer();

[0192] Understandably, this operation copies the color-converted image stored in FBO1 to the drawing target FrameBuffer of the original Android process. Furthermore, after the original process is completed, the contents of the FrameBuffer will be displayed on the device screen, thus achieving the goal of color conversion and display adjustment, and presenting a new image on the screen.

[0193] This application provides a display control method that reduces the data volume and storage requirements of the texture mapping set by performing data dimensionality reduction on the color mapping set corresponding to the target effect mode, thereby ensuring query speed. Furthermore, this application eliminates the need for overlay technology, overcoming the drawbacks of security-critical App usage scenarios and excessive memory usage, while simultaneously implementing color-conversion-based display adjustment functionality. This allows users to flexibly and customarily adjust the display effects of the Android terminal. Additionally, it performs texture lookup for the color values ​​corresponding to each color component for each pixel in the display page, ensuring adjustment accuracy and thus improving the display accuracy and performance of the effect mode adjustment.

[0194] To better implement the display control method in the embodiments of this application, a display control device is also provided in the embodiments of this application, such as... Figure 9 As shown, the display control device includes modules 901-903:

[0195] The response acquisition module 901 is used to acquire the texture mapping set corresponding to the target effect mode in response to a trigger operation that adjusts the display mode of the display page to the target effect mode. The texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a color mapping relationship group on multiple color components.

[0196] The mapping module 902 is used to extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode;

[0197] The output module 903 is used to render the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode.

[0198] In this solution, the traditional layering process is abandoned to achieve display effect mode conversion, thereby improving the display accuracy of the target effect mode. Furthermore, texture mapping conversion is performed at the texture level to improve the conversion accuracy and display performance of the target effect mode.

[0199] In one embodiment of this application, the response acquisition module 901 is further configured to generate a texture mapping set based on the color mapping set corresponding to the target effect mode, specifically including:

[0200] Obtain the color mapping set corresponding to the target effect mode;

[0201] A texture is created based on the texture size corresponding to the display page, and the texture is updated with data according to the color mapping set to obtain the texture mapping set.

[0202] In some embodiments of this application, the response acquisition module 901 is configured to acquire a color mapping set corresponding to the target effect mode, including methods for:

[0203] Obtain the initial color mapping set corresponding to the target effect mode;

[0204] If the index value in the initial color mapping set includes at least three color components, then the first color component in the index value is sampled to obtain a first index sub-value, wherein the first color component is any one of the at least three color components;

[0205] For each first index sub-value, a color mapping subset corresponding to each first index sub-value is created based on the second index sub-value in the index values ​​including the first index sub-value and the output value corresponding to each index value, wherein the second index sub-value is the index sub-value corresponding to the other color components in the index values ​​other than the first index sub-value;

[0206] Each of the first index sub-values ​​and the color mapping subset corresponding to the first index sub-value are set as the color mapping set corresponding to the target effect mode.

[0207] In this embodiment of the application, the initial color mapping set is the aforementioned three-dimensional 3D LUT data structure. This solution reduces the dimensionality of the first index sub-value obtained by sampling the first color component and creates a color mapping subset corresponding to each first index sub-value. This allows the 3D LUT to be represented by a two-dimensional structure without affecting the lookup table function and the amount of color mapping information. This avoids the problem that the three-dimensional 3D LUT data structure is more complex and consumes more memory when the application transmits, loads, and parses the data, and when the shader program reads and parses the texture.

[0208] In some embodiments of this application, the response acquisition module 901 is configured to create a texture according to the texture size corresponding to the display page, and update the texture data according to the color mapping set to obtain a texture mapping set, including:

[0209] Based on the texture size corresponding to the display page, create a texture area with the same number of first index sub-values;

[0210] The binding relationship between the color mapping subset and the texture area is determined based on the size relationship between each of the first index sub-values ​​and the arrangement order between each texture area;

[0211] According to the preset binding function, the color mapping subset and the texture area with the binding relationship are data bound together to obtain the texture mapping set.

[0212] In some embodiments of this application, the mapping module 902 is configured to extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each of the initial texture values ​​according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode, including:

[0213] Create the association between the texture map set and the shader, and perform the following based on the shader:

[0214] Obtain the initial texture value corresponding to each pixel in the display page, and determine the texture mapping input based on the initial texture value;

[0215] The texture mapping set is searched based on the texture mapping input to obtain the target texture value corresponding to the texture mapping input.

[0216] In some embodiments of this application, the shader includes a vertex shader unit and a fragment shader unit, the fragment shader unit including a first variable and a second variable, the first variable being associated with an initial texture map set corresponding to the display page, and the second variable being associated with the texture map set;

[0217] The mapping module 902 is used to obtain the initial texture value corresponding to each pixel in the display page, and determine the texture mapping input based on the initial texture value, including:

[0218] Based on the vertex shading unit, the initial texture mapping input corresponding to each pixel in the display page is extracted, and the initial texture mapping input is sent to the fragment shading unit;

[0219] The fragment shader unit receives the initial texture map input, calls the first variable to perform a texture map lookup on the initial texture map set, obtains the initial texture value corresponding to the initial texture map input, and sets the initial texture value as the texture map input corresponding to the second variable.

[0220] In some embodiments of this application, the output module 903 is configured to render the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode, including:

[0221] Based on the page size of the displayed page, create a frame buffer object area and bind the frame buffer object area to the display output interface;

[0222] Based on the position of each target texture value in the display page, the target texture value is rendered to the frame buffer object area to generate the target display page corresponding to the target effect mode;

[0223] The target display page is output and displayed based on the display output interface.

[0224] In some embodiments of this application, a modification module is also included for:

[0225] In response to a trigger operation that modifies the data corresponding to the target effect mode, obtain the color mapping set corresponding to the target effect mode;

[0226] The page is then adjusted based on the data generated from the color mapping set.

[0227] In response to a modification operation on the data adjustment page, obtain the modification parameters corresponding to the modification operation;

[0228] The color mapping set is updated according to the modified parameters.

[0229] This application provides a display control device, which includes a response acquisition module for acquiring a texture mapping set corresponding to the target effect mode in response to a trigger operation that adjusts the display mode of a display page to a target effect mode. The texture mapping set is generated based on a color mapping set corresponding to the target effect mode, and the color mapping set includes multiple color mapping relationship groups on color components. A mapping module is used to extract the initial texture value corresponding to each pixel in the display page and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value of each pixel corresponding to the target effect mode. An output module is used to render the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode. This solution generates a corresponding texture mapping set based on the color mapping relationship of the target effect mode. When the display mode of the response display page is adjusted, the texture mapping set corresponding to the target effect mode is directly obtained, and the texture information of the display page is mapped for each pixel to obtain the texture value corresponding to each pixel in the target effect mode. The target display page in the target effect mode is then re-rendered based on the texture value in the target effect mode. The target effect mode conversion is performed at the texture level, which improves the conversion accuracy and can meet the effect conversion of complex display scenarios, thereby improving display performance.

[0230] Based on the above implementation scheme, this invention also provides an electronic device, such as... Figure 10 As shown, Figure 10 This is a schematic diagram of an embodiment of the electronic device provided in this application.

[0231] Electronic devices include:

[0232] One or more processors, wherein the processors include a central processing unit and / or a graphics processing unit;

[0233] Memory; and

[0234] One or more applications, wherein the applications are stored in memory and configured to be executed by a processor from the steps of the display control method in any of the above embodiments of the display control method.

[0235] Specifically, an electronic device may include components such as a processor 1001 with one or more processing cores, a memory 1002 with one or more computer-readable storage media, a power supply 1003, and an input unit 1004. Those skilled in the art will understand that... Figure 10 The electronic device structure shown does not constitute a limitation on the electronic device and may include more or fewer components than shown, or combine certain components, or have different component arrangements. Wherein:

[0236] The processor 1001 is the control center of the display, connecting various parts of the electronic device through various interfaces and lines. It executes software programs and / or modules stored in the memory 1002, and calls data stored in the memory 1002, to perform various functions and process data, thereby providing overall monitoring of the electronic device. It is understood that the processor 1001 communicates with the controller via signal transmission. Optionally, the processor 1001 may include one or more processing cores; preferably, the processor 1001 may integrate an application processor and a modem processor, wherein the application processor mainly handles the operating system, user interface, and applications, while the modem processor mainly handles wireless communication. It is understood that the modem processor may also not be integrated into the processor 1001.

[0237] The memory 1002 can be used to store software programs and modules. The processor 1001 executes various functional applications and data processing by running the software programs and modules stored in the memory 1002. The memory 1002 may mainly include a program storage area and a data storage area. The program storage area may store the operating system, application programs required for at least one function (such as sound playback function, image playback function, etc.), etc.; the data storage area may store data created according to the use of the electronic device, etc. In addition, the memory 1002 may include high-speed random access memory, and may also include non-volatile memory, such as at least one disk storage device, flash memory device, or other volatile solid-state storage device. Accordingly, the memory 1002 may also include a memory controller to provide the processor 1001 with access to the memory 1002.

[0238] In some embodiments of this application, the display control device can be implemented as a computer program, and the computer program can be implemented as follows: Figure 10 The device operates on the electronic device shown. The memory of the electronic device can store the various program modules that make up the display control method apparatus, for example, Figure 9 The diagram shows a response acquisition module 901, a mapping module 902, and an output module 903. The computer program comprised of these modules causes the processor to execute the steps of the display control methods in the various embodiments of this application described in this specification.

[0239] For example, Figure 10 The electronic device shown can be used as follows Figure 9The response acquisition module 901 in the illustrated display control method apparatus executes step S201. The electronic device can execute step S202 via the mapping module 902. The electronic device can execute step S202 via the output module 903. The electronic device includes a processor, memory, and a network interface connected via a system bus. The processor of the electronic device provides computing and control capabilities. The memory of the electronic device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The network interface of the electronic device is used to communicate with external electronic devices via a network connection. When the computer program is executed by the processor, it implements a display control method.

[0240] The electronic device also includes a power supply 1003 that supplies power to various components. Preferably, the power supply 1003 can be logically connected to the processor 1001 through a power management system, thereby enabling functions such as charging, discharging, and power consumption management through the power management system. The power supply 1003 may also include one or more DC or AC power supplies, recharging systems, power fault detection circuits, power converters or inverters, power status indicators, and other arbitrary components.

[0241] The electronic device may also include an input unit 1004, which can be used to receive input digital or character information, and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function control.

[0242] Although not shown, the electronic device may also include a display unit, etc., which will not be described in detail here. Specifically, in this embodiment, the processor 1001 in the electronic device loads the executable files corresponding to the processes of one or more applications into the memory 1002 according to the following instructions, and the processor 1001 runs the applications stored in the memory 1002 to realize various functions, as follows:

[0243] In response to a triggering operation that adjusts the display mode of the display page to the target effect mode, a texture mapping set corresponding to the target effect mode is obtained, wherein the texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components;

[0244] Extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode;

[0245] The target texture value corresponding to each pixel is rendered to obtain the target display page corresponding to the target effect mode and then displayed.

[0246] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be performed by instructions, or by instructions controlling related hardware. These instructions can be stored in a computer-readable storage medium and loaded and executed by a processor.

[0247] Therefore, embodiments of the present invention provide a computer-readable storage medium (hereinafter referred to as the storage medium), which may include: read-only memory (ROM), random access memory (RAM), magnetic disk or optical disk, etc. A computer program is stored thereon, and the computer program is loaded by a processor to execute the steps in any of the display control methods provided in the embodiments of the present invention. For example, the computer program loaded by the processor can execute the following steps:

[0248] In response to a triggering operation that adjusts the display mode of the display page to the target effect mode, a texture mapping set corresponding to the target effect mode is obtained, wherein the texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components;

[0249] Extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode;

[0250] The target texture value corresponding to each pixel is rendered to obtain the target display page corresponding to the target effect mode and then displayed.

[0251] In the above embodiments, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the detailed descriptions of other embodiments above, which will not be repeated here.

[0252] In practice, each of the above units or structures can be implemented as an independent entity or can be arbitrarily combined to be implemented as the same or several entities. For the specific implementation of each of the above units or structures, please refer to the previous method embodiments, which will not be repeated here.

[0253] For details on the implementation of each of the above operations, please refer to the previous examples, which will not be repeated here.

[0254] The above provides a detailed description of a display control method, apparatus, electronic device, and storage medium provided in the embodiments of this application. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A display control method, characterized in that, include: In response to a triggering operation that adjusts the display mode of the display page to the target effect mode, a texture mapping set corresponding to the target effect mode is obtained, wherein the texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a group of color mapping relationships on multiple color components; Extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode; The target texture value corresponding to each pixel is rendered to obtain the target display page corresponding to the target effect mode and then displayed.

2. The display control method according to claim 1, characterized in that, The texture mapping set is generated based on the color mapping set corresponding to the target effect mode, including: Obtain the color mapping set corresponding to the target effect mode; A texture is created based on the texture size corresponding to the display page, and the texture is updated with data according to the color mapping set to obtain the texture mapping set.

3. The display control method according to claim 2, characterized in that, The step of obtaining the color mapping set corresponding to the target effect mode includes: Obtain the initial color mapping set corresponding to the target effect mode; If the index value in the initial color mapping set includes at least three color components, then the first color component in the index value is sampled to obtain a first index sub-value, wherein the first color component is any one of the at least three color components; For each first index sub-value, a color mapping subset corresponding to each first index sub-value is created based on the second index sub-value in the index values ​​including the first index sub-value and the output value corresponding to each index value, wherein the second index sub-value is the index sub-value corresponding to the other color components in the index values ​​other than the first index sub-value; Each of the first index sub-values ​​and the color mapping subset corresponding to the first index sub-value are set as the color mapping set corresponding to the target effect mode.

4. The display control method according to claim 3, characterized in that, The step of creating a texture based on the texture size corresponding to the display page and updating the texture data according to the color mapping set to obtain a texture mapping set includes: Based on the texture size corresponding to the display page, create a texture area with the same number of first index sub-values; The binding relationship between the color mapping subset and the texture area is determined based on the size relationship between each of the first index sub-values ​​and the arrangement order between each texture area; According to the preset binding function, the color mapping subset and the texture area with the binding relationship are data bound together to obtain the texture mapping set.

5. The display control method according to claim 1, characterized in that, The step of extracting the initial texture value corresponding to each pixel in the display page, and performing texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode, includes: Create the association between the texture map set and the shader, and perform the following based on the shader: Obtain the initial texture value corresponding to each pixel in the display page, and determine the texture mapping input based on the initial texture value; The texture mapping set is searched based on the texture mapping input to obtain the target texture value corresponding to the texture mapping input.

6. The display control method according to claim 5, characterized in that, The shader includes a vertex shader unit and a fragment shader unit. The fragment shader unit includes a first variable and a second variable. The first variable is associated with the initial texture map set corresponding to the display page, and the second variable is associated with the texture map set. The step of obtaining the initial texture value corresponding to each pixel in the display page and determining the texture mapping input based on the initial texture value includes: Based on the vertex shading unit, the initial texture mapping input corresponding to each pixel in the display page is extracted, and the initial texture mapping input is sent to the fragment shading unit; The fragment shader unit receives the initial texture map input, calls the first variable to perform a texture map lookup on the initial texture map set, obtains the initial texture value corresponding to the initial texture map input, and sets the initial texture value as the texture map input corresponding to the second variable.

7. The display control method according to claim 1, characterized in that, The step of rendering the target texture value corresponding to each pixel to obtain and display the target display page corresponding to the target effect mode includes: Based on the page size of the displayed page, create a frame buffer object area and bind the frame buffer object area to the display output interface; Based on the position of each target texture value in the display page, the target texture value is rendered to the frame buffer object area to generate the target display page corresponding to the target effect mode; The target display page is output and displayed based on the display output interface.

8. The display control method according to any one of claims 1-7, characterized in that, The method further includes: In response to a trigger operation that modifies the data corresponding to the target effect mode, obtain the color mapping set corresponding to the target effect mode; The page is then adjusted based on the data generated from the color mapping set. In response to a modification operation on the data adjustment page, obtain the modification parameters corresponding to the modification operation; The color mapping set is updated according to the modified parameters.

9. A display control device, characterized in that, The display control device includes: The response acquisition module is used to acquire the texture mapping set corresponding to the target effect mode in response to a trigger operation that adjusts the display mode of the display page to the target effect mode. The texture mapping set is generated according to the color mapping set corresponding to the target effect mode, and the color mapping set includes a color mapping relationship group on multiple color components. The mapping module is used to extract the initial texture value corresponding to each pixel in the display page, and perform texture mapping on each initial texture value according to the texture mapping set to obtain the target texture value corresponding to each pixel in the target effect mode; The output module is used to render the target texture value corresponding to each pixel, obtain the target display page corresponding to the target effect mode, and display it.

10. An electronic device, characterized in that, The electronic device includes: One or more processors; Memory; and One or more applications, wherein the one or more applications are stored in the memory and configured to be executed by the processor to implement the display control method of any one of claims 1 to 8.

11. A computer-readable storage medium, characterized in that, It stores a computer program, which is loaded by a processor to perform the steps of the display control method according to any one of claims 1 to 8.