CN116844196A - Dynamic effect picture display method and electronic equipment - Google Patents

Dynamic effect picture display method and electronic equipment Download PDF

Info

Publication number
CN116844196A
CN116844196A CN202311113071.8A CN202311113071A CN116844196A CN 116844196 A CN116844196 A CN 116844196A CN 202311113071 A CN202311113071 A CN 202311113071A CN 116844196 A CN116844196 A CN 116844196A
Authority
CN
China
Prior art keywords
fingerprint
memory
pixel data
data set
electronic equipment
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202311113071.8A
Other languages
Chinese (zh)
Other versions
CN116844196B (en
Inventor
赵和平
谭文文
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202311113071.8A priority Critical patent/CN116844196B/en
Publication of CN116844196A publication Critical patent/CN116844196A/en
Application granted granted Critical
Publication of CN116844196B publication Critical patent/CN116844196B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/12Fingerprints or palmprints
    • G06V40/13Sensors therefor
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T13/00Animation
    • G06T13/802D [Two Dimensional] animation, e.g. using sprites
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/12Fingerprints or palmprints
    • G06V40/1347Preprocessing; Feature extraction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V40/00Recognition of biometric, human-related or animal-related patterns in image or video data
    • G06V40/10Human or animal bodies, e.g. vehicle occupants or pedestrians; Body parts, e.g. hands
    • G06V40/12Fingerprints or palmprints
    • G06V40/1365Matching; Classification

Abstract

The application provides a dynamic effect picture display method and electronic equipment, wherein the method is applied to the electronic equipment and comprises the following steps: after the electronic equipment is started, displaying a first interface at a first time point; acquiring a first image set, and decoding to obtain a first pixel data set; at a second time point, responding to a first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying a second interface after the unlocking moving effect picture is displayed; at a third time point, when the screen of the electronic equipment is detected to be off, the first image set is not decoded; and at a fourth time point, responding to the first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying a second interface after the unlocking moving effect picture is displayed. Therefore, the application only needs to execute the decoding once, reduces the power consumption of the electronic equipment and saves the power consumption of the electronic equipment.

Description

Dynamic effect picture display method and electronic equipment
Technical Field
The application relates to the field of terminals, in particular to a dynamic effect picture display method and electronic equipment.
Background
Along with the continuous development of information technology, fingerprint identification unlocking technology is widely used in electronic equipment such as mobile phones and tablet computers, and becomes an important ring of the electronic equipment for user identification.
Currently, in the process of fingerprint identification unlocking, the electronic equipment increases interactivity of fingerprint identification unlocking by displaying a fingerprint unlocking dynamic effect picture on a display screen; however, the current process of displaying the fingerprint unlocking moving effect picture by the electronic device is complex and has repeated steps, so that the power consumption and the electric quantity consumption of the electronic device are increased by the process of displaying the fingerprint unlocking moving effect picture by the electronic device.
Disclosure of Invention
The application provides a dynamic effect picture display method and electronic equipment, which reduce the power consumption and the electricity consumption of the electronic equipment.
In a first aspect, the present application provides a moving-effect picture display method, which is applied to an electronic device; the method comprises the following steps:
after the electronic equipment is started, displaying a first interface at a first time point, wherein the first interface is an interface when the electronic equipment is in a screen locking state;
acquiring a first image set, and decoding to obtain a first pixel data set;
at a second time point, responding to a first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, displaying a second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the second time point is later than the first time point, and the second interface is an interface when the electronic equipment is in an unlocking state;
When the screen of the electronic equipment is detected to be off at a third time point, the first image set is not decoded, the electronic equipment is not powered off between the second time point and the third time point, and the third time point is later than the second time point;
and at a fourth time point, responding to the first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying the second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the fourth time point is later than the third time point.
In the method, after the first display of the unlocking moving effect picture on the first interface is finished, the first pixel data set in the first memory is not deleted, and the first image set is not required to be decoded again, namely the first pixel data set in the first memory is reserved, so that the electronic equipment in the screen locking state can display the unlocking moving effect picture directly according to the first pixel data set when receiving the first operation every time later, the power consumption of the electronic equipment is reduced, and the electric quantity consumption of the electronic equipment is reduced.
With reference to the first aspect, in some implementations of the first aspect, the electronic device includes a first memory and a second memory, where data in the first memory is cleared when the electronic device is turned off, and data in the second memory is not cleared when the electronic device is turned off, so as to obtain the first pixel data set, and the method further includes:
The first set of pixel data is stored in a first memory and the first set of images is stored in a second memory.
In the method, the first pixel data set is stored in the first memory, so that when the first operation is received, the unlocking dynamic effect picture can be displayed directly according to the first pixel data set in the first memory.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes:
acquiring a fingerprint image of a user in response to a first operation of the fingerprint identification area on the first interface;
fingerprint identification is carried out on the fingerprint image;
when the fingerprint identification is successful and the display of the unlocking moving effect picture is finished, compressing the first pixel data set;
and decompressing the first pixel data set when the electronic equipment is detected to be off-screen.
In the method, after the fingerprint identification is successful and the display of the unlocking dynamic effect picture is finished, the first pixel data set in the first memory can be compressed, so that the pressure of the first memory is released, the performance of the electronic equipment is prevented from being reduced, the running program is prevented from being crashed, and the performance and the stability of an electronic equipment system are ensured.
With reference to the first aspect, in some implementations of the first aspect, when fingerprint identification is successful and the unlocking of the dynamic effect screen display is finished, compressing the first pixel data set includes:
acquiring a fingerprint image of a user in response to a first operation of the fingerprint identification area on the first interface;
fingerprint identification is carried out on the fingerprint image;
when the fingerprint identification is successful and the display of the unlocking moving effect picture is finished, determining whether the pressure level of the first memory is larger than a first threshold value, wherein the pressure level is used for indicating the storage pressure of the first memory, and the storage pressure is related to the pause time of a program in the running of the electronic equipment for waiting for the first memory to allocate the storage space;
the first set of pixel data in the first memory is compressed when the pressure level is greater than the first threshold.
In the method, after the fingerprint identification is successful and the display of the unlocking dynamic effect picture is finished, the pressure level of the first memory can be determined, and when the pressure level of the first memory is greater than the first threshold value, the first pixel data set in the first memory is required to be compressed, so that the pressure of the first memory is released, the performance of the electronic equipment is prevented from being reduced, the running program is prevented from being crashed, and the performance and stability of the electronic equipment system are ensured.
With reference to the first aspect, in certain implementation manners of the first aspect, before decoding the first image set to obtain the first pixel data set, the method further includes:
and starting a fingerprint monitoring function.
In the method, when the electronic equipment is started or restarted and is in the screen-lightening and screen-locking state for the first time, the electronic equipment can register the fingerprint monitoring function, acquire the first image set from the second memory, store the first pixel data set of the fingerprint obtained by decoding into the first memory after decoding, namely store the first pixel data set into the first memory in advance, so that the electronic equipment can display the unlocking moving effect picture directly according to the first pixel data set in the first memory when receiving the first operation for the first time and each time afterwards, the decoding time is saved, the power consumption of the electronic equipment is reduced, and the consumption of electric quantity of the electronic equipment is reduced.
With reference to the first aspect, in certain implementation manners of the first aspect, after the unlocking the moving effect screen display is finished, the method further includes:
the monitor fingerprint function is turned off.
In the method, after the fingerprint identification is successful and the display of the unlocking dynamic effect picture is finished, the fingerprint monitoring function is closed, so that the power consumption of the electronic equipment can be reduced, the electric quantity consumption of the electronic equipment is reduced, and the use smoothness of the electronic equipment is ensured.
With reference to the first aspect, in certain implementation manners of the first aspect, when detecting that the electronic device is off-screen, decompressing the first pixel data set includes:
when detecting that the electronic equipment is off-screen, determining whether a fingerprint monitoring function is started;
when the fingerprint monitoring function is not started, starting the fingerprint monitoring function;
determining whether a first pixel data set is present in the first memory in response to turning on the snoop fingerprint function;
and decompressing the first pixel data set when the first pixel data set exists in the first memory and the first pixel data set is compressed data.
In the above method, before the screen is turned off, the function of monitoring the fingerprint may be registered, and the first pixel data set obtained by decoding the first image set in the second memory is stored in the first memory; the monitoring fingerprint function may also be turned off after registering the monitoring fingerprint function and storing a first pixel data set obtained by decoding a first image set in the second memory into the first memory; the snoop fingerprint function may not be registered, and therefore, when the snoop fingerprint function is not registered and the first pixel data set does not exist in the first memory, the snoop fingerprint function is registered, and the first pixel data set obtained by decoding the first image set in the second memory is stored in the first memory, so that data preparation is made for displaying the unlock dynamic picture when the first operation is received next time.
And because the first pixel data set in the first memory is compressed when the fingerprint identification is successful and the pressure level of the first memory is greater than the first threshold after the display of the unlocking moving effect picture is finished, the first pixel data set needs to be decompressed, so that data preparation is made for displaying the unlocking moving effect picture when the first operation is received next time; when the electronic equipment is off-screen, the first pixel data set is decompressed, compared with when the electronic equipment is on-screen, the first pixel data set is decompressed, so that the power consumption of the electronic equipment can be reduced, and the power consumption of the electronic equipment can be reduced.
With reference to the first aspect, in certain implementations of the first aspect, the method further includes:
decoding the first image set in the second memory to obtain a first pixel data set when the first pixel data set does not exist in the first memory;
the first set of pixel data is stored in a first memory.
In the above method, before the electronic device is turned off, the electronic device may not register the function of monitoring the fingerprint, and the first pixel data set obtained by decoding the first image set in the second memory is not stored in the first memory, so that when the first pixel data set does not exist in the first memory, the first image set in the second memory needs to be decoded to obtain the first pixel data set, and the first pixel data set is stored in the first memory, so that data preparation is ready for displaying the unlocking moving effect picture when the first operation is received next time.
With reference to the first aspect, in certain implementation manners of the first aspect, displaying an unlock moving effect screen according to the first pixel data set includes:
determining whether a first set of pixel data is present in a first memory;
decoding the first image set in the second memory to obtain a first pixel data set when the first pixel data set does not exist in the first memory;
storing the first set of pixel data in a first memory;
and displaying the unlocking dynamic effect picture according to the first pixel data set in the first memory.
In the method, when the first operation is received, the unlocking moving effect picture can be displayed according to the first pixel data set stored in the first memory; or when the first operation is received, judging whether the first pixel data set exists in the first memory, executing a decoding process when the first pixel data set does not exist, storing the first pixel data set in the first memory, and displaying the unlocking moving effect picture according to the first pixel data set stored in the first memory when the first pixel data set exists, so that the situation that the first pixel data set does not exist in the first memory possibly caused by various factors can be avoided, and the unlocking moving effect picture can be ensured to be displayed smoothly according to the first pixel data set.
With reference to the first aspect, in certain implementations of the first aspect, compressing the first pixel data set in the first memory includes:
performing object level compression on a first pixel data set in a first memory;
decompressing the first pixel data set, comprising:
object-level decompression is performed on the first pixel data set.
Wherein the object-level compression is an independent compression of each object to be compressed in the first memory, e.g. an independent compression of each group of pixel data in the first pixel data set.
Object-level decompression is to decompress each compressed object independently, rather than decompressing the entire file; for example, each group of pixel data in the first set of pixel data is decompressed independently.
In the method, the object-level compression technology is adopted to compress the first pixel data set, so that finer granularity compression control can be realized, the compression efficiency and performance are improved, the storage space of the first pixel data set on the first memory is reduced, and the size of data in the transmission process is reduced.
Further, since the first pixel data set in the first memory is data subjected to object-level compression, object-level decompression of the first pixel data set in the first memory is required.
With reference to the first aspect, in certain implementations of the first aspect, decompressing the first pixel data set includes:
and decompressing the first pixel data set through the memory locking interface, wherein the decompressed first pixel data set is in an incompressible state.
Wherein the incompressible state indicates that the decompressed first pixel data set cannot be compressed.
In the method, the first pixel data set is locked in the first memory through the memory locking interface, so that the first pixel data set is in an incompressible state, and the first pixel data set can be prevented from being compressed again after screen failure.
With reference to the first aspect, in certain implementations of the first aspect, after displaying the unlock dynamic screen on the first interface according to the first pixel data set in the first memory, the method includes:
and converting the first pixel data set into a compressible state through the memory unlocking interface.
Wherein the compressible state represents the decompressed first pixel data set, which is capable of being compressed.
In the above method, after unlocking the memory unlocking interface, the first pixel data set is in a compressible state, and when the pressure level of the first memory is greater than the first threshold value, the compression of the first pixel data set can be triggered again.
With reference to the first aspect, in certain implementation manners of the first aspect, the first image set includes a plurality of first images, and displaying the unlock moving effect screen according to the first pixel data set includes:
drawing a plurality of first images in a first pixel data set in a first memory to obtain a plurality of second images, wherein the plurality of second images are in one-to-one correspondence with the plurality of first images;
and displaying an unlocking moving effect picture on the first interface according to the plurality of second images.
Wherein the plurality of second images corresponds to each frame of the unlock motion picture.
In the above method, since the unlocking moving effect picture needs to be displayed according to the image, each group of pixel data in the first pixel data set needs to be drawn first to obtain a plurality of second images, and then the unlocking moving effect picture needs to be displayed according to the plurality of second images.
In a second aspect, the present application provides a dynamic picture display device, which may comprise one or more modules for performing the dynamic picture display method of the first aspect and any one of the possible implementation manners of the first aspect.
The plurality of modules can comprise a pressure pause information module, a fingerprint service module, a fingerprint identification trusted application module and a pressure pause information kernel module.
In a third aspect, the present application provides an electronic device comprising one or more processors, a memory and one or more computer programs, wherein the one or more computer programs are stored on the memory, which when executed by the one or more processors, cause the electronic device to perform the method of displaying a moving picture in any one of the first aspect and the possible implementation manner of the first aspect.
In a fourth aspect, the present application provides a chip system, the chip system including a processor for calling and running a computer program from a memory, so that a station device on which the chip system is installed performs the dynamic picture display method in any one of the possible implementations of the first aspect and the first aspect.
In a fifth aspect, the present application provides a computer readable storage medium comprising a computer program which, when run on an electronic device, causes a website device to perform the dynamic picture display method of the first aspect and any one of the possible implementation manners of the first aspect.
In a sixth aspect, the present application provides a computer program product for, when run on a computer, causing the computer to perform the dynamic picture display method of the first aspect and any one of the possible implementation manners of the first aspect.
It will be appreciated that the advantages of the second to sixth aspects may be found in the relevant description of the first aspect, and are not described here again.
Drawings
FIG. 1 is a flow chart of a method for displaying a moving effect picture according to the prior art;
FIG. 2 is a timing diagram of a dynamic image display method according to the prior art;
fig. 3 to fig. 4 are schematic diagrams of an application scenario according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 6 is a schematic software architecture of an electronic device according to an embodiment of the present application;
FIG. 7 is a flowchart of a method for displaying a moving picture according to an embodiment of the present application;
FIG. 8 is a schematic diagram of a data compression and decompression process according to an embodiment of the present application;
FIG. 9 is a flowchart of a method for displaying a moving picture according to an embodiment of the present application;
FIG. 10 is a flowchart of a method for displaying a moving picture according to an embodiment of the present application;
FIG. 11 is a schematic diagram of a name event and a full event according to an embodiment of the present application;
FIG. 12 is a schematic diagram of a name event and a full event according to an embodiment of the present application;
FIG. 13 is a schematic diagram of a name event and a full event according to an embodiment of the present application;
fig. 14 is a flowchart of a method for displaying a moving picture according to an embodiment of the application.
Detailed Description
In the present application, "at least one" means one or more, and "a plurality" means two or more. "and/or", describes an association relationship of an association object, and indicates that there may be three relationships, for example, a and/or B, and may indicate: a alone, a and B together, and B alone, wherein a, B may be singular or plural. The character "/" generally indicates that the context-dependent object is an "or" relationship. "at least one of" or the like means any combination of these items, including any combination of single item(s) or plural items(s). For example, at least one (one) of a, b, or c alone may represent: a alone, b alone, c alone, a combination of a and b, a combination of a and c, b and c, or a combination of a, b and c, wherein a, b, c may be single or plural. Furthermore, the terms "first," "second," and the like, are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
The fingerprint identification technology has the advantages of high safety, high identification speed, high identification success rate and the like, so the fingerprint identification technology has been widely applied to various scenes.
For example, the fingerprint identification technology can be applied to a scene of fingerprint unlocking of the electronic device, and in the fingerprint unlocking scene, the identity of the user can be identified through the fingerprint identification technology.
When the fingerprint identification technology can be applied to a fingerprint unlocking scene, the fingerprint of a user needs to be acquired through a fingerprint sensor, and the fingerprint sensor can be positioned at the back, the side edge or the lower part of a display screen of the electronic equipment.
When the fingerprint sensor is positioned below the display screen of the electronic equipment, a user can place a finger in a fingerprint identification area on the display screen, fingerprint images of the user are collected through the fingerprint sensor and are matched with the pre-stored fingerprint images to realize fingerprint unlocking, and the electronic equipment can be changed into a bright screen unlocking state from a screen locking state after unlocking.
The fingerprint identification area on the display screen is an area where the display screen is electrically connected with the fingerprint sensor.
Specifically, the screen locking state may be a screen locking state of screen extinction or a screen locking state of screen brightness.
The display screen of the electronic device can display date, time and other information.
In the process of fingerprint identification, a corresponding fingerprint unlocking moving effect picture can be displayed on a display screen of the electronic equipment, and the fingerprint unlocking moving effect picture can be also called as fingerprint unlocking moving effect.
The fingerprint unlocking moving effect picture not only can remind the user that the fingerprint is successfully read and the electronic equipment is verifying and matching the fingerprint information of the fingerprint image, but also can provide visual interaction for the user, so that the fingerprint unlocking process is more visual and pleasant, and the perception of the user on the safety and convenience of the electronic equipment is enhanced.
The fingerprint unlocking moving effect picture corresponds to a fingerprint moving effect picture, and the fingerprint moving effect picture is stored in a memory 1 in the electronic equipment in advance.
In one possible implementation manner, for an electronic device in a screen locking state, after a user places a finger in a fingerprint identification area on a display screen, a fingerprint sensor under the display screen may receive a contact operation, so that, as shown in S111-S114 in the embodiment shown in fig. 1, a fingerprint service module in an application Framework (FWK) layer registers a monitoring fingerprint function on a fingerprint identification trusted application module of a secure execution environment system through a fingerprint identification module of a hardware abstraction layer, and then, as shown in S115 in the embodiment shown in fig. 1, the fingerprint service module acquires a fingerprint moving effect picture from a memory 1 of the electronic device, and decodes the fingerprint moving effect picture to obtain fingerprint moving effect pixel data, and then, as shown in S116 in the embodiment shown in fig. 1, the fingerprint service module stores the fingerprint moving effect pixel data in a memory 2; after receiving the identification message, the fingerprint service module obtains the fingerprint moving effect pixel data from the memory 2 as shown in S117-S118 in the embodiment shown in fig. 1, and S120, and the fingerprint service module displays a fingerprint unlocking moving effect screen according to the fingerprint moving effect pixel data as shown in S121 in the embodiment shown in fig. 1.
In addition, after the user places the finger in the fingerprint identification area on the display screen, as shown in S119 in the embodiment shown in fig. 1, the fingerprint sensor may also collect a fingerprint image and send the fingerprint image to the fingerprint identification trusted application module, so that, as shown in S122 in the embodiment shown in fig. 1, the fingerprint identification trusted application module matches the collected fingerprint image with a pre-stored fingerprint image, and after the matching is finished, as shown in S123 and S124 in the embodiment shown in fig. 1, the fingerprint identification trusted application module sends a fingerprint identification result to the fingerprint service module; as shown in S125 in the embodiment shown in fig. 1, if the fingerprint identification result indicates that the fingerprint identification is successful, the electronic device is successfully unlocked, and after the unlocking is successful, the electronic device is in an unlocked state, and the fingerprint service module deletes the fingerprint effective pixel data stored in the memory 2.
After the electronic device is turned off, as shown in S126 in the embodiment of fig. 1, the fingerprint service module obtains a fingerprint moving effect picture from the memory 1 of the electronic device, and decodes the fingerprint moving effect picture to obtain fingerprint moving effect pixel data, and then, as shown in S127 in the embodiment of fig. 1, the fingerprint service module stores the fingerprint moving effect pixel data in the memory 2.
The fingerprint moving effect picture comprises a plurality of pictures, fingerprint moving effect Pixel data comprises a plurality of groups of Pixel data, one picture corresponds to one group of Pixel data, namely bitmap (bitmap) data, and one group of Pixel data comprises a grid or matrix formed by pixels (pixels).
Thus, as can be seen in conjunction with fig. 2, after the electronic device is started or restarted, the function of monitoring the fingerprint can be registered, the fingerprint moving effect picture is obtained from the memory 1 of the electronic device, the fingerprint moving effect picture is decoded, the fingerprint moving effect pixel data obtained by decoding is stored in the memory 2, after the fingerprint sensor receives the contact operation, the moving effect picture can be displayed according to the fingerprint moving effect pixel data in the memory 2, the display is finished, after the fingerprint is successfully unlocked, the fingerprint moving effect pixel data is deleted, and after the screen is removed, the fingerprint moving effect picture is obtained from the memory 1 of the electronic device again, and the fingerprint moving effect picture is decoded; in this way, the power consumption of the electronic device is increased, as well as the consumption of the electric power.
In view of the above problems, the present application may provide a moving-effect picture display method, an electronic device, a chip system, a computer-readable storage medium, and a computer program product, which may acquire a fingerprint moving-effect picture from a memory 1 in advance after registering a listening fingerprint function, decode the fingerprint moving-effect picture, store the decoded fingerprint moving-effect picture in a memory 2, display a moving-effect picture according to fingerprint moving-effect pixel data when the electronic device receives an identification message, and not delete the fingerprint moving-effect pixel data in the memory 2 after the display is completed; after the electronic equipment is turned off, repeated decoding processing is not needed to be carried out on the fingerprint moving effect picture; therefore, repeated decoding can be avoided, when fingerprint motion effect pixel data is needed to be used next time, the fingerprint motion effect pixel data can be directly obtained from the memory 2, decoding time and electric quantity of the electronic equipment can be saved, and power consumption of the electronic equipment is reduced.
The dynamic effect picture display method can be applied to electronic equipment with a fingerprint unlocking function. The electronic device may be an electronic device with display screen hardware and corresponding software support.
For example, the site device may be a cell phone, tablet computer, in-vehicle device, notebook computer, wearable device, ultra-mobile personal computer (UMPC), netbook, personal digital assistant (personal digital assistant, PDA), smart car, smart television, robot, etc.
It should be noted that, in some possible implementations, the electronic device may also be referred to as a terminal device, a User Equipment (UE), or the like, which is not limited by the embodiment of the present application.
Referring to fig. 3 and fig. 4, fig. 3 and fig. 4 show schematic diagrams of an application scenario according to an embodiment of the application.
As shown in fig. 3 (a), the electronic device is in a state of being on or being restarted and being locked, the electronic device may register a monitoring fingerprint function, acquire a fingerprint moving effect picture from the memory 1 in advance after registering the monitoring fingerprint function, decode the fingerprint moving effect picture, and store the decoded fingerprint moving effect picture in the memory 2; as shown in fig. 3 (b) -fig. 4 (a), after the user places the finger in the fingerprint recognition area on the display screen, the fingerprint sensor under the display screen may receive a touch operation, and thus, the electronic device may display a moving effect screen according to the fingerprint moving effect pixel data in the memory 2; meanwhile, the electronic device starts to match the fingerprint image acquired by the fingerprint sensor with a pre-stored fingerprint image, as shown in (b) of fig. 4, if the matching is successful, the electronic device is successfully unlocked, and a main interface (interface without screen) of the electronic device is displayed.
After the electronic device is turned off, the step of decoding the fingerprint moving effect picture and storing the decoded fingerprint moving effect picture in the memory 2 is not needed, so that the fingerprint sensor of the electronic device can display the moving effect picture directly according to the fingerprint moving effect pixel data in the memory 2 after receiving the contact operation next time.
For example, the moving effect screen corresponding to (b) in fig. 3- (a) in fig. 4 may be: and the fingerprint identification area is taken as a circle center to be outwards diffused to form an elliptic pattern which is larger than the fingerprint identification area.
It should be understood that the foregoing is illustrative of a scenario and is not intended to limit the scenario of the present application in any way.
For convenience of description, fig. 5 illustrates an electronic device 100 as an example of a mobile phone.
As shown in fig. 5, the electronic device 100 may include a processor 101, a communication module 102, a display 103, a camera 104, a sensor 105, an internal memory 106, a USB interface 107, an external memory interface 108, a charge management module 109, a power management module 110, a battery 111, and the like.
The processor 101 may include one or more processing units, for example: the processor 101 may include an application processor (application processor, AP), a modem processor, a graphics processor, an image signal processor (image signal processor, ISP), a controller, a memory, a video stream codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and/or a neural network processor (neural-network processing unit, NPU), etc. Wherein the different processing units may be separate devices or may be integrated in one or more processors 101.
A memory may also be provided in the processor 101 for storing instructions and data.
In some embodiments, the memory in the processor 101 is a cache memory. The memory may hold instructions or data that has just been used or recycled by the processor 101. If the processor 101 needs to reuse the instruction or data, it may be called directly from memory. Repeated accesses are avoided and the latency of the processor 101 is reduced, thus improving the efficiency of the system.
In some embodiments, the processor 101 may include one or more interfaces. The interfaces may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, a universal asynchronous receiver transmitter (universal asynchronous receiver/transmitter, UART) interface, a mobile industry processor interface (mobile industry processor interface, MIPI), a general-purpose input/output (GPIO) interface, a subscriber identity module (subscriber identity module, SIM) interface, and/or a universal serial bus (universal serial bus, USB) interface, among others.
The communication module 102 may include an antenna 1 and an antenna 2, a mobile communication module, and/or a wireless communication module.
The display screen 103 is used for displaying images or videos in a human-computer interaction interface. The display screen 103 includes a display panel. The display panel may employ a liquid crystal display (liquid crystal display, LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED) or an active-matrix organic light-emitting diode (matrix organic light emitting diode), a flexible light-emitting diode (flex), miniLED, microLED, micro-OLED, a quantum dot light-emitting diode (quantum dot light emitting diodes, QLED), or the like. In some embodiments, the electronic device 100 may include 1 or N display screens 103, N being a positive integer greater than 1.
The camera 104 is used to capture still images or video.
The charge management module 109 is configured to receive a charge input from a charger. The charger can be a wireless charger or a wired charger.
In some wired charging embodiments, the charge management module 109 may receive a charging input of a wired charger through the USB interface 107.
In some wireless charging embodiments, the charge management module 109 may receive wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 109 may also supply power to the electronic device 100 through the power management module 110 while charging the battery 111.
The power management module 110 is used for connecting the battery 111, the charge management module 109 and the processor 101. The power management module 110 receives input from the battery 111 and/or the charge management module 109 and provides power to the processor 101, the internal memory 106, the external memory, the communication module 102, and the like. The power management module 110 may also be configured to monitor battery capacity, battery cycle times, battery health (leakage, impedance), and other parameters.
In other embodiments, the power management module 110 may also be disposed in the processor 101.
In other embodiments, the power management module 110 and the charge management module 109 may also be disposed in the same device.
The external memory interface 108 may be used to connect an external memory card, such as a Micro SD card, to enable expansion of the memory capabilities of the electronic device 100. The external memory card communicates with the processor 101 through an external memory interface 108 to implement data storage functions. For example, files such as music, video streams, etc. are stored in an external memory card.
The internal memory 106 may be used to store computer executable program code that includes instructions. The processor 101 executes instructions stored in the internal memory 106 to thereby perform various functional applications and data processing of the electronic device 100. The internal memory 106 may include a stored program area and a stored data area.
The storage program area may store an application program (such as a sound playing function, an image playing function, etc.) required for at least one function of the operating system, etc. The storage data area may store data created during use of the electronic device 100 (e.g., audio data, phonebook, etc.), and so on. In addition, the internal memory 106 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, universal flash memory (universal flash storage, UFS), and the like.
The sensors 105 in the electronic device 100 may include image sensors, touch sensors, pressure sensors, gyroscopic sensors, barometric pressure sensors, magnetic sensors, acceleration sensors, distance sensors, proximity sensors, ambient light sensors, fingerprint sensors, temperature sensors, bone conduction sensors, etc. to enable sensing and/or acquisition of different signals.
Optionally, the electronic device 100 may also include peripheral devices such as a mouse, keys, indicator lights, keyboard, speakers, microphone, etc.
It is to be understood that the structure illustrated in the present embodiment does not constitute a specific limitation on the electronic apparatus 100.
In other embodiments, electronic device 100 may include more or fewer components than shown, or certain components may be combined, or certain components may be split, or different arrangements of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Fig. 6 is a schematic diagram of a software architecture of an electronic device according to an embodiment of the present application. When the moving-effect picture display method provided by the embodiment of the present application is applied to the electronic device 100 shown in fig. 6, software in the electronic device 100 may be divided into an application layer 201, an application framework layer (FWK) 202, a kernel layer 203, and a hardware abstraction layer (hardware abstraction layer, HAL) 204 as shown in fig. 7.
The application layer 201 may have a plurality of applications installed therein.
Application framework layer 202 the application framework layer provides a basic set of functions and services for application layer invocation and use.
The application framework layer 202 may include, among other things, a pressure quiesce information (pressure stall information, PSI) module, a fingerprint service (fingerprint service) module, a power management service (power manager service, PMS) module, a graphics processing (graphics) module, and a graphics image processing library.
The application framework layer 202 may include two sub-layers, a java layer and a native layer, respectively.
Specifically, the fingerprint service (fingerprint service) module, the power management service (power manager service, PMS) module, and the graphics processing (graphics) module belong to the java layer in the application framework layer 202. The pressure quiesce information (pressure stall information, PSI) module and the graphic image processing library belong to the native layer in the application framework layer 202.
The pressure dwell information (pressure stall information, PSI) module is a module for collecting and recording the pressure conditions of the memory 2. The fingerprint service (fingerprint service) module is a module for handling fingerprint recognition functions. The power management service (power manager service, PMS) is a module for managing power and device status. Graphics processing (graphics) modules are a type of module for performing graphics-related computations. A graphic image processing library is a module for responsible user interactions with an electronic device.
The kernel layer 203 comprises a kernel and a functional safe partition, processes of a common application run in the kernel, processes of the functional safe application run in the functional safe partition, and in order to ensure that the functional safe partition is compatible with the ecology of the kernel, interaction can be performed between the functional safe partition and the kernel, and the kernel assists in completing operations of some functional safe applications.
The kernel layer 203 may include a pressure quiesce information (pressure stall information, PSI) kernel module, among others. The pressure quiesce information (pressure stall information, PSI) kernel module of kernel layer 203 is associated with the pressure quiesce information (pressure stall information, PSI) module of application framework layer 202.
The hardware abstraction layer 204 is software located between the operating system kernel and the hardware circuitry, and is typically used to abstract the hardware to implement the interaction of the operating system with the hardware circuitry at the logic level. In an embodiment of the present application, the hardware abstraction layer 204 may include a camera hardware abstraction layer (camera Hardware Abstraction Layer, camera HAL) that enables camera applications to interact with the image sensor at a logical layer.
It should be noted that, other contents may be included in the application layer 201, the application framework layer 202, the kernel layer 203, and the hardware abstraction layer 204, which are not limited in detail herein.
In the following, the electronic device is taken as an example, and the moving effect picture display method provided by the embodiment of the application is described in detail with reference to the accompanying drawings and application scenes.
Referring to fig. 7, fig. 7 is a flowchart illustrating a moving-effect picture display method according to an embodiment of the application.
As shown in fig. 7, the moving effect picture display method provided by the present application may include:
s21, the fingerprint service module registers a fingerprint monitoring function with the fingerprint identification module.
S22, the fingerprint identification module registers the fingerprint monitoring function with the fingerprint identification trusted application module.
Wherein a fingerprint recognition (fingerprint) module is a software module in a hardware abstraction of the electronic device. The fingerprinting trusted application module is a software module in a secure execution environment system (trusted execution environment, TEE) of the electronic device.
The fingerprint recognition module is a module for performing a fingerprint recognition function. The fingerprint identification trusted application module is a module for monitoring fingerprint information and verifying and matching fingerprint images.
Among these, the secure execution environment system (trusted execution environment, TEE) is a combined system of hardware and software for creating a secure execution environment to protect critical data and sensitive operations. TEE provides a trusted execution environment in which applications may run while preventing malware, attackers, or privileged code from interfering with or damaging them.
If the electronic device has already opened the fingerprint unlocking function, after the electronic device is started or restarted each time, the electronic device is in a state of being on-screen and locked, the fingerprint service module can execute S21 in the state, register the fingerprint monitoring on the fingerprint identification module, and after the fingerprint service module registers the monitoring fingerprint function on the fingerprint identification module, the fingerprint identification module can execute S22, register the monitoring fingerprint function on the fingerprint identification trusted application module.
That is, the fingerprint service module can register fingerprint monitoring on the fingerprint identification trusted application module through the fingerprint identification module, so that the fingerprint identification module has the function of monitoring the fingerprint image.
S23, the fingerprint identification trusted application module sends a monitoring message to the fingerprint identification module.
S24, the fingerprint identification module sends a monitoring message to the fingerprint service module.
The monitoring message is used for indicating that the monitoring fingerprint function is started successfully.
Based on the above, after the fingerprint service module registers the monitoring fingerprint function with the fingerprint identification trusted application module through the fingerprint identification module, the fingerprint identification trusted application module sends a monitoring message to the fingerprint service module through the fingerprint identification module, so that the fingerprint service module can conveniently determine that the starting of the monitoring fingerprint function of the electronic equipment is successful.
S25, the fingerprint service module reads the fingerprint moving effect picture from the memory 1 and decodes the fingerprint moving effect picture to obtain fingerprint moving effect pixel data.
The fingerprint moving effect picture is a picture corresponding to the moving effect picture.
In some embodiments, the fingerprint moving picture is pre-stored in the memory 1 and can be read when required.
In some embodiments, memory 1 is a universal flash memory (universal flash storage, UFS).
In other embodiments, the memory 1 is an embedded multimedia memory card (embedded multi media card, EMMC).
The memory 1 has the characteristics of being not easy to lose, and the like, and when the electronic equipment is restarted or turned off, the data in the memory 1 are not cleared, so that the electronic equipment can be stored for a long time.
It will be appreciated that pictures are typically stored in a compressed format to reduce storage space and facilitate transmission. Therefore, before displaying or processing a picture, it is necessary to decode the picture first, converting the picture from a compressed format to a format that can be used for processing and display, i.e., a readable format.
In some embodiments, the decoding process may include:
decompressing the fingerprint moving effect picture to obtain the pixel data of the fingerprint moving effect picture.
Based on the pixel data, it is stored in a grid or matrix format.
The pixel data is composed of orderly arranged pixel points, and each pixel point is composed of a plurality of color channels, such as R, G, B three color channels.
Wherein the set of pixel data includes pixel data of a fingerprint moving effect picture corresponding to the set of pixel data.
For example, when the number of pictures in the fingerprint moving effect picture is 24, the number of pixel data in the decoded fingerprint moving effect pixel data is 24 groups.
Based on the above, after the fingerprint monitoring function is successfully registered, the fingerprint service module reads the fingerprint moving effect picture from the memory 1 and decodes the fingerprint moving effect picture, so that fingerprint moving effect pixel data corresponding to the fingerprint moving effect picture can be obtained, and data preparation is performed for the subsequent fingerprint service module to display the moving effect picture according to the fingerprint moving effect pixel data.
S26, the fingerprint service module stores the decoded fingerprint dynamic effect pixel data into the memory 2.
Based on S25, the fingerprint service module may obtain the fingerprint moving effect pixel data, and thus, the fingerprint service module may store the fingerprint moving effect pixel data in the memory 2.
The fingerprint moving effect pixel data comprises a plurality of groups of pixel data, one group of pixel data corresponds to one fingerprint moving effect picture, and one group of pixel data comprises pixel data of one fingerprint moving effect picture corresponding to the one group of pixel data.
In some embodiments, the memory 2 is a random-access memory (RAM).
The memory 2 has the characteristics of being volatile, and the like, and when the electronic device is restarted or turned off, the data in the memory 2 is cleared.
And S27, when the contact operation is received, the fingerprint sensor sends an identification message to the fingerprint identification module.
S28, the fingerprint identification module sends an identification message to the fingerprint service module.
The fingerprint sensor may be disposed in the electronic device in various manners.
In some embodiments, the fingerprint sensor is located below and electrically connected to a display screen of the electronic device.
The fingerprint sensor is used for collecting fingerprint images; when the fingerprint sensor is positioned below the display screen of the electronic device, the fingerprint sensor can receive a contact operation when a user contacts the corresponding position of the display screen, which is connected with the fingerprint sensor, so that the fingerprint sensor starts to collect fingerprint images of the user.
The fingerprint sensor may be an optical fingerprint sensor, a capacitive fingerprint sensor, an ultrasonic fingerprint sensor or an inductive fingerprint sensor.
The application is not limited to the type of fingerprint sensor.
Wherein the identification information is used for indicating the start of fingerprint identification. The identification message may be an interrupt event.
When the fingerprint sensor is positioned below the display screen of the electronic device, a user can not only collect fingerprint images but also receive contact operation when touching the corresponding position of the display screen, which is electrically connected with the display screen, of the fingerprint sensor, so that the fingerprint sensor sends identification information to the fingerprint identification module according to the contact operation, and the fingerprint identification module sends the identification information to the fingerprint service (fingerprint service) module after receiving the fingerprint identification information.
Thus, the fingerprint service module can start to display the dynamic effect picture after receiving the identification message.
S29, the fingerprint service module reads fingerprint dynamic effect pixel data from the memory 2.
Based on S26, the fingerprint service module has already stored the fingerprint moving effect pixel data in the memory 2, so the fingerprint service module needs to read the fingerprint moving effect pixel data from the memory 2, so as to prepare data for the fingerprint service module to display the moving effect picture on the display screen of the electronic device according to the fingerprint moving effect pixel data.
S30, the fingerprint service module displays the dynamic effect picture according to the fingerprint dynamic effect pixel data.
Based on S29, after receiving the identification message, the fingerprint service module may read the fingerprint moving effect pixel data from the memory 2, so that a moving effect screen can be displayed according to the fingerprint moving effect pixel data.
For example, after the fingerprint service module reads the fingerprint moving effect pixel data, each group of pixel data in the fingerprint moving effect pixel data can be respectively drawn on the canvas to obtain a plurality of pictures corresponding to the fingerprint moving effect picture, and then the drawn plurality of pictures are sequentially displayed to form the effect of dynamic display image.
Optionally, after receiving the identification message, the fingerprint service module may further determine whether fingerprint moving effect pixel data exists in the memory 2, so that, when the fingerprint service module reads the fingerprint moving effect pixel data from the memory 2, and displays a moving effect picture according to the fingerprint moving effect pixel data; when the fingerprint service module does not exist, the fingerprint service module reads the fingerprint moving effect picture from the memory 1, decodes the fingerprint moving effect picture, stores the decoded fingerprint moving effect pixel data into the memory 2, reads the fingerprint moving effect pixel data from the memory 2, and displays the moving effect picture according to the fingerprint moving effect pixel data.
S31, the fingerprint sensor sends the fingerprint image to the fingerprint identification trusted application module.
After the fingerprint image is collected, the fingerprint sensor can send the fingerprint image to the fingerprint identification trusted application module, so that the fingerprint identification trusted application module can conveniently verify and match the fingerprint according to the fingerprint image after receiving the fingerprint image.
S32, the fingerprint identification trusted application module verifies and matches the fingerprint image.
After the fingerprint image is collected, the fingerprint sensor sends the fingerprint image to the fingerprint identification trusted application module, so that the fingerprint identification trusted application module can perform fingerprint verification and matching according to the fingerprint image after receiving the fingerprint image.
In some embodiments, fingerprint authentication and matching by the fingerprint identification trusted application module from the fingerprint image comprises the steps of:
and step 1, extracting fingerprint characteristics according to the fingerprint image acquired by the fingerprint sensor.
And 2, comparing the extracted fingerprint features with the fingerprint features of the pre-stored fingerprint images to obtain a similarity value.
And 3, judging whether the fingerprint features corresponding to the collected fingerprint images are matched with the stored fingerprint features of the fingerprint images according to the similarity values.
Step 4, if the matching is successful, the unlocking is successful, and the user can access the functions and data of the electronic equipment by using the electronic equipment; if the matching fails, the electronic device can refuse to unlock and remind the user to try to unlock again, or remind the user to unlock by adopting other unlocking modes, such as passwords or patterns.
The application does not limit the fingerprint verification and matching process.
S33, the fingerprint identification trusted application module sends a fingerprint identification result to the fingerprint identification module.
S34, the fingerprint identification module sends a fingerprint identification result to the fingerprint service module.
Based on S32, the fingerprint identification trusted application module performs fingerprint verification and matching according to the fingerprint image, and after the fingerprint verification and matching are finished, the fingerprint identification result is sent to the fingerprint service module.
If the similarity between the fingerprint features of the fingerprint image acquired by the fingerprint sensor and the fingerprint features of the pre-stored fingerprint image is greater than or equal to a similarity threshold, the fingerprint identification result sent by the fingerprint identification trusted application module to the fingerprint service module is used for indicating that the fingerprint identification is successful.
If the similarity between the fingerprint features of the fingerprint image acquired by the fingerprint sensor and the fingerprint features of the pre-stored fingerprint image is smaller than a similarity threshold, the fingerprint identification result sent by the fingerprint identification trusted application module to the fingerprint service module is used for indicating that the fingerprint identification fails.
And S35, when the received fingerprint identification result shows that the fingerprint identification is successful, the fingerprint service module closes the function of monitoring the fingerprint.
When the received fingerprint identification result shows that the fingerprint identification is successful, the fingerprint service module closes the function of monitoring the fingerprint, so that the power consumption of the electronic equipment can be reduced, and the electric quantity of the electronic equipment can be saved.
Optionally, S35 may include:
after the moving effect picture is displayed and the fingerprint identification is successful, the fingerprint service module can compress the fingerprint moving effect pixel data in the memory 2.
Therefore, the pressure of the memory 2 of the electronic equipment can be released, the performance of the electronic equipment can be prevented from being reduced, the running programs are prevented from being crashed, and the performance and the stability of the electronic equipment system are ensured.
In some embodiments, the fingerprint service module may perform object-level compression on the fingerprint motion pixel data in the memory 2, and in this step, the fingerprint service module needs to perform object-level decompression (object-level compression) on the fingerprint motion pixel data in the memory 2.
Wherein object level decompression is to decompress each compressed object independently, rather than decompressing the entire file; for example, each set of pixel data is decompressed independently.
The object-level decompression technique requires each object to be stored separately, provides a more flexible access method, simultaneously avoids unnecessary performance consumption of the electronic device caused by decompression of the whole file, and can improve efficiency and flexibility.
In some embodiments, the process of object-level compression of the fingerprint active pixel data in memory 2 by the fingerprint service module may include:
1. and determining a virtual address corresponding to the physical address stored in the memory 2 and the size of the storage space occupied by the fingerprint dynamic effect pixel data.
2. And compressing the fingerprint effective pixel data according to the virtual address and the size of the storage space occupied by the fingerprint effective pixel data through a recovery (reclaim) node of the system process.
It should be appreciated that the virtual address corresponds to the actual storage location of a physical page (physical address) in memory 2.
The application framework layer comprises a java layer and a native layer. The java layer includes a graphics processing (graphics) module. The native layer includes a graphic image processing library (libhwui).
In some embodiments, in conjunction with fig. 8, the fingerprint service module compresses the fingerprint active pixel data in the memory 2, which may specifically include:
The fingerprint service module can call a graphics processing (graphics) module of the java layer, so that the graphics processing module calls a graphics image processing library of the active layer based on a recovery (reclaim) interface (system function), then the graphics image processing library calls a proc/pid/reclaim interface, and the proc/pid/reclaim interface calls a fs/proc interface of a kernel (kernel) layer, and compression of fingerprint dynamic pixel data in the memory 2 is realized by adopting the memory management module.
The RECLAIM interface can call proc/pid/RECLAIM interface to compress fingerprint dynamic pixel data in the memory 2 by recovering the reclaim_range function provided by the RECLAIM interface.
Based on the above, the fingerprint service module compresses the fingerprint effective pixel data stored in the memory 2, so that the pressure of the memory 2 can be reduced; further, if the fingerprint service module performs object-level compression on the fingerprint motion effect pixel data stored in the memory 2, the pressure of the memory 2 can be reduced to a greater extent.
According to the moving effect picture display method, when the electronic equipment is started or restarted and is in a bright screen locking state, the fingerprint service module can register a monitoring fingerprint function, then the fingerprint service module acquires fingerprint moving effect pictures from the memory 1, after decoding, the decoded fingerprint moving effect pixel data are stored in the memory 2, and the fingerprint moving effect pixel data are read from the memory 2, so that when the fingerprint service module receives an identification message, the moving effect picture can be displayed according to the fingerprint moving effect pixel data in the memory 2, after the display is finished, the fingerprint moving effect pixel data in the memory 2 are not deleted, and therefore, when the fingerprint service module receives the identification message next time, the fingerprint service module determines that the fingerprint moving effect pixel data exist in the memory 2, and the electronic equipment can display the moving effect picture directly according to the fingerprint moving effect pixel data in the memory 2, so that the decoding time is saved, the power consumption of the electronic equipment is reduced, and the electric quantity consumption of the electronic equipment is reduced.
In a possible implementation manner, the electronic device is taken as an example, and the moving effect picture display method provided by the embodiment of the application is described in detail with reference to the accompanying drawings.
Referring to fig. 9, fig. 9 is a flowchart illustrating a moving-effect picture display method according to an embodiment of the application.
As shown in fig. 9, the moving effect picture display method provided by the present application may include:
s41, the fingerprint service module registers a monitoring screen-off event with the power management service module.
The fingerprint service (fingerprint service) module and the pressure power management service (power manager service, PMS) module are software modules in an application framework layer (FWK) of the electronic device.
The fingerprint service module is used for processing fingerprint identification functions; the power management service module is a module for managing power and electronic device status.
The fingerprint service module registers a monitoring screen-off event on the power management service module, so that the power management service module has a function of sending a screen-off message when monitoring that the electronic equipment is off screen.
The manner in which the fingerprint service module registers the monitor off-screen event on the power management service module may include: the fingerprint service module registers the off-screen broadcast on the power management service module, or the fingerprint service module registers the off-screen event callback function on the power management service module.
In the process of starting or restarting the electronic equipment each time, the fingerprint service module needs to execute S51, and a monitoring screen-off event is registered on the power management service module, so that the power management service module can inform the fingerprint service module when monitoring that the display screen of the electronic equipment is off, and the fingerprint service module can execute corresponding operation.
Specifically, after the fingerprint service module registers a monitoring screen-off event on the power management service module, if the electronic equipment is in screen-off state, the power management service module can send a screen-off message to the fingerprint service module, and after the fingerprint service module receives the screen-off message, the fingerprint service module can execute corresponding operation.
Therefore, the fingerprint service module registers monitoring screen-off events on the power management service module, so that the fingerprint service module can acquire the screen-off events of the electronic equipment in time, and the fingerprint service module can conveniently perform corresponding operations according to the screen-off events.
Wherein S41 is an optional step.
S42, when the display screen of the electronic equipment is turned off, the power management service module sends an off-screen message to the fingerprint service module.
The screen-off message is used for indicating that the display screen of the electronic equipment is off.
In some embodiments, when the electronic device is started or restarted, the fingerprint service module registers a monitor screen-off event on the power management service module, and when the power management service module monitors that the display screen of the electronic device is off, the power management service module can send a screen-off message to the fingerprint service module to inform the fingerprint service module that the electronic device is off.
In other embodiments, the electronic device includes an off-screen application, and the off-screen application is capable of sending an off-screen message to the fingerprint service module to notify the fingerprint service module that the electronic device has been off-screen when the electronic device is off-screen.
The first screen-off of the electronic device may occur before the fingerprint sensor receives the contact operation performed by the user on the electronic device, and the fingerprint sensor sends the identification message to the fingerprint service module through the fingerprint identification module, or may occur after the fingerprint sensor receives the contact operation performed by the user on the electronic device, and the moving effect picture is displayed.
If the display of the moving effect picture is finished and the fingerprint identification is successful, the fingerprint service module compresses the fingerprint moving effect pixel data in the memory 2, and then the fingerprint service module can directly decompress the fingerprint moving effect pixel data after receiving the screen-off message.
Optionally, S42 may further include:
s43, the fingerprint service module judges whether the function of monitoring the fingerprint is registered.
If the electronic equipment opens the fingerprint unlocking function and the electronic equipment screen-off occurs after the moving effect picture is displayed, the electronic equipment already executes the steps S21-S24 and the steps S25-S35; since the fingerprint service module has turned off the listening fingerprint function in S35, then the fingerprint service module determines that the listening fingerprint function is not registered at this time.
If the electronic equipment does not open the fingerprint unlocking function and the electronic equipment screen-off occurs after the dynamic effect picture is displayed, the electronic equipment does not execute the steps S21-S35; then the fingerprint service module determines that the listening fingerprint function is unregistered at this point. If the electronic equipment opens the fingerprint unlocking function and the electronic equipment screen-off occurs before the contact operation is received, the electronic equipment executes the steps S21-S24; then the fingerprint service module determines that the listening fingerprint function is registered at this point.
If the electronic equipment does not open the fingerprint unlocking function and the electronic equipment screen-off occurs before the contact operation is received, the electronic equipment does not execute the steps S21-S24; then the fingerprint service module determines that the listening fingerprint function is unregistered at this point.
Therefore, the fingerprint service module needs to determine whether the function of monitoring the fingerprint is registered.
When the monitoring fingerprint function is registered, the fingerprint service module executes S48; when the monitor fingerprint function is not registered, the fingerprint service module performs S48 after S44-S47.
S44, the fingerprint service module registers the fingerprint monitoring function with the fingerprint identification module.
S45, the fingerprint identification module registers the fingerprint monitoring function with the fingerprint identification trusted application module.
S46, the fingerprint identification trusted application module sends a monitoring message to the fingerprint identification module.
S47, the fingerprint identification module sends a monitoring message to the fingerprint service module.
The implementation of S44-S47 is similar to the implementation of S21-S24 in the embodiment shown in fig. 7, and will not be described here again.
S48, the fingerprint service module judges whether fingerprint dynamic effect pixel data exist in the memory 2.
If the electronic equipment does not open the fingerprint unlocking function, after the electronic equipment is started or restarted, the electronic equipment does not execute the steps S21-S35; then the fingerprint service module determines that no fingerprint active pixel data is present in the memory 2.
If the electronic equipment opens the fingerprint unlocking function, after the electronic equipment is started or restarted, the electronic equipment executes the steps S21-S35; then the fingerprint service module determines that fingerprint active pixel data is present in the memory 2.
Therefore, the fingerprint service module needs to determine whether the fingerprint active pixel data exists in the memory 2.
When the fingerprint dynamic effect pixel data does not exist in the memory 2, the fingerprint service module executes S49-S51; when the fingerprint dynamic pixel data exists in the memory 2, the fingerprint service module performs S51.
And S49, the fingerprint service module reads the fingerprint moving effect picture from the memory 1 and decodes the fingerprint moving effect picture to obtain fingerprint moving effect pixel data.
S50, the fingerprint service module stores the decoded fingerprint dynamic effect pixel data into the memory 2.
The implementation of S49 and S50 is similar to the implementation of S25 and S26 in the embodiment shown in fig. 7, and will not be described here again.
And S51, when the fingerprint dynamic effect pixel data in the memory 2 is compressed data, the fingerprint service module decompresses the fingerprint dynamic effect pixel data.
The reading of the fingerprint moving effect pixel data from the memory 2 is similar to the implementation of S30 in the embodiment shown in fig. 7, and will not be described herein.
Based on the above description, after the display of the moving-effect picture is finished and the fingerprint identification is successful, the fingerprint service module can compress the fingerprint moving-effect pixel data in the memory 2, so that when the screen-off message is received, if the fingerprint service module determines that the fingerprint moving-effect pixel data is compressed data, the fingerprint moving-effect pixel data needs to be decompressed.
In some embodiments, the fingerprint service module can compress the fingerprint effective pixel data in the memory 2 to a memory page of the memory 2, so that when the display screen of the electronic device is turned off, the fingerprint service module can scan the virtual address and the occupied storage space corresponding to the compression of the fingerprint effective pixel data in the memory 2 through the mlock interface (system function), and trigger the decompression of the fingerprint effective pixel data.
Continuing to combine with fig. 8, the fingerprint service module decompresses the fingerprint dynamic effect pixel data through the mlock interface, which may specifically include: the fingerprint service module can call a graphics processing (graphics) module of the java layer, so that the graphics processing module calls a graphics image processing library of the active layer based on a memory lock (mlock) interface (system function), then the graphics image processing library calls the mlock interface, and then a memory management module of the kernel (kernel) layer is called through the mlock interface to lock a physical page corresponding to fingerprint dynamic pixel data in the memory 2.
In the locking process, the memory management module of the kernel layer scans the physical page and the size of the occupied storage space in the memory 2 corresponding to the virtual address of the fingerprint effective pixel data, scans the vma function corresponding to the physical page in the memory 2 corresponding to the fingerprint effective pixel data, and decompresses the data in the exchange partition onto the physical page if the data mapped by the vma function is found in the exchange partition, thereby actively triggering the decompression of the fingerprint effective pixel data.
Based on the above description, after the electronic device is off-screen, the fingerprint service module decompresses the fingerprint active pixel data through the mlock interface, so that in the off-screen state, the fingerprint active pixel data is always stored in the memory 2 and is in an uncompressed state, and then when the fingerprint service module receives the identification message, the fingerprint service module can directly read the fingerprint active pixel data in the memory 2 without passively triggering to decompress the fingerprint active pixel data from the switch (swap) partition of the memory 2. Meanwhile, as the fingerprint dynamic effect pixel data is locked (lock) in the memory 2 through the lock interface, the fingerprint dynamic effect pixel data can be prevented from being compressed again by the fingerprint service module after the screen is turned off.
In some embodiments, the fingerprint service module is capable of unlocking the locked fingerprint active pixel data via the munlock interface after each active screen display is completed.
Referring to fig. 8, the fingerprint service module unlocks the locked fingerprint active pixel data through the munlock interface, which may specifically include:
the fingerprint service module can call a graphics processing (graphics) module of a java layer, so that the graphics processing module calls a graphics image processing library of a native layer based on a memory lock (Munlock) interface (system function), then the graphics image processing library calls the Munlock interface, and then a memory management module of a kernel (kernel) layer is called through the Munlock interface to realize unlocking of a physical page corresponding to the locked fingerprint effective pixel data, and after unlocking, compression of the fingerprint effective pixel data can be triggered again when the pressure level of the memory 2 is high.
If the fingerprint service module executes S41, S21 to S35 are executed after S41. If the off-screen event of the electronic device occurs after S35, S42-S51 are performed after S35.
For example, the electronic device is started or restarted at 10 point 48 minutes 0 seconds, S41 is executed, a monitor off event is registered, S21-S24 is executed at 10 point 48 minutes 15 seconds, a monitor fingerprint function is registered, if the user performs fingerprint unlocking at 10 point 48 minutes 30 seconds, the fingerprint service module executes S27-S34, and when the fingerprint identification result in S34 indicates that the fingerprint identification is successful, S35 is executed, and the monitor fingerprint function is closed; after a period of time, at point 10 and 52 minutes and 55 seconds, the electronic equipment is turned off, S42 is executed, after receiving the off-screen message, the fingerprint service module executes S43, if the unregistered monitoring fingerprint function is determined, S44-S47 is executed, S48 is executed, if yes, S51 is executed, and if no, S49-S51 is executed; if it is determined that the monitor fingerprint function is registered, S48 is executed, if yes, S51 is executed, and if no, S49-S51 are executed.
According to the moving effect picture display method, before the screen is turned off, the electronic equipment possibly registers a monitoring fingerprint function, fingerprint moving effect pixel data obtained by decoding the fingerprint moving effect picture in the memory 1 is stored in the memory 2, namely the electronic equipment registers the monitoring fingerprint function; it is also possible to turn off the monitor fingerprint function so that the monitor fingerprint function is not registered; the snoop fingerprint function may not have been registered; then, when the electronic device is off-screen, the off-screen function may be registered, or the off-screen function may not be registered, and the fingerprint active pixel data may not exist in the memory 2, or may exist in the memory; therefore, when the monitor fingerprint function is not registered and the fingerprint moving effect pixel data does not exist in the memory 2, the monitor fingerprint function is registered, and the fingerprint moving effect pixel data obtained by decoding the fingerprint moving effect picture in the memory 1 is stored in the memory 2, so that the moving effect picture is ready for data to be displayed when the contact operation is received next time.
In addition, when the pressure level of the memory 2 is greater than the threshold 1, the fingerprint service module needs to compress the fingerprint dynamic effect pixel data, so that the fingerprint dynamic effect pixel data needs to be decompressed; when the electronic equipment is off-screen, the fingerprint dynamic effect pixel data is decompressed, compared with when the electronic equipment is on-screen, the fingerprint dynamic effect pixel data is decompressed, so that the power consumption of the electronic equipment can be reduced, and the power consumption of the electronic equipment can be reduced.
In a possible implementation manner, the electronic device is taken as an example, and the moving effect picture display method provided by the embodiment of the application is described in detail with reference to the accompanying drawings.
Referring to fig. 10, fig. 10 is a flowchart illustrating a moving-effect picture display method according to an embodiment of the application.
As shown in fig. 10, the moving effect picture display method provided by the present application may include:
s61, the fingerprint service module registers a memory monitoring callback function with the pressure pause information module.
If the fingerprint service module executes both S41 and S61, the execution order of S41 and S61 is not sequential, and may be sequentially executed or may be executed simultaneously.
The pressure pause information (pressure stall information, PSI) module is a software module in an application framework layer (FWK) of the electronic device.
The pressure dwell information module is a module for collecting and recording pressure conditions of the memory 2.
Specifically, the pressure pause information module provides a method for evaluating the pressure of the memory (memory) 2, quantifies the interruption of task execution caused by insufficient memory resources of the memory 2, counts the time for waiting for memory allocation of tasks in the system, and is used for measuring the pressure condition of the memory 2. The longer the task waits for the pause time caused by memory allocation, the greater the pressure of the memory 2; the shorter the pause time caused by the task waiting for memory allocation, the less pressure the memory 2 will be. The PSI module opens an interface to the fingerprint service module through the file system node. For example, the fingerprint service module writes "name 1500001000000" to the/proc/pressure/memory node, and may register a memory name event with a statistical time period of 1s and a pressure threshold of 150 ms.
The memory monitor callback function is a specific function, and is used for monitoring and processing the pressure condition of the memory 2.
After the fingerprint service module registers the memory monitoring callback function with the pressure pause information module, the pressure pause information module can reflect the pressure state of the memory 2 through two indexes of a name and full.
The name index is used to represent the percentage of time that one or more tasks have been stalled during a period of time due to waiting for memory allocation of the memory 2. The full indicator is used to indicate the percentage of time that all tasks in the non-idle state have been stalled by waiting for memory allocation of memory 2.
For example, in fig. 11, task a is running without a pause in 60 seconds nearest to the current time, while task B spends 30 seconds waiting for memory allocation during running due to the memory shortage of memory 2, the value of the name is 50 seconds, or 50%, and the value of full is 0.
For another example, in fig. 12, within 60 seconds nearest to the current time, the task B waits for the memory allocation time to be 30 seconds, the task a waits for the memory allocation time to be 10 seconds, and the waiting times of the task a and the task B overlap due to the memory shortage of the memory 2. During this overlapping period of 10 seconds, task a and task B are both waiting for memory allocation, the value of the name is 50 seconds, or 50%, the value of full is 10 seconds, or 10/60=16.66%.
For another example, in fig. 13, in 60 seconds nearest to the current time, the tasks a and B are running for 40 seconds in total, the name event time is 40 seconds in total, the overlapping time period is a full event, and the total time period is 15 seconds, the value of the name is 40 seconds, or 40/60=66.66%, and the value of the full is 15 seconds, or 15/60=25%.
In some embodiments, the pressure dwell information module monitors the pressure condition of the memory 2 by a pressure threshold, wherein the pressure condition of the memory 2 can be monitored by writing a pressure threshold to a/proc/pressure/memory node in the following format:
<some|full><stall amount in us><time window in us>。
and in a preset time period, when the value of the name and/or the full value is greater than the corresponding pressure threshold value, the pressure pause information module can report the pressure level of the memory 2 to the fingerprint service module according to the pressure level corresponding to the name and/or the full value.
The pressure level of the memory 2 is used to indicate the magnitude of the storage pressure of the memory 2, and the higher the pressure level, the greater the pressure of the memory 2, and the lower the pressure level, the lower the pressure of the memory 2.
For example, the preset time period may be 500ms-10s.
For example, in a time period of 1000ms, when the pressure pause information module counts that the value of the name of the memory 2 is greater than the pressure threshold value of 70ms (7%), reporting a Low memory pressure waterline, that is, reporting a pressure level of 1; when the value of the name is greater than the pressure threshold value by 100ms (10%), reporting the Medium memory pressure waterline, namely reporting the pressure grade as grade 2; and when the full value is greater than the pressure threshold value of 70ms (7%), reporting the Critical memory pressure waterline, namely reporting the pressure grade to be equal to grade 3.
Based on this, in each start-up or restarting process of the electronic device, the fingerprint service module needs to execute S21, registers the memory monitoring callback function on the pressure pause information module, that is, the fingerprint service module registers the address of the memory monitoring callback function into the memory monitoring mechanism of the pressure pause information module, so as to prepare for the pressure pause information module to monitor the pressure condition of the memory 2 through the pressure pause information kernel module.
And S62, when the value of the name and/or the full value is greater than the corresponding pressure threshold value, the pressure pause information kernel module sends pressure information to the pressure pause information module.
The kernel module of the pressure pause information (pressure stall information, PSI) is a software module in the kernel layer of the electronic device. The pressure quiescing information kernel module is associated with a pressure quiescing information module, which is capable of monitoring the pressure condition of the memory 2 through the pressure quiescing information kernel module.
Wherein the pressure information comprises the pressure level of the memory 2.
Since the pressure of the memory 2 may vary, it is necessary to monitor the pressure level of the memory 2, so that when the pressure level of the memory 2 is high, the data stored in the memory 2 is processed accordingly.
That is, when the value of the name and/or the full value is greater than the corresponding pressure threshold, the pressure quiescing information kernel module sends pressure information to the pressure quiescing information module to inform the pressure quiescing information module of the pressure condition of the memory 2 at the current time.
Based on the above description, if after the electronic device is started or restarted each time, the fingerprint service module registers the memory monitoring callback function on the pressure pause information module, and the pressure pause information module can monitor the pressure level of the memory 2 through the pressure pause information kernel module, and each time the value of the name and/or the full value is greater than the corresponding pressure threshold value, the pressure pause information kernel module sends pressure information to the pressure pause information module, so that the pressure pause information module can report the pressure information to the fingerprint service module.
And S63, the pressure pause information module sends pressure information to the fingerprint service module.
Based on S62, the pressure pause information module can receive the pressure information sent by the pressure pause information kernel module, so that the pressure pause information module continues to send the pressure information to the fingerprint service module, that is, reports the pressure condition of the memory 2, and can prepare data for the fingerprint service module to judge whether the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information.
The pressure pause information module needs to send pressure information to the fingerprint service module after receiving the pressure information each time.
Based on the description of S61, since the fingerprint service module registers the memory monitoring callback function on the pressure pause information module after the electronic device is started or restarted each time, when the value of the name and/or the full value is greater than the corresponding pressure threshold, S62 is executed, the pressure pause information module is notified according to the pressure level of the memory 2, and S23 is executed by the pressure pause information module, so that the fingerprint service module can execute the corresponding operation.
Optionally, S35 may further include:
s64, the fingerprint service module judges whether the pressure level of the memory 2 is greater than a threshold value 1.
The pressure level of the memory 2 in the electronic device may be varied by a number of factors such that the pressure level of the memory 2 is greater than the threshold 1.
When the pressure level of the memory 2 is greater than the threshold 1, the performance of the electronic device is reduced, and the application program running on the electronic device is crashed or abnormally exited, so that the electronic device needs to reduce the pressure of the memory 2 and improve the performance and stability of the system of the electronic device, for example, compress the data in the memory 2, and the fingerprint service module executes S40.
When the pressure level of the memory 2 is less than or equal to the threshold 1, the performance of the electronic device is in a normal state, and thus the fingerprint service module does not perform any operation, i.e. does not perform compression of the fingerprint active pixel data.
The threshold 1 is preset, and the threshold 1 may be used to avoid the condition that the pressure level of the memory 2 is too high, so that when the pressure level of the memory 2 is high, the fingerprint service module compresses the fingerprint effective pixel data in the memory 2 to reduce the pressure of the memory 2.
For example, the pressure level in the pressure information received by the fingerprint service module is level 1 (Low memory pressure watermark), and the threshold 1 is level 2 (Medium memory pressure watermark), and then the pressure level is less than the threshold 1.
For another example, the fingerprint service module receives the pressure information with a pressure level of 3 (Critical memory pressure pipeline) and a threshold value of 1 (Medium memory pressure pipeline), and then the pressure level is greater than the threshold value of 1.
For another example, the fingerprint service module receives the pressure information with a pressure level of 2 (Medium memory pressure pipeline) and a threshold value of 1 with a pressure level of 2 (Medium memory pressure pipeline), and then the pressure level is equal to the threshold value of 1.
It will be appreciated that the fingerprint service module may receive the pressure information before or after receiving the fingerprint identification result.
The fingerprint service module receives pressure information before receiving the fingerprint identification result can be divided into two cases:
in the case 1, before the fingerprint service module does not receive the identification message sent by the fingerprint sensor, the fingerprint service module receives the pressure information sent by the pressure pause information module; i.e. S62-S63 are performed before S27 is performed.
In the case 2, the fingerprint service module receives the pressure information sent by the pressure pause information module in the processes of receiving the identification information sent by the fingerprint sensor, starting to display the dynamic effect picture and displaying the dynamic effect picture; i.e., in the process of executing S27-S30, S62-S63 are executed.
In some embodiments, if the fingerprint service module receives the pressure information before receiving the fingerprint identification result, the fingerprint service module can determine whether the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information received last time before receiving the fingerprint identification result when the fingerprint service module receives the fingerprint identification result and the fingerprint identification result is used for indicating that the fingerprint identification is successful.
Thus, when the fingerprint service module determines that the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information, the fingerprint service module performs S65, otherwise, does not perform any operation.
For example, the electronic device is started or restarted at 10 point 48 minutes 0 seconds, S61 is executed, the memory monitor callback function is registered, S21-S24 is executed at 10 point 48 minutes 15 seconds, the monitor fingerprint function is registered, the pressure level of the memory 2 changes at 10 point 48 minutes 30 seconds, and the fingerprint identification module executes S62-S63, so that the fingerprint identification module receives the pressure information; if the user performs fingerprint unlocking at 10 points 48 minutes 50 seconds, the fingerprint service module performs S27-S34, and if the fingerprint recognition result in S34 indicates that the fingerprint recognition is successful, the fingerprint recognition module performs S64 according to the pressure information, and if it is determined that the pressure level of the memory 2 is greater than the threshold 1, the fingerprint service module performs S65.
It should be noted that, if the fingerprint service module receives the pressure information before receiving the fingerprint identification result, when the fingerprint service module receives the fingerprint identification result and the fingerprint identification result indicates that the fingerprint identification fails, the fingerprint service module does not perform any operation, that is, does not perform S65.
It will be understood that when the fingerprint recognition result received by the fingerprint service module indicates that fingerprint recognition fails, the user will typically unlock the fingerprint again, if the fingerprint service module executes S65 at this time, when it is determined that the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information received by the fingerprint service module before the fingerprint recognition result is received, the fingerprint effective pixel data is compressed, and then when the user unlocks the fingerprint again, the pixel data in the memory 2 is in a compressed state and is not decompressed, and the effective picture cannot be displayed according to the pixel data in the memory 2.
For example, the electronic device is started or restarted at 10 point 48 minutes 0 seconds, S61 is executed, the memory monitor callback function is registered, S21-S24 is executed at 10 point 48 minutes 15 seconds, the monitor fingerprint function is registered, the pressure level of the memory 2 changes at 10 point 48 minutes 30 seconds, and the fingerprint identification module executes S62-S63, so that the fingerprint identification module can receive the pressure information; if the user performs fingerprint unlocking at 10 points 48 minutes 50 seconds, the fingerprint service module executes S27-S34, and when the fingerprint identification result in S34 indicates that the fingerprint identification fails, the fingerprint service module does not execute S64.
In other embodiments, after the fingerprint recognition result received by the fingerprint service module indicates that the fingerprint recognition is successful, the pressure information is received after a period of time, and the fingerprint service module determines, at the moment of receiving the pressure information, whether the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information.
Thus, when the fingerprint service module determines that the pressure level of the memory 2 is greater than the threshold 1 according to the pressure information, the fingerprint service module performs S65, otherwise, does not perform any operation.
For example, the electronic device is started or restarted at 10 point 48 minutes 0 seconds, S61 is executed, the memory monitor callback function is registered, S21-S24 is executed at 10 point 48 minutes 15 seconds, the monitor fingerprint function is registered, if the user performs fingerprint unlocking at 10 point 48 minutes 30 seconds, the fingerprint service module executes S27-S34, and when the fingerprint identification result indicates that the fingerprint identification is successful in S34, the user can start to use the electronic device; after a period of time, the pressure level of the memory 2 changes at 10 points 52 for 50 seconds, and the fingerprint recognition module performs S62-S63, so that the fingerprint recognition module can receive the pressure information, and performs S64 according to the pressure information, and if it is determined that the pressure level of the memory 2 is greater than the threshold 1, the fingerprint service module performs S65.
It should be noted that, if the fingerprint service module receives the pressure information after receiving the fingerprint identification result, but when the fingerprint identification result received by the fingerprint service module is used to indicate that the fingerprint identification fails, the fingerprint service module does not perform any operation, that is, does not perform S65.
The fingerprint service module determines that the pressure level of the memory 2 is less than or equal to the threshold 1, and the fingerprint service module does not compress the fingerprint dynamic effect pixel data, so that after the electronic device is off-screen, the fingerprint service module does not execute the decompression step.
It can be understood that the fingerprint recognition result received by the fingerprint service module is used to indicate that fingerprint recognition fails, and in general, the user may perform fingerprint unlocking again, if the fingerprint service module performs S65 to compress the fingerprint moving effect pixel data at this time, then when the user performs fingerprint unlocking again, the pixel data in the memory 2 is in a compressed state, and is not decompressed, and the moving effect picture cannot be displayed according to the pixel data in the memory 2.
S65, the fingerprint service module compresses the fingerprint dynamic effect pixel data in the memory 2.
Based on S64, if the fingerprint service module determines that the pressure level of the memory 2 is greater than the threshold 1, the pressure of the memory 2 is greater, and the fingerprint service module can compress the fingerprint effective pixel data stored in the memory 2, so as to release the pressure of the memory 2.
In some embodiments, the fingerprint service module performs object-level compression (object-level memory compression) on the fingerprint active pixel data in memory 2.
The object level compression is to compress each object to be compressed independently, for example, compress each group of pixel data independently. The object-level compression technology can realize finer-granularity compression control, so that the compression efficiency and performance are improved, the storage space of data on the memory 2 is reduced, and the size of the data in the transmission process is reduced.
Alternatively, S35 may further include:
the fingerprint service module periodically (every preset time period) judges whether the pressure level of the memory 2 is greater than a threshold value 1 according to the pressure information, and compresses the fingerprint dynamic effect pixel data in the memory 2 when the pressure level is greater than the threshold value 1.
According to the dynamic effect picture display method, when the pressure level of the memory 2 is greater than the threshold value 1, the fingerprint service module compresses the fingerprint dynamic effect pixel data, so that the pressure of the memory 2 of the electronic equipment is released, the performance of the electronic equipment is prevented from being reduced, the running program is prevented from being crashed, and the performance and the stability of an electronic equipment system are ensured.
Based on the foregoing embodiments, the moving-effect picture display method provided by the present application is described below.
Illustratively, the present application provides a moving-effect picture display method.
For convenience of explanation, the moving-effect picture display method of the present application may be performed by the electronic device in fig. 2; the electronic equipment comprises a first memory and a second memory, wherein the first memory is a volatile memory, the second memory is a nonvolatile memory, data in the first memory can be cleared when the electronic equipment is powered off, and data in the second memory can not be cleared when the electronic equipment is powered off.
Referring to fig. 14, fig. 14 is a flowchart illustrating a moving-effect picture display method according to an embodiment of the application.
As shown in fig. 14, the moving effect picture display method provided by the present application may include:
s301, after the electronic equipment is started, displaying a first interface at a first time point, wherein the first interface is an interface when the electronic equipment is in a screen locking state.
The specific implementation of the first interface may be referred to as interface 11 shown in fig. 3 (a), and the related description of the lock screen interface in fig. 7.
The specific implementation of S301 may be referred to the interface 11 shown in fig. 3 (a), and the related description of S27 in fig. 7, which will not be described herein.
S302, at a second time point, responding to a first operation of a fingerprint identification area on a first interface, displaying an unlocking moving effect picture according to a first pixel data set, displaying a second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the second time point is later than the first time point, and the second interface is an interface when the electronic equipment is in an unlocking state.
The specific implementation of the first operation may be referred to as a contact operation in the interface 14 shown in fig. 4 (b), and a related description of the contact operation in fig. 7.
A specific implementation of the first pixel data set may be seen in fig. 7 with respect to the relevant description of the fingerprint active pixel data.
A specific implementation of the first picture set may be seen in fig. 7 with respect to a description of a fingerprint moving effect picture.
Specific implementations of unlocking the dynamic effect screen can be seen from the interface 12 shown in fig. 3 (b) -the dynamic effect screen in the interface 13 shown in fig. 4 (a), and the related description of the dynamic effect screen in fig. 7.
The specific implementation of S302 may be referred to the interface 12 shown in fig. 3 (b) -the interface 13 shown in fig. 4 (a), and the related descriptions of S27-S30 in fig. 7, which are not repeated here.
And S303, when the screen of the electronic equipment is detected to be off, the first image set is not decoded, the electronic equipment is not powered off between the second time point and the third time point, and the third time point is later than the second time point.
The specific implementation of S303 may be referred to in fig. 9 for descriptions related to S41-S51, which are not described herein.
And S304, at a fourth time point, responding to a first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying the second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the fourth time point is later than the third time point.
The specific implementation of S304 may be referred to the interface 12 shown in fig. 3 (b) -the interface 13 shown in fig. 4 (a), and the related descriptions of S27-S30 in fig. 7, which are not repeated here.
According to the dynamic effect picture display method, after the dynamic effect picture is displayed on the first interface for the first time and the screen of the electronic equipment is closed, the first pixel data set in the first memory is not deleted, and the first image data set is not required to be decoded again, namely the first pixel data set is reserved, so that the electronic equipment in the screen locking state can display the dynamic effect picture directly according to the first pixel data set in the first memory when receiving the first operation every time, the decoding time is saved, the power consumption of the electronic equipment is reduced, and the electric quantity consumption of the electronic equipment is reduced.
In another embodiment of the present application, the moving effect picture display method of the present application may include:
s401, after the electronic equipment is started, displaying a first interface at a first time point, wherein the first interface is an interface when the electronic equipment is in a screen locking state.
S402, acquiring a first image set from a second memory, and decoding to obtain a first pixel data set.
The electronic device may also turn on the listening fingerprint function before S402.
S403, storing the first pixel data set in the first memory.
The specific implementation of the first memory can be seen from the relevant description of the memory 2 in fig. 7.
A specific implementation of the second memory can be seen in fig. 7 in relation to the description of the memory 1.
S404, at a second time point, responding to a first operation of a fingerprint identification area on the first interface, acquiring a fingerprint image of a user, performing fingerprint identification on the fingerprint image, displaying an unlocking moving effect picture according to the first pixel data set, and displaying a second interface after the unlocking moving effect picture is displayed, wherein the second time point is later than the first time point, and the second interface is an interface when the electronic equipment is in an unlocking state.
The specific implementation manner of acquiring the fingerprint image of the user may refer to the description related to S31 in fig. 7, which is not described herein.
The specific implementation of S404 may be referred to in fig. 7 for description of S27-S34, which is not repeated here.
And S405, closing the fingerprint monitoring function when fingerprint identification is successful and the display of the unlocking moving effect picture is finished, and determining whether the pressure level of the first memory is greater than a first threshold value or not, wherein the pressure level is used for indicating the storage pressure of the first memory, and the storage pressure is related to the pause time of a program in the running of the electronic equipment waiting for the first memory to allocate the storage space.
Optionally, when the fingerprint identification is successful and the display of the unlocking moving effect picture is finished, the electronic device may directly compress the first pixel data set; and decompressing the first pixel data set when the electronic equipment is detected to be off-screen.
The specific implementation of the pressure level can be seen in fig. 10, which is related to the pressure level and the pressure information.
For a specific implementation of the first threshold, see the relevant description of threshold 1 in fig. 10.
When the fingerprint image is matched with a preset fingerprint image, the fingerprint identification is successful.
And, prior to receiving the first operation, the electronic device may obtain pressure information; in the process of receiving a first operation and displaying a dynamic effect picture on a first interface according to a first pixel data set in a first memory in response to the first operation; the electronic device may obtain pressure information; after the dynamic effect picture is displayed, the electronic equipment can obtain the pressure information.
Thus, after the dynamic effect picture is displayed, whether the pressure level of the first memory is greater than the first threshold value can be determined according to the pressure information.
The proc/pid/RECLAIM interface is called through a reclaim_range function provided by the RECLAIM interface, so that the compression of the first pixel data set in the first memory is realized.
The specific implementation of S405 may be referred to as S33-S35 in fig. 7, and the related descriptions of S64-S65 in fig. 10, which are not described herein.
After the fingerprint identification is successful and the moving effect picture is displayed, the fingerprint monitoring function is closed, so that the power consumption of the electronic equipment can be reduced, the electric quantity consumption of the electronic equipment is reduced, and the use smoothness of the electronic equipment is ensured.
And determining whether the pressure level of the first memory is greater than a first threshold may prepare data for compressing the first pixel data set in the first memory when the pressure level is greater than the first threshold.
S406, performing object-level compression on the first pixel data set in the first memory when the pressure level is greater than a first threshold.
The object-level compression is an independent compression of each object to be compressed in the first memory, e.g. an independent compression of each group of pixel data in the first pixel data set.
The specific implementation of S406 may be referred to the description related to S65 in fig. 10, which is not described herein.
After the fingerprint identification is successful and the dynamic picture display is finished, the pressure level of the first memory can be determined, and when the pressure level of the first memory is larger than a first threshold value, the first pixel data set in the first memory is compressed, so that the pressure of the first memory is released, the performance of the electronic equipment is prevented from being reduced, the running program is prevented from being crashed, and the performance and stability of the electronic equipment system are ensured.
And the object-level compression technology is adopted to compress the first pixel data set, so that finer granularity compression control can be realized, the compression efficiency and performance are improved, the storage space of the first pixel data set on the first memory is reduced, and the size of data in the transmission process is reduced.
S407, when the electronic equipment screen-off is detected, determining whether a fingerprint monitoring function is started.
The specific implementation manner of the function of starting the monitor fingerprint may refer to the related description of the function of registering the monitor fingerprint in fig. 7, which is not described herein.
During each startup or restarting process of the electronic equipment, a monitoring screen-off event can be registered, so that when the electronic equipment is off-screen, the electronic equipment can receive a screen-off message, and whether the electronic equipment is registered for monitoring the fingerprint function can be determined in response to the receiving of the screen-off message.
The specific implementation of S407 may be referred to in the description of S43 in fig. 9, which is not described herein.
S408, when the monitoring fingerprint function is not started, the monitoring fingerprint function is started.
The specific implementation of S408 can be seen from the relevant descriptions of S44-S47 in fig. 9, and will not be described here.
S409, in response to turning on the snoop fingerprint function, determining whether a first pixel data set exists in the first memory.
The specific implementation of S409 may be referred to in the description of S48 in fig. 9, which is not described herein.
S410, when a first pixel data set exists in the first memory and the first pixel data set is compressed data, object-level decompression is performed on the first pixel data set.
In S406, since the first pixel data set in the first memory is data subjected to object-level compression, object-level decompression of the first pixel data set is required.
When the first pixel data set is decompressed, the first pixel data set is decompressed through the memory locking interface, and the decompressed first pixel data set is in an incompressible state.
The memory lock interface may be an mlock interface.
In the application, the first pixel data set is locked in the first memory through the memory locking interface, namely the mlock interface locking, so that the first pixel data set is in an incompressible state, and the first pixel data set can be prevented from being compressed again after screen failure.
And after displaying the unlocking moving effect picture on the first interface, the method further comprises the following steps: and converting the first pixel data set into a compressible state through the memory unlocking interface.
The memory unlocking interface may be a munlock interface.
In the application, after unlocking the lock interface through the memory, namely unlocking the mulock interface, the first pixel data set is in a compressible state, and when the pressure level of the first memory is greater than a first threshold value, the compression of the first pixel data set can be triggered again.
The specific implementation of S410 may be referred to the description related to S51 in fig. 9, which is not described herein.
S411, when the first pixel data set does not exist in the first memory, decoding the first image set in the second memory to obtain the first pixel data set.
The specific implementation of S411 may be referred to the description related to S49 in fig. 9, which is not described herein.
In the application, before the screen is turned off, the function of monitoring the fingerprint may be registered, and the first pixel data set obtained by decoding the first image set in the second memory is stored in the first memory; the monitoring fingerprint function may also be turned off after registering the monitoring fingerprint function and storing a first pixel data set obtained by decoding a first image set in the second memory into the first memory; the snoop fingerprint function may not be registered, and therefore, when the snoop fingerprint function is not registered and the first pixel data set does not exist in the first memory, the snoop fingerprint function is registered, and the first pixel data set obtained by decoding the first image set read in the second memory is stored in the first memory, so that data preparation is made for displaying the active picture when the first operation is received next time.
And because the first pixel data set in the first memory is compressed when the fingerprint identification is successful and the pressure level of the first memory is greater than the first threshold after the display of the dynamic effect picture is finished, the first pixel data set needs to be decompressed, so that the dynamic effect picture is displayed for data preparation when the first operation is received next time; when the electronic equipment is off-screen, the first pixel data set is decompressed, compared with when the electronic equipment is on-screen, the first pixel data set is decompressed, so that the power consumption of the electronic equipment can be reduced, and the power consumption of the electronic equipment can be reduced.
S412, storing the first pixel data set in the first memory.
The specific implementation of S412 may be referred to as S50 in fig. 9, which is not described herein.
Illustratively, the present application provides a moving-effect picture display device, which may include one or more modules for performing the moving-effect picture display method in the foregoing embodiments.
The plurality of modules can comprise a pressure pause information module, a fingerprint service module, a fingerprint identification trusted application module and a pressure pause information kernel module.
The specific implementation manner of the pressure pause information module, the fingerprint service module, the fingerprint identification trusted application module and the pressure pause information kernel module for executing the active screen display method can be referred to as S21-S34 in fig. 7, S41-S51 in fig. 9 and the related description of S61-S65 in fig. 10, which are not repeated here.
Illustratively, the present application provides an electronic device comprising a processor; the computer code or instructions in the memory, when executed by the processor, cause the electronic device to perform the dynamic picture display method of the previous embodiments.
Illustratively, the present application provides an electronic device comprising: a memory and a processor; the memory is coupled with the processor and is used for storing program codes or instructions; the processor is configured to invoke the program code or instructions in the memory to cause the electronic device to perform the dynamic picture display method in the previous embodiment.
Illustratively, the present application provides a chip system for use with an electronic device including a memory, a display screen, and a sensor; the chip system includes: one or more interface circuits and one or more processors; the interface circuit and the processor are interconnected through a circuit; the interface circuit is used for receiving signals from the memory and sending signals to the processor, wherein the signals comprise computer codes or instructions stored in the memory; when the processor executes the computer code or instructions, the electronic device performs the moving-effect picture display method of the previous embodiments.
Illustratively, the present application provides a computer-readable storage medium having code or instructions stored therein which, when executed on an electronic device, cause the electronic device to perform the method of the previous embodiments.
Illustratively, the present application provides a computer program product which, when run on a computer, causes an electronic device to implement the moving-effect picture display method in the previous embodiments.
In the above-described embodiments, all or part of the functions may be implemented by software, hardware, or a combination of software and hardware. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer codes or instructions. When the computer program code or instructions are loaded and executed on a computer, the processes or functions in accordance with the present application are fully or partially produced. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer code or instructions may be stored in a computer readable storage medium. Computer readable storage media can be any available media that can be accessed by a computer or data storage devices, such as servers, data centers, etc., that contain an integration of one or more available media. Usable media may be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., DVDs), or semiconductor media (e.g., solid State Disks (SSDs)), among others.
Those of ordinary skill in the art will appreciate that implementing all or part of the above-described method embodiments may be accomplished by a computer program to instruct related hardware, the program may be stored in a computer readable storage medium, and the program may include the above-described method embodiments when executed. And the aforementioned storage medium includes: a Read Only Memory (ROM) or a random access memory (random access memory, RAM), a magnetic disk or an optical disk, or the like.

