CN110806909A - Method and device for determining page frame dropping information of application program and electronic equipment - Google Patents

Method and device for determining page frame dropping information of application program and electronic equipment Download PDF

Info

Publication number
CN110806909A
CN110806909A CN201911061001.6A CN201911061001A CN110806909A CN 110806909 A CN110806909 A CN 110806909A CN 201911061001 A CN201911061001 A CN 201911061001A CN 110806909 A CN110806909 A CN 110806909A
Authority
CN
China
Prior art keywords
time period
preset time
application program
theoretical
frame
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.)
Pending
Application number
CN201911061001.6A
Other languages
Chinese (zh)
Inventor
张丹
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Kingsoft Internet Security Software Co Ltd
Original Assignee
Beijing Kingsoft Internet Security Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Kingsoft Internet Security Software Co Ltd filed Critical Beijing Kingsoft Internet Security Software Co Ltd
Priority to CN201911061001.6A priority Critical patent/CN110806909A/en
Publication of CN110806909A publication Critical patent/CN110806909A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/448Execution paradigms, e.g. implementations of programming paradigms
    • G06F9/4482Procedural
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/90Details of database functions independent of the retrieved data types
    • G06F16/95Retrieval from the web
    • G06F16/957Browsing optimisation, e.g. caching or content distillation

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The embodiment of the invention provides a method and a device for determining information of dropped frames of an application page and electronic equipment, wherein the method comprises the following steps: acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of a current page of an application program in each preset time period according to the acquisition time of the vertical synchronization signal, wherein the first difference value is used as a frame drop number of the current page of the application program in each preset time period; and based on the frame dropping number, calculating the frame dropping information of the application program in each preset time period, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program. In the embodiment of the invention, the frame dropping information of the page can be automatically obtained without manually obtaining the page drawing parameters and manually analyzing based on the parameters, so that the efficiency and timeliness of the frame dropping information calculation are improved.

Description

