Window image display method and device, terminal equipment and storage medium

By generating target layers and cache queues and managing the graphics cache, the memory consumption problem caused by high-pixel image display in the Android system is solved, and the display smoothness of terminal devices is improved.

CN115761028BActive Publication Date: 2026-07-24BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
BEIJING XIAOMI MOBILE SOFTWARE CO LTD
Filing Date
2022-11-18
Publication Date
2026-07-24

AI Technical Summary

Technical Problem

When displaying high-resolution images, the Android system consumes a large amount of memory in the graphics buffer, causing the device to lag and reducing the user experience.

Method used

By setting the scaling parameter to a positive number less than 1, target layers and buffer queues are generated, the graphics buffer is managed, and image drawing, rendering, and compositing are performed, thereby reducing the size of the graphics buffer.

Benefits of technology

It reduces the size of the graphics buffer required to display images, thereby reducing memory usage and improving the smoothness of display on terminal devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115761028B_ABST
    Figure CN115761028B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a window image display method and device, a terminal device and a storage medium, wherein the method comprises: determining a first application requiring to display an image; determining a scaling parameter; generating a first target layer of the first application and a buffer area queue corresponding to the first target layer according to the scaling parameter; performing drawing rendering on a to-be-rendered image according to the first target layer and the buffer area queue to store the graphic data of the to-be-rendered image drawn by the first target layer to a graphic buffer area; synthesizing the to-be-rendered image in the graphic buffer area, and displaying the synthesized image on a screen of the terminal device. The technical solution of the present disclosure reduces the size of the graphic buffer area required for displaying the image, thereby reducing the memory occupation and improving the display fluency of the terminal device.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure relates to the field of image technology, and in particular to a window image display method, apparatus, terminal device and storage medium. Background Technology

[0002] When displaying images, the Android system uses a graphics buffer, and the size of the graphics buffer affects system memory usage. When the image to be displayed has a high pixel count, the graphics buffer will also be larger, leading to higher memory usage, which in turn causes device display lag and reduces the user experience. Summary of the Invention

[0003] To overcome the problems existing in related technologies, this disclosure provides a window image display method, apparatus, terminal device and storage medium.

[0004] According to a first aspect of the present disclosure, a window image display method is provided, comprising: determining a first application that needs to display an image; determining a scaling parameter; wherein the value of the scaling parameter is a positive number less than 1; generating a first target layer of the first application and a cache queue corresponding to the first target layer according to the scaling parameter; wherein the first target layer is used to draw an image to be rendered by the first application, and the cache queue is used to manage a graphics cache of the first application; drawing and rendering the image to be rendered according to the first target layer and the cache queue, so as to store the graphics data of the image to be rendered drawn by the first target layer in the graphics cache; compositing the image to be rendered in the graphics cache, and displaying the composite image on a terminal device screen.

[0005] In one implementation, determining the scaling parameters includes: determining scaling parameters corresponding to the first application; or, determining preset scaling parameters.

[0006] In one optional implementation, determining the scaling parameters corresponding to the first application includes: obtaining the scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

[0007] In one optional implementation, the first application is characterized by being an application in a small window display mode; or, the first application is an application in a preset application list.

[0008] Optionally, the method further includes: determining the hardware information of the terminal device; and determining the corresponding preset application list based on the hardware information.

[0009] In one implementation, the first application is an application in a small window display mode; determining the scaling parameter includes: determining the scaling parameter based on the size of the small window in the small window display mode.

[0010] In one implementation, generating a first target layer of the first application and a cache queue corresponding to the first target layer based on the scaling parameters includes: generating a scaling matrix based on the scaling parameters; generating the first target layer based on the scaling matrix; adjusting the width and height information in the exploded cache queue used to construct the cache queue based on the scaling parameters; and generating the cache queue based on the exploded cache queue after adjusting the width and height information.

[0011] In one implementation, compositing the image to be rendered in the graphics cache includes: generating a magnification matrix based on the scaling parameters, and generating a second target layer based on the magnification matrix; wherein the second target layer is used to compose the image to be rendered in the graphics cache; and compositing the image to be rendered in the graphics cache based on the second target layer.

[0012] In one alternative implementation, generating the magnification matrix based on the scaling parameter includes: determining the reciprocal of the scaling parameter; and generating the magnification matrix based on the reciprocal of the scaling parameter.

