CN103997680B - The switching method and device of a kind of video code flow - Google Patents

The switching method and device of a kind of video code flow Download PDF

Info

Publication number
CN103997680B
CN103997680B CN201410250882.7A CN201410250882A CN103997680B CN 103997680 B CN103997680 B CN 103997680B CN 201410250882 A CN201410250882 A CN 201410250882A CN 103997680 B CN103997680 B CN 103997680B
Authority
CN
China
Prior art keywords
video code
code stream
target video
current
network state
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.)
Active
Application number
CN201410250882.7A
Other languages
Chinese (zh)
Other versions
CN103997680A (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.)
Shanghai Zhongyuan Network Co., Ltd.
Original Assignee
Shanghai Zhongyuan Network 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 Shanghai Zhongyuan Network Co Ltd filed Critical Shanghai Zhongyuan Network Co Ltd
Priority to CN201410250882.7A priority Critical patent/CN103997680B/en
Publication of CN103997680A publication Critical patent/CN103997680A/en
Application granted granted Critical
Publication of CN103997680B publication Critical patent/CN103997680B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Mobile Radio Communication Systems (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The embodiment of the invention discloses a kind of switching method of video code flow and device, a kind of switching method of video code flow, including:After the instruction of video code flow handover trigger is received, the target video code stream corresponding to bitstreams switching is determined;The target video code stream is loaded, and continues to play current video code stream;Detect whether the load progress of target video code stream is more than the playing progress rate of current video code stream;If the load progress of target video code stream is more than the playing progress rate of current video code stream, currently playing video code flow is switched into target video code stream.Using above-mentioned technical proposal, in the case where video player reaches switching condition to the load progress of target video code stream, the broadcasting to current video code stream can just be stopped, the seamless switching between different video code stream can be realized, " interim card " or " blank screen " phenomenon in video code flow handoff procedure is avoided, user's views and admires experience preferably.

Description

The switching method and device of a kind of video code flow
Technical field
The present invention relates to technical field of video processing, the switching method and device of more particularly to a kind of video code flow.
Background technology
With the fast development of network multimedia technology, SD video code flow, HD video code stream, ultra high-definition video code flow Etc. the appearance for the video code flow for meeting heterogeneous networks playing environment so that it is special that the broadcasting form of video file is no longer limited to certain Fixed video code flow., can be according to user's during video player plays video in order to improve the experience of viewing and admiring of user Netcast environment, the video code flow for being switched to suitable current network playing environment is played out.
In the prior art, after video player receives video code flow handover trigger, stop immediately to current video code The broadcasting of stream, and start the down operation of target video code stream, when download meets playing condition, to the target downloaded Video code flow is played out.
However, due to starting the down operation of target video code stream since video player to the target video code stream Download meets one section of stand-by period of playing condition needs, existing which results in " interim card " or " blank screen " in video display process As viewing and admiring for user experiences poor.
The content of the invention
In order to solve the above problems, the embodiment of the invention discloses a kind of switching method of video code flow and device, specifically Technical scheme is as follows:
A kind of switching method of video code flow, including:
After the instruction of video code flow handover trigger is received, the target video code stream corresponding to bitstreams switching is determined;
The target video code stream is loaded, and continues to play current video code stream;
Detect whether the load progress of target video code stream is more than the playing progress rate of current video code stream;
If the load progress of target video code stream is more than the playing progress rate of current video code stream, currently playing is regarded Frequency code stream switches to target video code stream.
It is preferred that, the target video code stream determined corresponding to bitstreams switching, including:
According to the trigger action of user, the target video code stream corresponding to bitstreams switching is determined.
It is preferred that, the target video code stream determined corresponding to bitstreams switching, including:
The current network state of monitoring;
It is regular according to default network state grade classification, it is determined that the network state grade belonging to current network state, Wherein, the different video code flow handover scheme of different network state grades correspondence;
Networking state grade according to belonging to identified current network state, determines that the target corresponding to bitstreams switching is regarded Frequency code stream.
It is preferred that, it is described that the target video code stream is loaded, including:
The time point for receiving the instruction of video code flow handover trigger is recorded as start time;
Determine corresponding target video code stream after the start time;
Target video code stream after the time point is loaded.
It is preferred that, whether the load progress of the detection target video code stream is more than the playing progress rate of current video code stream, Including:
Whether the load progress of detection target video code stream is more than the playing progress rate of current video code stream in real time;
Or
According to default detection cycle, detect whether the load progress of target video code stream is more than broadcasting for current video code stream Degree of putting into.
It is preferred that, whether the load progress of the detection target video code stream is more than the playing progress rate of current video code stream, Including:
The broadcasting whether load progress of detection target video code stream within the default time is more than current video code stream is entered Degree;
If the load progress of the target code stream is more than the playing progress rate of current video code stream, currently playing is regarded Frequency code stream switches to target video code stream, is specially:
If the load progress of target code stream is more than the playing progress rate of current video code stream within the default time, Currently playing video code flow is switched into target video code stream.
It is preferred that, if the load progress of target video code stream is not more than current video code stream within the default time Playing progress rate, then further comprise:
Suspend the loading to the target video code stream.
It is preferred that, this method further comprises:
Message notifying is sent to user, the message notifying is used to point out user under current playing environment, without entering Row bitstreams switching is operated.
It is preferred that, before the instruction of video code flow handover trigger is received, in addition to:
Whether the current network state of detection changes;
If it is, automatically generating the instruction of video code flow handover trigger, or prompting message is sent to user, according to user's Operation, the handover trigger instruction of generation video code flow.
It is preferred that, whether the current network state of the detection changes, including:
Detect whether current network state changes in real time;
Or
According to the default time cycle, detect whether current network state changes.
It is preferred that, after currently playing video code flow is switched into target video code stream, in addition to:
Message informing is sent to user, the message informing is used to point out user video code stream to switch successfully.
A kind of switching device of video code flow, including:
Code stream determining module, for after the instruction of video code flow handover trigger is received, determining corresponding to bitstreams switching Target video code stream;
Code stream load-on module, for loading the target video code stream, and continues to play current video code stream;
Progress detection module, for detecting whether the load progress of target video code stream is more than the broadcasting of current video code stream Progress;
Bitstreams switching module, for the load progress in target video code stream more than the playing progress rate of current video code stream In the case of, currently playing video code flow is switched into target video code stream.
It is preferred that, the code stream determining module, specifically for:
According to the trigger action of user, the target video code stream corresponding to bitstreams switching is determined.
It is preferred that, the code stream determining module, including:
Network Expert Systems submodule, the current network state for monitoring;
Network hierarchy divides submodule, for according to default network state grade classification rule, it is determined that current network Network state grade belonging to state, wherein, the different video code flow handover scheme of different network state grade correspondences;
Code stream determination sub-module, for the networking state grade according to belonging to identified current network state, it is determined that code Flow the target video code stream corresponding to switching.
It is preferred that, the code stream load-on module, specifically for:
The time point for receiving the instruction of video code flow handover trigger is recorded as start time;
Determine corresponding target video code stream after the start time;
Target video code stream after the time point is loaded, and continues to play current video code stream.
It is preferred that, the progress detection module, specifically for:
Whether the load progress of detection target video code stream is more than the playing progress rate of current video code stream in real time;
Or
According to default detection cycle, detect whether the load progress of target video code stream is more than broadcasting for current video code stream Degree of putting into.
It is preferred that, the progress detection module, specifically for:
The broadcasting whether load progress of detection target video code stream within the default time is more than current video code stream is entered Degree;
The bitstreams switching module, will in the case of being in the testing result of the progress detection module Currently playing video code flow switches to target video code stream.
It is preferred that, the device further comprises:
Code stream loading pause module, in the case of being no in the testing result of the progress detection module, pause pair The loading of the target video code stream.
It is preferred that, the device further comprises:
Message notifying sending module, for sending message notifying to user, the message notifying is used to point out user working as Under preceding playing environment, without carrying out bitstreams switching operation.
It is preferred that, the device also includes:
Network state detection module and directive generation module;
The network state detection module, for detecting, whether current network state changes;
The directive generation module includes:First generation submodule or the second generation submodule;
The first generation submodule, in the case of being in the testing result of the network state detection module, Automatically generate the instruction of video code flow handover trigger;
The second generation submodule, in the case of being in the testing result of the network state detection module, Prompting message is sent to user, according to the operation of user, the handover trigger instruction of generation video code flow.
It is preferred that, the network state detection module, specifically for:
Detect whether current network state changes in real time;
Or
According to the default time cycle, detect whether current network state changes.
It is preferred that, the device also includes:
Message informing sending module, for sending message informing to user, the message informing is used to point out user video Code stream has been switched successfully.
Using technical scheme provided in an embodiment of the present invention, video player is receiving the instruction of video code flow handover trigger Afterwards, determine the target video code stream corresponding to bitstreams switching, the target video code stream loaded, and continue play work as forward sight Frequency code stream, until when the load progress of target video code stream is more than the playing progress rate of current video code stream, currently playing is regarded Frequency code stream is switched to target video code stream.
Compared with prior art, when video player reaches switching condition to the load progress of target video code stream, just meeting Stop broadcasting to current video code stream, the seamless switching between different video code stream can be realized, it is to avoid video code flow is cut " interim card " or " blank screen " phenomenon during changing, user's views and admires experience preferably.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing There is the accompanying drawing used required in technology description to be briefly described, it should be apparent that, drawings in the following description are only this Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, can be with Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 a are a kind of the first flow chart of the switching method of video code flow provided in an embodiment of the present invention;
A kind of flow chart for embodiment that Fig. 1 b are S101 in Fig. 1 a provided in an embodiment of the present invention;
A kind of flow chart for embodiment that Fig. 1 c are S102 in Fig. 1 a provided in an embodiment of the present invention;
Fig. 1 d are a kind of flow chart of video code flow loading method provided in an embodiment of the present invention;
Fig. 2 is a kind of second of flow chart of the switching method of video code flow provided in an embodiment of the present invention;
Fig. 3 is a kind of the third flow chart of the switching method of video code flow provided in an embodiment of the present invention;
Fig. 4 is a kind of the 4th kind of flow chart of switching method of video code flow provided in an embodiment of the present invention;
Fig. 5 is a kind of the 5th kind of flow chart of switching method of video code flow provided in an embodiment of the present invention;
Fig. 6 a are a kind of the first structural representation of the switching device of video code flow provided in an embodiment of the present invention;
Fig. 6 b are the structural representation of Network Expert Systems submodule 601 in Fig. 6 a provided in an embodiment of the present invention;
Fig. 7 is a kind of second of structural representation of the switching device of video code flow provided in an embodiment of the present invention;
Fig. 8 is a kind of the third structural representation of the switching device of video code flow provided in an embodiment of the present invention;
Fig. 9 is a kind of the 4th kind of structural representation of switching device of video code flow provided in an embodiment of the present invention;
Figure 10 is a kind of the 5th kind of structural representation of switching device of video code flow provided in an embodiment of the present invention.
Embodiment
In order that those skilled in the art more fully understand the technical scheme in the present invention, below in conjunction with present invention implementation Accompanying drawing in example, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment Only a part of embodiment of the invention, rather than whole embodiments.Based on the embodiment in the present invention, the common skill in this area The every other embodiment that art personnel are obtained under the premise of creative work is not made, belongs to the model that the present invention is protected Enclose.
In recent years, network multimedia technology is fast-developing, SD video code flow, HD video code stream, super clear video code flow Different experience of viewing and admiring are brought to user etc. the video code flow for meeting heterogeneous networks playing environment, user wishes different video code stream Between mutually switching when, the broadcasting pictures of video are smooth, not interim card, be this embodiments of the invention provide a kind of video code flow Switching method and device.
A kind of switching method of video code flow provided in an embodiment of the present invention is introduced first below.
It should be noted that a kind of switching method for video code flow that the embodiment of the present invention is provided can apply to electronics In equipment, in actual applications, the electronic equipment can be desktop computer, notebook computer, tablet personal computer, mobile phone and intelligence electricity Depending on etc., the embodiment of the present invention is not construed as limiting to this.
As shown in Figure 1a, a kind of switching method of video code flow, can include:
S101, after the instruction of video code flow handover trigger is received, determines the target video code stream corresponding to bitstreams switching.
" video code flow " described in the embodiment of the present invention can be understood as the data that video file is used within the unit interval Flow, under normal circumstances the size to code stream in units of Kb/s or Mb/s be described;Video code flow is video coding process The key factor of middle control video pictures quality, as a rule, under equal resolution, the code stream of video file is bigger, video pressure Contracting than just it is smaller, picture quality is better, and image quality is also more clear.
In order to make it easy to understand, " instruction of video code flow handover trigger " described in the embodiment of the present invention can be understood as being used to touch Videoconference client software in hair electronic equipment switches to currently playing video code flow the instruction of target video code stream.
It should be noted that size of the people generally according to code stream value, following several code stream classes are divided into by video code flow Type:SD video code flow, HD video code stream, ultra high-definition video code flow etc., the embodiment of the present invention is not construed as limiting to this.
In actual applications, generally there is the different types of video file of multiple code streams in a video file, to ensure Under different network environments, can meet user views and admires demand substantially, such as, in the case that network environment is poor, preferential to protect Demonstrate,prove the smoothness of video playback picture;Or in the case of network environment is extraordinary, it is excellent on the premise of video playback picture is smoother First ensure the clear of video playback picture.
In an embodiment of the invention, receive video code flow handover trigger instruction after, can according to work as Preceding network state, to determine the target video code stream corresponding to bitstreams switching, specific implementation as shown in Figure 1 b, can be with Including:
S101a, monitors current network state.
After the instruction of video code flow handover trigger is received, the monitoring to current network state can be started immediately, with Monitoring result is obtained, so as to continue executing with follow-up operation according to the monitoring result.It is " network-like described in the embodiment of the present invention State " can be understood as the broadband speed of network, or network stabilization degree etc., and the embodiment of the present invention is not construed as limiting to this.
S101b, according to default network state grade classification rule, it is determined that the network state belonging to current network state Grade.
" default network state grade classification rule " described in the embodiment of the present invention can be understood as electronic equipment or electricity The rule that grade classification is carried out to different network states that videoconference client in sub- equipment is pre-set, in actual conditions In, the size of network bandwidth speed different network states can be divided into several different network hierarchies according to, such as Network bandwidth speed is less than 1Mb/s, and corresponding network state grade is network hierarchy A, and network bandwidth speed is more than 1Mb/s, and Less than 2Mb/s, corresponding network state grade is network hierarchy B, and network bandwidth speed is more than 2Mb/s, corresponding network state Grade is network hierarchy C;
Or different network states is divided into by several different network hierarchies according to network stabilization degree, such as network is steady Qualitative poor, corresponding network state grade is network hierarchy A, and network stabilization is general, and corresponding network state grade is net Network grade B, preferably, corresponding network state grade is network hierarchy C to network stabilization, and network stabilization is very good, corresponding Network state grade is network hierarchy D.The embodiment of the present invention to the division of the default network state grade classification rule according to According to being not construed as limiting.
, can be according to default network state grade classification rule after current network state is monitored.To determine Network state grade belonging to the network state monitored.
S101c, the network state grade according to belonging to identified current network state, is determined corresponding to bitstreams switching Target video code stream.
, can be according to identified network state etc. it is determined that after network state grade belonging to current network state Level, to determine the target video code stream corresponding to bitstreams switching, such as, and network state grade have network hierarchy A, network hierarchy B, Network hierarchy C, wherein, network hierarchy A correspondence SDs video code flow, network hierarchy B correspondence HD videos code stream, network hierarchy C Correspondence ultra high-definition video code flow, the network hierarchy belonging to current network state is A, then the target video code corresponding to bitstreams switching Flow for SD video code flow.
S102, is loaded to the target video code stream, and continues to play current video code stream.
Such as, currently playing video code flow is HD video code stream, it is determined that target video code stream is SD video codes After stream, start the loading to SD video code flow, while continuing to play HD video code stream.
In an embodiment of the invention, can be with it is determined that after target video code stream corresponding to bitstreams switching Select some time point as start time, the target video code stream after the start time is loaded, the side of implementing Formula, as illustrated in figure 1 c, can include:
S102a, start time is recorded as by the time point for receiving the instruction of video code flow handover trigger.
In order that the process is more directly perceived, as shown in Figure 1 d, 1. in, the multiple different video code streams of video file correspondence Video file, the duration of each video file is identical, such as the video file corresponding to currently playing video code flow when It is long, it is identical with the video file duration corresponding to target video code stream.
It should be noted that rectangular black portions represent that video code flow has been loaded in Fig. 1 d, white rectangle part is represented Video code flow is not loaded.
In embodiments of the present invention, videoconference client software in electronic equipment or electronic equipment etc. can be received and regarded At the time point of frequency code stream handover trigger instruction, start time is recorded as, the position as where " ↓ " in Fig. 1 d is start time.
S102b, determines corresponding target video code stream after the start time.
S102c, is loaded to the target video code stream after the time point, and continues to play current video code stream.
As shown in Fig. 1 d 2., the target video code stream after identified start time in S102a is loaded, together Shi Jixu plays the current video code stream after the start time, is begun to so as to avoid from the head of video file to target Video code flow is loaded, brought it is time-consuming long the problem of.
S103, detects whether the load progress of target video code stream is more than the playing progress rate of current video code stream, if it is, Currently playing video code flow is then switched into target video code stream.
Load, continue during playing current video code stream to target video code stream, can be by real time Detect whether the load progress of target video code stream is more than the playing progress rate of current video code stream, or according to default detection cycle Detect whether the load progress of target video code stream is more than the playing progress rate of current video code stream, determining whether with this will be current The video code flow of broadcasting switches to target video code stream.
As shown in Fig. 1 d 3., it is determined that the load progress of target video code stream is more than the playing progress rate of current video code stream When, currently playing video code flow can be switched to target video code stream.
It should be noted that during " default detection cycle " of the present invention can be electronic equipment or electronic equipment The time cycle value that videoconference client software is set automatically in advance, such as 40s;Certainly in actual applications, user also may be used According to their needs, voluntarily to set the value of the default detection cycle, the embodiment of the present invention is not construed as limiting to this.
As can be seen here, video player is determined corresponding to bitstreams switching after the instruction of video code flow handover trigger is received Target video code stream, the target video code stream is loaded, and continue play current video code stream, until target video code When the load progress of stream is more than the playing progress rate of current video code stream, currently playing video code flow is switched to target video code Stream.
Compared with prior art, when video player reaches switching condition to the load progress of target video code stream, just meeting Stop broadcasting to current video code stream, the seamless switching between different video code stream can be realized, it is to avoid video code flow is cut " interim card " or " blank screen " phenomenon during changing, user's views and admires experience preferably.
User on an electronic device online viewing video during, network state be not it is unalterable, sometimes, user Wish that videoconference client software or webpage client on the electronic equipment can be user automatically according to current network state Higher appreciation effect video pictures are provided, be this embodiments of the invention provide the switching method of another video code flow, such as Fig. 2 Shown, this method can include:
S200, detects whether current network state changes;If it is, automatically generating video code flow handover trigger Instruction, or prompting message is sent to user, generating video code flow handover trigger according to the operation of user instructs.
In embodiments of the present invention, can be by detecting whether current network state changes in real time, or according to pre- If time cycle, detect whether current network state changes, the embodiment of the present invention is not construed as limiting to this.
It should be noted that during " default time cycle " of the present invention can be electronic equipment or electronic equipment The time cycle value that videoconference client software is set automatically in advance, such as 30s;Certainly in actual applications, user also may be used According to their needs, voluntarily to set the value of the default time cycle, the embodiment of the present invention is not construed as limiting to this.
In an embodiment of the invention, when detecting current network state and changing, it can give birth to automatically Into bitstreams switching triggering command, with the video code flow handover operation of triggering following, so as to be user's automatic switchover video code flow.
In yet another embodiment of the present invention, when detecting current network state and changing, can to A prompting message is sent at family, such as " current network state is very good, and whether you are switched to HD video code stream pattern ", Yong Hutong "Yes" can be selected by crossing, to realize input video code stream trigger action on an electronic device;So as to which the electronic equipment can basis The operation generation video code flow triggering command of user's input, with the video code flow handover operation of triggering following.
S201, after the instruction of video code flow handover trigger is received, determines the target video code stream corresponding to bitstreams switching.
S202, is loaded to the target video code stream, and continues to play current video code stream.
S203, detects whether the load progress of target video code stream is more than the playing progress rate of current video code stream, if it is, Currently playing video code flow is then switched into target video code stream.
S201, S202 and S203 in the embodiment of the present invention is identical with S101, S102 and S103 in previous embodiment, this Inventive embodiments are repeated no more to this.
As can be seen here, the embodiment of the present invention, by the detection to current network state, is automatically use according to testing result Family switches video code flow of the currently playing video code flow corresponding to the higher video pictures of appreciation effect, such as currently playing Video code flow be HD video code stream, current network state is poor, and the videoconference client software on electronic equipment can root According to current network state, currently playing video code flow is switched into SD video code flow automatically, so as to ensure video pictures Fluency, it is to avoid it is lasting the problems such as play the interim card that same video code flow is brought.
In another embodiment of the present invention, as shown in figure 3, a kind of switching method of video code flow, can include:
S301, after the instruction of video code flow handover trigger is received, determines the target video code stream corresponding to bitstreams switching.
S302, is loaded to the target video code stream, and continues to play current video code stream.
S303, detects whether the load progress of target video code stream is more than the playing progress rate of current video code stream, if it is, Currently playing video code flow is then switched into target video code stream.
S301, S302 and S303 in the embodiment of the present invention is identical with S101, S102 and S103 in previous embodiment, this Inventive embodiments are repeated no more to this.
S304, message informing is sent to user, and the message informing is used to point out user video code stream to switch successfully.
After video code flow handover success, message informing can be sent to user, inform user's current video code stream Handover operation has succeeded, it is to avoid user takes for video code flow handover operation not successfully, and repeatedly carries out on an electronic device Video code flow handover trigger is operated, and the situation for increasing the processing pressure of server occurs.
The load progress of default objects video code flow can be more than the playing progress rate of current video code stream in above-described embodiment, But in actual applications, the load progress that may have target video code stream is not more than the playing progress rate of current video code stream Situation, in this case, continue loaded targets video code flow can cause the waste of the network bandwidth, can further cause video Occur the phenomenons such as interim card, blank screen in playing process.
In order to solve the above problems, the embodiments of the invention provide the switching method of another video code flow, such as Fig. 4 institutes Show, this method can include:
S401, after the instruction of video code flow handover trigger is received, determines the target video code stream corresponding to bitstreams switching.
S402, is loaded to the target video code stream, and continues to play current video code stream.
S401, S402 in the embodiment of the present invention is identical with S101, S102 in previous embodiment, the embodiment of the present invention pair This is repeated no more.
S403, detects whether the load progress of the target video code stream within the default time is more than broadcasting for current video code stream Degree of putting into, if it is, going to S404, otherwise goes to S405.
In the embodiment of the present invention, it can be regarded by pre-setting a time to solve target present in practical application The problem of load progress of frequency code stream is not more than the playing progress rate of current video code stream, such as 10min, if within 10min, The load progress of target video code stream is not more than the playing progress rate of current video code stream, then can stop to the target video code stream Loading.
It should be noted that " default time " of the present invention can be the video in electronic equipment or electronic equipment The time cycle value that client software is set automatically in advance, such as 10min;Certainly in actual applications, user can also According to their needs, the value of the default time is voluntarily set, and the embodiment of the present invention is not construed as limiting to this.
S404, target video code stream is switched to by currently playing video code flow.
The broadcasting for being more than current video code stream in the load progress for detecting the target video code stream within the default time is entered In the case of degree, currently playing video code flow can be switched to target video code stream.
S405, suspends the loading to the target video code stream.
It is not more than the broadcasting of current video code stream in the load progress for detecting the target video code stream within the default time In the case of progress, the loading to the target video code stream can be suspended.
In another embodiment of the present invention, as shown in figure 5, a kind of switching method of video code flow, can include:
S501, after the instruction of video code flow handover trigger is received, determines the target video code stream corresponding to bitstreams switching.
S502, is loaded to the target video code stream, and continues to play current video code stream.
S503, detects whether the load progress of the target video code stream within the default time is more than broadcasting for current video code stream Degree of putting into, if it is, going to S504, otherwise goes to S505.
S504, target video code stream is switched to by currently playing video code flow.
S505, suspends the loading to the target video code stream.
S401, S402, S403 in S501, S502, S503 and S504 and previous embodiment in the embodiment of the present invention and S404 is identical, and the embodiment of the present invention is repeated no more to this.
S506, message notifying is sent to user, and the message notifying is used to point out user under current playing environment, nothing Bitstreams switching operation need to be carried out.
After loading of the pause to target video code stream, message notifying can be sent to user, inform that user is current Bitstreams switching need not be carried out under playing environment, it is to avoid user takes for video code flow handover operation not successfully, and repeatedly in electronics Video code flow handover trigger operation is carried out in equipment, the situation for increasing the processing pressure of server occurs.
Corresponding to above method embodiment, the embodiment of the present invention additionally provides a kind of switching device of video code flow.
As shown in Figure 6 a, a kind of switching device of video code flow, can include:
Code stream determining module 601, for after the instruction of video code flow handover trigger is received, determining corresponding to bitstreams switching Target video code stream;
Code stream load-on module 602, for loading the target video code stream, and continues to play current video code Stream;
Progress detection module 603, for detecting whether the load progress of target video code stream is more than current video code stream Playing progress rate;
Bitstreams switching module 604, the broadcasting for being more than current video code stream in the load progress of target video code stream is entered In the case of degree, currently playing video code flow is switched into target video code stream.
In an embodiment of the invention, as shown in Figure 6 b, the code stream determining module 601, including:
Network Expert Systems submodule 601a, the current network state for monitoring;
Network hierarchy divides submodule 601b, for according to default network state grade classification rule, it is determined that current Network state grade belonging to network state, wherein, the different video code flow handover scheme of different network state grade correspondences;
Code stream determination sub-module 601c, for the networking state grade according to belonging to identified current network state, really Determine the target video code stream corresponding to bitstreams switching.
In yet another embodiment of the present invention, the code stream determining module 601, for being grasped according to the triggering of user Make, determine the target video code stream corresponding to bitstreams switching.
In yet another embodiment of the present invention, the code stream load-on module 602, cuts for that will receive video code flow The time point for changing triggering command is recorded as start time;
Determine corresponding target video code stream after the start time;
Target video code stream after the time point is loaded, and continues to play current video code stream.
In yet another embodiment of the present invention, the progress detection module 603, specifically for:
Whether the load progress of detection target video code stream is more than the playing progress rate of current video code stream in real time;
Or
According to default detection cycle, detect whether the load progress of target video code stream is more than broadcasting for current video code stream Degree of putting into.
In another embodiment, as shown in fig. 7, a kind of switching device of video code flow, can include:
Network state detection module 701, for detecting, whether current network state changes;
Directive generation module 702 includes:First generation submodule or the second generation submodule;
Wherein, the first generation submodule, for the feelings for being yes in the testing result of the network state detection module Under condition, the instruction of video code flow handover trigger is automatically generated;
The second generation submodule, in the case of being in the testing result of the network state detection module, Prompting message is sent to user, according to the operation of user, the handover trigger instruction of generation video code flow;
Code stream determining module 703, for after the instruction of video code flow handover trigger is received, determining corresponding to bitstreams switching Target video code stream;
Code stream load-on module 704, for loading the target video code stream, and continues to play current video code Stream;
Progress detection module 705, for detecting whether the load progress of target video code stream is more than current video code stream Playing progress rate;
Bitstreams switching module 706, the broadcasting for being more than current video code stream in the load progress of target video code stream is entered In the case of degree, currently playing video code flow is switched into target video code stream.
In an embodiment of the invention, the network state detection module 701, specifically for:
Detect whether current network state changes in real time;
Or
According to the default time cycle, detect whether current network state changes.
In another embodiment of the present invention, as shown in figure 8, a kind of switching device of video code flow, can include:
Code stream determining module 801, for after the instruction of video code flow handover trigger is received, determining corresponding to bitstreams switching Target video code stream;
Code stream load-on module 802, for loading the target video code stream, and continues to play current video code Stream;
Progress detection module 803, for detecting whether the load progress of target video code stream is more than current video code stream Playing progress rate;
Bitstreams switching module 804, the broadcasting for being more than current video code stream in the load progress of target video code stream is entered In the case of degree, currently playing video code flow is switched into target video code stream;
Message informing sending module 805, for sending message informing to user, the message informing is used to point out user to regard Frequency code stream has been switched successfully.
In another embodiment of the present invention, as shown in figure 9, a kind of switching device of video code flow, can include:
Code stream determining module 901, for after the instruction of video code flow handover trigger is received, determining corresponding to bitstreams switching Target video code stream;
Code stream load-on module 902, for loading the target video code stream, and continues to play current video code Stream;
Progress detection module 903, for detecting whether the load progress of the target video code stream within the default time is more than The playing progress rate of current video code stream;
Bitstreams switching module 904, ought in the case of being in the testing result of the progress detection module 903 The video code flow of preceding broadcasting switches to target video code stream;
Code stream loading pause module 905, in the case of being no in the testing result of the progress detection module 903, Suspend the loading to the target video code stream.
In another embodiment of the present invention, as shown in Figure 10, a kind of switching device of video code flow, can include:
Code stream determining module 1001, for after the instruction of video code flow handover trigger is received, determining that bitstreams switching institute is right The target video code stream answered;
Code stream load-on module 1002, for loading the target video code stream, and continues to play current video code Stream;
Progress detection module 1003, for detecting whether the load progress of the target video code stream within the default time is more than The playing progress rate of current video code stream;
Bitstreams switching module 1004, will in the case of being in the testing result of the progress detection module 1003 Currently playing video code flow switches to target video code stream;
Code stream loading pause module 1005, for the situation for being no in the testing result of the progress detection module 1003 Under, suspend the loading to the target video code stream;
Message notifying sending module 1006, for sending message informing to user, the message informing is used to point out user Video code flow has been switched successfully.
For device embodiment, because it is substantially similar to embodiment of the method, so description is fairly simple, it is related Part illustrates referring to the part of embodiment of the method.
For convenience of description, it is divided into various modules during description apparatus above with function to describe respectively.Certainly, this is being implemented The function of each module can be realized in same or multiple softwares and/or hardware during invention.
It should be noted that herein, such as first and second or the like relational terms are used merely to a reality Body or operation make a distinction with another entity or operation, and not necessarily require or imply these entities or deposited between operating In any this actual relation or order.Moreover, term " comprising ", "comprising" or its any other variant are intended to Nonexcludability is included, so that process, method, article or equipment including a series of key elements not only will including those Element, but also other key elements including being not expressly set out, or also include being this process, method, article or equipment Intrinsic key element.In the absence of more restrictions, the key element limited by sentence " including one ... ", it is not excluded that Also there is other identical element in the process including the key element, method, article or equipment.
Each embodiment in this specification is described by the way of related, identical similar portion between each embodiment Divide mutually referring to what each embodiment was stressed is the difference with other embodiment.It is real especially for device Apply for example, because it is substantially similar to embodiment of the method, so description is fairly simple, related part is referring to embodiment of the method Part explanation.
Can one of ordinary skill in the art will appreciate that realizing that all or part of step in above method embodiment is To instruct the hardware of correlation to complete by program, described program can be stored in computer read/write memory medium, The storage medium designated herein obtained, such as:ROM/RAM, magnetic disc, CD etc..
The foregoing is merely illustrative of the preferred embodiments of the present invention, is not intended to limit the scope of the present invention.It is all Any modification, equivalent substitution and improvements made within the spirit and principles in the present invention etc., are all contained in protection scope of the present invention It is interior.

Claims (22)

1. a kind of switching method of video code flow, it is characterised in that this method includes:
After the instruction of video code flow handover trigger is received, the target video code stream corresponding to bitstreams switching is determined, wherein, video Code stream is the data traffic that video file is used within the unit interval;
The target video code stream is loaded, and continues to play current video code stream;
Detect whether the load progress of target video code stream is more than the playing progress rate of current video code stream;
If the load progress of target video code stream is more than the playing progress rate of current video code stream, by currently playing video codes Stream switches to target video code stream.
2. according to the method described in claim 1, it is characterised in that the target video code determined corresponding to bitstreams switching Stream, including:
According to the trigger action of user, the target video code stream corresponding to bitstreams switching is determined.
3. according to the method described in claim 1, it is characterised in that the target video code determined corresponding to bitstreams switching Stream, including:
The current network state of monitoring;
It is regular according to default network state grade classification, it is determined that the network state grade belonging to current network state, wherein, The different video code flow handover scheme of different network state grade correspondences;
Networking state grade according to belonging to identified current network state, determines the target video code corresponding to bitstreams switching Stream.
4. according to the method described in claim 1, it is characterised in that described that the target video code stream is loaded, including:
The time point for receiving the instruction of video code flow handover trigger is recorded as start time;
Determine corresponding target video code stream after the start time;
Target video code stream after the time point is loaded.
5. according to the method described in claim 1, it is characterised in that whether the load progress of the detection target video code stream is big In the playing progress rate of current video code stream, including:
Whether the load progress of detection target video code stream is more than the playing progress rate of current video code stream in real time;
Or
According to default detection cycle, the load progress of detection target video code stream whether enter by the broadcasting more than current video code stream Degree.
6. according to the method described in claim 1, it is characterised in that whether the load progress of the detection target video code stream is big In the playing progress rate of current video code stream, including:
Detect whether the load progress of the target video code stream within the default time is more than the playing progress rate of current video code stream;
If the load progress of the target code stream is more than the playing progress rate of current video code stream, by currently playing video codes Stream switches to target video code stream, is specially:
If the load progress of target code stream is more than the playing progress rate of current video code stream within the default time, ought The video code flow of preceding broadcasting switches to target video code stream.
7. method according to claim 6, it is characterised in that if the target video code stream within the default time Load progress is not more than the playing progress rate of current video code stream, then further comprises:
Suspend the loading to the target video code stream.
8. method according to claim 7, it is characterised in that this method further comprises:
Message notifying is sent to user, the message notifying is used to point out user under current playing environment, without carrying out code Flow handover operation.
9. according to the method described in claim 1, it is characterised in that before the instruction of video code flow handover trigger is received, also wrap Include:
Whether the current network state of detection changes;
If it is, automatically generating the instruction of video code flow handover trigger, or prompting message is sent to user, according to the behaviour of user Make, the handover trigger instruction of generation video code flow.
10. method according to claim 9, it is characterised in that whether the current network state of the detection changes, Including:
Detect whether current network state changes in real time;
Or
According to the default time cycle, detect whether current network state changes.
11. according to the method described in claim 1, it is characterised in that switching to target to regard currently playing video code flow After frequency code stream, in addition to:
Message informing is sent to user, the message informing is used to point out user video code stream to switch successfully.
12. a kind of switching device of video code flow, it is characterised in that the device includes:
Code stream determining module, for after the instruction of video code flow handover trigger is received, determining the target corresponding to bitstreams switching Video code flow, wherein, video code flow is the data traffic that video file is used within the unit interval;
Code stream load-on module, for loading the target video code stream, and continues to play current video code stream;
Progress detection module, for detecting the load progress of target video code stream whether enter by the broadcasting more than current video code stream Degree;
Bitstreams switching module, the situation of the playing progress rate for being more than current video code stream in the load progress of target video code stream Under, currently playing video code flow is switched into target video code stream.
13. device according to claim 12, it is characterised in that the code stream determining module, specifically for:
According to the trigger action of user, the target video code stream corresponding to bitstreams switching is determined.
14. device according to claim 12, it is characterised in that the code stream determining module, including:
Network Expert Systems submodule, the current network state for monitoring;
Network hierarchy divides submodule, for according to default network state grade classification rule, it is determined that current network state Affiliated network state grade, wherein, the different video code flow handover scheme of different network state grade correspondences;
Code stream determination sub-module, for the networking state grade according to belonging to identified current network state, determines that code stream is cut Change corresponding target video code stream.
15. device according to claim 12, it is characterised in that the code stream load-on module, specifically for:
The time point for receiving the instruction of video code flow handover trigger is recorded as start time;
Determine corresponding target video code stream after the start time;
Target video code stream after the time point is loaded, and continues to play current video code stream.
16. device according to claim 12, it is characterised in that the progress detection module, specifically for:
Whether the load progress of detection target video code stream is more than the playing progress rate of current video code stream in real time;
Or
According to default detection cycle, the load progress of detection target video code stream whether enter by the broadcasting more than current video code stream Degree.
17. device according to claim 12, it is characterised in that the progress detection module, specifically for:
Detect whether the load progress of the target video code stream within the default time is more than the playing progress rate of current video code stream;
The bitstreams switching module, will be current in the case of being in the testing result of the progress detection module The video code flow of broadcasting switches to target video code stream.
18. device according to claim 17, it is characterised in that the device further comprises:
Code stream loading pause module, in the case of being no in the testing result of the progress detection module, suspends to described The loading of target video code stream.
19. device according to claim 18, it is characterised in that the device further comprises:
Message notifying sending module, for sending message notifying to user, the message notifying is used to point out user current Under playing environment, without carrying out bitstreams switching operation.
20. device according to claim 12, it is characterised in that the device also includes:
Network state detection module and directive generation module;
The network state detection module, for detecting, whether current network state changes;
The directive generation module includes:First generation submodule or the second generation submodule;
The first generation submodule, in the case of being in the testing result of the network state detection module, automatically Generate the instruction of video code flow handover trigger;
The second generation submodule, in the case of being in the testing result of the network state detection module, Xiang Yong Family sends prompting message, according to the operation of user, the handover trigger instruction of generation video code flow.
21. device according to claim 20, it is characterised in that the network state detection module, specifically for:
Detect whether current network state changes in real time;
Or
According to the default time cycle, detect whether current network state changes.
22. device according to claim 12, it is characterised in that the device also includes:
Message informing sending module, for sending message informing to user, the message informing is used to point out user video code stream Switch successfully.
CN201410250882.7A 2014-06-06 2014-06-06 The switching method and device of a kind of video code flow Active CN103997680B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201410250882.7A CN103997680B (en) 2014-06-06 2014-06-06 The switching method and device of a kind of video code flow

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201410250882.7A CN103997680B (en) 2014-06-06 2014-06-06 The switching method and device of a kind of video code flow

Publications (2)

Publication Number Publication Date
CN103997680A CN103997680A (en) 2014-08-20
CN103997680B true CN103997680B (en) 2017-10-24

Family

ID=51311664

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201410250882.7A Active CN103997680B (en) 2014-06-06 2014-06-06 The switching method and device of a kind of video code flow

Country Status (1)

Country Link
CN (1) CN103997680B (en)

Families Citing this family (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104967884B (en) * 2015-04-17 2018-01-26 北京奇艺世纪科技有限公司 A kind of bitstreams switching method and apparatus
CN104837051B (en) * 2015-05-26 2019-02-22 腾讯科技(北京)有限公司 Video broadcasting method and client
CN105472439A (en) * 2015-12-15 2016-04-06 小米科技有限责任公司 Method and device for displaying image data
CN105611393B (en) * 2015-12-21 2019-04-23 深圳Tcl数字技术有限公司 Video playing control method and device
CN106131615A (en) * 2016-07-25 2016-11-16 北京小米移动软件有限公司 Video broadcasting method and device
CN111970572B (en) * 2018-01-31 2022-05-17 聚好看科技股份有限公司 Method for controlling video occlusion map on smart television
CN108848414A (en) * 2018-06-26 2018-11-20 曜宇航空科技(上海)有限公司 The switching method and player of a kind of playback method of video, clarity
CN109144612B (en) * 2018-09-03 2021-10-15 武汉斗鱼网络科技有限公司 Android definition switching method and device, terminal and readable medium
CN109246462B (en) * 2018-10-11 2021-08-06 苏宁易购集团股份有限公司 Seamless switching method and device for video stream
CN109413457B (en) * 2018-10-18 2021-11-09 武汉斗鱼网络科技有限公司 Code stream definition switching method and device for Android system, terminal and readable medium
CN111479171B (en) * 2019-01-23 2022-05-20 上海哔哩哔哩科技有限公司 Pseudo seamless switching method, device and medium among different video sources played by Web
WO2021012180A1 (en) * 2019-07-23 2021-01-28 深圳市大疆创新科技有限公司 Transmission control method and device for code streams, and computer readable storage medium
CN110677326B (en) * 2019-10-15 2021-05-14 深圳品阔信息技术有限公司 Network state detection method, device, terminal and storage medium
CN112543342B (en) * 2020-11-26 2023-03-14 腾讯科技(深圳)有限公司 Virtual video live broadcast processing method and device, storage medium and electronic equipment
CN113556621B (en) * 2021-07-22 2023-09-08 乐视网信息技术(北京)股份有限公司 Method, server, client, device and storage medium for switching code streams

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752543A (en) * 2012-07-27 2012-10-24 北京威泰嘉业科技有限公司 Seamless switching method and seamless switching system of high-definition hybrid matrix
CN102905188A (en) * 2012-11-01 2013-01-30 北京奇艺世纪科技有限公司 Video code stream switching method and device
CN103561283A (en) * 2013-10-30 2014-02-05 乐视致新电子科技(天津)有限公司 Method and device for code rate switch of smart television
CN103686346A (en) * 2013-12-26 2014-03-26 乐视网信息技术(北京)股份有限公司 Video playing unsmoothness switching method and system
CN103716681A (en) * 2013-12-06 2014-04-09 乐视网信息技术(北京)股份有限公司 Code stream switching method and electronic equipment

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20020191116A1 (en) * 2001-04-24 2002-12-19 Damien Kessler System and data format for providing seamless stream switching in a digital video recorder
CN101179700B (en) * 2006-12-20 2011-05-11 腾讯科技(深圳)有限公司 Program source switch method and stream media play system
JP2010523048A (en) * 2007-03-29 2010-07-08 トムソン ライセンシング Content distribution to digital cinema system and playback method and apparatus in digital cinema system
KR20110042198A (en) * 2008-07-28 2011-04-25 톰슨 라이센싱 Method and apparatus fast channel change using a scalable video coding(svc) stream
CN101466034A (en) * 2008-12-25 2009-06-24 华为技术有限公司 Method and device for sending and playing stream medium data and stream medium program request system
CN103188529A (en) * 2011-12-27 2013-07-03 北京朝歌数码科技股份有限公司 Multimedia play method for switching from first channel to second channel and multimedia play device
CN102724584B (en) * 2012-06-18 2016-07-27 Tcl集团股份有限公司 The online player method of Internet video, the online playing device of video and intelligent television

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102752543A (en) * 2012-07-27 2012-10-24 北京威泰嘉业科技有限公司 Seamless switching method and seamless switching system of high-definition hybrid matrix
CN102905188A (en) * 2012-11-01 2013-01-30 北京奇艺世纪科技有限公司 Video code stream switching method and device
CN103561283A (en) * 2013-10-30 2014-02-05 乐视致新电子科技(天津)有限公司 Method and device for code rate switch of smart television
CN103716681A (en) * 2013-12-06 2014-04-09 乐视网信息技术(北京)股份有限公司 Code stream switching method and electronic equipment
CN103686346A (en) * 2013-12-26 2014-03-26 乐视网信息技术(北京)股份有限公司 Video playing unsmoothness switching method and system

Also Published As

Publication number Publication date
CN103997680A (en) 2014-08-20

Similar Documents

Publication Publication Date Title
CN103997680B (en) The switching method and device of a kind of video code flow
US10042420B2 (en) Gaze-aware control of multi-screen experience
CN107277242A (en) A kind of processing method of displaying information on screen, display methods and display system
US10798363B2 (en) Video file processing method and apparatus
CN102905188A (en) Video code stream switching method and device
CN112153470B (en) Video playing method and device, computer equipment and storage medium
CN103618959A (en) Method and device for video playing
CN104023264A (en) Method and device for playing video
CN113342248B (en) Live broadcast display method and device, storage medium and electronic equipment
CN106162232A (en) video playing control method and device
CN103226961A (en) Play method and device
US10231005B2 (en) Operation instructing method and apparatus for remote controller of intelligent television
CN109358941B (en) Control method and electronic equipment
KR20230144582A (en) Live streaming video-based interaction method and apparatus, device and storage medium
CN111757164B (en) Video playing switching method and device, electronic equipment and storage medium
CN104965694A (en) Information processing method and terminal
CN106033247B (en) A kind of information processing method and electronic equipment
CN113965665A (en) Method and equipment for determining virtual live broadcast image
CN111766989A (en) Interface switching method and device
CN110215689A (en) The method and apparatus of game interaction control
CN114650496B (en) Audio playing method and electronic equipment
KR20210143651A (en) Method for displaying images based on scroll gesture and viewer device for performing the same
CN113395585A (en) Video detection method, video playing control method and device and electronic equipment
CN105828013A (en) Display device signal source selection method and device
CN106502562A (en) A kind of method and device of cleaning internal memory

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
ASS Succession or assignment of patent right

Owner name: SHANGHAI ZHONGYUAN NETWORK CO., LTD.

Free format text: FORMER OWNER: BEIJING QIYI CENTURY TECHNOLOGY CO., LTD.

Effective date: 20150810

C41 Transfer of patent application or patent right or utility model
TA01 Transfer of patent application right

Effective date of registration: 20150810

Address after: 201103 room 3, building 33, No. 701, Leshan Road, Shanghai

Applicant after: Shanghai Zhongyuan Network Co., Ltd.

Address before: A 100080 street Beijing city Haidian District North No. 2, building 10, 11 layers of Goldtron expand

Applicant before: Beijing Qiyi Century Technology Co., Ltd.

GR01 Patent grant
GR01 Patent grant