Method and device for determining page frame dropping information of application program and electronic equipment
Technical Field
The invention relates to the technical field of computers, in particular to a method and a device for determining page frame dropping information of an application program and electronic equipment.
Background
With the rapid popularization of intelligent terminal devices such as mobile phones and the like, various terminal application programs are also developed endlessly, and during internal testing of the application programs, a page frame dropping phenomenon that the actual refreshing frame number of a page is smaller than the preset theoretical refreshing frame number within unit time occurs due to page design problems such as excessive page data or unreasonable page layout and the like when the application programs run on a terminal, and when the page frame dropping reaches a certain degree, a visual stuck phenomenon is caused to a user, so that the use experience is influenced. Therefore, research and development personnel need to determine the serious frame dropping, namely, the page to be optimized with high frame dropping frequency according to the frequency of the frame dropping of each page in the running process of the application program, and then perform optimization design on the page to be optimized again.
At present, a method for determining the frequency of dropped frames of an application page includes: research personnel start a terminal device operating system to set developer permission in a page, so that current page drawing parameters such as analysis time and CPU (central processing unit) calculation time of a current page of an application program are obtained, and then the frame dropping frequency of the current page is manually analyzed based on the parameters.
The method has low calculation efficiency and poor timeliness.
Disclosure of Invention
The embodiment of the invention aims to provide a method and a device for determining page frame dropping information of an application program and electronic equipment, so as to improve the calculation efficiency of the page frame dropping information. The specific technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides a method for determining information of dropped frames of an application page, where the method is applied to a client device, and the method includes:
acquiring a vertical synchronization signal generated by the operating system of the client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period according to the acquisition time of the vertical synchronization signal, wherein the first difference value is used as a frame drop number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and calculating frame dropping information of the application program in each preset time period based on the frame dropping number, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
Further, the step of determining, according to the acquisition time of the vertical synchronization signal, a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period, as a frame drop number of the current page of the application program in each preset time period, includes:
in the process of acquiring the vertical synchronizing signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronizing signals in the same preset time period in real time according to the acquisition time of the vertical synchronizing signal;
calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval;
subtracting 1 from the second theoretical refresh frame number to obtain a second difference value between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval;
and summing all the second differences in the same preset time period to obtain a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in the preset time period, wherein the first difference is used as the drop frame number of the current page of the application program in the preset time period.
Further, the step of determining, according to the acquisition time of the vertical synchronization signal, a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period, as a frame drop number of the current page of the application program in each preset time period, includes:
respectively determining the times of the acquired vertical synchronization signals in each preset time period according to the acquisition time of the vertical synchronization signals;
and respectively taking the difference between a first theoretical refresh frame number and the number of times of the acquired vertical synchronization signals in each preset time period as the frame dropping number of the current page of the application program in each preset time period, wherein the first theoretical refresh frame number is equal to the product of the theoretical refresh frequency and the preset time period.
Further, the step of calculating the frame dropping information of the application program in each preset time period based on the frame dropping number includes:
respectively taking the ratio of the frame dropping number to the first theoretical refreshing frame number as the frame dropping information of the application program in each preset time period; wherein the first theoretical refresh frame number is equal to the product of the preset time period and the theoretical refresh frequency;
or,
and respectively taking the ratio of the frame dropping number to the preset time period as the frame dropping information of the application program in each preset time period.
Further, the method further comprises:
and when each preset time period is finished, respectively sending the frame dropping information in the preset time period and the identification information of the current page to the server side equipment in communication connection with the client side equipment.
In a second aspect, an embodiment of the present invention provides an apparatus for determining information of dropped frames of an application page, where the apparatus is applied to a client device, and the apparatus includes:
the vertical synchronizing signal acquisition module is used for acquiring a vertical synchronizing signal generated by the operating system of the client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
a frame dropping number determining module, configured to determine, according to the acquisition time of the vertical synchronization signal, a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period, where the first difference is used as a frame dropping number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and the frame dropping information calculation module is used for calculating frame dropping information of the application program in each preset time period based on the frame dropping number, and the frame dropping information represents the frequency of frame dropping of the current page of the application program.
Further, the frame dropping number determining module is specifically configured to:
in the process of acquiring the vertical synchronizing signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronizing signals in the same preset time period in real time according to the acquisition time of the vertical synchronizing signal;
calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval;
subtracting 1 from the second theoretical refresh frame number to obtain a second difference value between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval;
and summing all the second differences in the same preset time period to obtain a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in the preset time period, wherein the first difference is used as the drop frame number of the current page of the application program in the preset time period.
Further, the frame dropping number determining module is specifically configured to:
respectively determining the times of the acquired vertical synchronization signals in each preset time period according to the acquisition time of the vertical synchronization signals;
and respectively taking the difference between a first theoretical refresh frame number and the number of times of the acquired vertical synchronization signals in each preset time period as the frame dropping number of the current page of the application program in each preset time period, wherein the first theoretical refresh frame number is equal to the product of the theoretical refresh frequency and the preset time period.
Further, the frame dropping information calculating module is specifically configured to:
respectively taking the ratio of the frame dropping number to the first theoretical refreshing frame number as the frame dropping information of the application program in each preset time period; wherein the first theoretical refresh frame number is equal to the product of the preset time period and the theoretical refresh frequency;
or,
and respectively taking the ratio of the frame dropping number to the preset time period as the frame dropping information of the application program in each preset time period.
Further, the apparatus further comprises: an information sending module;
and the information sending module is used for sending the frame dropping information and the identification information of the current page in each preset time period to the server-side equipment in communication connection with the client-side equipment when each preset time period is finished.
In a third aspect, an embodiment of the present invention provides an electronic device, including a processor, a communication interface, a memory, and a communication bus, where the processor and the communication interface complete communication between the memory and the processor through the communication bus;
a memory for storing a computer program;
and the processor is used for realizing the steps of the method for determining the page frame dropping information of any application program when the program stored in the memory is executed.
In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored, and when the computer program runs on a computer, the computer is caused to execute any one of the above methods for determining page frame dropping information of an application program.
The method, the device and the electronic equipment for determining the page frame dropping information of the application program, provided by the embodiment of the invention, are used for acquiring a vertical synchronization signal generated by an operating system of the client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page; determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period according to the acquisition time of the vertical synchronization signal, and taking the first difference value as a frame drop number of the current page of the application program; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period; and calculating frame dropping information of the application program in each preset time period based on the frame dropping number, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program. In the embodiment of the invention, the frame dropping number of the current page of the application program in each preset time period can be calculated according to the acquisition time of the vertical synchronization signal, so that the frame dropping information representing the frequency of the frame dropping of the current page of the application program can be obtained.
Of course, not all of the advantages described above need to be achieved at the same time in the practice of any one product or method of the invention.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flowchart of a method for determining information of dropped frames of an application page according to an embodiment of the present invention;
fig. 2 is another schematic flowchart of a method for determining information of a dropped frame of an application page according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of another method for determining information of dropped frames of an application page according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of an apparatus for determining information of dropped frames of an application page according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In order to improve the calculation efficiency of the page frame dropping information, the embodiment of the invention provides a method and a device for determining the page frame dropping information of an application program and electronic equipment.
Referring to fig. 1, fig. 1 is a schematic flowchart of a method for determining page frame dropping information of an application according to an embodiment of the present invention, which specifically includes the following steps:
step 101, acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; wherein, the vertical synchronizing signal generated by the operating system represents the beginning of one frame page drawing.
The page drawing frequency of the terminal equipment display is controlled by the operating system display card, the starting of one-frame page drawing is represented every time the operating system display card generates a vertical synchronization signal, and the frequency of the vertical synchronization signal generated by the operating system display card is the actual page drawing frequency of the display, namely the actual refreshing frequency of the current page of the application program.
Step 102, determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of a current page of an application program in each preset time period according to the acquisition time of a vertical synchronization signal, and taking the first difference value as a frame drop number of the current page of the application program in each preset time period; and the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period.
Specifically, the page rendering (refreshing) process of the display is not that the whole page is changed simultaneously, but that a single pixel point is rendered and refreshed line by line, so that only when the refreshing frequency reaches a certain degree, human eyes cannot perceive the page refreshing process, that is, when the refreshing frequency reaches a certain degree, the page is smooth and continuous for human eyes, generally speaking, the theoretical refreshing frequency can be set to be 60Hz, and when the refreshing frequency is not lower than the theoretical refreshing frequency, the page seen by human eyes is smooth.
And 103, calculating frame dropping information of the application program in each preset time period based on the frame dropping number, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
In this step, the frame dropping information may be calculated in various ways, for example: the ratio of the dropped frame number to the first theoretical refresh frame number may be used as the dropped frame information of the application program in each preset time period; or the ratio of the dropped frame number to the preset time period can be used as the dropped frame information of the application program in each preset time period; the ratio of the dropped frame number to the actual refresh frame number of the current page of the application program in each preset time period may also be used as dropped frame information of the application program in each preset time period, and the like, where a specific manner for calculating the dropped frame information is not limited.
In the embodiment of the invention, the frame dropping number of the current page of the application program in each preset time period can be calculated according to the acquisition time of the vertical synchronization signal, so that the frame dropping information representing the frequency of the frame dropping of the current page of the application program is obtained.
Referring to fig. 2, fig. 2 is another schematic flow chart of a method for determining page frame dropping information of an application according to an embodiment of the present invention, which specifically includes the following steps:
step 201, acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; wherein, the vertical synchronizing signal generated by the operating system represents the beginning of one frame page drawing.
Step 202, in the process of acquiring the vertical synchronization signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronization signals within the same preset time period in real time according to the acquisition time of the vertical synchronization signal.
Step 203, calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval.
And step 204, subtracting 1 from the second theoretical refresh frame number to obtain a second difference between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval.
Step 205, summing all the second differences within the same preset time period to obtain a first difference between the first theoretical refresh frame number and the actual refresh frame number of the current page of the application program within the preset time period, which is used as the drop frame number of the current page of the application program within the preset time period.
And the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period.
And step 206, based on the frame dropping number, calculating the frame dropping information of the application program in each preset time period, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
In this step, the frame dropping information may be calculated in various ways, for example: the ratio of the dropped frame number to the first theoretical refresh frame number may be used as the dropped frame information of the application program in each preset time period; or the ratio of the dropped frame number to the preset time period can be used as the dropped frame information of the application program in each preset time period; the ratio of the dropped frame number to the actual refresh frame number of the current page of the application program in each preset time period may also be used as dropped frame information of the application program in each preset time period, and the like, where a specific manner for calculating the dropped frame information is not limited.
For ease of understanding, the contents of the above steps 201-206 are explained in detail below by way of specific examples:
assuming that page frame dropping information of the application a installed in the client device is to be determined, in step 201, a vertical synchronization signal generated by an operating system of the client device can be monitored and acquired in real time, in steps 202-203, an acquisition time of each acquisition of the vertical synchronization signal is recorded, in each time period of 1000ms, an acquisition time interval of two consecutive acquisition of the vertical synchronization signal is calculated, assuming that 1000ms is a time period, and then a product of the acquisition time interval and a theoretical refresh frequency is determined as a second theoretical refresh frame number in the acquisition time interval, for example, a time when the vertical synchronization signal is received for the first time is t1 ms, a time when the vertical synchronization signal is received for the second time is t2 ms, the acquisition time interval is 50ms, and the second theoretical refresh frame number in the acquisition time interval is 50ms × 60Hz — 3, in step 204, obtaining a second difference between a second theoretical refresh frame number and an actual refresh frame number of the current page of the application program in the obtaining time interval, where the second difference is 3-1 to 2, and so on, and thus a second difference corresponding to the obtaining time interval of the vertical synchronization signal obtained continuously any two times in the same time period can be obtained, and in step 205, summing all the second differences in the same preset time period, so as to obtain a first difference between the first theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the preset time period, which is used as a dropped frame number of the current page of the application program in the preset time period; finally, in step 206, the frame dropping information of the current page of the application a in each preset time period can be determined by any one of the frame dropping information determination methods listed in step 206.
And step 207, when each preset time period is finished, respectively sending the frame dropping information and the identification information of the current page in the preset time period to the server side equipment in communication connection with the client side equipment.
At present, aiming at the method that research and development personnel need to start the developer permission in the terminal device operating system, so that the frame dropping frequency of the current page is manually analyzed, due to the limited personnel, high manual analysis cost and the like, only the page frame dropping information of the application program on the individual testing client device with the developer permission started can be obtained, and the page frame dropping information of the application program on a large batch of or all testing client devices cannot be obtained.
During the page optimization design, in order to quickly and accurately locate a page to be optimized, page frame dropping information of an application program on a large number of client devices for testing can be acquired, and the acquired page frame dropping information is divided into a plurality of levels according to a preset frame dropping information threshold, for example, the page frame dropping information is divided into three levels, namely a high frame dropping rate, a medium frame dropping rate and a low frame dropping rate, specifically, more than 30% of the frame dropping information can be divided into high frame dropping rate information, more than 10% and less than 30% of the frame dropping information can be divided into medium frame dropping rate information, and less than 10% of the frame dropping information can be divided into low frame dropping rate information. For the current page, when the number of the client devices with high frame dropping rate information exceeds a certain preset number or a certain preset proportion, the current page may be determined as a page to be optimized. In the embodiment of the present invention, after the frame dropping information of the page is automatically obtained, the client device may further send the obtained frame dropping information and the identification information of the current page to the server device, so that the server device obtains the page frame dropping information when the application program runs on a large number of or all client devices, and then divides the obtained page frame dropping information into a plurality of levels according to a preset frame dropping information threshold, for example, the page frame dropping information into three levels, i.e., a high frame dropping rate, a medium frame dropping rate and a low frame dropping rate, specifically, more than 30% of the frame dropping information may be divided into high frame dropping rate information, more than 10% and less than 30% of the frame dropping information may be divided into medium frame dropping rate information, and less than 10% of the frame dropping information may be divided into low frame dropping rate information. For the current page, when the number of the client devices with high frame dropping rate information exceeds a certain preset number or a certain preset proportion, the current page may be determined as a page to be optimized.
Further, different page data may be presented in the same page of the application program at different times, for example, at a previous time, a video playing area and a comment area may be displayed in the page, but at a next time, the user may maximize the video playing area, and at this moment, only one video playing area is displayed in the page.
In the embodiment shown in fig. 2, the frame dropping number of the current page of the application program in each preset time period can be calculated according to the acquisition time of the vertical synchronization signal, and then frame dropping information representing the frequency of frame dropping of the current page of the application program is obtained. Meanwhile, after the frame dropping information of the page is automatically obtained, the obtained frame dropping information and the identification information of the current page are sent to the server side equipment, and a reference basis is provided for quickly positioning the page to be optimized.
Referring to fig. 3, fig. 3 is a schematic flowchart of another method for determining information of dropping frames of an application page according to an embodiment of the present invention, which specifically includes the following steps:
step 301, acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; wherein, the vertical synchronizing signal generated by the operating system represents the beginning of one frame page drawing.
Step 302, respectively determining the number of times of acquiring the vertical synchronization signal within each preset time period according to the acquisition time of the vertical synchronization signal.
Step 303, respectively taking the difference between the first theoretical refresh frame number and the number of times of the acquired vertical synchronization signal in each preset time period as the drop frame number of the current page of the application program in each preset time period, wherein the first theoretical refresh frame number is equal to the product of the theoretical refresh frequency and the preset time period.
And 304, calculating frame dropping information of the application program in each preset time period based on the frame dropping number, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
Step 305, when each preset time period ends, respectively sending the frame dropping information and the identification information of the current page in the preset time period to a server device in communication connection with the client device.
The contents of step 304 and step 305 are the same as the contents of step 206 and step 207, respectively, and are not described herein again.
In the embodiment shown in fig. 3, the frame dropping number of the current page of the application program in each preset time period can be calculated according to the acquisition time of the vertical synchronization signal, and then frame dropping information representing the frequency of frame dropping of the current page of the application program is obtained. Meanwhile, after the frame dropping information of the page is automatically obtained, the obtained frame dropping information and the identification information of the current page are sent to the server side equipment, and a reference basis is provided for quickly positioning the page to be optimized.
Based on the same inventive concept, according to the method for determining the page frame dropping information of the application program provided by the above embodiment of the present invention, correspondingly, the embodiment of the present invention further provides a device for determining the page frame dropping information of the application program, which is applied to the client device; the schematic structural diagram of the device is shown in fig. 4, and the device comprises:
a vertical synchronization signal obtaining module 401, configured to obtain a vertical synchronization signal generated by an operating system of a client device in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
a frame dropping number determining module 402, configured to determine, according to the acquisition time of the vertical synchronization signal, a first difference between a first theoretical refresh frame number and an actual refresh frame number of a current page of the application program in each preset time period, where the first difference is used as a frame dropping number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and a frame dropping information calculating module 403, configured to calculate frame dropping information of the application program in each preset time period based on the number of frame dropping, where the frame dropping information represents how frequently the current page of the application program drops frames.
Further, the dropped frame number determining module 402 is specifically configured to:
in the process of acquiring the vertical synchronizing signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronizing signals in the same preset time period in real time according to the acquisition time of the vertical synchronizing signal;
calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval;
subtracting 1 from the second theoretical refresh frame number to obtain a second difference value between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval;
and summing all the second differences in the same preset time period to obtain a first difference between the first theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the preset time period, and taking the first difference as the drop frame number of the current page of the application program in the preset time period.
Further, the dropped frame number determining module 402 is specifically configured to:
respectively determining the times of the acquired vertical synchronization signals in each preset time period according to the acquisition time of the vertical synchronization signals;
and respectively taking the difference value of the first theoretical refreshing frame number and the number of times of the acquired vertical synchronization signals in each preset time period as the frame dropping number of the current page of the application program in each preset time period, wherein the first theoretical refreshing frame number is equal to the product of the theoretical refreshing frequency and the preset time period.
Further, the dropped frame information calculating module 403 is specifically configured to:
respectively taking the ratio of the frame dropping number to the first theoretical refreshing frame number as the frame dropping information of the application program in each preset time period; wherein the first theoretical refresh frame number is equal to the product of the preset time period and the theoretical refresh frequency;
or,
and respectively taking the ratio of the frame dropping number to the preset time period as the frame dropping information of the application program in each preset time period.
Further, the apparatus further comprises: an information sending module;
and the information sending module is used for sending the frame dropping information and the identification information of the current page in each preset time period to the server-side equipment in communication connection with the client-side equipment when each preset time period is finished.
In the embodiment shown in fig. 4 of the present invention, the frame dropping number of the current page of the application program in each preset time period can be calculated according to the acquisition time of the vertical synchronization signal, so as to obtain the frame dropping information representing the frequency of frame dropping of the current page of the application program.
An embodiment of the present invention further provides an electronic device, as shown in fig. 5, which includes a processor 501, a communication interface 502, a memory 503 and a communication bus 504, where the processor 501, the communication interface 502 and the memory 503 complete mutual communication through the communication bus 504,
a memory 503 for storing a computer program;
the processor 501, when executing the program stored in the memory 503, implements the following steps:
acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of a current page of an application program in each preset time period according to the acquisition time of the vertical synchronization signal, wherein the first difference value is used as a frame drop number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and based on the frame dropping number, calculating the frame dropping information of the application program in each preset time period, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
Further, other processing flows in the method for determining the page drop frame information of the application program provided by the embodiment of the present invention may also be included, and are not described in detail herein.
The communication bus mentioned in the electronic device may be a Peripheral Component Interconnect (PCI) bus, an Extended Industry Standard Architecture (EISA) bus, or the like. The communication bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is shown, but this does not mean that there is only one bus or one type of bus.
The communication interface is used for communication between the electronic equipment and other equipment.
The Memory may include a Random Access Memory (RAM) or a Non-Volatile Memory (NVM), such as at least one disk Memory. Further, the memory may be at least one memory device located remotely from the processor.
The Processor may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; the device can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other Programmable logic device, a discrete Gate or transistor logic device, or a discrete hardware component.
In another embodiment of the present invention, a computer-readable storage medium is further provided, where instructions are stored in the computer-readable storage medium, and when the instructions are executed on a computer, the computer is caused to execute any one of the above methods for determining page frame dropping information of an application program.
In another embodiment of the present invention, there is also provided a computer program product containing instructions, which when run on a computer, causes the computer to execute any of the above methods for determining page drop frame information of an application.
In the above embodiments, the implementation may be wholly or partially realized by software, hardware, firmware, or any combination thereof. 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 instructions. The procedures or functions described above in accordance with the embodiments of the invention may be generated, in whole or in part, when the computer program instructions described above are loaded and executed on a computer. The computer may be a general purpose computer, a special purpose computer, a network of computers, or other programmable device. The computer instructions may be stored on a computer readable storage medium or transmitted from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wire (e.g., coaxial cable, fiber optic cable, Digital Subscriber Line (DSL)), or wireless (e.g., infrared, wireless, microwave, etc.). The computer-readable storage medium can be any available medium that can be accessed by a computer or a data storage device, such as a server, a data center, etc., that includes one or more of the available media. The usable medium may be a magnetic medium (e.g., a floppy Disk, a hard Disk, a magnetic tape), an optical medium (e.g., a Digital Video Disc (DVD)), a semiconductor medium (e.g., a Solid State Disk (SSD)), or the like.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
All the embodiments in the present specification are described in a related manner, and the same and similar parts among the embodiments may be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, as for the apparatus, the terminal device and the storage medium embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant points can be referred to the partial description of the method embodiment.
The above description is only for the preferred embodiment of the present invention, and is not intended to limit the scope of the present invention. Any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention shall fall within the protection scope of the present invention.