[0013] According to a second aspect of the present disclosure, a window image display device is provided, comprising: a determining module, configured to determine a first application for which an image needs to be displayed; a first processing module, configured to determine a scaling parameter, wherein the value of the scaling parameter is a positive number less than 1; a second processing module, configured to generate a first target layer of the first application and a cache queue corresponding to the first target layer according to the scaling parameter; wherein the first target layer is used to draw an image to be rendered by the first application, and the cache queue is used to manage a graphics cache of the first application; a third processing module, configured to draw and render the image to be rendered according to the first target layer and the cache queue, so as to store the graphics data of the image to be rendered drawn by the first target layer in the graphics cache; and a display module, configured to synthesize the image to be rendered in the graphics cache and display the synthesized image on a terminal device screen.

[0014] In one implementation, the first processing module is specifically used to: determine the scaling parameters corresponding to the first application; or, determine the preset scaling parameters.

[0015] In one optional implementation, the first processing module is specifically used to: obtain scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

[0016] In one alternative implementation, the first application is an application in a small window display mode; or, the first application is an application from a preset application list.

[0017] Optionally, the first processing module is further configured to: determine the hardware information of the terminal device; and determine the corresponding preset application list based on the hardware information.

[0018] In one implementation, the first application is an application in a small window display mode; the first processing module is specifically used to: determine the scaling parameter based on the size of the small window in the small window display mode.

[0019] In one implementation, the second processing module is specifically used to: generate a scaling matrix based on the scaling parameters; generate the first target layer based on the scaling matrix; adjust the width and height information in the exploded buffer queue used to construct the buffer queue based on the scaling parameters; and generate the buffer queue based on the exploded buffer queue after adjusting the width and height information.

[0020] In one implementation, the display module is specifically used to: generate a magnification matrix according to the scaling parameters, and generate a second target layer according to the magnification matrix; wherein the second target layer is used to synthesize the image to be rendered in the graphics cache; and to synthesize the image to be rendered in the graphics cache according to the second target layer.

[0021] In one alternative implementation, the display module is specifically configured to: determine the reciprocal of the scaling parameter; and generate the magnification matrix based on the reciprocal of the scaling parameter.

[0022] According to a third aspect of the present disclosure, a terminal device is provided, comprising: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, the instructions being executed by the at least one processor to enable the at least one processor to perform the method as described in the first aspect above.

[0023] According to a fourth aspect of the present disclosure, a computer-readable storage medium is provided for storing instructions that, when executed, cause the method described in the first aspect to be implemented.

[0024] According to a fifth aspect of the present disclosure, a computer program product is provided, including a computer program that, when executed by a processor, implements the steps of the method described in the first aspect.

[0025] The technical solutions provided by the embodiments of this disclosure can include the following beneficial effects: A first target layer of a first application and a corresponding cache queue can be generated based on determined scaling parameters to synthesize and display the image of the first application on the screen of the terminal device. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the smoothness of the terminal device display.

[0026] It should be understood that the above general description and the following detailed description are exemplary and explanatory only, and are not intended to limit this disclosure. Attached Figure Description

[0027] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0028] Figure 1 This is a flowchart illustrating a window image display method according to an exemplary embodiment.

[0029] Figure 2 This is a flowchart illustrating another method for displaying a window image according to an exemplary embodiment.

[0030] Figure 3 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment.

[0031] Figure 4 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment.

[0032] Figure 5 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment.

[0033] Figure 6 This is a block diagram illustrating a window image display device according to an exemplary embodiment.

[0034] Figure 7 This is a schematic diagram of a terminal device according to an exemplary embodiment. Detailed Implementation

[0035] Exemplary embodiments will now be described in detail, examples of which are illustrated in the accompanying drawings. When the following description relates to the drawings, unless otherwise indicated, the same numerals in different drawings denote the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Rather, they are merely examples of apparatuses and methods consistent with some aspects of the invention as detailed in the appended claims.

[0036] In the description of this disclosure, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A alone, A and B simultaneously, and B alone. The various numerical designations such as "first," "second," etc., involved in this disclosure are only for descriptive convenience and are not intended to limit the scope of the embodiments of this disclosure, nor do they indicate a chronological order.