Claims (12)

1. A moving effect picture display method, characterized in that it is applied to an electronic device, the method comprising:
after the electronic equipment is started, displaying a first interface at a first time point, wherein the first interface is an interface when the electronic equipment is in a screen locking state;
acquiring a first image set, and decoding to obtain a first pixel data set;
at a second time point, responding to a first operation of a fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying a second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the second time point is later than the first time point, and the second interface is an interface when the electronic equipment is in an unlocking state;
When the electronic equipment is detected to be off-screen at a third time point, the first image set is not decoded, the electronic equipment is not powered off between the second time point and the third time point, and the third time point is later than the second time point;
and at a fourth time point, responding to a first operation of the fingerprint identification area on the first interface, displaying an unlocking moving effect picture according to the first pixel data set, and displaying the second interface after the unlocking moving effect picture is displayed and the fingerprint identification is successful, wherein the fourth time point is later than the third time point.
2. The method of claim 1, wherein the electronic device includes a first memory and a second memory, wherein data in the first memory is cleared when the electronic device is powered off, and wherein data in the second memory is not cleared when the electronic device is powered off; after the first image set is acquired and decoded to obtain the first pixel data set, the method further includes:
the first set of pixel data is stored in the first memory and the first set of images is stored in the second memory.
3. The method according to claim 2, wherein the method further comprises:
responding to a first operation of a fingerprint identification area on the first interface, and acquiring a fingerprint image of a user;
fingerprint identification is carried out on the fingerprint image;
when fingerprint identification is successful and the display of the unlocking moving effect picture is finished, compressing the first pixel data set, and storing the compressed first pixel data set in the first memory;
and decompressing the first pixel data set when the electronic equipment is detected to be off-screen.
4. A method according to claim 3, wherein compressing the first pixel data set when the fingerprint identification is successful and the unlock dynamic picture display is completed comprises:
when fingerprint identification is successful and the display of the unlocking moving effect picture is finished, determining whether the pressure level of the first memory is larger than a first threshold value, wherein the pressure level is used for indicating the storage pressure of the first memory, and the storage pressure is related to the pause time of a program in running of the electronic equipment waiting for the first memory to allocate a storage space;
The first set of pixel data is compressed when the pressure level is greater than the first threshold.
5. The method according to claim 3 or 4, wherein before decoding the first image set to obtain the first pixel data set, the method further comprises:
starting a fingerprint monitoring function;
after the unlocking moving effect picture is displayed, the method further comprises the following steps:
closing the fingerprint monitoring function;
when the electronic equipment is detected to be off-screen, decompressing the first pixel data set, including:
when detecting that the electronic equipment is off-screen, determining whether the fingerprint monitoring function is started;
when the monitoring fingerprint function is not started, starting the monitoring fingerprint function;
determining whether the first pixel data set is present in the first memory based on the snoop fingerprint function;
and decompressing the first pixel data set when the first pixel data set exists in the first memory and the first pixel data set is compressed data.
6. The method of claim 5, wherein the method further comprises:
Decoding the first image set in the second memory to obtain the first pixel data set when the first pixel data set does not exist in the first memory;
the first set of pixel data is stored in the first memory.
7. The method of claim 2, wherein displaying an unlock dynamic screen from the first set of pixel data comprises:
determining whether the first set of pixel data is present in the first memory;
decoding the first image set in the second memory to obtain the first pixel data set when the first pixel data set does not exist in the first memory;
storing the first set of pixel data in the first memory;
and displaying an unlocking dynamic effect picture according to the first pixel data set in the first memory.
8. A method according to claim 3, wherein said compressing said first set of pixel data in said first memory comprises:
performing object level compression on the first pixel data set in the first memory;
decompressing the first pixel data set, comprising:
Object-level decompression is performed on the first pixel data set.
9. A method according to claim 3, wherein said decompressing said first set of pixel data comprises:
decompressing the first pixel data set through a memory locking interface, wherein the decompressed first pixel data set is in an incompressible state.
10. The method of claim 9, wherein after displaying an unlock dynamic screen from the first set of pixel data, the method further comprises:
and converting the first pixel data set into a compressible state through a memory unlocking interface.
11. An electronic device, comprising:
one or more processors, memory, and one or more computer programs; wherein the one or more computer programs are stored on the memory, which when executed by the one or more processors, cause the electronic device to perform the dynamic picture display method of any one of claims 1-10.
12. A computer readable storage medium comprising a computer program, characterized in that the computer program, when run on a terminal device, causes the electronic device to perform the dynamic picture display method according to any one of claims 1 to 10.
CN202311113071.8A 2023-08-31 2023-08-31 Dynamic effect picture display method and electronic equipment Active CN116844196B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202311113071.8A CN116844196B (en) 2023-08-31 2023-08-31 Dynamic effect picture display method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202311113071.8A CN116844196B (en) 2023-08-31 2023-08-31 Dynamic effect picture display method and electronic equipment

