CN110909277A - Multimedia resource loading method and device, electronic equipment and storage medium - Google Patents

Multimedia resource loading method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN110909277A
CN110909277A CN201911077099.4A CN201911077099A CN110909277A CN 110909277 A CN110909277 A CN 110909277A CN 201911077099 A CN201911077099 A CN 201911077099A CN 110909277 A CN110909277 A CN 110909277A
Authority
CN
China
Prior art keywords
resolution
window value
multimedia resource
loading
determining
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
CN201911077099.4A
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 QIYI Century Science and Technology Co Ltd
Original Assignee
Beijing QIYI Century Science and Technology 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 QIYI Century Science and Technology Co Ltd filed Critical Beijing QIYI Century Science and Technology Co Ltd
Priority to CN201911077099.4A priority Critical patent/CN110909277A/en
Publication of CN110909277A publication Critical patent/CN110909277A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • 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
    • G06F16/9574Browsing optimisation, e.g. caching or content distillation of access to content, e.g. by caching

Abstract

The embodiment of the invention provides a multimedia resource loading method, a multimedia resource loading device, electronic equipment and a storage medium, and relates to the technical field of Internet, wherein the multimedia resource loading method is applied to the electronic equipment and comprises the following steps: acquiring a first resolution and a first loading time of a loaded first multimedia resource; determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time; loading the second multimedia asset having the second resolution. The multimedia resource loading method provided by the embodiment of the invention effectively avoids the problem of unsmooth loading caused by loading the high-resolution multimedia resource in the low network speed environment; and under the high network speed environment, the resolution of the loaded multimedia resources can be improved, and the browsing experience of the user is improved.

Description