[0037] Figure 1 This is a flowchart illustrating a window image display method according to an exemplary embodiment. This method can be applied to terminal devices with a display interface, such as mobile phones or tablets. Figure 1 As shown, the method may include, but is not limited to, the following steps.

[0038] Step S101: Determine the first application for which the image needs to be displayed.

[0039] For example, identify the first application on the terminal device that needs to display the image. For instance, when a user requests to open application A, the application interface image of application A needs to be displayed on the screen of the terminal device; application A is the first application that needs to display the image.

[0040] Step S102: Determine the scaling parameters.

[0041] In the embodiments of this disclosure, the value of the scaling parameter is a positive number less than 1.

[0042] For example, determine the scaling parameters for scaling the image that the first application needs to display.

[0043] Step S103: Based on the scaling parameters, generate the first target layer of the first application and the corresponding buffer queue (BufferQueue) of the first target layer.

[0044] The first target layer is used to draw the image to be rendered for the first application, and the buffer queue is used to manage the graphics buffer of the first application.

[0045] For example, the layer of the image to be rendered for drawing the first application is scaled according to the scaling parameters to obtain the first target layer, and the image size in the buffer queue for managing the graphics buffer of the first application is scaled according to the scaling parameters to generate the buffer queue corresponding to the first target layer.

[0046] Step S104: Draw and render the image to be rendered according to the first target layer and the buffer queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphic buffer.

[0047] For example, the image to be rendered in the buffer queue is drawn and rendered on the first target layer, and the resulting image is stored in the graphics buffer, thereby storing the graphics data of the image to be rendered drawn on the first target layer in the graphics buffer.

[0048] Step S105: Composite the image to be rendered in the graphics buffer and display the composite image on the terminal device screen.

[0049] For example, the image to be rendered is read from the graphics cache, and the display compositing system SurfaceFlinger is used to composite the image based on HWC (Hardware Composer) or GPU (graphics processing unit), and the composite image is displayed on the screen of the terminal device.

[0050] By implementing the embodiments of this disclosure, a first target layer of a first application and a corresponding buffer queue can be generated based on determined scaling parameters to synthesize and display the image of the first application on the screen of a terminal device. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the smoothness of the terminal device's display.

[0051] In one implementation, the scaling parameter is either the scaling parameter corresponding to the first application, or a preset scaling parameter. For an example, please refer to [link to example]. Figure 2 , Figure 2 This is a flowchart illustrating another method for displaying a window image according to an exemplary embodiment. For example... Figure 2 As shown, the method may include, but is not limited to, the following steps.

[0052] Step S201: Determine the first application that needs to display the image.

[0053] In the embodiments of this disclosure, step S201 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0054] Step S202: Determine the scaling parameters corresponding to the first application; or, determine the preset scaling parameters.

[0055] In the embodiments of this disclosure, the first application is an application in a small window display mode; or, the first application is an application in a preset application list, which may be an application with low display resolution requirements.

[0056] As an example, in response to the first application being an application in a small window display mode, a scaling parameter corresponding to the first application is determined. For instance, when different applications are in small window display mode, those different applications have corresponding scaling parameters. For example, if both application A and application B are in small window display mode, the scaling parameters corresponding to application A and application B can be the same or different.

[0057] As another example, in response to the first application being an application in a small window display mode, a preset scaling parameter is determined. This scaling parameter is a fixed value. That is, the scaling parameter used is the same regardless of the type of application in small window display mode.

[0058] As another example, in response to the first application being an application in the preset application list, the scaling parameters corresponding to the first application are determined.

[0059] As another example, in response to the first application being an application from the preset application list, preset scaling parameters are determined.

[0060] In one alternative implementation, determining the scaling parameters corresponding to the first application may include: obtaining the scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

[0061] For example, when developing the first application, a first interface can be added to the first application. This first interface can store the scaling parameters corresponding to the first application, so that the corresponding scaling parameters can be obtained from the first application through the first interface.

[0062] Optionally, in this embodiment of the disclosure, the method may further include: determining the hardware information of the terminal device; and determining a corresponding preset application list based on the hardware information.