Claims (10)

1. A method for determining information of dropped frames of an application program page is characterized by comprising the following steps:
acquiring a vertical synchronization signal generated by an operating system of client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
determining a first difference value between a first theoretical refresh frame number and an actual refresh frame number of a current page of an application program in each preset time period according to the acquisition time of the vertical synchronization signal, wherein the first difference value is used as a frame drop number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and calculating frame dropping information of the application program in each preset time period based on the frame dropping number, wherein the frame dropping information represents the frequency of frame dropping of the current page of the application program.
2. The method according to claim 1, wherein the step of determining a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period according to the acquisition time of the vertical synchronization signal, as a frame dropping number of the current page of the application program in each preset time period, comprises:
in the process of acquiring the vertical synchronizing signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronizing signals in the same preset time period in real time according to the acquisition time of the vertical synchronizing signal;
calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval;
subtracting 1 from the second theoretical refresh frame number to obtain a second difference value between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval;
and summing all the second differences in the same preset time period to obtain a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in the preset time period, wherein the first difference is used as the drop frame number of the current page of the application program in the preset time period.
3. The method according to claim 1, wherein the step of determining a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in each preset time period according to the acquisition time of the vertical synchronization signal, as a frame dropping number of the current page of the application program in each preset time period, comprises:
respectively determining the times of the acquired vertical synchronization signals in each preset time period according to the acquisition time of the vertical synchronization signals;
and respectively taking the difference between a first theoretical refresh frame number and the number of times of the acquired vertical synchronization signals in each preset time period as the frame dropping number of the current page of the application program in each preset time period, wherein the first theoretical refresh frame number is equal to the product of the theoretical refresh frequency and the preset time period.
4. The method according to claim 2 or 3, wherein the step of calculating the frame dropping information of the application program in each preset time period based on the frame dropping number comprises:
respectively taking the ratio of the frame dropping number to the first theoretical refreshing frame number as the frame dropping information of the application program in each preset time period; wherein the first theoretical refresh frame number is equal to the product of the preset time period and the theoretical refresh frequency;
or,
and respectively taking the ratio of the frame dropping number to the preset time period as the frame dropping information of the application program in each preset time period.
5. An apparatus for determining information of dropped frames of an application page, the apparatus comprising:
the vertical synchronizing signal acquisition module is used for acquiring a vertical synchronizing signal generated by the operating system of the client equipment in real time; wherein, the operation system generates a vertical synchronizing signal once to represent the beginning of drawing a frame of page;
a frame dropping number determining module, configured to determine, according to the acquisition time of the vertical synchronization signal, a first difference between a first theoretical refresh frame number and an actual refresh frame number of a current page of the application program in each preset time period, where the first difference is used as a frame dropping number of the current page of the application program in each preset time period; the first theoretical refresh frame number is the theoretical refresh frame number of the page in a preset time period;
and the frame dropping information calculation module is used for calculating frame dropping information of the application program in each preset time period based on the frame dropping number, and the frame dropping information represents the frequency of frame dropping of the current page of the application program.
6. The apparatus of claim 5, wherein the dropped frame number determining module is specifically configured to:
in the process of acquiring the vertical synchronizing signal, calculating the acquisition time interval of two times of continuously acquired vertical synchronizing signals in the same preset time period in real time according to the acquisition time of the vertical synchronizing signal;
calculating the product of the acquisition time interval and the theoretical refresh frequency to obtain a second theoretical refresh frame number in the acquisition time interval;
subtracting 1 from the second theoretical refresh frame number to obtain a second difference value between the second theoretical refresh frame number and the actual refresh frame number of the current page of the application program in the acquisition time interval;
and summing all the second differences in the same preset time period to obtain a first difference between a first theoretical refresh frame number and an actual refresh frame number of the current page of the application program in the preset time period, wherein the first difference is used as the drop frame number of the current page of the application program in the preset time period.
7. The apparatus of claim 5, wherein the dropped frame number determining module is specifically configured to:
respectively determining the times of the acquired vertical synchronization signals in each preset time period according to the acquisition time of the vertical synchronization signals;
and respectively taking the difference between a first theoretical refresh frame number and the number of times of the acquired vertical synchronization signals in each preset time period as the frame dropping number of the current page of the application program in each preset time period, wherein the first theoretical refresh frame number is equal to the product of the theoretical refresh frequency and the preset time period.
8. The apparatus according to claim 6 or 7, wherein the dropped frame information calculating module is specifically configured to:
respectively taking the ratio of the frame dropping number to the first theoretical refreshing frame number as the frame dropping information of the application program in each preset time period; wherein the first theoretical refresh frame number is equal to the product of the preset time period and the theoretical refresh frequency;
or,
and respectively taking the ratio of the frame dropping number to the preset time period as the frame dropping information of the application program in each preset time period.
9. An electronic device is characterized by comprising a processor, a communication interface, a memory and a communication bus, wherein the processor and the communication interface are used for realizing mutual communication by the memory through the communication bus;
a memory for storing a computer program;
a processor for implementing the method steps of any of claims 1 to 4 when executing a program stored in the memory.
10. A computer-readable storage medium, characterized in that a computer program is stored in the computer-readable storage medium, which computer program, when being executed by a processor, carries out the method steps of any one of claims 1 to 4.
CN201911061001.6A 2019-11-01 2019-11-01 Method and device for determining page frame dropping information of application program and electronic equipment Pending CN110806909A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911061001.6A CN110806909A (en) 2019-11-01 2019-11-01 Method and device for determining page frame dropping information of application program and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911061001.6A CN110806909A (en) 2019-11-01 2019-11-01 Method and device for determining page frame dropping information of application program and electronic equipment