Multimedia resource loading method and device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of internet technologies, and in particular, to a multimedia resource loading method and apparatus, an electronic device, and a storage medium.
Background
To meet the demand for multimedia resources (e.g., pictures, videos, etc.) from electronic devices with different screen resolutions, multimedia resource providers typically provide multimedia resources with multiple resolutions for the same multimedia content.
In some application environments, for example, in transportation vehicles such as subways and high-speed rails, network connection speed of electronic equipment fluctuates, and in the prior art, a loading mode of multimedia resources is not sensitive to the fluctuation of the network connection speed, which is mainly reflected in that it is difficult to switch the resolution of the loaded multimedia resources according to the network connection speed. For example, when the network connection speed is reduced due to fluctuation, if the high-resolution multimedia resource is continuously loaded, phenomena of blank loading, incomplete loading or blocked loading are likely to occur, and further, the problem of low multimedia resource loading fluency is brought, and the use experience of the user is affected.
Disclosure of Invention
The embodiment of the invention aims to provide a multimedia resource loading method, a multimedia resource loading device, electronic equipment and a storage medium, so that the resolution of a loaded multimedia resource can be switched in time when the network connection speed fluctuates, and the loading fluency of the multimedia resource is guaranteed. The specific technical scheme is as follows:
in a first aspect of the present invention, there is provided a multimedia resource loading method applied to an electronic device, including:
acquiring a first resolution and a first loading time of a loaded first multimedia resource;
determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
loading the second multimedia asset having the second resolution.
In a second aspect of the present invention, there is also provided a multimedia resource loading apparatus applied to an electronic device, including:
the acquisition module is used for acquiring a first resolution and a first loading time of a loaded first multimedia resource;
the determining module is used for determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
a loading module for loading the second multimedia resource with the second resolution.
In yet another aspect of the present invention, there is also provided a computer-readable storage medium, having stored therein instructions, which when run on a computer, cause the computer to execute any one of the above-mentioned multimedia asset loading methods.
In yet another aspect of the present invention, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to perform any of the above-mentioned multimedia asset loading methods.
According to the embodiment of the invention, the resolution of the next multimedia resource to be loaded is determined according to the resolution and the loading time of the loaded multimedia, so that the resolution of the multimedia resource to be loaded can be dynamically adjusted according to the network speed in the multimedia resource loading process; the defect that the loading mode of the multimedia resources in the prior art is not sensitive to the fluctuation of the network connection speed is overcome; the problem of unsmooth loading caused by loading high-resolution multimedia resources in a low network speed environment is effectively solved; and under the high network speed environment, the resolution of the loaded multimedia resources can be improved, and the browsing experience of the user is improved.
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.
FIG. 1 is a flowchart illustrating a method for loading multimedia resources according to an embodiment of the present invention;
FIG. 2 is a flow chart of an alternative implementation of determining the second resolution in an embodiment of the present invention;
FIG. 3 is a flow chart of an alternative embodiment of determining a second resolution in an embodiment of the present invention;
FIG. 4 is a flowchart of an alternative implementation of obtaining a third window value in an embodiment of the present invention;
FIG. 5 is a diagram illustrating a mapping relationship among a resolution, a loading time, and a window value of a multimedia resource according to an embodiment of the present invention;
FIG. 6 is a schematic structural diagram of a multimedia resource loading apparatus according to an embodiment of the present invention;
FIG. 7 is a block diagram of a determination module according to an embodiment of the present invention;
FIG. 8 is a block diagram of a second determining submodule in an embodiment of the present invention;
FIG. 9 is a schematic structural diagram of a second obtaining unit according to an embodiment of the present invention;
fig. 10 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 described below with reference to the drawings in the embodiments of the present invention.
The multimedia assets may be picture, video, etc. type assets. In practical applications, for example, when a web page is accessed, a plurality of multimedia resources of the type of thumbnails, dynamic images or videos may be loaded on the web page; the multimedia resources are sequentially loaded in the loading process, for example, the multimedia resources are loaded from top to bottom according to the typesetting positions, or the multimedia resources are loaded according to a preset loading sequence. In the loading process, the network connection speed (hereinafter referred to as network speed) of the electronic device may fluctuate, thereby causing a large difference in loading time of different multimedia resources. The multimedia resource loading method provided by the embodiment of the invention is mainly described below by taking a process of loading a plurality of pictures on a webpage as an example.
As shown in fig. 1, a multimedia resource loading method provided in an embodiment of the present invention is applied to an electronic device, and includes:
step S100, acquiring a first resolution and a first loading time of a loaded first multimedia resource;
step S200, determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
step S300, loading the second multimedia resource with the second resolution.
When a plurality of pictures exist on a webpage accessed by a user, the loading of the pictures has a sequence, when the webpage starts to load a first picture (namely a first multimedia resource), a loading request of the first picture is intercepted, the first resolution of the first picture is determined, timing is started, and when the loading of the first picture on the webpage is finished, first loading time is obtained. According to the first resolution and the first loading time of the first picture, a reasonable expectation can be made on the current network state of the electronic equipment, the second resolution of a second picture to be loaded (namely, a second multimedia resource) is determined according to the current network state of the electronic equipment, and the second picture with the second resolution is loaded when a loading request of the second picture is obtained.
For example, the pictures loaded on the web page have several resolutions, i.e. 2M, 1M, 512k, 256k and 128k, and an acceptable loading time range, e.g. 0.3s to 0.8s, is preset for each resolution. Setting the first resolution of the first picture as 512k, if the first loading time of the first picture is 0.5s, the first loading time is within the acceptable loading time range, which indicates that the current network speed is moderate, and determining the second resolution of the second picture to be loaded as 512 k; if the first loading time is 0.2s and the first loading time is lower than the minimum value of the acceptable loading time range, the current network speed is high, and in order to improve the browsing experience of a user on a webpage, the second resolution of the second picture can be determined to be 1M; if the first loading time is 1s, the first loading time is higher than the maximum value of the acceptable loading time range, which indicates that the current network speed is slow, and in order to avoid situations such as too long loading time, incomplete loading, and the like, the second resolution of the second picture may be determined to be 256 k.
The pictures may be present on the same web page or on different web pages of the same application, for example, when a user closes a web page and opens a new web page, the resolution of the first picture loaded on the new web page may be determined by the resolution and loading time of the last picture loaded on the last closed web page. It will be appreciated that for a dynamic map, the resolution may also be understood as frames per second.
In addition, the multimedia resources can be not only pictures, but also video and other resources; for the video, the resolution ratios of the same video resource in different playing time periods can be adjusted; the resolution may be adjusted for each of a plurality of video resources played in sequence. For example: for a long video, the long video can be pre-divided into a plurality of segments, the playing time of each segment is 2 minutes, and the resolution of the next segment to be loaded is determined by the resolution and the loading time of the previous segment. For another example, for a plurality of short videos with relatively similar time duration, the resolution of the next short video to be loaded may be determined according to the resolution and the loading time of the previously loaded short video.
According to the embodiment of the invention, the resolution of the next multimedia resource to be loaded is determined according to the resolution and the loading time of the loaded multimedia, so that the resolution of the multimedia resource to be loaded can be dynamically adjusted according to the network speed in the multimedia resource loading process; the defect that the loading mode of the multimedia resources in the prior art is not sensitive to the fluctuation of the network connection speed is overcome; the problem of unsmooth loading caused by loading high-resolution multimedia resources in a low network speed environment is effectively solved; and under the high network speed environment, the resolution of the loaded multimedia resources can be improved, and the browsing experience of the user is improved.
Optionally, as shown in fig. 2, the step S200 of determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time includes:
step S210, determining a first window value according to the first resolution and the first loading time;
step S220, determining a second resolution of the second multimedia resource to be loaded according to the first window value.
In one possible embodiment, for any resolution, the corresponding load time versus window value formula can be expressed as:
Figure BDA0002262828810000051
wherein, wi(t) represents a window value when the loading time is t at the resolution of the serial number i;
Figure BDA0002262828810000052
a window value end point value representing a resolution with a sequence number i;
Figure BDA0002262828810000053
a window value starting value representing a resolution with a sequence number i;
Figure BDA0002262828810000054
a base load time endpoint value representing a resolution of a sequence number i;
Figure BDA0002262828810000055
a base load time start value representing a resolution with index i. As described above
Figure BDA0002262828810000056
All are preset values, and can be defined according to actual needs. The sequence number i of the resolution can be obtained by sequentially ordering and numbering the sizes of the resolutions, for example, for five resolutions of 2M, 1M, 512k, 256k and 128k, the sequence number i thereof can be sequentially defined as 1, 2, 3, 4 and 5.
Let the acceptable loading time range be 0.3 s-0.8 s for each resolution picture, i.e. for any resolution there is
Figure BDA0002262828810000057
Definition for a resolution of 2K it is,
Figure BDA0002262828810000058
i.e. according to equation (1), if the obtained w is calculatediWhen the value of (t) is in the interval [1,1.5), the second resolution is determined to be 2K. In defining the window value start point value and the window value end point value at the remaining resolutions, the following relationship may be satisfied:
Figure BDA0002262828810000059
to ensure the continuity of the window value, a window value w is obtained by calculationi(t) can be calculated from the window value wi(t) finding a unique corresponding resolution.
Based on the above rules, it can further be set that: if calculated according to the formula (1) to obtain wi(t) determining the second resolution to be 1K when the value is in the interval [1.5, 2.5); if calculated wi(t) when the value is in the interval [2.5,5), determining the second resolution as 512 k; if calculated wi(t) when the value is in the interval [5,13), determining the second resolution to be 256 k; if calculated wiThe (t) value is in the interval [13, M), where M is a constant greater than 13, the second resolution is determined to be 128 k.
Assuming that the first resolution of the first picture is 512k, the above formula (1) can be simplified as w3(t) 5t +1, when the first loading time is 0.5s, w is calculated3(t) 3.5, and within the interval [2.5,5), determining the second resolution to be 512 k; when the first loading time is 0.05s, w3(t) ═ 1.25, over the interval [1,1.5), the second resolution was determined to be 2M; when the first loading time is 0.2s, w3(t) ═ 2, in the interval [1.5,2.5), the second resolution is determined to be 1M; when the first loading time is 1s, w3When (t) is 6, the second resolution is determined to be 256k in the interval [5, 13).
Of course, the above description is only for one possible implementation of the present embodiment, and in practical applications,
Figure BDA0002262828810000061
can be adjusted according to actual needs; for any resolution, the corresponding loading time may not be a linear function (e.g., an exponential function, a quadratic function that increases or decreases within an acceptable loading time, etc.).
In this embodiment, the first window value is determined according to the first resolution and the first loading time, and then the second resolution is determined according to the first window value, so that the second resolution can be directly determined as any resolution according to the network speed, and the resolution of the second multimedia resource can be switched more flexibly.
Optionally, as shown in fig. 3, the step S220 of determining a second resolution of a second multimedia resource to be loaded according to the first window value includes:
step S221, obtaining a second window value, where the second window value is a window value used for determining a first resolution of the first multimedia resource;
step S222, obtaining a third window value according to the first window value and the second window value;
step S223, determining a second resolution of the second multimedia resource to be loaded according to the window value interval where the third window value is located and the corresponding relationship between the preset window value interval and the resolution.
Taking the example of loading multiple pictures on the web page, since the first picture may be the first picture loaded on the web page when the user accesses the web page, or may be the nth picture (N is a positive integer greater than 1) loaded. When the first picture is the first picture, the second window value can be a preset window value; when the first picture is the nth picture, the second window value may be a window value calculated based on the loading process of the N-1 st picture.
To explain the working principle of this embodiment more clearly, the following is combined with the formula (1) and
Figure BDA0002262828810000062
the following describes a possible implementation of this embodiment:
when a first picture is loaded on a webpage, a preset window value is obtained and set to be 2.5 (corresponding to a second window value at this time), a picture with the resolution of 512k is loaded correspondingly, and the formula (1) can be simplified to w3(t) 5t + 1. If the loading time of the first picture is 1.5s, calculating w3(t) 8.5 (corresponding to the first window value in this case). Averaging the two window values of 2.5 and 8.5 to obtain a third window value of 5.5; the third window value is used to determine the resolution of the second picture to be loaded, and since the third window value is within the interval [5,13), the resolution of the second picture to be loaded is determined to be 256 k.
When the second picture is loaded on the webpage and the third picture is to be loaded, acquiring the sub-group of the second pictureResolution (i.e., 256k) and load time (set to 0.6s), equation (1) now reduces to w4(t) 16t +0.2, and t 0.6s into the formula w4W is calculated in (t) ═ 16t +0.24(t) 9.8 (corresponding to the first window value at this time); since the resolution of the second picture is determined based on the window value of 5.5 (which corresponds to the second window value at this time), the two window values of 9.8 and 5.5 are averaged to obtain a third window value of 7.65; at this time, the third window value is used to determine the resolution of the third picture to be loaded, and since the third window value is still in the interval [5,13), the resolution of the third picture to be loaded is determined to be 256 k.
The determination of the resolution of more loaded pictures can be embodied by the following table:
load sequence number 0 (Preset) 1 2 3 4
Load time 1.5s 0.6s 0.2s 0.15s
When the corresponding window value is loaded 8.5 9.8 3.4 2.6
Next window value (average value) 2.5 5.5 7.65 5.525 4.0625
Next time loading resolution 512k 256k 256k 256k 512k
In the above table, the "current loading corresponding window value" under one loading serial number corresponds to the first window value under the loading serial number; the "next window value" under one loading sequence number corresponds to the third window value under the loading sequence number, and also corresponds to the second window value under the next loading sequence number. The "next loading resolution" at a loading sequence number corresponds to the second resolution at the loading sequence number, and also corresponds to the first resolution at the next loading sequence number.
In this embodiment, when determining the second resolution, not only the first window value calculated according to the first resolution and the first loading time of the first multimedia resource is considered, but also the window value used for determining the first resolution of the first multimedia resource is considered, that is, the resolution of the multimedia resource to be loaded is determined by using the window values of a plurality of time points, so that the resolution of the multimedia resource is prevented from being greatly fluctuated in the loading process.
Of course, in some optional embodiments, in the process of calculating the third window value according to the first window value and the second window value, the third window value may also be calculated by performing weighted average, geometric average, harmonic average, square average, and the like on the first window value and the second window value; alternatively, the third window value is calculated based on more window values.
Optionally, as shown in fig. 4, in step S222, obtaining a third window value according to the first window value and the second window value includes:
step S2221, calculating the change rate of the first window value relative to the second window value;
step S2222, determining a weight coefficient of the first window value according to the change rate;
step S2223, according to the weight coefficient, perform weighted average calculation on the first window value and the second window value to obtain the third window value.
In this embodiment, a third window value is obtained by performing weighted average calculation on the first window value and the second window value, and when the first window value becomes larger or smaller sharply than the second window value, the weight coefficient of the first window value may be decreased.
For example, the weight coefficients of the first window value and the second window value are a and b, respectively, and the variation rate r of the first window value relative to the second window value can be calculated by the following formula:
r ═ second window value/first window value
Define that when r < -0.5 or r >1, the value of a is reduced. Assuming that a-b-0.5 under the initial condition, the second window value is 3 (the resolution of the loaded picture is 512 k); when the first window value is less than 1.5, or more than 6, the value of a can be adjusted to be 0.3; setting the first window value to be 8 specifically, if a is not adjusted, calculating to obtain a third window value of 5.5, and then reducing the resolution of the picture to be loaded to 256 k; if the value of a is reduced to 0.3, the calculated third window value is 4.875, and the resolution of the picture to be loaded is still 512k at this time. Therefore, when the change of the first window value relative to the second window value is too violent, the fluctuation of the multimedia resource resolution ratio in the loading process can be effectively reduced by reducing the weight coefficient of the second window value.
Alternatively, when-0.5 ≦ r ≦ 1, the value of a may be reset back to 0.5.
Optionally, if it is required to quickly adjust the resolution of the multimedia resource to be loaded when the network speed fluctuates severely, the value of a may also be increased when r < -0.5 or r >1, for example, when the electronic device is on a subway and enters an area with a low network speed, the value of a may be increased to quickly switch to loading a picture with a low resolution, so as to complete the loading of the picture on the web page as soon as possible, and avoid the situations of blank loading and incomplete loading after the network speed is too low or no signal area.
The values of a, b, and r are set merely for convenience of explaining the operation principle of the present embodiment, and in practical applications, the values of a, b, and r may be set as needed; in addition, in some possible embodiments, the weighting coefficient b of the second window value may also be adjusted according to r, or a and b may also be adjusted at the same time.
Optionally, in step S210, determining a first window value according to the first resolution and the first loading time includes:
and determining the first window value according to the first resolution and the first loading time and a preset corresponding relation, wherein the preset corresponding relation is the corresponding relation among the resolution of the multimedia resource, the loading time and the window value.
In this embodiment, the preset corresponding relationship may be embodied by a line graph as shown in fig. 5, where the ordinate is a window value, the abscissa is a loading time, and the preset corresponding relationship is divided into a plurality of intervals by different resolutions, each interval having a corresponding loading time variation range (i.e., on the whole abscissa axis, the loading time may not be increased to the right in a single direction along the origin of coordinates).
The preset corresponding relation can be established in the following way:
1) the resolutions of the multimedia resources are sorted according to high and low levels, for example, five resolutions of 2M, 1M, 512k, 256k and 128k are sequentially sorted;
2) defining a reference loading time starting point value for any one resolution ratio
Figure BDA0002262828810000091
And a base loading time endpoint value
Figure BDA0002262828810000092
Wherein the subscript i represents the serial number of the resolution, and the serial number i can be sequentially defined as 1, 2, 3, 4 and 5 for five resolutions of 2M, 1M, 512k, 256k and 128 k; for the
Figure BDA0002262828810000093
Corresponding to different values of i
Figure BDA0002262828810000094
Can be the same or different from each other,
Figure BDA0002262828810000095
the same is true for the same;
3) a base load time origin value corresponding to any one of the resolutions
Figure BDA0002262828810000096
Base load time end value
Figure BDA0002262828810000097
Defining window value start points respectively
Figure BDA0002262828810000098
Window value end point value
Figure BDA0002262828810000099
Wherein the content of the first and second substances,
Figure BDA00022628288100000910
4) will be provided with
Figure BDA00022628288100000911
The resolution, the loading time and the window value of the multimedia resource are sequentially connected by a straight line, and the corresponding relationship among the resolution, the loading time and the window value of the multimedia resource is established, that is, for any resolution, the relationship between the corresponding window value and the loading time is a linear function relationship (the relationship corresponding to the resolution of 128k is not shown in fig. 5)
Figure BDA00022628288100000912
Value and function line).
When a first window value is determined, firstly determining a calculation interval according to a first resolution, namely determining a linear function relation between the window value and loading time, and then calculating to obtain the first window value according to the first loading time and the determined linear function relation; in a subsequent step, the second resolution is determined using the first window value, e.g. when the first window value is at
Figure BDA0002262828810000101
When in range, the second resolution is determined to be 512 k.
In the practical application of the method, the material is,
Figure BDA0002262828810000102
the two can also be connected by a curve, such as an exponential function curve, a one-way increasing quadratic function curve, and the like.
The embodiment determines the first window value through the first resolution, the first loading time and the preset corresponding relation, and has the advantages of accuracy and quickness.
Optionally, the resolution in the preset corresponding relationship is in positive correlation or negative correlation with a window value change rate, where the window value change rate is a change rate of a window value relative to a loading time in the preset corresponding relationship.
As shown in fig. 5, in one possible embodiment, the slope of the line corresponding to the resolution on the left side is smaller than the slope of the line corresponding to the resolution on the right side, that is, the resolution is inversely related to the window value change rate. The larger the resolution ratio is, the smaller the window value change rate is, and the smaller the resolution ratio is, the larger the window value change rate is, so that when a low-resolution picture is loaded, the window value can move to a high resolution ratio more easily, can be switched to the high-resolution picture more quickly, and can be kept in a high-resolution picture area more stably.
In another possible embodiment, the slope of the line corresponding to the left resolution is greater than the slope of the line corresponding to the right resolution, that is, the resolution is positively correlated to the window value change rate. When the resolution ratio is larger, the window value change rate is larger, and when the resolution ratio is smaller, the window value change rate is smaller, so that the image can be more stably kept in a low-resolution image area.
According to the multimedia resource loading method provided by the embodiment of the invention, the loading time and the resolution of the loaded multimedia resource are used as input, and the resolution of the multimedia resource to be loaded after dynamic adjustment is carried out, so that the multimedia resource can still be displayed on a webpage or application quickly under the condition that the network environment of the electronic equipment fluctuates, and a user can obtain better browsing experience.
An embodiment of the present invention further provides a multimedia resource loading apparatus, which is applied to an electronic device, and as shown in fig. 6, the apparatus includes:
an obtaining module 410, configured to obtain a first resolution and a first loading time of a loaded first multimedia resource;
a determining module 420, configured to determine a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
a loading module 430, configured to load the second multimedia resource with the second resolution.
Optionally, as shown in fig. 7, the determining module 420 includes:
a first determining submodule 421, configured to determine a first window value according to the first resolution and the first loading time;
the second determining submodule 422 is configured to determine, according to the first window value, a second resolution of the second multimedia resource to be loaded.
Optionally, as shown in fig. 8, the second determining sub-module 422 includes:
a first obtaining unit 4221, configured to obtain a second window value, where the second window value is a window value used for determining a first resolution of the first multimedia resource;
a second obtaining unit 4222, configured to obtain a third window value according to the first window value and the second window value;
a first determining unit 4223, configured to determine a second resolution of the second multimedia resource to be loaded according to a window value interval where the third window value is located and a preset corresponding relationship between the window value interval and the resolution.
Optionally, as shown in fig. 9, the second obtaining unit 4222 includes:
a first calculating subunit 42221, configured to calculate a change rate of the first window value with respect to the second window value;
a determining subunit 42222, configured to determine a weight coefficient of the first window value according to the change rate;
a second calculating subunit 42223, configured to perform weighted average calculation on the first window value and the second window value according to the weight coefficient, so as to obtain the third window value.
Optionally, the first determining submodule 421 includes:
and a second determining unit, configured to determine the first window value according to a preset correspondence between the first resolution and the first loading time, where the preset correspondence is a correspondence between a resolution of the multimedia resource, the loading time, and the window value.
Optionally, the resolution in the preset corresponding relationship is in positive correlation or negative correlation with a window value change rate, where the window value change rate is a change rate of a window value relative to a loading time in the preset corresponding relationship.
It should be noted that the multimedia resource loading apparatus provided in the embodiment of the present invention is an apparatus corresponding to the multimedia resource loading method, and all implementation manners in the embodiment of the method are applicable to the embodiment of the apparatus, so that the same technical effect can be achieved.
An embodiment of the present invention further provides an electronic device, as shown in fig. 10, 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 first resolution and a first loading time of a loaded first multimedia resource;
determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
loading the second multimedia asset having the second resolution.
Optionally, the determining, according to the first resolution and the first loading time, a second resolution of a second multimedia resource to be loaded includes:
determining a first window value according to the first resolution and the first loading time;
and determining the second resolution of the second multimedia resource to be loaded according to the first window value.
Optionally, the determining, according to the first window value, a second resolution of a second multimedia resource to be loaded includes:
acquiring a second window value, wherein the second window value is used for determining the first resolution of the first multimedia resource;
acquiring a third window value according to the first window value and the second window value;
and determining the second resolution of the second multimedia resource to be loaded according to the window value interval where the third window value is located and the corresponding relation between the preset window value interval and the resolution.
Optionally, the obtaining a third window value according to the first window value and the second window value includes:
calculating the change rate of the first window value relative to the second window value;
determining a weight coefficient of the first window value according to the change rate;
and according to the weight coefficient, performing weighted average calculation on the first window value and the second window value to obtain the third window value.
Optionally, the determining a first window value according to the first resolution and the first loading time includes:
and determining the first window value according to the first resolution and the first loading time and a preset corresponding relation, wherein the preset corresponding relation is the corresponding relation among the resolution of the multimedia resource, the loading time and the window value.
Optionally, the resolution in the preset corresponding relationship is in positive correlation or negative correlation with a window value change rate, where the window value change rate is a change rate of a window value relative to a loading time in the preset corresponding relationship.
The communication bus mentioned in the above terminal 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 terminal and other equipment.
The Memory may include a Random Access Memory (RAM) or a non-volatile Memory (non-volatile Memory), such as at least one disk Memory. Optionally, the memory may also 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, which stores instructions that, when executed on a computer, cause the computer to execute the multimedia resource loading method described in any of the above embodiments.
In yet another embodiment, the present invention further provides a computer program product containing instructions, which when run on a computer, causes the computer to execute the multimedia resource loading method described in any of the above embodiments.
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. When loaded and executed on a computer, cause the processes or functions described in accordance with the embodiments of the invention to occur, in whole or in part. 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 in a computer readable storage medium or transmitted from one computer readable storage medium to another, for example, from one website site, computer, server, or data center to another website site, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, 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 incorporates one or more of the available media. The usable medium may be a magnetic medium (e.g., floppy Disk, hard Disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., Solid State Disk (SSD)), among others.
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, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made 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 multimedia resource loading method is applied to electronic equipment and is characterized by comprising the following steps:
acquiring a first resolution and a first loading time of a loaded first multimedia resource;
determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
loading the second multimedia asset having the second resolution.
2. The method of claim 1, wherein determining the second resolution of the second multimedia resource to be loaded according to the first resolution and the first loading time comprises:
determining a first window value according to the first resolution and the first loading time;
and determining the second resolution of the second multimedia resource to be loaded according to the first window value.
3. The method of claim 2, wherein determining the second resolution of the second multimedia resource to be loaded according to the first window value comprises:
acquiring a second window value, wherein the second window value is used for determining the first resolution of the first multimedia resource;
acquiring a third window value according to the first window value and the second window value;
and determining the second resolution of the second multimedia resource to be loaded according to the window value interval where the third window value is located and the corresponding relation between the preset window value interval and the resolution.
4. The method of claim 3, wherein obtaining a third window value according to the first window value and the second window value comprises:
calculating the change rate of the first window value relative to the second window value;
determining a weight coefficient of the first window value according to the change rate;
and according to the weight coefficient, performing weighted average calculation on the first window value and the second window value to obtain the third window value.
5. The method of claim 2, wherein determining a first window value based on the first resolution and the first load time comprises:
and determining the first window value according to the first resolution and the first loading time and a preset corresponding relation, wherein the preset corresponding relation is the corresponding relation among the resolution of the multimedia resource, the loading time and the window value.
6. The method according to claim 5, wherein the resolution in the preset correspondence is positively or negatively correlated with a window value change rate, wherein the window value change rate is a change rate of a window value relative to a loading time in the preset correspondence.
7. A multimedia resource loading device applied to electronic equipment is characterized by comprising:
the acquisition module is used for acquiring a first resolution and a first loading time of a loaded first multimedia resource;
the determining module is used for determining a second resolution of a second multimedia resource to be loaded according to the first resolution and the first loading time;
a loading module for loading the second multimedia resource with the second resolution.
8. The apparatus of claim 7, wherein the determining module comprises:
the first determining submodule is used for determining a first window value according to the first resolution and the first loading time;
and the second determining submodule is used for determining the second resolution of the second multimedia resource to be loaded according to the first window value.
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 as claimed in any one of claims 1 to 6 when executing a program stored in the memory.
10. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the method according to any one of claims 1-6.
CN201911077099.4A 2019-11-06 2019-11-06 Multimedia resource loading method and device, electronic equipment and storage medium Pending CN110909277A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911077099.4A CN110909277A (en) 2019-11-06 2019-11-06 Multimedia resource loading method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911077099.4A CN110909277A (en) 2019-11-06 2019-11-06 Multimedia resource loading method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN110909277A true CN110909277A (en) 2020-03-24