[0063] For example, the hardware information of the terminal device is determined, and a corresponding preset application list is determined based on this hardware information. The applications in the preset application list are those with low display resolution requirements on the terminal device. Thus, for low-end terminal devices (such as those with low memory, poor CPU and GPU performance, etc.), the method disclosed herein can also reduce the size of the graphics buffer required to display images, thereby reducing memory usage and improving the smoothness of the terminal device's display.

[0064] Step S203: Based on the scaling parameters, generate the first target layer of the first application and the corresponding cache queue of the first target layer.

[0065] In the embodiments of this disclosure, step S203 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0066] Step S204: Draw and render the image to be rendered according to the first target layer and the buffer queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphics buffer.

[0067] In the embodiments of this disclosure, step S204 can be implemented in any of the ways described in the various embodiments of this disclosure. The embodiments of this disclosure do not limit this and will not elaborate further.

[0068] Step S205: Composite the image to be rendered in the graphics buffer and display the composite image on the terminal device screen.

[0069] In the embodiments of this disclosure, step S205 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0070] By implementing the embodiments of this disclosure, scaling parameters corresponding to the first application or preset scaling parameters can be obtained, and a first target layer of the first application and a cache queue corresponding to the first target layer can be generated according to the scaling parameters, so as to display the content of the first application on the screen of the terminal device. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the display smoothness of the terminal device.

[0071] In one implementation, when the first application is in a small window display mode, the scaling parameters can be determined based on the size of the small window in small window display mode. For an example, please refer to [link to example]. Figure 3 , Figure 3 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment. For example... Figure 3 As shown, the method may include, but is not limited to, the following steps.

[0072] Step S301: Determine the first application for which the image needs to be displayed.

[0073] In the embodiments of this disclosure, step S301 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0074] Step S302: Determine the scaling parameters based on the size of the small window in the small window display mode.

[0075] In this embodiment of the disclosure, the first application is an application in a small window display mode.

[0076] For example, based on the size of the small window in the small window display mode and the actual size of the content that the first application expects to display, a scaling parameter is determined that allows the content that the first application expects to display to be fully displayed on the small window.

[0077] Step S303: Based on the scaling parameters, generate the first target layer of the first application and the corresponding cache queue of the first target layer.

[0078] In the embodiments of this disclosure, step S303 can be implemented in any of the various embodiments of this disclosure. This disclosure does not limit this implementation and will not elaborate further.

[0079] Step S304: Draw and render the image to be rendered according to the first target layer and the buffer queue, so as to store the graphic data of the image to be rendered drawn on the first target layer into the graphics buffer.

[0080] In the embodiments of this disclosure, step S304 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0081] Step S305: Composite the image to be rendered in the graphics buffer and display the composite image on the terminal device screen.

[0082] In the embodiments of this disclosure, step S305 can be implemented in any of the various embodiments of this disclosure. This disclosure does not limit this implementation and will not elaborate further.

[0083] By implementing the embodiments of this disclosure, when the first application is an application in a small window display mode, scaling parameters can be determined based on the size of the small window in the small window display mode, and a first target layer of the first application and a cache queue corresponding to the first target layer can be generated based on the scaling parameters, so as to generate and display the content of the first application on the screen of the terminal device. This reduces the size of the graphics buffer required to display images, thereby reducing memory usage and improving the smoothness of the terminal device display.

[0084] In one implementation, a scaling matrix can be generated based on scaling parameters, and then the first target layer of the first application and the corresponding buffer queue for the first target layer can be generated based on the scaling matrix. For an example, please refer to... Figure 4 , Figure 4 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment. For example... Figure 4 As shown, the method may include, but is not limited to, the following steps.

[0085] Step S401: Determine the first application for which the image needs to be displayed.

[0086] In the embodiments of this disclosure, step S401 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0087] Step S402: Determine the scaling parameters.

[0088] In the embodiments of this disclosure, step S402 can be implemented in any of the ways described in the various embodiments of this disclosure. The embodiments of this disclosure do not limit this and will not elaborate further.

[0089] Step S403: Generate a reduced matrix based on the scaling parameters.

[0090] For example, by using the scaling parameter as an element in the matrix, a reduced matrix can be generated.

[0091] Step S404: Generate the first target layer based on the reduction matrix.

[0092] For example, a scaling matrix is ​​set for the layer used to draw the image to be rendered for the first application, so as to resize the layer to generate the first target layer.

