CN107197371A - The switching method and device of video definition - Google Patents

The switching method and device of video definition Download PDF

Info

Publication number
CN107197371A
CN107197371A CN201610149109.0A CN201610149109A CN107197371A CN 107197371 A CN107197371 A CN 107197371A CN 201610149109 A CN201610149109 A CN 201610149109A CN 107197371 A CN107197371 A CN 107197371A
Authority
CN
China
Prior art keywords
video source
video
definition
source
sharpness
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201610149109.0A
Other languages
Chinese (zh)
Other versions
CN107197371B (en
Inventor
刘成
罗彬�
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Alibaba China Co Ltd
Original Assignee
Guangzhou Dongjing Computer 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 Guangzhou Dongjing Computer Technology Co Ltd filed Critical Guangzhou Dongjing Computer Technology Co Ltd
Priority to CN201610149109.0A priority Critical patent/CN107197371B/en
Priority to PCT/CN2017/075638 priority patent/WO2017157191A1/en
Publication of CN107197371A publication Critical patent/CN107197371A/en
Application granted granted Critical
Publication of CN107197371B publication Critical patent/CN107197371B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • H04N21/440263Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display by altering the spatial resolution, e.g. for displaying on a connected PDA
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream or rendering scenes according to encoded video stream scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/442Monitoring of processes or resources, e.g. detecting the failure of a recording device, monitoring the downstream bandwidth, the number of times a movie has been viewed, the storage space available from the internal hard disk
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/442Monitoring of processes or resources, e.g. detecting the failure of a recording device, monitoring the downstream bandwidth, the number of times a movie has been viewed, the storage space available from the internal hard disk
    • H04N21/44209Monitoring of downstream path of the transmission network originating from a server, e.g. bandwidth variations of a wireless network

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Databases & Information Systems (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The invention discloses a kind of switching method of video definition and device, it is related to video broadcasting field, to be invented the problem of solving definition handoff procedure influence video playback fluency.The method of the present invention includes:Switch Video definition is determined whether according to current network condition during the first video source is played;The second decoding storehouse is set up if Switch Video definition, the second video source of levels of sharpness corresponding with current network speed is loaded by the second decoding storehouse;According to playing progress rate the second video source of synchronous broadcasting of the first video source on the newly-built painting canvas overlapping with the first video source painting canvas;Commencing play out the transparency transition and conversion of the first video source painting canvas in the preset duration that the second video source rises to be fully transparent, while being completely opaque by the transparency transition and conversion of newly-built painting canvas;The sound of first video source is switched to the sound of the second video source;Stop playing the first video source.During switching online video definition.

Description

The switching method and device of video definition
Technical field
The present invention relates to the switching method and dress of video broadcasting field, more particularly to a kind of video definition Put.
Background technology
At present, major video websites can all provide the video of different definition for Online Video, more Common levels of sharpness includes " SD ", " high definition ", " super clear " etc..User is passing through browser Web player or APP clients primary player viewing Online Video when, can be according to net Network condition and the suitable levels of sharpness of demands of individuals selection.Generally, do not limited in the network bandwidth In the case of, user typically understands the higher video-see of prioritizing selection definition, and when the network bandwidth without When method supports current levels of sharpness, then user is needed to lower the levels of sharpness of video.
In the prior art, the switching of video definition is mainly manually operated completion, and user clicks on and broadcast " definition " control in device is put, the definition needed is selected in the levels of sharpness menu of triggering Grade.After user's selection is finished, client stops the broadcasting of former video, and please be looked for novelty to service end Levels of sharpness video, after the stream medium data of new video is loaded into, player from stop broadcast The point of interruption put commences play out new video, thus completes the definition switching of video.
The mode of existing Switch Video definition needs the manually operated intervention of user, and client exists After the former video of stopping broadcasting, before the video that loading is new, player is in the state that can not be played, Until new video loading completes to continue to play.Therefore video display process can cutting because of definition Change and be forced to interrupt, so as to influence the fluency of video playback, user's viewing video is brought inconvenience.
The content of the invention
The invention provides a kind of switching method of video definition and device, it can solve the problem that definition is cut The problem of changing process influence video playback fluency.
To solve the above problems, on the one hand, the invention provides a kind of switching method of video definition, This method includes:
It is true according to current network condition during the first video source is played by the first decoding storehouse It is fixed whether Switch Video definition;
If Switch Video definition, the second decoding storehouse is set up, by the second decoding storehouse loading and currently Second video source of the corresponding levels of sharpness of network speed, the second video source is same with the first video source The different video source of video content;
On the newly-built painting canvas overlapping with the first video source painting canvas, according to the playing progress rate of the first video source It is synchronous to play the second video source, wherein, the initial transparent degree of newly-built painting canvas is fully transparent, and second regards The initial play volume in frequency source is identical with the broadcast sound volume of the first video source;
Commencing play out in the preset duration that the second video source rises, by the transparency of the first video source painting canvas Transition and conversion is fully transparent, while being completely opaque by the transparency transition and conversion of newly-built painting canvas; And the sound of the first video source is switched to the sound of the second video source;
Stop playing the first video source.
On the other hand, present invention also offers a kind of switching device of video definition, the device includes:
Determining unit, during playing the first video source by the first decoding storehouse in broadcast unit, Switch Video definition is determined whether according to current network condition;
Loading unit, if for Switch Video definition, setting up the second decoding storehouse, passes through the second solution Code storehouse loads the second video source of levels of sharpness corresponding with current network speed, the second video source and first Video source is the different video source of same video content;
Broadcast unit, in the newly-built painting canvas overlapping with the first video source painting canvas, being regarded according to first The playing progress rate in frequency source synchronously plays the second video source, wherein, the initial transparent degree of newly-built painting canvas has been All-transparent, the initial play volume of the second video source is identical with the broadcast sound volume of the first video source;
Control unit, for commencing play out in the preset duration that the second video source rises, by the first video The transparency transition and conversion of source painting canvas is fully transparent, while by the transparency transition and conversion of newly-built painting canvas For completely it is opaque;And the sound of the first video source is switched to the sound of the second video source;
Broadcast unit is additionally operable to stop playing the first video source.
The switching method and device for the video definition that the present invention is provided, can be according to current network bar Part automatically determines whether Switch Video definition, if it need to switch selection matched with current network speed it is clear Second video source of degree grade is loaded, and handoff procedure performs any operation without user;In switching During definition, the present invention is realized using dual decoding storehouse mechanism, i.e., play first in the first decoding storehouse During video source, by the second decoding storehouse on the newly-built painting canvas overlapping with the first video source painting canvas It is synchronous to play the second video source, the buffer gap between video source is thus eliminated, video source picture is realized Seamless connection;In addition, the present invention also uses the handover mechanism of gradual change form, by transparent to painting canvas The smooth conversion of image sharpness is realized in the transition adjustment of degree, so as to avoid the great-jump-forward of image sharpness Change so that handoff procedure is more natural and tripping.What time summary is as can be seen that the present invention is provided Video definition switching method and device, video definition can be carried out automatically seamless smoothly to cut Change, can in handoff procedure effective guarantee video playback fluency.
Described above is only the general introduction of technical solution of the present invention, in order to better understand the present invention's Technological means, and being practiced according to the content of specification, and in order to allow the above-mentioned of the present invention and Other objects, features and advantages can become apparent, below especially exemplified by the embodiment of the present invention.
Brief description of the drawings
By reading the detailed description of hereafter preferred embodiment, various other advantage and benefit for Those of ordinary skill in the art will be clear understanding.Accompanying drawing is only used for showing the mesh of preferred embodiment , and it is not considered as limitation of the present invention.And in whole accompanying drawing, with identical with reference to symbol Number represent identical part.In the accompanying drawings:
Fig. 1 shows a kind of switching method flow chart of video definition provided in an embodiment of the present invention;
Fig. 2 shows the switching method flow chart of another video definition provided in an embodiment of the present invention;
Fig. 3 shows a kind of composition frame of the switching device of video definition provided in an embodiment of the present invention Figure;
Fig. 4 shows the composition of the switching device of another video definition provided in an embodiment of the present invention Block diagram.
Embodiment
The exemplary embodiment of the disclosure is more fully described below with reference to accompanying drawings.Although showing in accompanying drawing The exemplary embodiment of the disclosure is shown, it being understood, however, that may be realized in various forms the disclosure Without that should be limited by embodiments set forth here.Conversely it is able to more there is provided these embodiments Thoroughly understand the disclosure, and can be by the technology for conveying to this area of the scope of the present disclosure completely Personnel.
The embodiments of the invention provide a kind of switching method of video definition, this method is predominantly located at hand Machine, PC (PC), tablet personal computer, wearable device etc. can install DST PLAYER Electronic equipment side is performed, and the DST PLAYER can be the primary players of APP or web player. As shown in figure 1, this method includes:
101st, during the first video source is played by the first decoding storehouse, according to current network bar Part determines whether Switch Video definition.
Under normal circumstances, the levels of sharpness that player can be selected according to set or user plays video source, , can be by levels of sharpness according to the order of definition from low to high in a kind of definition grade scale It is in turn divided into:Smoothness, SD, high definition, ultra high-definition etc. are several.Can also basis in practical application Different vendor standard, professional standard, industry alliance's standard or countries/international standard formulates different clear The clear degree criteria for classifying, the present embodiment is not restricted to this.
First video source is the video source being currently played, and the levels of sharpness of the first video source can be with It is that player or video website default setting or user start or played in video playback Set manually in journey.In the present embodiment, the first video source is played by the first decoding storehouse in player When, equipment is using current network condition as basis for estimation, it is determined whether Switch Video definition.
The network condition can be the bandwidth speed (being subsequently referred to as network speed) or net of network Network type, the latter is such as 3G network, WIFI network, VPN.Equipment can be sent out in network speed Enter line definition switching during changing, or when network type changes (more due to network switching Cause) enter line definition switching.For the mobile networks such as GSM, 3G, 4G, the network Condition can further include equipment position in the cell, the load state of equipment own base station, The size of communication mode (either simplex, duplex) and equipment transmitting/receiving power between equipment and base station Deng.In general, the change of above-mentioned condition can change the signal strength of equipment in the cell, so that shadow The communication speed of down direction is rung, therefore the change of above-mentioned condition can be turned to triggering definition switching Factor use.For the LAN based on WIFI, the network condition can also be further Including the number of devices that equipment receives the strong and weak of WIFI signal, bridge joint series, the router of router are accessed Amount etc..The change of these conditions can influence the bandwidth that equipment is distributed, and thus influence what data were downloaded Network speed, therefore can equally be used as the triggering factors of definition switching.Above-mentioned network condition Can be used alone can also a variety of conditional combinations use, the present embodiment species not to network condition and Occupation mode carries out concrete restriction.
In practical application, equipment can actively initiate the monitoring flow to network condition, can also be passive The outside notification message sent is received to know which kind of change network condition there occurs.Exemplary, it is right In the former situation, equipment can update request to base station launch position to obtain the mark of current own base station Know, or Ping bags progress downlink data is sent to the webserver and test the speed.For latter case, if The cell update information of the standby transmission that target BS can be received when occurring cell switching, or from Mobile network, which is switched to LAN and is followed by bringing drill to an end, makees the network type Notification of Changes of system broadcasts.
When it is determined that during Switch Video definition, equipment order performs step 102 to step 105, when it is determined that During without Switch Video definition, equipment cancels the execution of follow-up process, continues to carry out network condition Monitoring actively or passively.
If the 102, Switch Video definition, set up the second decoding storehouse, by second decoding storehouse loading with Second video source of the corresponding levels of sharpness of current network speed.
Both second video source and the different video source that the first video source is same video content, i.e., The video content played is identical and playing duration is identical, for example, be cartoon《Black cat police chief》, area It is not that the levels of sharpness of generally the second video source is different from definition of the first video source etc. Level.Certainly, because levels of sharpness is setting corresponding with network speed, different network speed correspondences are different Levels of sharpness, therefore when the corresponding network speed of heterogeneous networks condition is identical or substantially similar, it is also possible to In the presence of the second video source and the levels of sharpness identical situation of the first video source, the present embodiment is to this feelings Condition is not repelled.
In the prior art, equipment carries out the switching of video definition using a decoding storehouse, is passing through solution When the first video source is played in code storehouse, line definition switching is entered if desired, then equipment can terminate first and regard The broadcasting in frequency source, is then loaded by the decoding storehouse and plays the second video source.Because loading second is regarded Frequency source needs to expend the regular hour, thus terminate play the first video source after, commence play out the Before two video sources, the time interval not waited for several seconds to tens seconds is had, the smoothness of video playback is destroyed Degree.
In the present embodiment, equipment using dual decoding storehouse mechanism enter line definition conversion, when need switching During definition, equipment sets up the second decoding storehouse, loads the second video source by the second decoding storehouse, herein During do not influence broadcasting of the first decoding storehouse to the first video source.
103rd, on the newly-built painting canvas overlapping with the first video source painting canvas, according to the broadcasting of the first video source Progress synchronously plays the second video source.
Equipment by the second decoding newly-built painting canvas in storehouse, the canvas size and the first video source painting canvas Size is identical, overlapping to be covered on or below the first video source painting canvas.On newly-built painting canvas, equipment The second video source is synchronously played according to the playing progress rate of the first video source.
Exemplary, when completing the loading of the second video source, the first video source is played to 1:43:59 The starting playing progress rate of second video source is adjusted to 1 by position, equipment:43:At 59, from 1:43:At 59 Start to play the second video source on newly-built painting canvas, so as to realize the first video source and the second video source It is synchronous to play.
It should be noted that in the present embodiment, the initial transparent degree of newly-built painting canvas be it is fully transparent, i.e., The second video source is played with fully transparent image effect on newly-built painting canvas.Due under normal circumstances One video source painting canvas is to play the first video source with fully opaque image effect, therefore at two Painting canvas is overlapping and in the case that newly-built painting canvas is fully transparent, and the content that user sees is still first to regard The content in frequency source.
In addition, in addition to carrying out transition and conversion to picture material, equipment also needs to the sound to video source Sound carries out indifference conversion, and this indifference conversion is embodied as the nothing of two video source broadcast sound volumes Difference, it is therefore desirable to ensure the initial play volume of the second video source and the broadcast sound volume of the first video source It is identical, carry out volume switching so as to follow-up.
104th, commencing play out in the preset duration that the second video source rises, by the saturating of the first video source painting canvas Lightness transition and conversion is fully transparent, while being completely impermeable by the transparency transition and conversion of newly-built painting canvas It is bright;And the sound of the first video source is switched to the sound of the second video source.
The time span that the preset duration is consumed by definition transition and conversion, can be by designer voluntarily Set, can also develop special setting interface, provide the user the possibility of self-defined setting. Generally, the transition effect of the bigger definition of preset duration is more gentle soft, and preset duration is smaller The transition effect of definition is all the more obvious.The number that preset duration can be based on second or millisecond in practical application Magnitude is configured, and the present embodiment is not limited the concrete numerical value of preset duration.
It is exemplary, when from 1:43:59 commence play out the second video source, and preset duration is set to 10 During the second, equipment is needed 1:44:The transition and conversion of definition was completed before 09.
Within this 10 seconds time, equipment is needed the progressively transition turn of the transparency of the first video source painting canvas Be changed to it is fully transparent, while by the transparency of newly-built painting canvas progressively transition and conversion for completely it is opaque. , can be to the first video source painting canvas and new to pursue the transition effect of absolute parallax free in the present embodiment The transparency for building painting canvas synchronizes transition, that is, ensures that the transition speed of both transparencies is identical.For example, When both carry out at the uniform velocity transition, it is necessary to ensure that both use identical transition speed, when both are carried out , it is necessary to ensure that both transition acceleration are identical during speed change transition.Certainly, suitably deposited in practical application Also be allowed in the transition effect of parallax, in the case of this without requiring the first video source painting canvas with it is new The transition speed for building painting canvas is exactly the same, as long as ensureing that both are completed in preset duration from fully transparent To completely it is opaque, or completely it is opaque arrive fully transparent conversion.
For the switching of sound, because the first video source is identical with the broadcast sound volume of the second video source, institute So that transition and conversion need not be carried out, as long as the sound of the first video source disposably is switched into the second video source Sound.In the present embodiment, equipment can carry out sound when commencing play out the second video source and cut Change, sound switching can also be carried out at the moment of any one in preset duration, or can also be saturating Any one moment after lightness is converted carries out sound switching.As long as equipment is stopping playing the Sound switching is completed before one video source, the present embodiment is not carried out to the specific opportunity for switching sound Limitation.
105th, stop playing the first video source.
After execution of step 104, the first video source painting canvas is changed into fully transparent, and user will not observe To the broadcasting content of the first video source, and after newly-built painting canvas is changed into completely opaque, user then can be with See the second video source, from the visual perception of user, equipment has completed the conversion of definition.But It is that now device interior is still playing the first video source by the first decoding storehouse, due to now the The broadcasting of one video source is without in all senses, therefore to save the resource consumption of player, and equipment is performed Step 105 stops the broadcasting of the first video source, and so far, flow is finished shown in Fig. 1.
The switching method for the video definition that the present embodiment is provided, can be according to current network condition certainly It is dynamic to determine whether Switch Video definition, definition that selection is matched with current network speed if it need to switch etc. Second video source of level is loaded, and handoff procedure performs any operation without user;It is clear in switching When spending, the present embodiment is realized using dual decoding storehouse mechanism, i.e., playing first in the first decoding storehouse regards During frequency source, by the second decoding storehouse on the newly-built painting canvas overlapping with the first video source painting canvas it is same Step plays the second video source, thus eliminates the buffer gap between video source, realizes video source picture Seamless connection;In addition, the present embodiment also uses the handover mechanism of gradual change form, by transparent to painting canvas The smooth conversion of image sharpness is realized in the transition adjustment of degree, so as to avoid the great-jump-forward of image sharpness Change so that handoff procedure is more natural and tripping.What time summary is as can be seen that the present embodiment is carried The switching method of the video definition of confession, automatically seamless to video definition progress can take over seamlessly, Can in handoff procedure effective guarantee video playback fluency.
Further, as the supplement to method shown in Fig. 1, the embodiment of the present invention additionally provides one kind The switching method of video definition, as shown in Fig. 2 this method includes:
201st, during the first video source is played by the first decoding storehouse, according to current network bar Part determines whether Switch Video definition.
When the change of actively monitoring network condition, equipment cycle during the entire process of player use Property carry out condition monitoring, such as every 2 minutes test network speed, or every 100 seconds request once Location updating.Equipment is cached to the network parameter that monitoring is obtained every time, to carry out bar next time Part is compared when monitoring and is used.When this network monitored ginseng compared with the network parameter of previous monitoring When number changes, you can it is determined that needing Switch Video definition.
It should be noted that for monitoring obtained network parameter for the first time after startup player, by There is no the network parameter of previous monitoring to be compared in it, therefore can be according to difference in practical application Design requirement formulate different implementation strategies.For example, it is primary to work as to save equipment and Internet resources During principle, equipment does not perform the task of Switch Video definition after network parameter is measured first;And work as During using Consumer's Experience as First Principles, equipment directly determines Switch Video after network parameter is measured first Definition.
When the change of passive monitoring network condition, the opportunity of monitoring network condition is not determined in itself by equipment Fixed, equipment directly determines Switch Video definition after the notice of changes in network condition is received.
The scheme that two kinds determine Switch Video definition according to network condition in the present embodiment is given below:
1st, according to network speed Switch Video definition
When equipment is located in some network, equipment routine test network speed, and judge the net of current network Whether changed for the network speed that the relatively previous test of speed is obtained.If the network speed of current network occurs Change, then equipment determines Switch Video definition.
Exemplary, equipment is linked into family's WIFI LANs, is playing the process of the first video source In, equipment is with 90 seconds for period measuring network speed.When the network speed measured be 1.2M/S when, equipment by its It is compared with the previous network speed test result 900KB/S of caching, it is found that both are inconsistent, equipment is true Determine Switch Video definition.Or, when previous network speed test result, which is more than, currently measures network speed, example Such as 1.8M/S, the same equipment of equipment determines Switch Video definition.
In practical application, network speed there may be minor variations, such as 900KB/S and 932KB/S, For this minor variations, it is not necessary that frequent switching video definition, therefore in one kind of this programme A minimum network speed difference, such as 0.5M/S can be preset in implementation, in equipment.Equipment only has When the difference of the front and rear network speed measured twice is more than or equal to this minimum network speed difference, switching is just determined Video definition, otherwise it is assumed that network speed does not change.
2nd, according to network change Switch Video definition
Generally, the network speed of different type network is had nothing in common with each other, and the general network speed of such as 3G network is higher than GSM Network, the network speed of 100,000,000 bandwidth LANs is often again higher than 3G network;Even in addition, same type Network also likely to be present network speed difference, such as network speed of 100,000,000 bandwidth LANs can be higher than 10,000,000 bandwidth LAN, the operator A 3G network of 3G network network speed less than operator B etc..Equipment can be sentenced Whether disconnected to be switched in new network, if being switched in new network, equipment determines that Switch Video is clear Clear degree, and the network speed of new network is tested.
In this programme, operating system is monitored network by special thread, and equipment is to operation System ordering system notification message, the notifications message is used to notify network switching event.Equipment is to be The no notifications message for receiving operating system transmission is foundation, judges whether to be switched to new network, Determine to have switched new network i.e. when receiving notifications message, and to receive notifications Then confirm not switching in new network during message.
Specifically, by taking Android operation system as an example:Operating system can provide one to all applications BroadcastReceiver service, based on the service, operating system can be by the event currently occurred with wide The form of broadcasting notifies the application to all this events of subscription.Generally, event can all determine in an operating system Justice is into a character string specified, and for occurring the event of network switching, its corresponding character string is “android.net.conn.CONNECTIVITY_CHANGE”.When the access of operating system discovering device Network when changing, by BroadcastReceiver services by the character string of network switching event Each application is sent to as notifications message.
In a kind of implementation in this programme, equipment actively can also ask current to operating system The network type of network, and judge whether to be switched to new net by the way that whether network type changes In network.Specifically, the application in equipment can perform getNetworkInfo method calls ConnectivityManager is serviced, and is asked to operating system by the network type of current network.
Both the above determines that the scheme of Switch Video definition is only the feasible side in part that the present embodiment is provided In case, practical application, equipment can with but be not limited to equipment whether switch base station, equipment whether position Whether the number of devices accessed in cell edge, LAN router the change of various network conditions such as changes Foundation is turned to, Switch Video definition is determined, is limited by length, the present embodiment is no longer to other schemes Introduced one by one.
It should be noted that no matter which kind of network condition Switch Video definition is determined by foundation of, if It is standby to be required for testing the network speed of current network, search the clear of the current network speed of correspondence so as to follow-up Spend the second video source of grade.In the present embodiment, equipment can set up dedicated thread progress in the application Network speed is tested, and can also be tested the speed by third party using progress network speed test and by the communication between process Mechanism obtains test result.Current network speed test belongs to the technological means of more maturation, the present embodiment pair The contents such as its test philosophy, test mode do not make excessive introduction.
If the 202, Switch Video definition, the levels of sharpness of the current network speed of correspondence is searched.
" network speed-levels of sharpness " mapping table is preset with equipment, the mapping table is used to record different nets The corresponding levels of sharpness of speed.After network speed test is carried out, equipment accesses mapping table search correspondence and worked as The levels of sharpness of preceding network speed.
Network speed parameter in mapping table can be discrete values, such as 100KB/S, 200KB/S, 500KB/S, 1M/S, 2M/S, 2.5M/S etc., the one or more network speeds of each network speed parameter correspondence Under the conditions of the levels of sharpness that can support.When a parameter multiple levels of sharpness of correspondence, equipment Any one levels of sharpness therein can be selected.Exemplary, mapping table can be with shape such as following table institute Show:
Network speed Levels of sharpness
1M/S It is smooth
2M/S Smooth, SD
5M/S Smoothness, SD, high definition
10M/S Smoothness, SD, high definition, ultra high-definition
It is the play quality for improving video as far as possible, equipment in a kind of implementation of the present embodiment The highest levels of sharpness that selection network speed parameter can be supported, i.e., load current net by the second decoding storehouse Second video source of the highest levels of sharpness that speed is supported.For example in upper table, when network speed is 1M/S When, equipment selects levels of sharpness " smoothness ", when network speed is 5M/S, equipment selection definition etc. Level " high definition ".
Further, to reduce the table data that equipment is traveled through, the duration of equipment access map table is shortened, The highest levels of sharpness of each network speed parameter of correspondence can also be only recorded in mapping table.Exemplary, Mapping table after improvement can be as shown in the table with shape:
Network speed Levels of sharpness
1M/S It is smooth
2M/S SD
5M/S High definition
10M/S Ultra high-definition
Concrete numerical value in above table is merely illustrative, and the limitation to the present embodiment is not constituted. In practical application, when measuring network speed and being not recorded in mapping table, equipment is with closest with actual network speed Network speed parameter search mapping table.For example when actually testing the speed as 4M/S, equipment is according to 5M/S net Fast gear selection levels of sharpness " high definition ".
203rd, the second decoding storehouse is set up, definition corresponding with current network speed is loaded by the second decoding storehouse Second video source of grade.
It is determined that after levels of sharpness, equipment sends video source by the second decoding storehouse to video website please Ask, corresponding second video source of the request of loading levels of sharpness.In practical application, equipment can be with excellent First to the video source of site requests second for providing the first video source, when the website does not provide the second video source When, equipment is selected to other video site requests second video source.
204th, the playing progress rate of the first video source is recorded in the second video source loaded, first is designated as Playing progress rate.
Storehouse is decoded when playing video source, of short duration buffer time is generally required, if to have loaded the During two video sources the playing progress rate of the first video source as the second video source starting playing progress rate, then When the second video source starts to play from starting playing progress rate, now the playing progress rate of the first video source has been Through more than the starting playing progress rate, so as to cause the second video source can not absolute synchronization with the first video source Play.For example, the playing progress rate of the first video source is when the second decoding storehouse has loaded the second video source 1:24:02.Assuming that by the starting playing progress rate of the second video source from 00:00:00 is buffered to 1:24:02 needs The time of 1 second, then with 1:24:02 just occurs so as the starting playing progress rate of the second video source The problem of:When the second video source buffering is finished and from 1:24:02 when commencing play out, now the first video The playing progress rate in source has arrived at 1:24:03, the progress difference in the presence of 1 second, causes two between the two Video source can not be played synchronously.
To solve the problem, the present embodiment uses the rearmounted mechanism of progress, passes through step 204 to step 207 Realization ensure two video sources play absolute synchronization.Specifically, equipment has been loaded in the second video source The record playing progress rate that now the first video source is reached, is designated as the first playing progress rate when finishing.Upper State in example, the first playing progress rate of equipment record is 1:24:02.
205th, the first playing progress rate is added with the rearmounted surplus of default progress, obtains the second playing progress rate.
The rearmounted surplus unit of the progress is the second, and its duration can rule of thumb be set, generally progress The setting of rearmounted surplus should meet following requirement:The rearmounted surplus of progress is not less than in specific network speed situation The lower maximum duration carried out needed for video source buffering.So-called specific network speed refers to that current network is likely to be breached Minimum network speed.For example, under the conditions of the minimum network speed of current network, one video source of buffering is most slow 3 seconds are needed, then the rearmounted surplus of progress should be equal to or more than 3 seconds.The purpose for doing above-mentioned requirements is, Ensure that the second video source completed buffering before the first video source is played to the second playing progress rate.
In practical application, the factor of influence video source buffering speed also includes website response video source request Speed, dns resolution speed, firewall filtering speed etc..Should in the rearmounted surplus of the progress of setting Considered based on each side's combined factors, to ensure that the duration of the rearmounted surplus of progress disclosure satisfy that video source is buffered It is time-consuming needed for.
In the present embodiment, it is assumed that the rearmounted surplus of progress is set to 3 seconds, then when the first playing progress rate is 1:24:When 02, it is 1 that this step, which calculates the second obtained playing progress rate,:24:05.
206th, the starting playing progress rate of the second video source is adjusted to the second playing progress rate.
Row buffering is entered in second decoding storehouse to the second video source, is originated playing progress rate from acquiescence 00:00:00 is adjusted to 1:24:05.In the process, the first video source proceeds to play, but plays Progress not yet reaches 1:24:05.Second video source is buffered to 1:24:Suspend after 05 and play, wait first to regard Frequency source is played to 1:24:05.
207th, when the first video source is played to the second playing progress rate, start on newly-built painting canvas and play the Two video sources.
Equipment is created by the second decoding storehouse after the second decoding storehouse is set up and plays the new of the second video source Painting canvas is built, when the first video source is played to 1:24:When 05, opened by the second decoding storehouse on newly-built painting canvas It is dynamic to play the second video source.Because the starting playing progress rate of the second video source is similarly 1:24:05, therefore It can ensure two video sources from 1:24:05 synchronous broadcasting.
On at the time of commencing play out the second video source, the transparency and normal play of the first video source painting canvas When transparency it is identical, be completely opaque, and the initial transparent degree of newly-built painting canvas is then to be fully transparent, What now user watched remains as the first video source, and video definition not yet changes.
208th, when commencing play out the second video source, the sound of the first video source is closed.
Commencing play out the 1 of the second video source:24:At 05, the first video source is closed by the first decoding storehouse Sound.Because the broadcast sound volume of the second video source is identical with the first video source, therefore sound can be realized Indifference switching on sound.First video source is played out after sound is closed still according to playing progress rate.
209th, the transparency for progressively lowering the first video source painting canvas according to default transparency step value is joined Number, while progressively raising the transparency parameter of newly-built painting canvas according to transparency step value.
Assuming that the preset duration for transition transparency is 4 seconds, the first video source and the second video source are needed Will be 1:24:05 to 1:24:Completed in 09 this section of duration.In the present embodiment, the first video source and second Video source at the uniform velocity transition transparency, both use identical transparency step value.
The present embodiment provides the implementation of two kinds of determination transparency step values.First, equipment is according to thoroughly Lightness parameter scope and preset duration calculate acquisition transparency step value automatically;Second, developer Or user manually sets transparency step value.For the former mode, it is assumed that transparency parameter scope is 0 It fully transparent 100 is the completely opaque (transparency parameter in other standards certainly to be to 100,0 Span can also be 0 to 1 or 0 to 200, herein not table), equipment is with transparency parameter Higher limit 100 divided by preset duration 4 seconds, calculate transparency step value for the video of 25, i.e., two The transparency change speed in source is that 25 transparency units are per second.For the latter's mode, transparency stepping Value is artificial based on experience value or personal like's setting, and the transparency step value of setting should be met default Transparency can be transformed into lower limit (higher limit) from higher limit (lower limit) in duration, for example can be by Transparency step value is set as 30 or 50.Or, equipment according to transparency parameter scope and can be set Fixed transparency step value, which is recalculated, obtains new conversion duration, such as when transparency step value is set For 40 when, equipment obtains transparency higher limit 100 divided by 40 during new conversion a length of 2.5 seconds.
When carrying out transparency conversion, the first video source is even from transparency 100 according to transparency step value Speed is converted to transparency 0, and the second video source is at the uniform velocity converted to according to transparency step value from transparency 0 Lightness 100.Because the conversion of transparency is linear, therefore the transition of definition is on visual experience It is gentle soft, be not in the change of jumping characteristic.
During transparency is changed, the first video source and the second video source remain synchronous broadcasting, When playing progress rate reaches 1:24:When 09 (when converting), the first video source painting canvas is changed into completely thoroughly Bright, newly-built painting canvas is changed into completely opaque, and the content that now user watches is the second video source.
210th, delete first and decode storehouse, remove the caching of the first video source.
Equipment stops the broadcasting of the first video source, deletes first and decodes storehouse and by the data of the first video source (including the data and buffering played complete the data not yet played) is removed from the cache.So far, broadcast Put and the second decoding storehouse is only remained with device the second video source is played out, definition switching flow terminates.
Further, as the supplement to method shown in Fig. 1 and Fig. 2, the embodiment of the present invention is also provided A kind of switching method of video definition.This method is to provide a user the video source of more fine definition For principle, if the levels of sharpness of the second video source is equal to or less than the first video source, then for section The process resource of network transmission resource and equipment is saved, equipment switches without definition.Specifically:
Equipment performs Fig. 2 steps 202, tables look-up and obtains the levels of sharpness of the second video source, and from first The levels of sharpness of the first video source is read in the data APMB package of video data, both are compared. If the levels of sharpness of the first video source is equal to or more than the levels of sharpness of the second video source, then it represents that The levels of sharpness of second video source will not be better than the first video source, Switch Video definition in the case of this Essential meaning is had no, equipment, which is cancelled, sets up the second decoding storehouse, no longer performs step 203 to step 210, And continue to play the first video source.If the levels of sharpness of the first video source is less than the second video source Levels of sharpness, then it represents that the second video source can provide higher-quality resolution chart picture, equipment is built Vertical second decoding storehouse, the second video source of loading simultaneously sequentially performs Fig. 2 follow-up process.
Further, as to the perfect of the above method, the levels of sharpness for the first video source is big In the situation of the levels of sharpness of the second video source, equipment can be to going out during the first video source of broadcasting Existing buffering number of times is counted, and when buffering number of times more than default frequency threshold value, sets up the second solution Code storehouse, loads the second video source.For example, after the levels of sharpness of completeer two video source, one In the section default period, if the playing process of the first video source, which is generated, repeatedly interrupts buffering (example Such as more than 3 times), then equipment sets up the second decoding storehouse, the second video source of loading and order execution Fig. 2 Follow-up process.
The purpose for designing above-mentioned mechanism is:When the levels of sharpness of the first video source is more than the second video During source, represent that current network speed has declined in theory, should be by first to avoid video playback interim card Video source switches to the second lower video source of levels of sharpness, to ensure the fluency of video playback. But network speed declines not necessarily caused by actual bandwidth declines this single factors.Practical application In, the less stable of network signal may also cause the fluctuation of network speed in a short time, such as in WIFI Signal weakens or equipment is located at when cell edge, although actual bandwidth does not decline, but net The decrease of network signal can cause the actual downstream speed of equipment side to decline.When equipment be in bandwidth compared with When in the high but poor environment of signal stabilization, the time of one section of recovery stability of network should be given, Now it is in no hurry to switch into line definition.When buffering repeatedly occurs interrupting in only the first video source, It is due to that bandwidth decline causes that more safe can determine this situation, now needs to sacrifice some users Experience is switched to low definition, otherwise after network signal recovers stable, it may appear that under the conditions of high bandwidth The problem of playing low definition video, runs counter to the principle for providing a user high definition video as far as possible.
More than, the switching method of several video definitions as provided in an embodiment of the present invention.It is simple below Singly introduce the application scenarios of several embodiment of the present invention:
1st, during video source is played, equipment fixed time test network speed, when network speed changes When, it is switched to the highest levels of sharpness that current network speed is supported.
2nd, after being switched in new network, the network speed of new network is tested, and is switched to new network The highest levels of sharpness supported of network speed.
3rd, after being switched in new network, according to the network type of new network, it is switched to adaptable clear Clear degree grade.For example, when being switched in the mobile networks such as GSM, 3G, 4G, to save user Flow, can suitably lower the levels of sharpness of video source, or be directly lowered to minimum definition Grade, not using definition quality as primary pursuit in the case of this;And when being switched in WIFI network, To improve the levels of sharpness of video source as far as possible, the maximum that current network speed supported can be switched to clear Spend grade.
4th, equipment sets the behavior of levels of sharpness to record user manually under different network speed environment And study, levels of sharpness preference of the user under different network speed environment is obtained, and according to current network speed It is switched to the levels of sharpness of user preference.
Further, as the realization to the above method and application scenarios, the embodiment of the present invention is also provided A kind of switching device of video definition, the device can be located at mobile phone, PC (PC), flat In the electronic equipments such as plate computer, wearable device, or independently of above-mentioned electronic equipment, but with it is upper Foundation has data interaction relation between stating electronic equipment.As shown in figure 3, the device includes:It is determined that single Member 31, loading unit 32, broadcast unit 33 and control unit 34.Wherein,
Determining unit 31, the mistake for playing the first video source by the first decoding storehouse in broadcast unit 33 Cheng Zhong, Switch Video definition is determined whether according to current network condition;
Loading unit 32, if for Switch Video definition, setting up the second decoding storehouse, passing through second Decode the second video source that storehouse loads corresponding with current network speed levels of sharpness, the second video source and the One video source is the different video source of same video content;
Broadcast unit 33, in the newly-built painting canvas overlapping with the first video source painting canvas, according to first The playing progress rate of video source synchronously plays the second video source, wherein, the initial transparent degree of newly-built painting canvas is Fully transparent, the initial play volume of the second video source is identical with the broadcast sound volume of the first video source;
Control unit 34, for commencing play out in the preset duration that the second video source rises, first is regarded The transparency transition and conversion of frequency source painting canvas is fully transparent, while the transparency transition of newly-built painting canvas is turned It is changed to completely opaque;And the sound of the first video source is switched to the sound of the second video source;
Broadcast unit 33 is additionally operable to stop playing the first video source.
Further, as shown in figure 4, determining unit 31 includes the first determining module 311, it is used for:
Judge whether the network speed of current network is changed;
If the network speed of current network is changed, it is determined that Switch Video definition.
Further, as shown in figure 4, determining unit 31 includes the second determining module 312, it is used for:
The notifications message of snoop-operations system broadcasts, notifications message is used to notify network switching Event;
Judge whether to be switched to new network according to whether receiving notifications message.
Further, the second determining module 312, is used for:
Current network is carried in the notifications message of snoop-operations system broadcasts, notifications message Network type information;
Judged whether to be switched to new network according to network type information.
Further, as shown in figure 4, the device further comprises:
Acquiring unit 35, for before the second decoding storehouse is set up, obtaining the definition of the second video source Grade;
Comparing unit 36, is compared for the levels of sharpness to the first video source and the second video source;
Loading unit 32, if the levels of sharpness for the first video source is equal to or more than the second video source Levels of sharpness, then cancel set up the second decoding storehouse;
If the levels of sharpness that loading unit 32 is additionally operable to the first video source is less than the clear of the second video source Grade is spent, then sets up the second decoding storehouse, the second video source is loaded.
Further, as shown in figure 4, the device further comprises:
Counting unit 37, if the levels of sharpness for the first video source is more than the clear of the second video source Grade is spent, then is counted to playing the buffering number of times occurred during the first video source;
Loading unit 32, for when buffering number of times more than default frequency threshold value, setting up the second decoding Storehouse, loads the second video source.
Further, loading unit 32 is used to be supported most by the second current network speed of decoding storehouse loading Second video source of fine definition grade.
Further, broadcast unit 33, are used for:In the second video source loaded, record first is regarded The playing progress rate in frequency source, is designated as the first playing progress rate;
First playing progress rate is added with the rearmounted surplus of default progress, the second playing progress rate is obtained;
The starting playing progress rate of second video source is adjusted to the second playing progress rate;
When the first video source is played to the second playing progress rate, start and play the second video source.
Further, control unit 34, are used for:
The transparency parameter of the first video source painting canvas is progressively lowered according to default transparency step value, together When the transparency parameter of newly-built painting canvas is progressively raised according to transparency step value.
Further, control unit 34, are regarded for when commencing play out the second video source, closing first The sound in frequency source.
Further, broadcast unit 33 is used for after the first video source of broadcasting is stopped:
Delete first and decode storehouse;
Remove the caching of the first video source.
The switching device for the video definition that the present embodiment is provided, can be according to current network condition certainly It is dynamic to determine whether Switch Video definition, definition that selection is matched with current network speed if it need to switch etc. Second video source of level is loaded, and handoff procedure performs any operation without user;It is clear in switching When spending, the present embodiment is realized using dual decoding storehouse mechanism, i.e., playing first in the first decoding storehouse regards During frequency source, by the second decoding storehouse on the newly-built painting canvas overlapping with the first video source painting canvas it is same Step plays the second video source, thus eliminates the buffer gap between video source, realizes video source picture Seamless connection;In addition, the present embodiment also uses the handover mechanism of gradual change form, by transparent to painting canvas The smooth conversion of image sharpness is realized in the transition adjustment of degree, so as to avoid the great-jump-forward of image sharpness Change so that handoff procedure is more natural and tripping.What time summary is as can be seen that the present embodiment is carried The switching device of the video definition of confession, automatically seamless to video definition progress can take over seamlessly, Can in handoff procedure effective guarantee video playback fluency.
In the above-described embodiments, the description to each embodiment all emphasizes particularly on different fields, and does not have in some embodiment The part being described in detail, may refer to the associated description of other embodiment.
It is understood that the correlated characteristic in the above method and device can be referred to mutually.In addition, " first ", " second " in above-described embodiment etc. is to be used to distinguish each embodiment, and does not represent each implementation The quality of example.
It is apparent to those skilled in the art that, it is for convenience and simplicity of description, above-mentioned The specific work process of the system, apparatus, and unit of description, may be referred in preceding method embodiment Corresponding process, will not be repeated here.
Provided herein algorithm and show not with any certain computer, virtual system or miscellaneous equipment It is intrinsic related.Various general-purpose systems can also be used together with based on teaching in this.According to above Description, the structure constructed required by this kind of system is obvious.In addition, the present invention is not also directed to Any certain programmed language.It is understood that, it is possible to use various programming languages realize described here The content of invention, and the description done to language-specific above is to disclose the optimal reality of the present invention Apply mode.
In the specification that this place is provided, numerous specific details are set forth.It is to be appreciated, however, that Embodiments of the invention can be put into practice in the case of these no details.In some instances, Known method, structure and technology is not been shown in detail, so as not to obscure the understanding of this description.
Similarly, it will be appreciated that in order to simplify the disclosure and help to understand one in each inventive aspect It is individual or multiple, above to the present invention exemplary embodiment description in, each feature of the invention Sometimes it is grouped together into single embodiment, figure or descriptions thereof.However, should be by The method of the disclosure is construed to reflect following intention:That is the present invention for required protection requirement is than each The more features of feature being expressly recited in claim.More precisely, as following right will Ask as book reflects, inventive aspect is all features less than single embodiment disclosed above. Therefore, it then follows thus claims of embodiment are expressly incorporated in the embodiment, Wherein each claim is in itself as the separate embodiments of the present invention.
Those skilled in the art, which are appreciated that, to be carried out to the module in the equipment in embodiment Adaptively change and they are arranged in one or more equipment different from the embodiment. Module or unit or component in embodiment can be combined into a module or unit or component, and In addition multiple submodule or subelement or sub-component can be divided into.Except such feature and/or , can be using any combinations to this explanation outside at least some in process or unit exclude each other All features and such as the displosure disclosed in book (including adjoint claim, summary and accompanying drawing) Any method or all processes or unit of equipment be combined.Unless expressly stated otherwise, originally Each feature disclosed in specification (including adjoint claim, summary and accompanying drawing) can be by carrying Replaced for the alternative features of identical, equivalent or similar purpose.
Although in addition, it will be appreciated by those of skill in the art that some embodiments described herein include Included some features rather than further feature in other embodiments, but the not feature of be the same as Example Combination mean to be within the scope of the present invention and form different embodiments.For example, under In the claims in face, the one of any of embodiment claimed can be in any combination Mode is used.
The all parts embodiment of the present invention can be realized with hardware, or with one or more The software module run on reason device is realized, or is realized with combinations thereof.Those skilled in the art It should be appreciated that can be realized in practice using microprocessor or digital signal processor (DSP) Some in denomination of invention according to embodiments of the present invention (device as determined website internal chaining grade) Or some or all functions of whole parts.The present invention is also implemented as being used to perform institute here The method of description some or all equipment or program of device (for example, computer program and Computer program product).Such program for realizing the present invention can be stored in computer-readable medium On, or can have the form of one or more signal.Such signal can be from internet net Download and obtain on standing, either provide or provided in any other form on carrier signal.
It should be noted that the present invention will be described rather than the present invention is limited for above-described embodiment Make, and those skilled in the art can design without departing from the scope of the appended claims Alternative embodiment.In the claims, any reference symbol between bracket should not be configured to Limitations on claims.Word "comprising" does not exclude the presence of element not listed in the claims or step Suddenly.Word "a" or "an" before element does not exclude the presence of multiple such elements.The present invention Can be by means of including the hardware of some different elements and coming real by means of properly programmed computer It is existing.In if the unit claim of equipment for drying is listed, several in these devices can be logical Same hardware branch is crossed to embody.The use of word first, second, and third is not indicated that Any order.These words can be construed to title.

Claims (22)

1. a kind of switching method of video definition, it is characterised in that methods described includes:
It is true according to current network condition during the first video source is played by the first decoding storehouse It is fixed whether Switch Video definition;
If Switch Video definition, set up the second decoding storehouse, by described second decoding storehouse loading with Second video source of the corresponding levels of sharpness of current network speed, second video source is regarded with described first Frequency source is the different video source of same video content;
On the newly-built painting canvas overlapping with the first video source painting canvas, according to the broadcasting of first video source Progress synchronously plays second video source, wherein, the initial transparent degree of the newly-built painting canvas is complete Transparent, the initial play volume of second video source is identical with the broadcast sound volume of first video source;
Commencing play out in the preset duration that second video source rises, by the saturating of the first video source painting canvas Lightness transition and conversion is fully transparent, while being complete by the transparency transition and conversion of the newly-built painting canvas It is opaque;And the sound of first video source is switched to the sound of second video source;
Stop playing first video source.
2. according to the method described in claim 1, it is characterised in that the current network bar of the basis Part determines whether Switch Video definition, including:
Judge whether the network speed of current network is changed;
If the network speed of current network is changed, it is determined that Switch Video definition.
3. according to the method described in claim 1, it is characterised in that the current network bar of the basis Part determines whether Switch Video definition, including:
Judge whether to be switched in new network;
If being switched in new network, it is determined that Switch Video definition.
4. method according to claim 3, it is characterised in that described to judge whether to be switched to newly Network in, including:
The notifications message of snoop-operations system broadcasts, the notifications message is used to notify network Handover event;
Judge whether to be switched to new network according to whether receiving the notifications message.
5. according to the method described in claim 1, it is characterised in that set up the second decoding storehouse described Before, methods described further comprises:
Obtain the levels of sharpness of second video source;
Levels of sharpness to first video source and second video source is compared;
If the levels of sharpness of first video source is equal to or more than the definition of second video source Grade, then cancel and set up the second decoding storehouse;
If the levels of sharpness of first video source is less than the levels of sharpness of second video source, The second decoding storehouse is then set up, second video source is loaded.
6. method according to claim 5, it is characterised in that if first video source is clear Clear degree grade is more than the levels of sharpness of second video source, then methods described further comprises:
Counted to playing the buffering number of times occurred during first video source;
When the buffering number of times exceedes default frequency threshold value, the second decoding storehouse is set up, loading is described Second video source.
7. according to the method described in claim 1, it is characterised in that described to be decoded by described second Storehouse loads the second video source of levels of sharpness corresponding with current network speed, including:
The second of the highest levels of sharpness that current network speed is supported is loaded by the described second decoding storehouse to regard Frequency source.
8. according to the method described in claim 1, it is characterised in that described according to first video The playing progress rate in source synchronously plays second video source, including:
The playing progress rate of first video source is recorded in the second video source loaded, is designated as First playing progress rate;
First playing progress rate is added with the rearmounted surplus of default progress, the second playing progress rate is obtained;
The starting playing progress rate of second video source is adjusted to second playing progress rate;
When first video source is played to second playing progress rate, start broadcasting described second and regard Frequency source.
9. according to the method described in claim 1, it is characterised in that described by the first video source painting canvas Transparency transition and conversion to be fully transparent, while being by the transparency transition and conversion of the newly-built painting canvas It is completely opaque, including:
The transparency parameter of the first video source painting canvas is progressively lowered according to default transparency step value, together When the transparency parameter of newly-built painting canvas is progressively raised according to the transparency step value.
10. according to the method described in claim 1, it is characterised in that described by first video The sound in source switches to the sound of second video source, including:
When commencing play out second video source, the sound of first video source is closed.
11. according to the method described in claim 1, it is characterised in that stop playing described described After first video source, methods described further comprises:
Delete the first decoding storehouse;
Remove the caching of first video source.
12. a kind of switching device of video definition, it is characterised in that described device includes:
Determining unit, during playing the first video source by the first decoding storehouse in broadcast unit, Switch Video definition is determined whether according to current network condition;
Loading unit, if for Switch Video definition, setting up the second decoding storehouse, passes through described Two decoding storehouses load the second video source of levels of sharpness corresponding with current network speed, second video Source and the different video source that first video source is same video content;
The broadcast unit, in the newly-built painting canvas overlapping with the first video source painting canvas, according to institute The playing progress rate for stating the first video source synchronously plays second video source, wherein, the newly-built painting canvas Initial transparent degree to be fully transparent, the initial play volume of second video source is regarded with described first The broadcast sound volume in frequency source is identical;
Control unit, for commencing play out in the preset duration that second video source rises, by first The transparency transition and conversion of video source painting canvas is fully transparent, while by the transparency of the newly-built painting canvas Transition and conversion is completely opaque;And switch to described second to regard the sound of first video source The sound in frequency source;
The broadcast unit is additionally operable to stop playing first video source.
13. device according to claim 12, it is characterised in that the determining unit includes the One determining module, is used for:
Judge whether the network speed of current network is changed;
If the network speed of current network is changed, it is determined that Switch Video definition.
14. device according to claim 12, it is characterised in that the determining unit includes the Two determining modules, are used for:
The notifications message of snoop-operations system broadcasts, the notifications message is used to notify network Handover event;
Judge whether to be switched to new network according to whether receiving the notifications message.
15. device according to claim 14, it is characterised in that second determining module, For:
Carried in the notifications message of snoop-operations system broadcasts, the notifications message current The network type information of network;
Judge whether to be switched to new network according to the network type information.
16. device according to claim 12, it is characterised in that described device further comprises:
Acquiring unit, for before the second decoding storehouse is set up, obtaining the clear of second video source Spend grade;
Comparing unit, enters for the levels of sharpness to first video source and second video source Row compares;
The loading unit, if the levels of sharpness for first video source is equal to or more than described The levels of sharpness of second video source, then cancel and set up the second decoding storehouse;
If the levels of sharpness that the loading unit is additionally operable to first video source is regarded less than described second The levels of sharpness in frequency source, then set up the second decoding storehouse, loads second video source.
17. device according to claim 16, it is characterised in that described device further comprises:
Counting unit, if the levels of sharpness for first video source is more than second video source Levels of sharpness, then counted to playing the buffering number of times occurred during first video source;
The loading unit, for when the buffering number of times exceedes default frequency threshold value, setting up the Two decoding storehouses, load second video source.
18. device according to claim 12, it is characterised in that the loading unit is used to lead to Cross the second video source that the second decoding storehouse loads the highest levels of sharpness that current network speed is supported.
19. device according to claim 12, it is characterised in that the broadcast unit, is used for: The playing progress rate of first video source is recorded in the second video source loaded, first is designated as Playing progress rate;
First playing progress rate is added with the rearmounted surplus of default progress, the second playing progress rate is obtained;
The starting playing progress rate of second video source is adjusted to second playing progress rate;
When first video source is played to second playing progress rate, start broadcasting described second and regard Frequency source.
20. device according to claim 12, it is characterised in that described control unit, is used for:
The transparency parameter of the first video source painting canvas is progressively lowered according to default transparency step value, together When the transparency parameter of newly-built painting canvas is progressively raised according to the transparency step value.
21. device according to claim 12, it is characterised in that described control unit, is used for When commencing play out second video source, the sound of first video source is closed.
22. device according to claim 12, it is characterised in that the broadcast unit is used for Stopping is played after first video source:
Delete the first decoding storehouse;
Remove the caching of first video source.
CN201610149109.0A 2016-03-15 2016-03-15 video definition switching method and device Active CN107197371B (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201610149109.0A CN107197371B (en) 2016-03-15 2016-03-15 video definition switching method and device
PCT/CN2017/075638 WO2017157191A1 (en) 2016-03-15 2017-03-03 Method and apparatus for switching video definitions

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610149109.0A CN107197371B (en) 2016-03-15 2016-03-15 video definition switching method and device

Publications (2)

Publication Number Publication Date
CN107197371A true CN107197371A (en) 2017-09-22
CN107197371B CN107197371B (en) 2019-12-13

Family

ID=59850544

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610149109.0A Active CN107197371B (en) 2016-03-15 2016-03-15 video definition switching method and device

Country Status (2)

Country Link
CN (1) CN107197371B (en)
WO (1) WO2017157191A1 (en)

Cited By (20)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109144611A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109144612A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109144613A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109413457A (en) * 2018-10-18 2019-03-01 武汉斗鱼网络科技有限公司 Code stream clarity switching method, device, terminal and the readable medium of android system
CN109451361A (en) * 2018-10-18 2019-03-08 武汉斗鱼网络科技有限公司 Code stream clarity switching method, device, terminal and the readable medium of android system
CN110149536A (en) * 2019-05-27 2019-08-20 湖南快乐阳光互动娱乐传媒有限公司 Video broadcasting method and device
CN110166810A (en) * 2019-04-25 2019-08-23 腾讯科技(深圳)有限公司 Video rendering engine switching method, device, equipment and readable storage medium storing program for executing
CN110278452A (en) * 2019-06-24 2019-09-24 北京字节跳动网络技术有限公司 Video Acceleration of starting method, apparatus, storage medium, terminal and server
CN110545461A (en) * 2018-05-29 2019-12-06 北京字节跳动网络技术有限公司 Resolution switching method and device of media file and storage medium
CN110582012A (en) * 2018-06-11 2019-12-17 腾讯科技(深圳)有限公司 Video switching method, video processing device and storage medium
CN110602425A (en) * 2018-06-13 2019-12-20 上海哔哩哔哩科技有限公司 Video definition adjusting method, system, computer readable storage medium and terminal
CN110719526A (en) * 2019-10-28 2020-01-21 腾讯科技(深圳)有限公司 Video playing method and device
CN110753266A (en) * 2019-10-23 2020-02-04 深圳市酷开网络科技有限公司 Video definition adjusting method and device and storage medium
CN111418215A (en) * 2018-08-17 2020-07-14 格雷斯诺特公司 Dynamic playout of transition frames when transitioning between playout of media streams
CN111510770A (en) * 2019-01-30 2020-08-07 上海哔哩哔哩科技有限公司 Method and device for switching definition, computer equipment and readable storage medium
CN111726642A (en) * 2019-03-19 2020-09-29 北京京东尚科信息技术有限公司 Live broadcast method, device and computer readable storage medium
CN112291611A (en) * 2020-10-27 2021-01-29 重庆虚拟实境科技有限公司 Video playing method, computer device and readable storage medium
CN113038243A (en) * 2021-05-28 2021-06-25 卡莱特云科技股份有限公司 Transparency adjusting method and device in video source picture playing process
CN113055833A (en) * 2019-12-11 2021-06-29 中国移动通信有限公司研究院 Service optimization method, base station and application layer equipment
CN113825020A (en) * 2021-09-18 2021-12-21 北京百度网讯科技有限公司 Video definition switching method, device, equipment, storage medium and program product

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111294641B (en) * 2020-03-10 2022-10-21 北京奇艺世纪科技有限公司 Video playing method, system, device, electronic equipment and readable storage medium
CN116781951B (en) * 2023-08-24 2023-12-05 湖南快乐阳光互动娱乐传媒有限公司 Definition adjusting method, device and server
CN118042197B (en) * 2024-04-09 2024-06-25 牡丹江师范学院 Automatic switching method and system for music video

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4912696B2 (en) * 2006-02-28 2012-04-11 パナソニック株式会社 Wireless transmission system for video data
CN103702042A (en) * 2013-12-27 2014-04-02 Tcl新技术(惠州)有限公司 Dual-channel display equipment-based signal source switching method and device
CN103763618A (en) * 2013-12-27 2014-04-30 乐视网信息技术(北京)股份有限公司 Definition switching method and electronic device
CN104219579A (en) * 2014-08-20 2014-12-17 北京奇艺世纪科技有限公司 Video switching method and video switching device

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4912696B2 (en) * 2006-02-28 2012-04-11 パナソニック株式会社 Wireless transmission system for video data
CN103702042A (en) * 2013-12-27 2014-04-02 Tcl新技术(惠州)有限公司 Dual-channel display equipment-based signal source switching method and device
CN103763618A (en) * 2013-12-27 2014-04-30 乐视网信息技术(北京)股份有限公司 Definition switching method and electronic device
CN104219579A (en) * 2014-08-20 2014-12-17 北京奇艺世纪科技有限公司 Video switching method and video switching device

Cited By (32)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110545461A (en) * 2018-05-29 2019-12-06 北京字节跳动网络技术有限公司 Resolution switching method and device of media file and storage medium
CN110582012A (en) * 2018-06-11 2019-12-17 腾讯科技(深圳)有限公司 Video switching method, video processing device and storage medium
CN110602425A (en) * 2018-06-13 2019-12-20 上海哔哩哔哩科技有限公司 Video definition adjusting method, system, computer readable storage medium and terminal
CN111418215B (en) * 2018-08-17 2022-05-17 六科股份有限公司 Media client, method, non-transitory data storage device
CN111418215A (en) * 2018-08-17 2020-07-14 格雷斯诺特公司 Dynamic playout of transition frames when transitioning between playout of media streams
CN109144612A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109144613A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109144611A (en) * 2018-09-03 2019-01-04 武汉斗鱼网络科技有限公司 Android clarity switching method, device, terminal and readable medium
CN109144612B (en) * 2018-09-03 2021-10-15 武汉斗鱼网络科技有限公司 Android definition switching method and device, terminal and readable medium
CN109144613B (en) * 2018-09-03 2021-10-15 武汉斗鱼网络科技有限公司 Android definition switching method and device, terminal and readable medium
CN109413457B (en) * 2018-10-18 2021-11-09 武汉斗鱼网络科技有限公司 Code stream definition switching method and device for Android system, terminal and readable medium
CN109451361B (en) * 2018-10-18 2022-01-04 武汉斗鱼网络科技有限公司 Code stream definition switching method and device for Android system, terminal and readable medium
CN109413457A (en) * 2018-10-18 2019-03-01 武汉斗鱼网络科技有限公司 Code stream clarity switching method, device, terminal and the readable medium of android system
CN109451361A (en) * 2018-10-18 2019-03-08 武汉斗鱼网络科技有限公司 Code stream clarity switching method, device, terminal and the readable medium of android system
CN111510770B (en) * 2019-01-30 2021-08-24 上海哔哩哔哩科技有限公司 Method and device for switching definition, computer equipment and readable storage medium
CN111510770A (en) * 2019-01-30 2020-08-07 上海哔哩哔哩科技有限公司 Method and device for switching definition, computer equipment and readable storage medium
US11303949B2 (en) 2019-01-30 2022-04-12 Shanghai Bilibili Technology Co., Ltd. Method of switching resolution, computing device, and computer-readable storage medium
CN111726642A (en) * 2019-03-19 2020-09-29 北京京东尚科信息技术有限公司 Live broadcast method, device and computer readable storage medium
CN110166810A (en) * 2019-04-25 2019-08-23 腾讯科技(深圳)有限公司 Video rendering engine switching method, device, equipment and readable storage medium storing program for executing
CN110149536A (en) * 2019-05-27 2019-08-20 湖南快乐阳光互动娱乐传媒有限公司 Video broadcasting method and device
CN110149536B (en) * 2019-05-27 2021-11-16 湖南快乐阳光互动娱乐传媒有限公司 Video playing method and device
CN110278452A (en) * 2019-06-24 2019-09-24 北京字节跳动网络技术有限公司 Video Acceleration of starting method, apparatus, storage medium, terminal and server
CN110753266A (en) * 2019-10-23 2020-02-04 深圳市酷开网络科技有限公司 Video definition adjusting method and device and storage medium
CN110719526A (en) * 2019-10-28 2020-01-21 腾讯科技(深圳)有限公司 Video playing method and device
CN110719526B (en) * 2019-10-28 2021-05-07 腾讯科技(深圳)有限公司 Video playing method and device
CN113055833A (en) * 2019-12-11 2021-06-29 中国移动通信有限公司研究院 Service optimization method, base station and application layer equipment
CN113055833B (en) * 2019-12-11 2022-08-12 中国移动通信有限公司研究院 Service optimization method, base station and application layer equipment
CN112291611A (en) * 2020-10-27 2021-01-29 重庆虚拟实境科技有限公司 Video playing method, computer device and readable storage medium
CN113038243B (en) * 2021-05-28 2021-09-17 卡莱特云科技股份有限公司 Transparency adjusting method and device in video source picture playing process
CN113038243A (en) * 2021-05-28 2021-06-25 卡莱特云科技股份有限公司 Transparency adjusting method and device in video source picture playing process
CN113825020A (en) * 2021-09-18 2021-12-21 北京百度网讯科技有限公司 Video definition switching method, device, equipment, storage medium and program product
CN113825020B (en) * 2021-09-18 2023-09-29 北京百度网讯科技有限公司 Video definition switching method, device, equipment, storage medium and program product

Also Published As

Publication number Publication date
CN107197371B (en) 2019-12-13
WO2017157191A1 (en) 2017-09-21

Similar Documents

Publication Publication Date Title
CN107197371A (en) The switching method and device of video definition
US20140122638A1 (en) Webpage Browsing Method And Device
US11469980B2 (en) Network access method and terminal
CN105100830B (en) A kind of device and method for being switched fast video source based on video aggregation service
CN109151597B (en) Information display method and device
CN109246462A (en) A kind of video flowing seamless handover method and device
CN104699378A (en) Information browsing method and information browsing system in multi-person chatting
US20140323178A1 (en) Electronic device for multiple radio access and method thereof
EP2929729B1 (en) Methods and apparatus for selecting an inter-radio access technology for an electronic device
CN103139876A (en) Method and device selecting wireless access mode for mobile terminal adaptively
CN104883610A (en) Patch video playing method and device
CA2835245A1 (en) Method and apparatus for pre-loading information over a communication network
CN106547417A (en) The method and apparatus for showing background task message
CN103179438A (en) Method and device for determining of video playing first access code rate
CN109005463A (en) Page presentation and page data method for pushing and device
CN109284464A (en) Page loading method and terminal, page response method and server
CN104159140A (en) Video processing method, apparatus and system
CN108073647A (en) Webpage display process and device
CN104244366A (en) Wireless network connection method and device and mobile device
CN104391628A (en) Process switching method and device
CN103874156B (en) A kind of terminal and method for switching network
CN108563479A (en) Redirect control method, device, virtual machine and the Redirectional system of window
CN107682535A (en) Based on intelligent mobile phone platform method for remote controlling computer
CN110856233A (en) Communication control method and related product
CN105556905A (en) Page insertion method and device

Legal Events

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

Effective date of registration: 20200507

Address after: 310051 room 508, floor 5, building 4, No. 699, Wangshang Road, Changhe street, Binjiang District, Hangzhou City, Zhejiang Province

Patentee after: Alibaba (China) Co.,Ltd.

Address before: 510640 Guangdong city of Guangzhou province Whampoa Tianhe District Road No. 163 Xiping Yun Lu Yun Ping B radio square 14 storey tower

Patentee before: GUANGZHOU UCWEB COMPUTER TECHNOLOGY Co.,Ltd.

TR01 Transfer of patent right