Publications (1)

Publication Number Publication Date
CN110806909A true CN110806909A (en) 2020-02-18

Family

ID=69501004

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911061001.6A Pending CN110806909A (en) 2019-11-01 2019-11-01 Method and device for determining page frame dropping information of application program and electronic equipment

Country Status (1)

Country Link
CN (1) CN110806909A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111880602A (en) * 2020-08-03 2020-11-03 北京小米移动软件有限公司 Dropped frame detection method and device
CN111949511A (en) * 2020-07-09 2020-11-17 厦门美柚股份有限公司 Application program pause processing method and device, terminal and storage medium

Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009290710A (en) * 2008-05-30 2009-12-10 Hitachi Ltd Image processing apparatus and display unit
US20100305731A1 (en) * 2009-05-29 2010-12-02 Sanyo Electric Co., Ltd. Digital data processing apparatus
US20120262463A1 (en) * 2011-04-03 2012-10-18 Reuven Bakalash Virtualization method of vertical-synchronization in graphics systems
CN106681913A (en) * 2016-12-08 2017-05-17 武汉斗鱼网络科技有限公司 Application not responding positioning system and method
CN106802935A (en) * 2016-12-29 2017-06-06 腾讯科技(深圳)有限公司 The method of testing and device of a kind of page fluency
CN106874168A (en) * 2017-01-12 2017-06-20 北京奇虎科技有限公司 Determine method, device and the mobile terminal of application program runnability
CN107797922A (en) * 2017-09-27 2018-03-13 北京金山安全软件有限公司 Application page testing method, electronic device and electronic equipment
CN107864378A (en) * 2017-11-10 2018-03-30 维沃移动通信有限公司 A kind of frame rate detection method, device, mobile terminal and server
CN108228344A (en) * 2017-08-22 2018-06-29 珠海市魅族科技有限公司 Multi-process internal memory processing method and device, computer installation and readable storage medium storing program for executing
CN108664377A (en) * 2018-05-02 2018-10-16 腾讯音乐娱乐科技(深圳)有限公司 A kind of interim card of user interface determines method, apparatus and storage medium
CN108769815A (en) * 2018-06-21 2018-11-06 威盛电子股份有限公司 Method for processing video frequency and its device
CN109144858A (en) * 2018-08-02 2019-01-04 腾讯科技(北京)有限公司 Fluency detection method, calculates equipment and storage medium at device
CN109522208A (en) * 2018-09-29 2019-03-26 中国平安人寿保险股份有限公司 Page fluency test method and device, computer installation and storage medium
CN109587551A (en) * 2017-09-29 2019-04-05 北京金山云网络技术有限公司 A kind of judgment method, device, equipment and the storage medium of live streaming media Caton
CN109766502A (en) * 2018-12-13 2019-05-17 平安普惠企业管理有限公司 Page improved method, device, computer equipment and storage medium
CN110069194A (en) * 2019-03-21 2019-07-30 北京三快在线科技有限公司 Page Caton determines method, apparatus, electronic equipment and readable storage medium storing program for executing