[0093] Step S405: Adjust the width and height information in the BlastBufferQueue used to build the buffer queue according to the scaling parameters.

[0094] For example, the width and height information in the exploded buffer queue used to build the buffer queue can be adjusted using the following formula.

[0095] w′=w*ratio

[0096] h′=h*ratio

[0097] Where w′ is the adjusted width information, w is the width information in the exploded buffer queue, ratio is the scaling parameter, h′ is the adjusted height information, and h is the height information in the exploded buffer queue.

[0098] Step S406: Generate a buffer queue based on the exploded buffer queue after adjusting the width and height information.

[0099] For example, based on the exploded buffer queue after adjusting the width and height information, a buffer queue corresponding to the first target layer is generated.

[0100] Step S407: Draw and render the image to be rendered according to the first target layer and the buffer queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphics buffer.

[0101] In the embodiments of this disclosure, step S407 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0102] Step S408: Composite the image to be rendered in the graphics buffer and display the composite image on the terminal device screen.

[0103] In the embodiments of this disclosure, step S408 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0104] By implementing the embodiments of this disclosure, a scaling matrix can be generated based on scaling parameters. This scaling matrix is ​​then used to generate a first target layer of the first application and a corresponding buffer queue for the first target layer, which are then used to composite and display the image of the first application on the screen of the terminal device. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the smoothness of the terminal device's display.

[0105] In one implementation, a second target layer can be generated based on scaling parameters, and the image to be rendered in the graphics buffer can be composited based on this second target layer. See also [example description missing]. Figure 5 , Figure 5 This is a flowchart illustrating yet another method for displaying a window image according to an exemplary embodiment. For example... Figure 5 As shown, the method may include, but is not limited to, the following steps.

[0106] Step S501: Determine the first application for which the image needs to be displayed.

[0107] In the embodiments of this disclosure, step S501 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0108] Step S502: Determine the scaling parameters.

[0109] In the embodiments of this disclosure, step S502 can be implemented in any of the ways described in the various embodiments of this disclosure. The embodiments of this disclosure do not limit this and will not elaborate further.

[0110] Step S503: Based on the scaling parameters, generate the first target layer of the first application and the corresponding cache queue of the first target layer.

[0111] In the embodiments of this disclosure, step S503 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0112] Step S504: Draw and render the image to be rendered according to the first target layer and the buffer queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphics buffer.

[0113] In the embodiments of this disclosure, step S504 can be implemented in any of the ways described in the various embodiments of this disclosure. This disclosure does not limit this and will not elaborate further.

[0114] Step S505: Generate a magnification matrix based on the scaling parameters, and generate a second target layer based on the magnification matrix.

[0115] The second target layer is used to synthesize the image to be rendered in the graphics buffer.

[0116] For example, a magnification matrix is ​​generated by using scaling parameters as elements in a matrix, and then the magnification matrix is ​​set to the layer used in compositing to obtain the second target layer.

[0117] In one alternative implementation, generating the magnification matrix based on the scaling parameter includes: determining the reciprocal of the scaling parameter; and generating the magnification matrix based on the reciprocal of the scaling parameter.

[0118] For example, the reciprocal of the scaling parameter is determined based on the scaling parameter, and the reciprocal of the scaling parameter is used as an element in the matrix to generate an enlarged matrix.

[0119] Step S506: Composite the image to be rendered in the graphics buffer based on the second target layer.

[0120] For example, the image to be rendered is read from the graphics buffer, and SurfaceFlinger is used to perform image compositing based on HWC or GPU to enlarge the image to be rendered in the graphics buffer to its original scale and draw it onto the second target layer to obtain the composite image.

[0121] Step S507: Display the synthesized image on the terminal device screen.

[0122] By implementing the embodiments of this disclosure, a second target layer can be generated according to scaling parameters, and the image to be rendered in the graphics buffer can be composited based on the second target layer, thereby displaying the content expected by the first application with less memory. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the smoothness of display on the terminal device.

[0123] Please see Figure 6 , Figure 6 This is a block diagram illustrating a window image display device according to an exemplary embodiment. For example... Figure 6 As shown, the device 600 includes: a determining module 601, used to determine a first application that needs to display an image; a first processing module 602, used to determine scaling parameters; wherein the value of the scaling parameters is a positive number less than 1; a second processing module 603, used to generate a first target layer of the first application and a cache queue corresponding to the first target layer according to the scaling parameters; wherein the first target layer is used to draw the image to be rendered of the first application, and the cache queue is used to manage the graphics cache of the first application; a third processing module 604, used to draw and render the image to be rendered according to the first target layer and the cache queue, so as to store the graphics data of the image to be rendered drawn by the first target layer in the graphics cache; and a display module 605, used to composite the image to be rendered in the graphics cache and display the composite image on the screen of the terminal device.

[0124] In one implementation, the first processing module 602 is specifically used to: determine the scaling parameters corresponding to the first application; or, determine the preset scaling parameters.

[0125] In one alternative implementation, the first processing module 602 is specifically used to: obtain scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

[0126] In one alternative implementation, the first application is an application in a small window display mode; or, the first application is an application in a preset application list.

[0127] Optionally, the first processing module 602 is further configured to: determine the hardware information of the terminal device; and determine the corresponding preset application list based on the hardware information.

[0128] In one implementation, the first application is an application in a small window display mode; the first processing module is specifically used to: determine the scaling parameters based on the size of the small window in the small window display mode.

[0129] In one implementation, the second processing module 603 is specifically used to: generate a scaling matrix based on scaling parameters; generate a first target layer based on the scaling matrix; adjust the width and height information in the exploded buffer queue used to construct the buffer queue based on scaling parameters; and generate a buffer queue based on the exploded buffer queue after adjusting the width and height information.

[0130] In one implementation, the display module 605 is specifically used to: generate a magnification matrix based on scaling parameters, and generate a second target layer based on the magnification matrix; wherein the second target layer is used to synthesize the image to be rendered in the graphics buffer; and to synthesize the image to be rendered in the graphics buffer based on the second target layer.

[0131] In one alternative implementation, the display module 605 is specifically used to: determine the reciprocal of the scaling parameter; and generate a magnification matrix based on the reciprocal of the scaling parameter.

[0132] The apparatus of this disclosure embodiment can determine scaling parameters and, based on these parameters, generate a first target layer of a first application and a corresponding cache queue for the first target layer, so as to synthesize and display the image of the first application on the screen of a terminal device. This reduces the size of the graphics buffer required to display the image, thereby reducing memory usage and improving the smoothness of the terminal device's display.

[0133] Regarding the apparatus in the above embodiments, the specific manner in which each module performs its operation has been described in detail in the embodiments related to the method, and will not be elaborated upon here.

[0134] Please see Figure 7 , Figure 7 This is a schematic diagram illustrating a terminal device according to an exemplary embodiment. For example, the terminal device 700 may be a mobile phone, computer, digital broadcasting terminal, messaging device, game console, tablet device, medical device, fitness equipment, personal digital assistant, wearable device, etc.

[0135] Reference Figure 7 The terminal device 700 may include one or more of the following components: processing component 702, memory 704, power supply component 706, multimedia component 708, audio component 710, input / output (I / O) interface 712, sensor component 714, and communication component 716.

[0136] Processing component 702 typically controls the overall operation of terminal device 700, such as operations associated with display, telephone calls, data communication, camera operation, and recording. Processing component 702 may include one or more processors 720 to execute instructions to complete all or part of the steps of the methods described above. Furthermore, processing component 702 may include one or more modules to facilitate interaction between processing component 702 and other components. For example, processing component 702 may include a multimedia module to facilitate interaction between multimedia component 708 and processing component 702.

[0137] Memory 704 is configured to store various types of data to support operation on terminal device 700. Examples of this data include instructions for any application or method operating on terminal device 700, contact data, phonebook data, messages, pictures, videos, etc. Memory 704 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.

[0138] Power supply component 706 provides power to various components of terminal device 700. Power supply component 706 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to terminal device 700.

[0139] Multimedia component 708 includes a touch display screen that provides an output interface between the terminal device 700 and the user. In some embodiments, the touch display screen may include a liquid crystal display (LCD) and a touch panel (TP). The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors may sense not only the boundaries of the touch or swipe action but also the duration and pressure associated with the touch or swipe operation. In some embodiments, multimedia component 708 includes a front-facing camera and / or a rear-facing camera. When the terminal device 700 is in an operating mode, such as a shooting mode or a video mode, the front-facing camera and / or the rear-facing camera may receive external multimedia data. Each front-facing camera and rear-facing camera may be a fixed optical lens system or have focal length and optical zoom capabilities.