Family

ID=69815848

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911077099.4A Pending CN110909277A (en) 2019-11-06 2019-11-06 Multimedia resource loading method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN110909277A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112596850A (en) * 2021-03-03 2021-04-02 全时云商务服务股份有限公司 Control method and system for multi-window application program
CN114979757A (en) * 2022-06-02 2022-08-30 北京字跳网络技术有限公司 Video distribution method, device, equipment and storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6070195A (en) * 1997-01-31 2000-05-30 Canon Kabushiki Kaisha Image display device and method, and image communication apparatus and method
CN102946418A (en) * 2012-10-26 2013-02-27 北京奇虎科技有限公司 Terminal equipment, picture providing system and picture transmission method
CN105979367A (en) * 2016-05-25 2016-09-28 乐视控股(北京)有限公司 Playing control method and apparatus
CN106254902A (en) * 2016-08-19 2016-12-21 恒安嘉新(北京)科技有限公司 A kind of based on mobile Internet video user perception and the method and system of analysis
CN107172274A (en) * 2017-04-27 2017-09-15 努比亚技术有限公司 It is a kind of to reduce the method and terminal of load
CN109040802A (en) * 2018-09-03 2018-12-18 青岛海信传媒网络技术有限公司 A kind of method and device that media resource obtains

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6070195A (en) * 1997-01-31 2000-05-30 Canon Kabushiki Kaisha Image display device and method, and image communication apparatus and method
CN102946418A (en) * 2012-10-26 2013-02-27 北京奇虎科技有限公司 Terminal equipment, picture providing system and picture transmission method
CN105979367A (en) * 2016-05-25 2016-09-28 乐视控股(北京)有限公司 Playing control method and apparatus
CN106254902A (en) * 2016-08-19 2016-12-21 恒安嘉新(北京)科技有限公司 A kind of based on mobile Internet video user perception and the method and system of analysis
CN107172274A (en) * 2017-04-27 2017-09-15 努比亚技术有限公司 It is a kind of to reduce the method and terminal of load
CN109040802A (en) * 2018-09-03 2018-12-18 青岛海信传媒网络技术有限公司 A kind of method and device that media resource obtains

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112596850A (en) * 2021-03-03 2021-04-02 全时云商务服务股份有限公司 Control method and system for multi-window application program
CN114979757A (en) * 2022-06-02 2022-08-30 北京字跳网络技术有限公司 Video distribution method, device, equipment and storage medium
CN114979757B (en) * 2022-06-02 2024-01-30 北京字跳网络技术有限公司 Video publishing method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
US9195637B2 (en) Proportional font scaling
CN108228463B (en) Method and device for detecting first screen time
US20220005393A1 (en) Method and device for determining pixel compensation value, electronic device and storage medium
CN108174276B (en) Bullet screen display method and display device
CN111583886A (en) Screen refresh rate adjusting method, device, equipment and medium
CN110909277A (en) Multimedia resource loading method and device, electronic equipment and storage medium
CN109767401B (en) Picture optimization method, device, terminal and corresponding storage medium
CN112395038B (en) Method and device for adjusting characters during desktop sharing
WO2022116936A1 (en) Interface layout method, electronic device, and computer-readable storage medium.
CN111757180B (en) Video display control device, video display system, video display method and device
CN108600780B (en) Method for pushing information, electronic device and computer readable medium
WO2019241775A1 (en) Systems and methods for optimized computer vision using deep neural networks and lipschitz analysis
CN105373593A (en) Method and apparatus for displaying target element from webpage
CN109635263B (en) Column width fixed display method and device based on WEB ultra-wide table and electronic equipment
US11134180B2 (en) Detection method for static image of a video and terminal, and computer-readable storage medium
US10600091B2 (en) Systems and methods for view-based advertisement selection
CN109429101B (en) Desktop loading method and device of interactive network television
CN113038055B (en) Image processing method and device and electronic equipment
CN110110260B (en) Page rendering method and device and electronic equipment
CN110992903B (en) Display screen backlight brightness adjusting method and device, computer equipment and medium
CN113626113B (en) Page rendering method and device
CN114170091A (en) Image scaling method and device, electronic equipment and storage medium
CN112258386A (en) Image deformation acceleration processing method and device, electronic equipment and readable storage medium
US11556237B2 (en) Picture presentation method and device
CN111787310A (en) Anti-shake performance testing method and device, computer equipment and storage medium

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20200324