Patent Citations (16)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2009290710A (en) * 2008-05-30 2009-12-10 Hitachi Ltd Image processing apparatus and display unit
US20100305731A1 (en) * 2009-05-29 2010-12-02 Sanyo Electric Co., Ltd. Digital data processing apparatus
US20120262463A1 (en) * 2011-04-03 2012-10-18 Reuven Bakalash Virtualization method of vertical-synchronization in graphics systems
CN106681913A (en) * 2016-12-08 2017-05-17 武汉斗鱼网络科技有限公司 Application not responding positioning system and method
CN106802935A (en) * 2016-12-29 2017-06-06 腾讯科技(深圳)有限公司 The method of testing and device of a kind of page fluency
CN106874168A (en) * 2017-01-12 2017-06-20 北京奇虎科技有限公司 Determine method, device and the mobile terminal of application program runnability
CN108228344A (en) * 2017-08-22 2018-06-29 珠海市魅族科技有限公司 Multi-process internal memory processing method and device, computer installation and readable storage medium storing program for executing
CN107797922A (en) * 2017-09-27 2018-03-13 北京金山安全软件有限公司 Application page testing method, electronic device and electronic equipment
CN109587551A (en) * 2017-09-29 2019-04-05 北京金山云网络技术有限公司 A kind of judgment method, device, equipment and the storage medium of live streaming media Caton
CN107864378A (en) * 2017-11-10 2018-03-30 维沃移动通信有限公司 A kind of frame rate detection method, device, mobile terminal and server
CN108664377A (en) * 2018-05-02 2018-10-16 腾讯音乐娱乐科技(深圳)有限公司 A kind of interim card of user interface determines method, apparatus and storage medium
CN108769815A (en) * 2018-06-21 2018-11-06 威盛电子股份有限公司 Method for processing video frequency and its device
CN109144858A (en) * 2018-08-02 2019-01-04 腾讯科技(北京)有限公司 Fluency detection method, calculates equipment and storage medium at device
CN109522208A (en) * 2018-09-29 2019-03-26 中国平安人寿保险股份有限公司 Page fluency test method and device, computer installation and storage medium
CN109766502A (en) * 2018-12-13 2019-05-17 平安普惠企业管理有限公司 Page improved method, device, computer equipment and storage medium
CN110069194A (en) * 2019-03-21 2019-07-30 北京三快在线科技有限公司 Page Caton determines method, apparatus, electronic equipment and readable storage medium storing program for executing

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111949511A (en) * 2020-07-09 2020-11-17 厦门美柚股份有限公司 Application program pause processing method and device, terminal and storage medium
CN111880602A (en) * 2020-08-03 2020-11-03 北京小米移动软件有限公司 Dropped frame detection method and device
CN111880602B (en) * 2020-08-03 2022-03-01 北京小米移动软件有限公司 Dropped frame detection method and device