[0140] Audio component 710 is configured to output and / or input audio signals. For example, audio component 710 includes a microphone (MIC) configured to receive external audio signals when terminal device 700 is in an operating mode, such as call mode, recording mode, and voice recognition mode. The received audio signals may be further stored in memory 704 or transmitted via communication component 716. In some embodiments, audio component 710 also includes a speaker for outputting audio signals.

[0141] I / O interface 712 provides an interface between processing component 702 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include, but are not limited to, home buttons, volume buttons, power buttons, and lock buttons.

[0142] Sensor assembly 714 includes one or more sensors for providing status assessments of various aspects of terminal device 700. For example, sensor assembly 714 can detect the on / off state of terminal device 700, the relative positioning of components such as the display and keypad of terminal device 700, changes in the position of terminal device 700 or a component of terminal device 700, the presence or absence of user contact with terminal device 700, the orientation or acceleration / deceleration of terminal device 700, and temperature changes of terminal device 700. Sensor assembly 714 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. Sensor assembly 714 may also include a light sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, sensor assembly 714 may also include an accelerometer, gyroscope, magnetometer, pressure sensor, or temperature sensor.

[0143] Communication component 716 is configured to facilitate wired or wireless communication between terminal device 700 and other devices. Terminal device 700 can access wireless networks based on communication standards, such as WiFi, 2G, or 3G, or combinations thereof. In one exemplary embodiment, communication component 716 receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, communication component 716 also includes a near-field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on radio frequency identification (RFID) technology, Infrared Data Association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology, and other technologies.

[0144] In an exemplary embodiment, the terminal device 700 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field-programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the methods described in any of the above embodiments.

[0145] This disclosure also provides a readable storage medium having instructions stored thereon that, when executed by a computer, implement the functions of any of the above method embodiments.

[0146] This disclosure also provides a computer program product that, when executed by a computer, implements the functions of any of the above method embodiments.

[0147] In the above embodiments, implementation can be achieved, in whole or in part, through software, hardware, firmware, or any combination thereof. When implemented in software, it can be implemented, in whole or in part, as a computer program product. The computer program product includes one or more computer programs. When the computer program is loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this disclosure are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer program can be stored in a computer-readable storage medium or transferred from one computer-readable storage medium to another. For example, the computer program can be transferred from one website, computer, server, or data center to another via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium accessible to a computer or a data storage device such as a server or data center that integrates one or more available media. The available media may be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., high-density digital video discs (DVDs)), or semiconductor media (e.g., solid-state disks (SSDs)).

[0148] Those skilled in the art will understand that the various numerical designations such as "first," "second," etc., used in this disclosure are merely for the convenience of description and are not intended to limit the scope of the embodiments of this disclosure, nor do they indicate the order of events.

[0149] At least one of the features described in this disclosure can also be described as one or more, and multiple features can be two, three, four or more, and this disclosure does not impose any limitations. In the embodiments of this disclosure, for a technical feature, the technical features in that technical feature are distinguished by "first", "second", "third", "A", "B", "C" and "D", etc., and there is no sequential order or size order among the technical features described by "first", "second", "third", "A", "B", "C" and "D".

[0150] The predefined terms in this disclosure can be understood as defined, predefined, stored, pre-stored, pre-negotiated, pre-configured, solidified, or pre-burned.

[0151] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this disclosure.

[0152] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0153] The above description is merely a specific embodiment of this disclosure, but the scope of protection of this disclosure is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this disclosure should be included within the scope of protection of this disclosure. Therefore, the scope of protection of this disclosure should be determined by the scope of the claims.

Claims

1. A method for displaying a window image, characterized in that, include: Determine the first application where the image needs to be displayed; Determine the scaling parameters; wherein the values ​​of the scaling parameters are positive numbers less than 1; Based on the scaling parameters, a first target layer of the first application and a cache queue corresponding to the first target layer are generated; wherein, the first target layer is used to draw the image to be rendered of the first application, and the cache queue is used to manage the graphics cache of the first application; The image to be rendered is drawn and rendered according to the first target layer and the cache queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphic cache. A second target layer is generated based on the magnification matrix generated by the reciprocal of the scaling parameter; the image to be rendered in the graphics cache is synthesized based on the second target layer, and the synthesized image is displayed on the terminal device screen.