Publications (2)

Publication Number Publication Date
CN116844196A true CN116844196A (en) 2023-10-03
CN116844196B CN116844196B (en) 2024-02-27

Family

ID=88160256

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202311113071.8A Active CN116844196B (en) 2023-08-31 2023-08-31 Dynamic effect picture display method and electronic equipment

Country Status (1)

Country Link
CN (1) CN116844196B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104461285A (en) * 2014-11-25 2015-03-25 深圳市金立通信设备有限公司 Unlocking interface processing method
CN106095247A (en) * 2013-09-09 2016-11-09 苹果公司 For handling the equipment of user interface, method and graphic user interface based on fingerprint sensor input
CN111176504A (en) * 2019-12-18 2020-05-19 华为技术有限公司 Interface element display method and electronic equipment
CN113096218A (en) * 2019-12-20 2021-07-09 腾讯科技(深圳)有限公司 Dynamic image playing method, device, storage medium and computer equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106095247A (en) * 2013-09-09 2016-11-09 苹果公司 For handling the equipment of user interface, method and graphic user interface based on fingerprint sensor input
CN104461285A (en) * 2014-11-25 2015-03-25 深圳市金立通信设备有限公司 Unlocking interface processing method
CN111176504A (en) * 2019-12-18 2020-05-19 华为技术有限公司 Interface element display method and electronic equipment
CN113096218A (en) * 2019-12-20 2021-07-09 腾讯科技(深圳)有限公司 Dynamic image playing method, device, storage medium and computer equipment