Similar Documents

Publication Publication Date Title
CN108721898B (en) Frame rate determination method and apparatus, storage medium, and electronic apparatus
CN110505141B (en) Instant messaging message processing method and device, readable medium and electronic equipment
CN109445884B (en) Function label display method and terminal equipment
CN109862100B (en) Method and device for pushing information
CN109271600B (en) Method, system and device for monitoring performance data
CN111163348A (en) Searching method and device based on video playing
CN112291370B (en) Method for processing service access relation and related equipment
CN113596488B (en) Live broadcast room display method and device, electronic equipment and storage medium
CN108600780B (en) Method for pushing information, electronic device and computer readable medium
CN112866809A (en) Video processing method and device, electronic equipment and readable storage medium
CN109271929B (en) Detection method and device
CN111159042A (en) Fluency testing method and device and electronic equipment
CN110806909A (en) Method and device for determining page frame dropping information of application program and electronic equipment
US20220036427A1 (en) Method for managing immersion level and electronic device supporting same
CN115396705A (en) Screen projection operation verification method, platform and system
CN111131812A (en) Broadcast time testing method and device and computer readable storage medium
CN109492163B (en) List display recording method and device, terminal equipment and storage medium
CN110209539B (en) Test method, terminal equipment and tester
CN114021016A (en) Data recommendation method, device, equipment and storage medium
CN106792251A (en) Method for information display, device and terminal
CN109388737B (en) Method and device for sending exposure data of content item and storage medium
CN110324707B (en) Video playing time consumption testing method and device
CN116661920A (en) Automatic switching method, device, equipment, system and medium for internet pages
CN115424039A (en) Theme color determining method of picture, model training method and device
CN113296666A (en) Anchor exposure data reporting method and device, terminal equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20200218

RJ01 Rejection of invention patent application after publication