2. The method as described in claim 1, characterized in that, Determining the scaling parameters includes: Determine the scaling parameters corresponding to the first application; Alternatively, you can specify the preset scaling parameters.

3. The method as described in claim 2, characterized in that, Determining the scaling parameters corresponding to the first application includes: Obtain scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

4. The method as described in claim 2 or 3, characterized in that, The first application is an application in small window display mode; Alternatively, the first application may be an application from a preset application list.

5. The method as described in claim 4, characterized in that, Also includes: Determine the hardware information of the terminal device; Based on the hardware information, determine the corresponding list of preset applications.

6. The method as described in claim 1, characterized in that, The first application is an application in small window display mode; determining the scaling parameters includes: The scaling parameter is determined based on the size of the small window in the small window display mode.

7. The method as described in claim 1, characterized in that, The step of generating a first target layer of the first application and a cache queue corresponding to the first target layer based on the scaling parameters includes: Generate a scaled-down matrix based on the scaling parameters; The first target layer is generated based on the reduction matrix; Adjust the width and height information in the BlastBufferQueue used to construct the buffer queue according to the scaling parameters; The buffer queue is generated based on the adjusted width and height information of the BlastBufferQueue.

8. The method as described in claim 1, characterized in that, The step of generating the magnification matrix based on the reciprocal of the scaling parameter includes: Determine the reciprocal of the scaling parameter; The magnification matrix is ​​generated based on the reciprocal of the scaling parameter.

9. A window image display device, characterized in that, include: The determination module is used to determine the first application for which the image needs to be displayed; The first processing module is used to determine the scaling parameter; wherein the value of the scaling parameter is a positive number less than 1; The second processing module is used to generate a first target layer of the first application and a cache queue corresponding to the first target layer according to the scaling parameters; wherein, the first target layer is used to draw the image to be rendered of the first application, and the cache queue is used to manage the graphics cache of the first application. The third processing module is used to draw and render the image to be rendered according to the first target layer and the cache queue, so as to store the graphic data of the image to be rendered drawn by the first target layer into the graphic cache. The display module is used to generate a second target layer based on the magnification matrix generated by the reciprocal of the scaling parameter; to synthesize the image to be rendered in the graphics cache based on the second target layer; and to display the synthesized image on the screen of the terminal device.

10. The apparatus as claimed in claim 9, characterized in that, The first processing module is specifically used for: Determine the scaling parameters corresponding to the first application; Alternatively, you can specify the preset scaling parameters.

11. The apparatus as claimed in claim 10, characterized in that, The first processing module is specifically used for: Obtain scaling parameters corresponding to the first application from the first application; wherein the first application includes a first interface, and the first interface stores the scaling parameters corresponding to the first application.

12. The apparatus as claimed in claim 10 or 11, characterized in that, The first application is an application in small window display mode; Alternatively, the first application may be an application from a preset application list.

13. The apparatus as claimed in claim 12, characterized in that, The first processing module is also used for: Determine the hardware information of the terminal device; Based on the hardware information, determine the corresponding list of preset applications.

14. The apparatus as claimed in claim 9, characterized in that, The first application is an application in a small window display mode; the first processing module is specifically used for: The scaling parameter is determined based on the size of the small window in the small window display mode.

15. The apparatus as claimed in claim 9, characterized in that, The second processing module is specifically used for: Generate a scaled-down matrix based on the scaling parameters; The first target layer is generated based on the reduction matrix; Adjust the width and height information in the BlastBufferQueue used to construct the buffer queue according to the scaling parameters; The buffer queue is generated based on the adjusted width and height information of the BlastBufferQueue.

16. The apparatus as claimed in claim 9, characterized in that, The display module is specifically used for: Determine the reciprocal of the scaling parameter; The magnification matrix is ​​generated based on the reciprocal of the scaling parameter.

17. A terminal device, characterized in that, include: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores instructions that can be executed by the at least one processor to enable the at least one processor to perform the method as described in any one of claims 1 to 8.

18. A computer-readable storage medium for storing instructions that, when executed, cause the method of any one of claims 1 to 8 to be implemented.