Also Published As

Publication number Publication date
CN116844196B (en) 2024-02-27

Similar Documents

Publication Publication Date Title
US11016641B2 (en) Method and apparatus for taking screenshot of screen of application in mobile terminal
CN104869305B (en) Method and apparatus for processing image data
CN107678876B (en) Screen freezing monitoring and solving method, mobile terminal and computer readable storage medium
CN111062323B (en) Face image transmission method, numerical value transfer method, device and electronic equipment
CN107885635B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN109101363A (en) Abnormal restoring method, device, smart machine and storage medium based on android system
WO2021143168A1 (en) Trusted execution environment operating system crash processing method and electronic device
CN107766222B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN115292052A (en) Memory recovery method, electronic device and computer-readable storage medium
CN115687035A (en) Memory leak detection method and electronic equipment
CN117707626A (en) System starting method and electronic equipment
CN115017534B (en) File processing authority control method, device and storage medium
US20240152439A1 (en) Detection Method and Electronic Device
CN107818036B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN107832191B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN107872367B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN116844196B (en) Dynamic effect picture display method and electronic equipment
CN110737476B (en) Terminal restarting method and device
CN107766210B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN107888411B (en) Black screen detection method, mobile terminal and computer readable storage medium
CN111813574A (en) Picture compression method and device, storage medium and electronic equipment
CN108038038B (en) Mobile terminal restart positioning method, mobile terminal and computer readable storage medium
WO2023185684A1 (en) Process killing method for application, and electronic device
CN116775345B (en) Data transmission method and electronic equipment
CN115858046B (en) Method for preloading memory pages, electronic equipment and chip system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant