WO2017071428A1 - Fast forward/rewind processing method and terminal - Google Patents

Fast forward/rewind processing method and terminal Download PDF

Info

Publication number
WO2017071428A1
WO2017071428A1 PCT/CN2016/099377 CN2016099377W WO2017071428A1 WO 2017071428 A1 WO2017071428 A1 WO 2017071428A1 CN 2016099377 W CN2016099377 W CN 2016099377W WO 2017071428 A1 WO2017071428 A1 WO 2017071428A1
Authority
WO
WIPO (PCT)
Prior art keywords
frame
time point
duration
current program
fast
Prior art date
Application number
PCT/CN2016/099377
Other languages
French (fr)
Chinese (zh)
Inventor
周茂林
程子乾
陈洲
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2017071428A1 publication Critical patent/WO2017071428A1/en

Links

Images

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/47End-user applications
    • H04N21/472End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
    • H04N21/47217End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content for controlling playback functions for recorded or on-demand content, e.g. using progress bars, mode or play-point indicators or bookmarks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/238Interfacing the downstream path of the transmission network, e.g. adapting the transmission rate of a video stream to network bandwidth; Processing of multiplex streams
    • H04N21/2387Stream processing in response to a playback request from an end-user, e.g. for trick-play
    • 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/47End-user applications
    • H04N21/472End-user interface for requesting content, additional data or services; End-user interface for interacting with content, e.g. for content reservation or setting reminders, for requesting event notification, for manipulating displayed content
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • H04N21/8455Structuring of content, e.g. decomposing content into time segments involving pointers to the content, e.g. pointers to the I-frames of the video stream

Definitions

  • the embodiments of the present invention relate to the field of streaming media communication technologies, and in particular, to a fast forward and fast rewind processing method and a terminal.
  • the OTT (Over The Top) service is the most common service in the Internet business, and the OTT mobile video service service based on the open Internet is suitable for many applications such as Live, On Demand, and Time Shift in the future.
  • One of the best solutions for demand is the most common service in the Internet business, and the OTT mobile video service service based on the open Internet is suitable for many applications such as Live, On Demand, and Time Shift in the future.
  • the playback control of the common OTT service adopts the code stream adaptive mode, and the commonly used protocols include: Http Live Streaming, MPEG DASH, Microsoft Smooth Streaming and the like.
  • the OTT service uses the low-level positioning method in fast forward and rewind. In this mode, the fast forward and rewind user experience of the current program is faster than that in the Internet Protocol Television (IPTV) service.
  • IPTV Internet Protocol Television
  • the fast-rewinding user experience is poor, and the IPTV service adopts the I frame (I Frame) playback mode to achieve fast forward and rewind.
  • the I frame is a full frame compression coded frame, which may also be referred to as an intraframe coded frame.
  • the data volume of the I frame is generally large, and the I frame is generated without reference to other frames, and belongs to the reference frame, and is only used for decoding. An I town can reconstruct a complete image.
  • the protocol used for OTT video playback is also considering the I frame play mode that supports fast forward and rewind, and based on the OTT video play service, the terminal generally downloads I frame data of all I frames of the currently playing program from the server. Down, after entering the fast forward and rewind state, the downloaded I frame data is sequentially output.
  • the main purpose of the embodiments of the present invention is to provide a fast forward and fast rewind processing method and a terminal, which are intended to solve the bandwidth of the I frame data that needs to be downloaded in a large number of I frames during fast forward and fast rewind in the related art. Asking too high a question.
  • an embodiment of the present invention provides a fast forward and fast rewind processing method, including:
  • the I frame is obtained according to the current program play duration, the index information of each I frame of the current program saved in advance, and the multiple speed included in the fast forward or fast reverse request.
  • the index information of each I frame of the current program saved in advance, and the content included in the fast forward or fast reverse request I frame is selected at double speed to obtain an I frame sequence, including:
  • the I frame is selected according to the duration of the current program, the second duration, and the time point of each I frame of the current program, to obtain the I frame sequence, including:
  • Step 1 the sum of the second duration of the current program played duration plus m times is taken as an effective time point
  • Step 2 determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
  • Step 4 If there is no I frame after the valid time point, the selection of the I frame ends.
  • the I frame is selected according to the duration of the current program, the second duration, and the time point of the I frame included in the index information of each I frame of the current program, to obtain the I frame sequence.
  • the duration of the current program the duration of the current program, the second duration, and the time point of the I frame included in the index information of each I frame of the current program, to obtain the I frame sequence.
  • Step 1 subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
  • Step 2 determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
  • the embodiment of the present invention further provides a terminal, including:
  • the selection module is configured to, according to the current program played duration, the pre-stored index information of each I frame of the current program, and the double speed included in the fast forward or rewind request, when the fast forward or fast reverse request is received Selecting an I frame to obtain an I frame sequence;
  • the sending module is configured to send a data request message to the server, and the data request message sequentially carries the I frame sequence in the sequence of the first time period that is preset before the selection module obtains the I frame sequence. Index information of the I frame;
  • the receiving output module is configured to receive and decode the I frame data that is fed back by the server according to the index information of the received I frame after the sending module sends the data request message.
  • the selecting module includes:
  • a duration determining module configured to receive a fast forward request or a fast reverse request, according to the fast The double speed of entering or rewinding determines the second time length
  • a frame selection module configured to: after the duration determining module determines the second duration, select an I frame according to the current duration of the current program, the second duration, and the time point of each I frame of the current program. Obtaining the I frame sequence, where the time point of the I frame is included in the index information of the I frame.
  • the frame selection module is specifically configured to:
  • Step 1 the sum of the second duration of the current program played duration plus m times is taken as an effective time point
  • Step 2 determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
  • Step 4 If there is no I frame after the valid time point, the selection of the I frame ends.
  • the frame selection module is specifically configured to:
  • Step 1 subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
  • Step 2 determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
  • a computer storage medium is also provided, and the computer storage medium is provided.
  • the quality may store an execution instruction for executing the fast forward and rewind processing method in the above embodiment.
  • An embodiment of the method for fast forward and rewind provided by the embodiment of the present invention is: when receiving a fast forward or fast reverse request, the terminal according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward.
  • the I frame is selected in the fast rewind request to obtain an I frame sequence, and a data request message is sent to the server for each first interval set in advance, and the transmitted data request message carries one of the I frame sequences in sequence.
  • the terminal will also receive and decode the data of the I frame fed back by the output server according to the index information of the received I frame to implement fast forward and rewind.
  • the selected I frame is a part of the I frame of the current program, when the fast forward and rewind are implemented, it is not necessary to download the I frame data of all the I frames of the current program, and the output effect of the fast forward and rewind can be realized. At the same time, the download amount of the I frame data is effectively reduced, and the reduction of the I frame data download amount can effectively reduce the requirement for the broadband.
  • FIG. 1 is a schematic flow chart of a first embodiment of a method for processing fast forward and rewind according to the present invention
  • FIG. 2 is a schematic flow chart of a second embodiment of a method for processing fast forward and rewind according to the present invention
  • FIG. 3 is a schematic diagram of functional modules of a first embodiment of a terminal according to the present invention.
  • FIG. 4 is a schematic diagram of functional modules of a second embodiment of a terminal of the present invention.
  • the main solution of the embodiment of the present invention is: when receiving the fast forward or fast reverse request, the terminal according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward and rewind request included in the request
  • the I frame is selected at a double speed to obtain an I frame sequence, and the I frame sequence includes a partial I frame of the current program.
  • the terminal sends a data request message to the server every time the interval is preset, and the data request message is sequentially carried in the sent data request message.
  • An I frame of the I frame sequence is carried, and the terminal further receives and decodes data of the I frame fed back by the output server according to the received index information of the I frame to implement fast forward and rewind.
  • the selected I frame is a part of the I frame of the current program, in the process of implementing fast forward and rewind, it is not necessary to download the I frame data of all the I frames of the current program, and the output can be fast forwarded and rewinded.
  • the effect is effective at reducing the download amount of I frame data, and the reduction of the I frame data download amount can effectively reduce the requirement for broadband.
  • FIG. 1 is a schematic diagram of a first embodiment of a fast forward and fast rewind processing method according to the present invention.
  • the method includes:
  • Step 101 When receiving a fast forward or fast reverse request, according to the current program play duration, the index information of each I frame of the current program saved in advance, and the I frame included in the fast forward or fast reverse request, the I frame is obtained, and I is obtained.
  • Frame sequence
  • the terminal when the terminal starts to play the program, the terminal sends an I frame index information request message to the server, and after receiving the I frame index information request message, the server parses the video source of the current program of the terminal, and obtains The index information of each I frame of the current program is fed back to the terminal by the obtained index information of each I frame.
  • the terminal After receiving the index information of each I frame of the current program, the terminal saves the index information of each I frame of the current program.
  • the index information of the I frame includes at least the time point of the I frame, and the time point of the I frame refers to the time point of the I frame in the current program.
  • the index information of the I frame may further include parameters such as the name of the fragment where the I frame is located, the offset position of the I frame in the fragment, and the size of the I frame.
  • the user may issue a fast forward or fast reverse request to the terminal by using a remote control or a touch screen touch, and the fast forward or fast reverse request includes a fast forward or fast reverse speed, wherein
  • the double speed of entering or rewinding can be 2, 4, 8, 16 and so on.
  • the terminal After receiving the fast forward or fast reverse request, the terminal selects an I frame according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward or fast reverse request. Get the I frame sequence.
  • the terminal will stop broadcasting at the normal playback speed after receiving the fast forward or fast reverse request. Release mode, and the terminal will obtain the elapsed duration of the current program when receiving the fast forward or fast rewind request, for example, if the fast forward or rewind request is received when the current program is played for 10 minutes, the current program has been played. The duration is 10 minutes.
  • the terminal may be a television, a computer, a set top box, a PAD, a smart phone, or the like.
  • Step 102 Send a data request message to the server every time the interval is preset, and the data request message sequentially carries the index information of the I frame in the I frame sequence.
  • Step 103 Receive and decode data of an I frame fed back by the output server according to the received index information of the I frame.
  • the terminal after selecting an I frame and obtaining an I frame sequence, the terminal sends a data request message to the server for each first interval set in advance, and the data request message sequentially carries the I in the I frame sequence.
  • the index information of the frame is not limited to the frame.
  • the I frames in the I frame sequence are arranged in the order of time points. If the I frame sequence obtained in the fast forward case, the I frame in the I frame sequence It is arranged in order of increasing time points. If the I frame sequence is obtained in the case of fast rewind, the I frames in the I frame sequence are arranged in order of decreasing time points.
  • the data request message includes the index information of the I frame in the I frame sequence, and the terminal is sequentially carried in the data request message according to the order of the I frames in the I frame sequence.
  • the terminal sequentially transmits the data carrying the index information of I0 for each first interval set in advance after the I frame sequence is obtained.
  • the request message the data request message carrying the index information of I1, the data request message carrying the index information of I2, the data request message carrying the index information of I3, ..., the data request message carrying the index information of I10.
  • the index information of the I frame carried by the terminal includes the time point of the I frame, the fragment name of the I frame, the offset position of the I frame in the fragment, and the I frame size.
  • the server After receiving the data request message, the server will use the index information of the I frame carried by the server.
  • the time point of the I frame in the I frame determines the position of the I frame on the total duration of the current program, and uses the slice name in which the I frame is located to determine the slice in which the I frame is located, and after determining the slice, the I frame is used in the segment.
  • the offset position and the I frame size in the slice extract I frame data, and the extracted I frame data is fed back to the terminal.
  • the server After receiving the data request message, the server determines the corresponding I frame data based on the index information of the I frame in the above manner, and feeds the obtained I frame data to the terminal. And each time the terminal receives the I frame data, the terminal will decode and output the received I frame data, so that the fast forward or fast reverse output effect can be displayed on the display interface of the terminal.
  • the I frame is selected according to the current program play duration, the index information of each I frame of the current program, and the double speed of fast forward or fast reverse, to obtain an I frame. a sequence, and sending a data request message to the server every predetermined first time period, and the data request message sequentially carries the index information of the I frame in the I frame sequence, and receives the index of the received I frame according to the received frame. After the I frame data of the information feedback, the terminal will decode and output the I frame data.
  • the I-frame of the selected part can be downloaded from the server to realize the fast-forward and fast-return output effect, without downloading all the I-frames of the current program, thereby effectively reducing the download amount of the I-frame data, and Can effectively reduce the requirements for broadband.
  • FIG. 2 is a schematic diagram of a second embodiment of a fast forward and fast rewind processing method provided by the present invention. Steps 201 and 202 in the method are correct.
  • the refinement of step 101 in the first embodiment, specifically, the method includes:
  • Step 201 When receiving a fast forward request or a fast reverse request, determining a second duration according to a double speed of fast forward or fast reverse;
  • the terminal when receiving a fast forward or fast reverse request, determines a second duration according to a fast forward or fast reverse speed, wherein the second duration is used to select an I frame.
  • the double speed of fast forward or fast reverse is carried in the fast forward or fast reverse request, and the user who uses the terminal can determine the double speed of fast forward or fast reverse by selecting.
  • determining the second duration according to the double speed of fast forward or rewind may be: if the double speed of fast forward or fast reverse is N, determining that the second duration is N seconds, or determining that the second duration is N double speed.
  • the second duration may be related to the first duration, where the first duration is a preset time interval for sending a data request message to the server. Specifically, the second duration is equal to the double speed of the fast forward or fast reverse and the first duration.
  • the product that is, if the first time is 1 second and the double speed is N, it is determined that the second time is N seconds, and if the first time is 1/3 second, the second time length is determined to be N/3 seconds.
  • Step 202 Select an I frame according to the current program duration, the second duration, and the time point of the I frame included in the index information of each I frame of the current program, to obtain an I frame sequence.
  • the terminal further selects an I frame according to the current program duration, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, where the index information of the I frame includes the I frame.
  • the index information of the I frame may further include a time point of the I frame, a name of the fragment where the I frame is located, an offset position of the I frame in the fragment, and an I frame size.
  • Step 1 The sum of the second duration of the current program played time plus m times is taken as the effective time point
  • Step 2 judging whether there is an I frame later according to the time point of each I frame of the current program
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • Step 1 subtract the difference of the second duration of the current program playback duration by m times as the effective time point
  • Step 2 According to the time point of each I frame of the current program, determine whether there is an I frame in the effective time point;
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • the I frames in the I frame sequence are arranged in the order of time points, so that when the data request message is sent to the server, the I frame time can be followed.
  • the sequence information of the I frame is sequentially carried in the data request message, and the I frame data received by the terminal is also arranged in order of time, so that the terminal can sequentially decode and output the I frame data according to the sequence of time points. It has a better fast-forward and fast-return output effect to avoid turbulence in the output.
  • Step 203 Send a data request message to the server every time the interval is preset, and the data request message carries the index information of the I frame in the I frame sequence in sequence;
  • the terminal sends a data request message to the server at a preset first time interval, and the data request message sequentially carries the index information of the I frame in the I frame sequence.
  • the terminal sends a data request message to the server, where the data request message carries the s+1th I frame in the I frame sequence, where the value of s is [0, 1, 2, ..., S ], T is the first duration, and the I frame sequence contains S+1 I frames.
  • s when s is 0, it means that the terminal immediately starts to send a data request message carrying the first I frame in the I frame sequence to the server after obtaining the I frame sequence.
  • the preset first duration may be a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
  • the terminal will send a data request message every 1 second, and by sending the data request message once every second, the speed can be realized by using the first duration as the step size to express different fast forwards. Or the difference between the speeds of rewinding, the user experience is good.
  • the terminal may further calculate the first duration based on the double speed of the fast forward or fast reverse.
  • the first duration is 1/logsN, where s is greater than 1, for example: if the speed is fast forward or rewind If 8, the terminal sends a data request message to the server every 1/3 second.
  • the data request message is a Hyper Text Transfer Protocol (http) request.
  • http Hyper Text Transfer Protocol
  • Step 204 Receive and decode the I frame data that the output server feeds back according to the received index information of the I frame.
  • the server parses the data request message, obtains the index information of the I frame included in the data request message, and obtains corresponding information according to the index information of the I frame. I frame data, and the obtained I frame data is fed back to the terminal.
  • the terminal After receiving the I frame data fed back by the server according to the received index information of the I frame, the terminal decodes and outputs the I frame data, and the terminal sends the data request message to the server every time the first interval is separated, the terminal also The I frame data fed back by the server is received every interval of time, so that the effective output of the fast forward and rewind can be realized on the display interface of the terminal.
  • the terminal may output the decoded I frame data according to the normal play mode, or output the decoded I frame data according to the play mode of the I frame, and the actual application may be performed according to specific needs. Settings, not limited here.
  • the terminal performs the steps 203 and 204 in a loop, that is, after the terminal sends a data request message, the terminal receives the I frame according to the data request message. Indexing the I frame data fed back by the information and decoding the output, and transmitting the data request message once, and receiving the I frame data fed back by the server, and decoding the output, and then analogizing to I, in the case of the first time interval from the last transmission interval.
  • Each I frame in the sequence of frames transmits a data request message and receives the feedback I frame data.
  • the output interface of the terminal will form an output effect of fast forward and rewind.
  • the second duration is determined according to the double speed of fast forward or fast reverse, and according to the current play duration, the second duration, and each I frame of the current program.
  • the I frame time included in the index information is selected as an I frame to obtain an I frame sequence, and after the I frame sequence is obtained, the terminal sends a number to the server for the first time interval preset for each interval.
  • the request message and the data request message sequentially carries the index information of the I frame in the I frame sequence; and the terminal further receives and decodes the I frame data fed back by the output server according to the index information of the I frame in the received data request message. .
  • the terminal receives the fast forward request, extracts the fast forward multiplication speed N included in the fast forward request, and determines the current program played time length T1;
  • the terminal determines that the time interval for sending the data request message to the server is 1/logsN, and the second duration for selecting the I frame is N/logsN;
  • the terminal determines the I frame sequence by using the second duration N/logsN, the current program playback duration T1, and the time point of each I frame of the current program saved by the terminal, and the I frame sequence is [I0, I1, I2, I3, ..., I10];
  • the terminal sends a data request message to the server, requesting I frame data of I0 in the I frame sequence;
  • the terminal receives the I frame data of the I0 fed back by the server, and decodes the output;
  • the terminal sends a data request message to the server, requesting I frame data of I1 in the I frame sequence;
  • the terminal receives the I frame data of the I1 fed back by the server, and decodes the output;
  • the terminal sends a data request message to the server, requesting I frame data of I10 in the I frame sequence;
  • the terminal receives the I frame data of the I10 fed back by the server, and decodes the output.
  • the program time step per second is N, but it is not required to acquire all I frames in N seconds per second, but 1/T0 I frames, the T0. It refers to the first duration, which can greatly reduce the number of I frames that need to be downloaded, and reduce the bandwidth requirement.
  • the larger the multiple the more I frames are acquired, and the output fast forwards and rewinds. Screen cut Better results can also enhance the user experience.
  • FIG. 3 it is an embodiment of a structure of a terminal according to an embodiment of the present invention, including:
  • the selecting module 301 is configured to: when receiving the fast forward or fast reverse request, select the I frame according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward or fast reverse request. , get the I frame sequence;
  • the sending module 302 is configured to send a data request message to the server after the I-frame sequence is obtained by the selecting module 301, and the data request message sequentially carries the index information of the I frame in the I frame sequence. ;
  • the receiving output module 303 is configured to receive and decode the I frame data fed back by the output server according to the received I frame index information after the sending module 302 sends the data request message.
  • the terminal when the terminal starts to play the program, the terminal sends an I frame index information request message to the server, and after receiving the I frame index information request message, the server parses the video source of the current program of the terminal, and obtains The index information of each I frame of the current program is fed back to the terminal by the obtained index information of each I frame.
  • the terminal After receiving the index information of each I frame of the current program, the terminal saves the index information of each I frame of the current program.
  • the index information of the I frame includes at least the time point of the I frame, and the time point of the I frame refers to the time point of the I frame in the current program.
  • the index information of the I frame may further include parameters such as the name of the fragment where the I frame is located, the offset position of the I frame in the fragment, and the size of the I frame.
  • the user may issue a fast forward or fast reverse request to the terminal by using a remote control or a touch screen touch, and the fast forward or fast reverse request includes a fast forward or fast reverse speed, wherein
  • the double speed of entering or rewinding can be 2, 4, 8, 16 and so on.
  • the terminal After receiving the fast forward or fast reverse request, the terminal will according to the current program play duration, the index information of each I frame of the current program saved in advance, and the content included in the fast forward or rewind request.
  • I frame is selected at double speed to obtain an I frame sequence.
  • the index information of the I frame carried by the terminal includes the time point of the I frame, the fragment name of the I frame, the offset position of the I frame in the fragment, and the I frame size.
  • the server After receiving the data request message, the server determines the position of the I frame on the total duration of the current program by using the time point of the I frame in the index information of the I frame carried by the server, and determines the I by using the slice name of the I frame. After the fragment is determined, and after determining the fragment, the I frame data is extracted by using the offset position of the I frame in the fragment and the I frame size, and the extracted I frame data is fed back to the terminal.
  • the terminal may be a television, a computer, a set top box, a PAD, a smart phone, or the like.
  • the selecting module 301 when receiving the fast forward or fast reverse request, is configured according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward or fast reverse request.
  • the I frame is selected at a multiple speed to obtain an I frame sequence.
  • the sending module 302 sends a data request message to the server every interval of the first time interval, and the data request message carries the index information of the I frame in the I frame sequence. And receiving, by the receiving output module 303, and decoding the I frame data fed back by the output server according to the index information of the received I frame.
  • the I frame is selected according to the current program play duration, the index information of each I frame of the current program, and the double speed of fast forward or fast reverse, to obtain an I frame. a sequence, and sending a data request message to the server every predetermined first time period, and the data request message sequentially carries index information of the I frame in the I frame sequence, and the received server receives the request message according to the received data request message. After the I frame data fed back by the I frame index information, the terminal will decode and output the I frame data.
  • the I-frame of the selected part can be downloaded from the server to realize the fast-forward and fast-return output effect, without downloading all the I-frames of the current program, thereby effectively reducing the download amount of the I-frame data, and Effectively reduce the requirements for broadband.
  • FIG. 4 is an embodiment of the structure of the terminal in the embodiment of the present invention, including the selection module 301 described in the embodiment shown in FIG.
  • the sending module 302 receives the output module 303 and is similar to the content described in the embodiment shown in FIG. 3, and details are not described herein again.
  • the selecting module 301 includes:
  • the duration determining module 401 is configured to determine the second duration according to the fast forward or fast reverse multiple speed when receiving the fast forward request or the fast reverse request;
  • the frame selection module 402 is configured to: after the duration determining module 401 determines the second duration, select an I frame according to the current duration of the program, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, and an I frame.
  • the time point is included in the index information of the I frame.
  • the frame selection module 402 is specifically configured to:
  • Step 1 The sum of the second duration of the current program played time plus m times is taken as the effective time point
  • Step 2 judging whether there is an I frame later according to the time point of each I frame of the current program
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • the frame selection module 402 is specifically configured to:
  • Step 1 subtract the difference of the second duration of the current program playback duration by m times as the effective time point
  • Step 2 According to the time point of each I frame of the current program, determine whether there is an I frame in the effective time point;
  • Step 4 If there is no I frame in the effective time point, the selection of the I frame ends.
  • the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
  • the selecting module 301 when receiving the fast forward or fast reverse request, is configured according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward or fast reverse request.
  • the I frame is selected at a multiple speed to obtain an I frame sequence.
  • the duration determining module 401 in the selecting module 301 determines the second duration according to the double speed of the fast forward or fast reverse, and is determined by the frame selection module 402 according to the duration of the current program.
  • the duration and the time point of each I frame of the current program select an I frame to obtain an I frame sequence, and the index information includes the time point of the I frame.
  • the sending module 302 sends a data request message to the server every time the interval is preset, and the data request message sequentially carries the index information of the I frame in the I frame sequence; and the receiving output module 303 receives and decodes the output.
  • the server feeds back I frame data according to the index information of the received I frame.
  • the second duration is determined according to the double speed of fast forward or fast reverse, and according to the current play duration, the second duration, and each I frame of the current program.
  • the I frame time included in the index information is selected as an I frame, and an I frame sequence is obtained.
  • the terminal sends a data request message to the server for each first interval set in advance, and the data request message is sequentially Carrying index information of the I frame in the I frame sequence; and the terminal will also receive and decode the I frame data fed back by the output server according to the received index information of the I frame.
  • Embodiments of the present invention also provide a storage medium.
  • the foregoing storage medium may be configured to store program code for performing the following steps:
  • the storage medium is further arranged to store program code for performing the following steps:
  • S2 Select an I frame according to the current duration of the program, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, where the time point of the I frame is included in the index information of the I frame.
  • the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory.
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • a mobile hard disk e.g., a hard disk
  • magnetic memory e.g., a hard disk
  • the terminal when receiving the fast forward or fast reverse request, selects I according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward rewind request.
  • the frame obtains an I frame sequence, and sends a data request message to the server every time the interval is preset, and the data request message carries one I frame in the I frame sequence, and the terminal also receives and decodes.
  • the output server feeds back the data of the I frame according to the index information of the received I frame to implement fast forward and rewind.
  • the selected I frame is a part of the I frame of the current program, when the fast forward and rewind are implemented, it is not necessary to download the I frame data of all the I frames of the current program, and the output effect of the fast forward and rewind can be realized. At the same time, the download amount of the I frame data is effectively reduced, and the reduction of the I frame data download amount can effectively reduce the requirement for the broadband.

Abstract

Disclosed in the embodiment of the present invention is a fast forward/rewind processing method, comprising: when a fast forward/rewind request is received, the terminal obtains an I-frame sequence according to a current program playing time, the index information of each I-frame of the current program stored in advance and a speed contained in the fast forward/rewind request; and sends a data request message to the server for each first predetermined time interval, wherein one I-frame in the I-frame sequence is sequentially carried in the sent data request message; and the terminal will also receive, decode and output the data of the I-frame fed back by the server according to the index information of the received I-frame. Disclosed in the embodiment of the invention also includes a terminal. The advantage realized by the embodiment of the invention is that the requirement on bandwidth can be effectively reduced.

Description

快进快退的处理方法及终端Fast forward and rewind processing method and terminal 技术领域Technical field
本发明实施例涉及流媒体通信技术领域,尤其涉及一种快进快退的处理方法及终端。The embodiments of the present invention relate to the field of streaming media communication technologies, and in particular, to a fast forward and fast rewind processing method and a terminal.
背景技术Background technique
目前OTT(Over The Top)业务是互联网业务中最常见的业务,且基于开放互联网的OTT移动视频服务业务是将来满足直播(Live)、点播(On Demand)以及时移(Time Shift)等诸多应用需求的最佳解决方案之一。At present, the OTT (Over The Top) service is the most common service in the Internet business, and the OTT mobile video service service based on the open Internet is suitable for many applications such as Live, On Demand, and Time Shift in the future. One of the best solutions for demand.
常见的OTT业务的播放控制采用的是码流自适应方式,常用的协议包括:Http Live Streaming,MPEG DASH,Microsoft Smooth Streaming等等。且一般的OTT业务在快进快退时都是采用底层定位的方式,这种方式下的当前节目的快进快退的用户体验比网络协定电视(Internet Protocol Television,IPTV)业务中的快进快退的用户体验要差,其中IPTV业务是采用的I帧(I Frame)播放模式实现快进快退的。其中,I帧是一种全帧压缩编码帧,也可称为帧内编码帧,I帧的数据量一般比较大,且I帧不需要参考其他帧而生成,属于参考帧,解码时仅用一个I镇就可以重构一个完整的图像。The playback control of the common OTT service adopts the code stream adaptive mode, and the commonly used protocols include: Http Live Streaming, MPEG DASH, Microsoft Smooth Streaming and the like. In general, the OTT service uses the low-level positioning method in fast forward and rewind. In this mode, the fast forward and rewind user experience of the current program is faster than that in the Internet Protocol Television (IPTV) service. The fast-rewinding user experience is poor, and the IPTV service adopts the I frame (I Frame) playback mode to achieve fast forward and rewind. The I frame is a full frame compression coded frame, which may also be referred to as an intraframe coded frame. The data volume of the I frame is generally large, and the I frame is generated without reference to other frames, and belongs to the reference frame, and is only used for decoding. An I town can reconstruct a complete image.
目前,OTT视频播放使用的协议也在考虑支持快进快退的I帧播放模式,且基于OTT视频播放业务,一般是终端从服务器将当前正在播放的节目的所有I帧的I帧数据都下载下来,在进入快进快退的状态之后,依次将下载的I帧数据输出。At present, the protocol used for OTT video playback is also considering the I frame play mode that supports fast forward and rewind, and based on the OTT video play service, the terminal generally downloads I frame data of all I frames of the currently playing program from the server. Down, after entering the fast forward and rewind state, the downloaded I frame data is sequentially output.
然而,由于I帧的数据量较大,下载当前节目的所有I帧对带宽的要求较高。However, due to the large amount of data of the I frame, all I frames downloaded for the current program have higher bandwidth requirements.
上述内容仅用于辅助理解本发明实施例的技术方案,并不代表承认上述内容是相关技术。 The above content is only used to assist in understanding the technical solutions of the embodiments of the present invention, and does not mean that the above content is related art.
发明内容Summary of the invention
本发明实施例的主要目的在于提供一种快进快退的处理方法及终端,旨在解决相关技术中在实现快进快退时需要下载大量的I帧的I帧数据带来的对带宽的要求太高的问题。The main purpose of the embodiments of the present invention is to provide a fast forward and fast rewind processing method and a terminal, which are intended to solve the bandwidth of the I frame data that needs to be downloaded in a large number of I frames during fast forward and fast rewind in the related art. Asking too high a question.
为实现上述目的,本发明实施例提供一种快进快退的处理方法,包括:To achieve the above object, an embodiment of the present invention provides a fast forward and fast rewind processing method, including:
当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列;When receiving the fast forward or fast reverse request, the I frame is obtained according to the current program play duration, the index information of each I frame of the current program saved in advance, and the multiple speed included in the fast forward or fast reverse request. I frame sequence;
每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且所述数据请求消息中依次携带所述I帧序列中的I帧的索引信息;Sending a data request message to the server, and the data request message carries the index information of the I frame in the I frame sequence in sequence;
接收并解码输出所述服务器根据接收到的I帧的索引信息反馈的I帧数据。Receiving and decoding the I frame data that the server feeds back according to the index information of the received I frame.
可选地,所述当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列,包括:Optionally, when receiving the fast forward or fast reverse request, according to the current program play duration, the index information of each I frame of the current program saved in advance, and the content included in the fast forward or fast reverse request I frame is selected at double speed to obtain an I frame sequence, including:
当接收到快进请求或快退请求时,根据所述快进或快退的倍速确定第二时长;When receiving the fast forward request or the fast reverse request, determining the second duration according to the double speed of the fast forward or fast reverse;
根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,所述I帧的时间点包含在所述I帧的索引信息中。Determining, according to the duration of the current program, the second duration and the time point of each I frame of the current program, selecting an I frame, and obtaining the I frame sequence, where the time point of the I frame is included in the I frame In the index information.
可选地,所述根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,包括:Optionally, the I frame is selected according to the duration of the current program, the second duration, and the time point of each I frame of the current program, to obtain the I frame sequence, including:
若为快进,则m的初始值为0,执行以下步骤:If fast forward, the initial value of m is 0, perform the following steps:
步骤1:将所述当前节目已播放时长加上m倍的所述第二时长的和作为有效时间点;Step 1: the sum of the second duration of the current program played duration plus m times is taken as an effective time point;
步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往后是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
步骤3:若所述有效时间点往后还有I帧,则往后选取时间点与所述 有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then select the time point and the The most recent I frame of the effective time point is used as the m+1th frame of the I frame sequence, so that m=m+1, returning to step 1;
步骤4:若所述有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame after the valid time point, the selection of the I frame ends.
可选地,所述根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的索引信息中包含的I帧的时间点选取I帧,得到所述I帧序列,包括:Optionally, the I frame is selected according to the duration of the current program, the second duration, and the time point of the I frame included in the index information of each I frame of the current program, to obtain the I frame sequence. ,include:
若为快退,则m的初始值为0,执行以下步骤:If it is fast rewind, the initial value of m is 0, perform the following steps:
步骤1:将所述当前节目已播放时长减去m倍的所述第二时长的差作为有效时间点;Step 1: subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往前是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
步骤3:若所述有效时间点往前还有I帧,则往前选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame in front of the valid time point, an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
步骤4:若所述有效时间点往前没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
可选地,所述预先设置的第一时长为预先设置的小于或等于1秒的时间值,或者为基于所述倍速计算得到的小于或等于1秒的时间值。Optionally, the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
为了解决上述问题,本发明实施例还提供一种终端,包括:In order to solve the above problem, the embodiment of the present invention further provides a terminal, including:
选取模块,设置为当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列;The selection module is configured to, according to the current program played duration, the pre-stored index information of each I frame of the current program, and the double speed included in the fast forward or rewind request, when the fast forward or fast reverse request is received Selecting an I frame to obtain an I frame sequence;
发送模块,设置为在所述选取模块得到所述I帧序列之后,每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且所述数据请求消息中依次携带所述I帧序列中的I帧的索引信息;The sending module is configured to send a data request message to the server, and the data request message sequentially carries the I frame sequence in the sequence of the first time period that is preset before the selection module obtains the I frame sequence. Index information of the I frame;
接收输出模块,设置为在所述发送模块发送数据请求消息之后,接收并解码输出所述服务器根据接收到的I帧的索引信息反馈的I帧数据。The receiving output module is configured to receive and decode the I frame data that is fed back by the server according to the index information of the received I frame after the sending module sends the data request message.
可选地,所述选取模块包括:Optionally, the selecting module includes:
时长确定模块,设置为当接收到快进请求或快退请求时,根据所述快 进或快退的倍速确定第二时长;a duration determining module, configured to receive a fast forward request or a fast reverse request, according to the fast The double speed of entering or rewinding determines the second time length;
帧选取模块,设置为在所述时长确定模块确定所述第二时长之后,根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,所述I帧的时间点包含在所述I帧的索引信息中。a frame selection module, configured to: after the duration determining module determines the second duration, select an I frame according to the current duration of the current program, the second duration, and the time point of each I frame of the current program. Obtaining the I frame sequence, where the time point of the I frame is included in the index information of the I frame.
可选地,所述帧选取模块具体设置为:Optionally, the frame selection module is specifically configured to:
若为快进,则m的初始值为0,执行以下步骤:If fast forward, the initial value of m is 0, perform the following steps:
步骤1:将所述当前节目已播放时长加上m倍的所述第二时长的和作为有效时间点;Step 1: the sum of the second duration of the current program played duration plus m times is taken as an effective time point;
步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往后是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
步骤3:若所述有效时间点往后还有I帧,则往后选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
步骤4:若所述有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame after the valid time point, the selection of the I frame ends.
可选地,所述帧选取模块具体设置为:Optionally, the frame selection module is specifically configured to:
若为快退,则m的初始值为0,执行以下步骤:If it is fast rewind, the initial value of m is 0, perform the following steps:
步骤1:将所述当前节目已播放时长减去m倍的所述第二时长的差作为有效时间点;Step 1: subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往前是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
步骤3:若所述有效时间点往前还有I帧,则往前选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame in front of the valid time point, an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
步骤4:若所述有效时间点往前没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
可选地,所述预先设置的第一时长为预先设置的小于或等于1秒的时间值,或者为基于所述倍速计算得到的小于或等于1秒的时间值。Optionally, the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
在本发明实施例中,还提供了一种计算机存储介质,该计算机存储介 质可以存储有执行指令,该执行指令用于执行上述实施例中的快进快退的处理方法。In the embodiment of the present invention, a computer storage medium is also provided, and the computer storage medium is provided. The quality may store an execution instruction for executing the fast forward and rewind processing method in the above embodiment.
本发明实施例提供的快进快退的方法的实施例是在接收到快进或快退请求时,终端根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进快退请求中包含的倍速选取I帧,得到I帧序列,且每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且发送的数据请求消息中依次携带该I帧序列中的一个I帧,终端还将接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧的数据,以实现快进快退。由于选取的I帧为当前节目的一部分I帧,使得在实现快进快退时,不需要将当前节目的所有I帧的I帧数据都下载下来,能够在实现快进快退的输出效果的同时有效的减少I帧数据的下载量,且I帧数据下载量的降低能够有效降低对宽带的要求。An embodiment of the method for fast forward and rewind provided by the embodiment of the present invention is: when receiving a fast forward or fast reverse request, the terminal according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward. The I frame is selected in the fast rewind request to obtain an I frame sequence, and a data request message is sent to the server for each first interval set in advance, and the transmitted data request message carries one of the I frame sequences in sequence. In the I frame, the terminal will also receive and decode the data of the I frame fed back by the output server according to the index information of the received I frame to implement fast forward and rewind. Since the selected I frame is a part of the I frame of the current program, when the fast forward and rewind are implemented, it is not necessary to download the I frame data of all the I frames of the current program, and the output effect of the fast forward and rewind can be realized. At the same time, the download amount of the I frame data is effectively reduced, and the reduction of the I frame data download amount can effectively reduce the requirement for the broadband.
附图说明DRAWINGS
图1为本发明快进快退的处理方法的第一实施例的流程示意图;1 is a schematic flow chart of a first embodiment of a method for processing fast forward and rewind according to the present invention;
图2为本发明快进快退的处理方法的第二实施例的流程示意图;2 is a schematic flow chart of a second embodiment of a method for processing fast forward and rewind according to the present invention;
图3为本发明终端的第一实施例的功能模块的示意图;3 is a schematic diagram of functional modules of a first embodiment of a terminal according to the present invention;
图4为本发明终端的第二实施例的功能模块的示意图。4 is a schematic diagram of functional modules of a second embodiment of a terminal of the present invention.
本发明实施例目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。The implementation, functional features and advantages of the embodiments of the present invention will be further described with reference to the accompanying drawings.
具体实施方式detailed description
应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。It is understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
本发明实施例的主要解决方案是:在接收到快进或快退请求时,终端根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进快退请求中包含的倍速选取I帧,得到I帧序列,该I帧序列中包含当前节目的部分I帧。终端在选取该I帧序列之后,每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且发送的数据请求消息中依次携 带该I帧序列中的一个I帧,且终端还将接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧的数据,以实现快进快退。由于选取的I帧为当前节目的一部分I帧,使得在实现快进快退的过程中,不需要将当前节目的所有I帧的I帧数据都下载下来,能够在实现快进快退的输出效果的同时有效的减少I帧数据的下载量,且I帧数据下载量的降低能够有效降低对宽带的要求。The main solution of the embodiment of the present invention is: when receiving the fast forward or fast reverse request, the terminal according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward and rewind request included in the request The I frame is selected at a double speed to obtain an I frame sequence, and the I frame sequence includes a partial I frame of the current program. After selecting the I frame sequence, the terminal sends a data request message to the server every time the interval is preset, and the data request message is sequentially carried in the sent data request message. An I frame of the I frame sequence is carried, and the terminal further receives and decodes data of the I frame fed back by the output server according to the received index information of the I frame to implement fast forward and rewind. Since the selected I frame is a part of the I frame of the current program, in the process of implementing fast forward and rewind, it is not necessary to download the I frame data of all the I frames of the current program, and the output can be fast forwarded and rewinded. The effect is effective at reducing the download amount of I frame data, and the reduction of the I frame data download amount can effectively reduce the requirement for broadband.
具体地,请参阅图1,为本发明提出的一种快进快退的处理方法的第一实施例的示意图,该方法包括:Specifically, please refer to FIG. 1 , which is a schematic diagram of a first embodiment of a fast forward and fast rewind processing method according to the present invention. The method includes:
步骤101、当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进或快退请求中包含的倍速选取I帧,得到I帧序列;Step 101: When receiving a fast forward or fast reverse request, according to the current program play duration, the index information of each I frame of the current program saved in advance, and the I frame included in the fast forward or fast reverse request, the I frame is obtained, and I is obtained. Frame sequence
在本发明实施例中,终端在最初开始播放节目时,将向服务器发送I帧索引信息请求消息,服务器在接收到该I帧索引信息请求消息之后,将解析该终端当前节目的视频源,获取该当前节目的各I帧的索引信息,并将获取到的各I帧的索引信息反馈给终端。In the embodiment of the present invention, when the terminal starts to play the program, the terminal sends an I frame index information request message to the server, and after receiving the I frame index information request message, the server parses the video source of the current program of the terminal, and obtains The index information of each I frame of the current program is fed back to the terminal by the obtained index information of each I frame.
其中,终端在接收到其当前节目的各I帧的索引信息之后,将保存该当前节目的各I帧的索引信息。After receiving the index information of each I frame of the current program, the terminal saves the index information of each I frame of the current program.
其中,I帧的索引信息至少包含I帧的时间点,且I帧的时间点是指该I帧在当前节目中所处的时间点。The index information of the I frame includes at least the time point of the I frame, and the time point of the I frame refers to the time point of the I frame in the current program.
此外,I帧的索引信息中还可以包括I帧所在分片的名称、I帧在分片中的偏移位置及I帧的大小等等参数。In addition, the index information of the I frame may further include parameters such as the name of the fragment where the I frame is located, the offset position of the I frame in the fragment, and the size of the I frame.
在本发明实施例中,用户可通过遥控器控制或者触摸屏触摸等方式向终端发出快进或快退的请求,该快进或快退的请求中包含快进或快退的倍速,其中,快进或快退的倍速可以是2、4、8、16等等。In the embodiment of the present invention, the user may issue a fast forward or fast reverse request to the terminal by using a remote control or a touch screen touch, and the fast forward or fast reverse request includes a fast forward or fast reverse speed, wherein The double speed of entering or rewinding can be 2, 4, 8, 16 and so on.
终端在接收到该快进或快退请求之后,将根据当前节目已播放时长、预先保存的该当前节目的各I帧的索引信息及该快进或快退请求中包含的倍速选取I帧,得到I帧序列。After receiving the fast forward or fast reverse request, the terminal selects an I frame according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward or fast reverse request. Get the I frame sequence.
其中,终端在接收到快进或快退请求之后,将停止正常播放速度的播 放模式,且终端将获取到当前节目在接收到快进或快退请求时的已播放时长,例如:若在当前节目播放10分钟的时候接收到快进或快退请求,则当前节目已播放时长为10分钟。The terminal will stop broadcasting at the normal playback speed after receiving the fast forward or fast reverse request. Release mode, and the terminal will obtain the elapsed duration of the current program when receiving the fast forward or fast rewind request, for example, if the fast forward or rewind request is received when the current program is played for 10 minutes, the current program has been played. The duration is 10 minutes.
在本发明实施例中,终端可以是电视机、电脑、机顶盒、PAD、智能手机等等。In the embodiment of the present invention, the terminal may be a television, a computer, a set top box, a PAD, a smart phone, or the like.
步骤102、每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;Step 102: Send a data request message to the server every time the interval is preset, and the data request message sequentially carries the index information of the I frame in the I frame sequence.
步骤103、接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧的数据。Step 103: Receive and decode data of an I frame fed back by the output server according to the received index information of the I frame.
在本发明实施例中,终端在选取I帧并得到I帧序列之后,将每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息。In the embodiment of the present invention, after selecting an I frame and obtaining an I frame sequence, the terminal sends a data request message to the server for each first interval set in advance, and the data request message sequentially carries the I in the I frame sequence. The index information of the frame.
需要说明的是,在本发明实施例中,I帧序列中的I帧是按照时间点的先后顺序进行排列的,若是在快进情况下得到的I帧序列,则I帧序列中的I帧是按照时间点逐渐增大的顺序排列的,若是在快退情况下得到的I帧序列,则I帧序列中的I帧是按照时间点逐渐减小的顺序排列的。It should be noted that, in the embodiment of the present invention, the I frames in the I frame sequence are arranged in the order of time points. If the I frame sequence obtained in the fast forward case, the I frame in the I frame sequence It is arranged in order of increasing time points. If the I frame sequence is obtained in the case of fast rewind, the I frames in the I frame sequence are arranged in order of decreasing time points.
终端每发送一个数据请求消息,该数据请求消息中都将包含I帧序列中的I帧的索引信息,且终端是按照I帧序列中的I帧的排列顺序依次携带在数据请求消息中发送的。Each time the terminal sends a data request message, the data request message includes the index information of the I frame in the I frame sequence, and the terminal is sequentially carried in the data request message according to the order of the I frames in the I frame sequence. .
例如:I帧序列为[I0,I1,I2,I3,……,I10],则终端在得到该I帧序列之后,将每间隔预先设置的第一时长,依次发送携带I0的索引信息的数据请求消息、携带I1的索引信息的数据请求消息,携带I2的索引信息的数据请求消息、携带I3的索引信息的数据请求消息,……,携带I10的索引信息的数据请求消息。For example, if the I frame sequence is [I0, I1, I2, I3, ..., I10], the terminal sequentially transmits the data carrying the index information of I0 for each first interval set in advance after the I frame sequence is obtained. The request message, the data request message carrying the index information of I1, the data request message carrying the index information of I2, the data request message carrying the index information of I3, ..., the data request message carrying the index information of I10.
其中,终端在向服务器发送数据请求消息时,其携带的I帧的索引信息包含该I帧的时间点、I帧所在分片名称、I帧在分片的偏移位置及I帧大小。When the terminal sends a data request message to the server, the index information of the I frame carried by the terminal includes the time point of the I frame, the fragment name of the I frame, the offset position of the I frame in the fragment, and the I frame size.
服务器在接收到数据请求消息之后,将利用其携带的I帧的索引信息 中的I帧的时间点确定I帧在当前节目的总时长上的位置,并利用I帧所在的分片名称确定I帧所在的分片,且在确定分片之后,利用I帧在该分片中的偏移位置及I帧大小提取I帧数据,且将提取的I帧数据反馈给终端。After receiving the data request message, the server will use the index information of the I frame carried by the server. The time point of the I frame in the I frame determines the position of the I frame on the total duration of the current program, and uses the slice name in which the I frame is located to determine the slice in which the I frame is located, and after determining the slice, the I frame is used in the segment. The offset position and the I frame size in the slice extract I frame data, and the extracted I frame data is fed back to the terminal.
服务器每次接收到数据请求消息之后,都将按照上述方式基于I帧的索引信息确定对应的I帧数据,并将获取到的I帧数据反馈给终端。且终端每次在接收到I帧数据之后,都将对接收到I帧数据进行解码输出,使得能够在终端的显示界面上显示快进或快退的输出效果。After receiving the data request message, the server determines the corresponding I frame data based on the index information of the I frame in the above manner, and feeds the obtained I frame data to the terminal. And each time the terminal receives the I frame data, the terminal will decode and output the received I frame data, so that the fast forward or fast reverse output effect can be displayed on the display interface of the terminal.
在本发明实施例中,当终端接收到快进或快退请求时,将根据当前节目已播放时长、当前节目各I帧的索引信息及快进或快退的倍速选取I帧,得到I帧序列,且每隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息,在接收到服务器根据接收到的I帧的索引信息反馈的I帧数据后,终端将解码输出该I帧数据。通过上述方式,使得只需要从服务器下载选取的部分的I帧即可实现快进快退的输出效果,而不需要将当期节目的所有I帧下载下来,有效减少I帧数据的下载量,且能够有效的降低对宽带的要求。In the embodiment of the present invention, when the terminal receives the fast forward or fast reverse request, the I frame is selected according to the current program play duration, the index information of each I frame of the current program, and the double speed of fast forward or fast reverse, to obtain an I frame. a sequence, and sending a data request message to the server every predetermined first time period, and the data request message sequentially carries the index information of the I frame in the I frame sequence, and receives the index of the received I frame according to the received frame. After the I frame data of the information feedback, the terminal will decode and output the I frame data. In the above manner, the I-frame of the selected part can be downloaded from the server to realize the fast-forward and fast-return output effect, without downloading all the I-frames of the current program, thereby effectively reducing the download amount of the I-frame data, and Can effectively reduce the requirements for broadband.
为了更好的理解本发明实施例中的技术方案,请参阅图2,为本发明提供的快进快退的处理方法的第二实施例的示意图,该方法中的步骤201和步骤202是对第一实施例中的步骤101的细化,具体的,该方法包括:For a better understanding of the technical solution in the embodiment of the present invention, please refer to FIG. 2 , which is a schematic diagram of a second embodiment of a fast forward and fast rewind processing method provided by the present invention. Steps 201 and 202 in the method are correct. The refinement of step 101 in the first embodiment, specifically, the method includes:
步骤201、当接收到快进请求或快退请求时,根据快进或快退的倍速确定第二时长;Step 201: When receiving a fast forward request or a fast reverse request, determining a second duration according to a double speed of fast forward or fast reverse;
在本发明实施例中,当接收到快进或快退请求时,终端将根据快进或快退的倍速确定第二时长,其中,该第二时长用于选取I帧。In the embodiment of the present invention, when receiving a fast forward or fast reverse request, the terminal determines a second duration according to a fast forward or fast reverse speed, wherein the second duration is used to select an I frame.
其中,快进或快退的倍速是携带在快进或快退请求中的,使用终端的用户可以通过选择确定快进或快退的倍速。Among them, the double speed of fast forward or fast reverse is carried in the fast forward or fast reverse request, and the user who uses the terminal can determine the double speed of fast forward or fast reverse by selecting.
进一步的,根据快进或快退的倍速确定第二时长可以是:若快进或快退的倍速为N,则确定第二时长为N秒,或者确定第二时长为N秒的倍速。 Further, determining the second duration according to the double speed of fast forward or rewind may be: if the double speed of fast forward or fast reverse is N, determining that the second duration is N seconds, or determining that the second duration is N double speed.
进一步的,第二时长可以与第一时长相关,该第一时长是预先设置的向服务器发送数据请求消息的时间间隔,具体的:第二时长等于快进或快退的倍速与第一时长的乘积,即若第一时长为1秒,倍速为N时,则确定第二时长为N秒,若第一时长为1/3秒时,则确定第二时长为N/3秒。Further, the second duration may be related to the first duration, where the first duration is a preset time interval for sending a data request message to the server. Specifically, the second duration is equal to the double speed of the fast forward or fast reverse and the first duration. The product, that is, if the first time is 1 second and the double speed is N, it is determined that the second time is N seconds, and if the first time is 1/3 second, the second time length is determined to be N/3 seconds.
步骤202、根据当前节目已播放时长,第二时长及当前节目的各I帧的索引信息中包含的I帧的时间点选取I帧,得到I帧序列;Step 202: Select an I frame according to the current program duration, the second duration, and the time point of the I frame included in the index information of each I frame of the current program, to obtain an I frame sequence.
在本发明实施例中,终端还将根据当前节目已播放时长,第二时长及当前节目的各I帧的时间点选取I帧,得到I帧序列,其中,I帧的索引信息中包含I帧的时间点,此外,I帧的索引信息中还可包含I帧的时间点、I帧所在分片的名称、I帧在分片的偏移位置及I帧大小等等参数。In the embodiment of the present invention, the terminal further selects an I frame according to the current program duration, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, where the index information of the I frame includes the I frame. In addition, the index information of the I frame may further include a time point of the I frame, a name of the fragment where the I frame is located, an offset position of the I frame in the fragment, and an I frame size.
下面将基于快进和快退不同的情况分别描述终端选取I帧的过程:The following describes the process of selecting an I frame by the terminal based on the different conditions of fast forward and fast reverse:
若为快进,则m的初始值为0,终端执行以下步骤:If fast forward, the initial value of m is 0, and the terminal performs the following steps:
步骤1:将当前节目已播放时长加上m倍的第二时长的和作为有效时间点;Step 1: The sum of the second duration of the current program played time plus m times is taken as the effective time point;
步骤2:根据当前节目的各I帧的时间点,判断有效时间点往后是否还有I帧;Step 2: judging whether there is an I frame later according to the time point of each I frame of the current program;
步骤3:若有效时间点往后还有I帧,则往后选取时间点与有效时间点最近的一个I帧作为I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so m=m+1, return to execution. step 1;
步骤4:若有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
或者;or;
若为快退,则m的初始值为0,终端执行以下步骤:If it is fast rewind, the initial value of m is 0, and the terminal performs the following steps:
步骤1:将当前节目已播放时长减去m倍的第二时长的差作为有效时间点;Step 1: subtract the difference of the second duration of the current program playback duration by m times as the effective time point;
步骤2:根据当前节目的各I帧的时间点,判断有效时间点往前是否还有I帧;Step 2: According to the time point of each I frame of the current program, determine whether there is an I frame in the effective time point;
步骤3:若有效时间点往前还有I帧,则往前选取时间点与有效时间点最近的一个I帧作为I帧序列的第m+1个帧,令m=m+1,返回执行步骤 1;Step 3: If there is an I frame in front of the effective time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so m=m+1, and return to execution. Step 1;
步骤4:若有效时间点往前没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
需要说明的是,按照上述方式得到的I帧序列,该I帧序列中的I帧是按照时间点的先后顺序排列的,便于在向服务器发送数据请求消息时,能够按照I帧的时间点的顺序依次将I帧的索引信息携带在数据请求消息中,且使得终端接收到的I帧数据也将是按照时间点顺序排列的,这样终端能够按照时间点的先后顺序依次解码输出I帧数据,具有较好的快进快退的输出效果,避免输出出现紊乱。It should be noted that, according to the I frame sequence obtained in the foregoing manner, the I frames in the I frame sequence are arranged in the order of time points, so that when the data request message is sent to the server, the I frame time can be followed. The sequence information of the I frame is sequentially carried in the data request message, and the I frame data received by the terminal is also arranged in order of time, so that the terminal can sequentially decode and output the I frame data according to the sequence of time points. It has a better fast-forward and fast-return output effect to avoid turbulence in the output.
需要说明的是,在本发明实施例中,往前往后是基于当前节目的播放时间来描述的,若是快进,则是往该当前节目未播放的时间的方向,若是快退,则是往该当前节目已播放时间的方向。It should be noted that, in the embodiment of the present invention, after going to the destination, it is described based on the playing time of the current program. If the fast forward is in the direction of the time when the current program is not playing, if it is rewinding, it is The direction in which the current program has played time.
步骤203、每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;Step 203: Send a data request message to the server every time the interval is preset, and the data request message carries the index information of the I frame in the I frame sequence in sequence;
在本发明实施例中,终端将每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息。In the embodiment of the present invention, the terminal sends a data request message to the server at a preset first time interval, and the data request message sequentially carries the index information of the I frame in the I frame sequence.
具体的:在sT时刻,终端向服务器发送数据请求消息,数据请求消息中携带I帧序列中的第s+1个I帧,其中,s的值为[0,1,2,……,S],T为第一时长,且I帧序列中包含S+1个I帧。其中,当s为0时,是表示终端在得到I帧序列之后,将立即开始向服务器发送携带I帧序列中的第1个I帧的数据请求消息。Specifically, at time sT, the terminal sends a data request message to the server, where the data request message carries the s+1th I frame in the I frame sequence, where the value of s is [0, 1, 2, ..., S ], T is the first duration, and the I frame sequence contains S+1 I frames. Wherein, when s is 0, it means that the terminal immediately starts to send a data request message carrying the first I frame in the I frame sequence to the server after obtaining the I frame sequence.
在本发明实施例中,该预先设置的第一时长可以是预先设置的小于或等于1秒的时间值,或者为基于倍速计算得到的小于或等于1秒的时间值。In the embodiment of the present invention, the preset first duration may be a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
例如:若该第一时长为1秒,则终端将每隔1秒发送一次数据请求消息,且通过每秒发送一次数据请求消息,可以实现通过第一时长作为步长的速度来体现不同快进或快退的倍速之间的差异,用户体验好。For example, if the first duration is 1 second, the terminal will send a data request message every 1 second, and by sending the data request message once every second, the speed can be realized by using the first duration as the step size to express different fast forwards. Or the difference between the speeds of rewinding, the user experience is good.
进一步的,终端还可基于快进或快退的倍速计算第一时长,在倍速为N时,则第一时长为1/logsN,其中s大于1,例如:若快进或快退的倍速 为8,则终端每隔1/3秒向服务器发送一个数据请求消息。Further, the terminal may further calculate the first duration based on the double speed of the fast forward or fast reverse. When the double speed is N, the first duration is 1/logsN, where s is greater than 1, for example: if the speed is fast forward or rewind If 8, the terminal sends a data request message to the server every 1/3 second.
需要说明的是,在本发明实施例中,数据请求消息是一种超文本传输协议(Hyper Text Transfer Protocol,http)请求。It should be noted that, in the embodiment of the present invention, the data request message is a Hyper Text Transfer Protocol (http) request.
步骤204、接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧数据。Step 204: Receive and decode the I frame data that the output server feeds back according to the received index information of the I frame.
在本发明实施例中,服务器在接收到终端发送的数据请求消息之后,解析该数据请求消息,获取该数据请求消息中包含的I帧的索引信息,并根据该I帧的索引信息获取相应的I帧数据,并将获取的I帧数据反馈给终端。In the embodiment of the present invention, after receiving the data request message sent by the terminal, the server parses the data request message, obtains the index information of the I frame included in the data request message, and obtains corresponding information according to the index information of the I frame. I frame data, and the obtained I frame data is fed back to the terminal.
终端在接收到服务器根据接收到的I帧的索引信息反馈的I帧数据之后,将对该I帧数据进行解码输出,由于终端是每间隔一个第一时长向服务器发送数据请求消息,则终端也将每间隔一个时长接收到服务器反馈的I帧数据,使得能够在终端的显示界面上实现快进快退的有效输出。After receiving the I frame data fed back by the server according to the received index information of the I frame, the terminal decodes and outputs the I frame data, and the terminal sends the data request message to the server every time the first interval is separated, the terminal also The I frame data fed back by the server is received every interval of time, so that the effective output of the fast forward and rewind can be realized on the display interface of the terminal.
其中,终端在解码I帧数据之后,可以按照正常的播放模式输出解码后的I帧数据,也可以按照I帧的播放模式输出解码后的I帧数据,在实际应用中科根据具体的需要进行设置,此处不做限定。After decoding the I frame data, the terminal may output the decoded I frame data according to the normal play mode, or output the decoded I frame data according to the play mode of the I frame, and the actual application may be performed according to specific needs. Settings, not limited here.
需要说明的是,在本发明实施例中,终端是循环执行步骤203和步骤204的,即终端每次发送一个数据请求消息之后,都要接收一次服务器根据该数据请求消息中包含的I帧的索引信息反馈的I帧数据并解码输出,并在距离上一次发送间隔第一时长的情况下,发送一次数据请求消息,并接收服务器的反馈的I帧数据并解码输出,依次类推,直至针对I帧序列中的每一个I帧都发送了一个数据请求消息并接收了反馈的I帧数据。且在执行步骤203和步骤204过程中,终端的输出界面将形成快进快退的输出效果。It should be noted that, in the embodiment of the present invention, the terminal performs the steps 203 and 204 in a loop, that is, after the terminal sends a data request message, the terminal receives the I frame according to the data request message. Indexing the I frame data fed back by the information and decoding the output, and transmitting the data request message once, and receiving the I frame data fed back by the server, and decoding the output, and then analogizing to I, in the case of the first time interval from the last transmission interval. Each I frame in the sequence of frames transmits a data request message and receives the feedback I frame data. And during the execution of step 203 and step 204, the output interface of the terminal will form an output effect of fast forward and rewind.
在本发明实施例中,当接收到快进或快退请求时,根据快进或快退的倍速确定第二时长,并根据当前节目已播放时长,第二时长及当前节目的各I帧的索引信息中包含的I帧时间选取I帧,得到I帧序列,且在得到I帧序列之后,终端将每间隔预先设置的第一时长,向服务器发送一个数 据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;且终端还将接收并解码输出服务器根据接收到的数据请求消息中的I帧的索引信息反馈的I帧数据。通过上述的方式,使得仅需要从服务器下载选取的I帧序列中的I帧,而不需要下载当前节目中的所有I帧,能够有效的降低I帧的下载量,降低对宽带的要求。In the embodiment of the present invention, when the fast forward or fast reverse request is received, the second duration is determined according to the double speed of fast forward or fast reverse, and according to the current play duration, the second duration, and each I frame of the current program. The I frame time included in the index information is selected as an I frame to obtain an I frame sequence, and after the I frame sequence is obtained, the terminal sends a number to the server for the first time interval preset for each interval. According to the request message, and the data request message sequentially carries the index information of the I frame in the I frame sequence; and the terminal further receives and decodes the I frame data fed back by the output server according to the index information of the I frame in the received data request message. . In the above manner, it is only necessary to download the I frame in the selected I frame sequence from the server, without downloading all the I frames in the current program, which can effectively reduce the download amount of the I frame and reduce the requirement for the broadband.
为了更好的理解本发明实施例中的技术方案,下面将详细介绍一个具体的应用场景,包括:For a better understanding of the technical solutions in the embodiments of the present invention, a specific application scenario is described in detail below, including:
1)终端接收到快进请求中,提取该快进请求中包含的快进倍速N,及确定当前节目已播放时长T1;1) The terminal receives the fast forward request, extracts the fast forward multiplication speed N included in the fast forward request, and determines the current program played time length T1;
2)终端确定向服务器发送数据请求消息的时间间隔第一时长为1/logsN,用于选取I帧的第二时长为N/logsN;2) The terminal determines that the time interval for sending the data request message to the server is 1/logsN, and the second duration for selecting the I frame is N/logsN;
3)终端利用第二时长N/logsN,当前节目已播放时长T1及终端已保存的当前节目的各I帧的时间点确定I帧序列,该I帧序列为[I0,I1,I2,I3,……,I10];3) The terminal determines the I frame sequence by using the second duration N/logsN, the current program playback duration T1, and the time point of each I frame of the current program saved by the terminal, and the I frame sequence is [I0, I1, I2, I3, ..., I10];
4)终端向服务器发送数据请求消息,请求I帧序列中的I0的I帧数据;4) The terminal sends a data request message to the server, requesting I frame data of I0 in the I frame sequence;
5)终端接收服务器反馈的I0的I帧数据,并解码输出;5) The terminal receives the I frame data of the I0 fed back by the server, and decodes the output;
6)终端向服务器发送数据请求消息,请求I帧序列中的I1的I帧数据;6) The terminal sends a data request message to the server, requesting I frame data of I1 in the I frame sequence;
7)终端接收服务器反馈的I1的I帧数据,并解码输出;7) The terminal receives the I frame data of the I1 fed back by the server, and decodes the output;
……......
8)终端向服务器发送数据请求消息,请求I帧序列中的I10的I帧数据;8) The terminal sends a data request message to the server, requesting I frame data of I10 in the I frame sequence;
9)终端接收服务器反馈的I10的I帧数据,并解码输出。9) The terminal receives the I frame data of the I10 fed back by the server, and decodes the output.
在本发明实施例中,N倍速快进或快退时,每秒的节目时间步长为N,但是不用每秒获取N秒内的所有I帧,而是1/T0个I帧,该T0是指第一时长,这样就可以很大程度上减少需要下载的I帧的数量,降低对带宽的需求,同时,倍数越大,获取的I帧个数也多,输出的快进快退的画面切 换效果更好,也能进一步提升用户体验。In the embodiment of the present invention, when N-speed fast forwards or rewinds, the program time step per second is N, but it is not required to acquire all I frames in N seconds per second, but 1/T0 I frames, the T0. It refers to the first duration, which can greatly reduce the number of I frames that need to be downloaded, and reduce the bandwidth requirement. At the same time, the larger the multiple, the more I frames are acquired, and the output fast forwards and rewinds. Screen cut Better results can also enhance the user experience.
在本发明实施例中,通过对当前节目的各I帧进行选取,使得只需要下载部分I帧的I帧数据,而不需要下载当前节目的所有I帧的I帧数据,能够有效的减少I帧数据的下载量,同时降低对宽带的要求。In the embodiment of the present invention, by selecting each I frame of the current program, it is only necessary to download the I frame data of the partial I frame without downloading the I frame data of all the I frames of the current program, which can effectively reduce I. The amount of frame data downloaded, while reducing the requirements for broadband.
请参阅图3,为本发明实施例中终端的结构的实施例,包括:Referring to FIG. 3, it is an embodiment of a structure of a terminal according to an embodiment of the present invention, including:
选取模块301,设置为当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进或快退请求中包含的倍速选取I帧,得到I帧序列;The selecting module 301 is configured to: when receiving the fast forward or fast reverse request, select the I frame according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward or fast reverse request. , get the I frame sequence;
发送模块302,设置为在选取模块301得到I帧序列之后,每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;The sending module 302 is configured to send a data request message to the server after the I-frame sequence is obtained by the selecting module 301, and the data request message sequentially carries the index information of the I frame in the I frame sequence. ;
接收输出模块303,设置为在发送模块302发送数据请求消息之后,接收并解码输出服务器根据接收到的I帧索引信息反馈的I帧数据。The receiving output module 303 is configured to receive and decode the I frame data fed back by the output server according to the received I frame index information after the sending module 302 sends the data request message.
在本发明实施例中,终端在最初开始播放节目时,将向服务器发送I帧索引信息请求消息,服务器在接收到该I帧索引信息请求消息之后,将解析该终端当前节目的视频源,获取该当前节目的各I帧的索引信息,并将获取到的各I帧的索引信息反馈给终端。In the embodiment of the present invention, when the terminal starts to play the program, the terminal sends an I frame index information request message to the server, and after receiving the I frame index information request message, the server parses the video source of the current program of the terminal, and obtains The index information of each I frame of the current program is fed back to the terminal by the obtained index information of each I frame.
其中,终端在接收到其当前节目的各I帧的索引信息之后,将保存该当前节目的各I帧的索引信息。After receiving the index information of each I frame of the current program, the terminal saves the index information of each I frame of the current program.
其中,I帧的索引信息至少包含I帧的时间点,且I帧的时间点是指该I帧在当前节目中所处的时间点。The index information of the I frame includes at least the time point of the I frame, and the time point of the I frame refers to the time point of the I frame in the current program.
此外,I帧的索引信息中还可以包括I帧所在分片的名称、I帧在分片中的偏移位置及I帧的大小等等参数。In addition, the index information of the I frame may further include parameters such as the name of the fragment where the I frame is located, the offset position of the I frame in the fragment, and the size of the I frame.
在本发明实施例中,用户可通过遥控器控制或者触摸屏触摸等方式向终端发出快进或快退的请求,该快进或快退的请求中包含快进或快退的倍速,其中,快进或快退的倍速可以是2、4、8、16等等。In the embodiment of the present invention, the user may issue a fast forward or fast reverse request to the terminal by using a remote control or a touch screen touch, and the fast forward or fast reverse request includes a fast forward or fast reverse speed, wherein The double speed of entering or rewinding can be 2, 4, 8, 16 and so on.
终端在接收到该快进或快退请求之后,将根据当前节目已播放时长、预先保存的该当前节目的各I帧的索引信息及该快进或快退请求中包含的 倍速选取I帧,得到I帧序列。After receiving the fast forward or fast reverse request, the terminal will according to the current program play duration, the index information of each I frame of the current program saved in advance, and the content included in the fast forward or rewind request. I frame is selected at double speed to obtain an I frame sequence.
其中,终端在向服务器发送数据请求消息时,其携带的I帧的索引信息包含该I帧的时间点、I帧所在分片名称、I帧在分片的偏移位置及I帧大小。When the terminal sends a data request message to the server, the index information of the I frame carried by the terminal includes the time point of the I frame, the fragment name of the I frame, the offset position of the I frame in the fragment, and the I frame size.
服务器在接收到数据请求消息之后,将利用其携带的I帧的索引信息中的I帧的时间点确定I帧在当前节目的总时长上的位置,并利用I帧所在的分片名称确定I帧所在的分片,且在确定分片之后,利用I帧在该分片中的偏移位置及I帧大小提取I帧数据,且将提取的I帧数据反馈给终端。After receiving the data request message, the server determines the position of the I frame on the total duration of the current program by using the time point of the I frame in the index information of the I frame carried by the server, and determines the I by using the slice name of the I frame. After the fragment is determined, and after determining the fragment, the I frame data is extracted by using the offset position of the I frame in the fragment and the I frame size, and the extracted I frame data is fed back to the terminal.
在本发明实施例中,终端可以是电视机、电脑、机顶盒、PAD、智能手机等等。In the embodiment of the present invention, the terminal may be a television, a computer, a set top box, a PAD, a smart phone, or the like.
在本发明实施例中,当接收到快进或快退请求时,选取模块301根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进或快退请求中包含的倍速选取I帧,得到I帧序列;接着,发送模块302每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;且由接收输出模块303接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧数据。In the embodiment of the present invention, when receiving the fast forward or fast reverse request, the selecting module 301 is configured according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward or fast reverse request. The I frame is selected at a multiple speed to obtain an I frame sequence. Then, the sending module 302 sends a data request message to the server every interval of the first time interval, and the data request message carries the index information of the I frame in the I frame sequence. And receiving, by the receiving output module 303, and decoding the I frame data fed back by the output server according to the index information of the received I frame.
在本发明实施例中,当终端接收到快进或快退请求时,将根据当前节目已播放时长、当前节目各I帧的索引信息及快进或快退的倍速选取I帧,得到I帧序列,且每隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息,在接收到服务器根据接收到的数据请求消息包含的I帧索引信息反馈的I帧数据后,终端将解码输出该I帧数据。通过上述方式,使得只需要从服务器下载选取的部分的I帧即可实现快进快退的输出效果,而不需要将当期节目的所有I帧下载下来,有效减少I帧数据的下载量,且有效的降低对宽带的要求。In the embodiment of the present invention, when the terminal receives the fast forward or fast reverse request, the I frame is selected according to the current program play duration, the index information of each I frame of the current program, and the double speed of fast forward or fast reverse, to obtain an I frame. a sequence, and sending a data request message to the server every predetermined first time period, and the data request message sequentially carries index information of the I frame in the I frame sequence, and the received server receives the request message according to the received data request message. After the I frame data fed back by the I frame index information, the terminal will decode and output the I frame data. In the above manner, the I-frame of the selected part can be downloaded from the server to realize the fast-forward and fast-return output effect, without downloading all the I-frames of the current program, thereby effectively reducing the download amount of the I-frame data, and Effectively reduce the requirements for broadband.
为了更好的理解本发明实施例中的终端,请参阅图4,为本发明实施例中终端的结构的实施例,包括如图3所示实施例中描述的选取模块301, 发送模块302,接收输出模块303,且与图3所示实施例中描述的内容相似,此处不再赘述。For a better understanding of the terminal in the embodiment of the present invention, refer to FIG. 4, which is an embodiment of the structure of the terminal in the embodiment of the present invention, including the selection module 301 described in the embodiment shown in FIG. The sending module 302 receives the output module 303 and is similar to the content described in the embodiment shown in FIG. 3, and details are not described herein again.
在本发明实施例中,选取模块301包括:In the embodiment of the present invention, the selecting module 301 includes:
时长确定模块401,设置为当接收到快进请求或快退请求时,根据快进或快退的倍速确定第二时长;The duration determining module 401 is configured to determine the second duration according to the fast forward or fast reverse multiple speed when receiving the fast forward request or the fast reverse request;
帧选取模块402,设置为在时长确定模块401确定第二时长之后,根据当前节目已播放时长,第二时长及当前节目的各I帧的时间点选取I帧,得到I帧序列,I帧的时间点包含在I帧的索引信息中。The frame selection module 402 is configured to: after the duration determining module 401 determines the second duration, select an I frame according to the current duration of the program, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, and an I frame. The time point is included in the index information of the I frame.
其中,帧选取模块402具体设置为:The frame selection module 402 is specifically configured to:
若为快进,则m的初始值为0,执行以下步骤:If fast forward, the initial value of m is 0, perform the following steps:
步骤1:将当前节目已播放时长加上m倍的第二时长的和作为有效时间点;Step 1: The sum of the second duration of the current program played time plus m times is taken as the effective time point;
步骤2:根据当前节目的各I帧的时间点,判断有效时间点往后是否还有I帧;Step 2: judging whether there is an I frame later according to the time point of each I frame of the current program;
步骤3:若有效时间点往后还有I帧,则往后选取时间点与有效时间点最近的一个I帧作为I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so m=m+1, return to execution. step 1;
步骤4:若有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
或者,帧选取模块402具体设置为:Alternatively, the frame selection module 402 is specifically configured to:
若为快退,则m的初始值为0,执行以下步骤:If it is fast rewind, the initial value of m is 0, perform the following steps:
步骤1:将当前节目已播放时长减去m倍的第二时长的差作为有效时间点;Step 1: subtract the difference of the second duration of the current program playback duration by m times as the effective time point;
步骤2:根据当前节目的各I帧的时间点,判断有效时间点往前是否还有I帧;Step 2: According to the time point of each I frame of the current program, determine whether there is an I frame in the effective time point;
步骤3:若有效时间点往前还有I帧,则往前选取时间点与有效时间点最近的一个I帧作为I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame in front of the effective time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so m=m+1, and return to execution. step 1;
步骤4:若有效时间点往前没有I帧,则结束对I帧的选取。 Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
在本发明实施例中,预先设置的第一时长为预先设置的小于或等于1秒的时间值,或者为基于倍速计算得到的小于或等于1秒的时间值。In the embodiment of the present invention, the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
在本发明实施例中,当接收到快进或快退请求时,选取模块301根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进或快退请求中包含的倍速选取I帧,得到I帧序列;具体的:选取模块301中的时长确定模块401根据快进或快退的倍速确定第二时长,并由帧选取模块402根据当前节目已播放时长,第二时长及当前节目的各I帧的时间点选取I帧,得到I帧序列,索引信息中包含I帧的时间点。In the embodiment of the present invention, when receiving the fast forward or fast reverse request, the selecting module 301 is configured according to the current program play duration, the index information of each I frame of the current program saved in advance, and the fast forward or fast reverse request. The I frame is selected at a multiple speed to obtain an I frame sequence. Specifically, the duration determining module 401 in the selecting module 301 determines the second duration according to the double speed of the fast forward or fast reverse, and is determined by the frame selection module 402 according to the duration of the current program. The duration and the time point of each I frame of the current program select an I frame to obtain an I frame sequence, and the index information includes the time point of the I frame.
接着,发送模块302每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;且由接收输出模块303接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧数据。Then, the sending module 302 sends a data request message to the server every time the interval is preset, and the data request message sequentially carries the index information of the I frame in the I frame sequence; and the receiving output module 303 receives and decodes the output. The server feeds back I frame data according to the index information of the received I frame.
在本发明实施例中,当接收到快进或快退请求时,根据快进或快退的倍速确定第二时长,并根据当前节目已播放时长,第二时长及当前节目的各I帧的索引信息中包含的I帧时间选取I帧,得到I帧序列,且在得到I帧序列之后,终端将每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且数据请求消息中依次携带I帧序列中的I帧的索引信息;且终端还将接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧数据。通过上述的方式,使得仅需要从服务器下载选取的I帧序列中的I帧,而不需要下载当前节目中的所有I帧,能够有效的降低I帧的下载量,降低对宽带的要求。In the embodiment of the present invention, when the fast forward or fast reverse request is received, the second duration is determined according to the double speed of fast forward or fast reverse, and according to the current play duration, the second duration, and each I frame of the current program. The I frame time included in the index information is selected as an I frame, and an I frame sequence is obtained. After the I frame sequence is obtained, the terminal sends a data request message to the server for each first interval set in advance, and the data request message is sequentially Carrying index information of the I frame in the I frame sequence; and the terminal will also receive and decode the I frame data fed back by the output server according to the received index information of the I frame. In the above manner, it is only necessary to download the I frame in the selected I frame sequence from the server, without downloading all the I frames in the current program, which can effectively reduce the download amount of the I frame and reduce the requirement for the broadband.
本发明的实施例还提供了一种存储介质。可选地,在本实施例中,上述存储介质可以被设置为存储用于执行以下步骤的程序代码:Embodiments of the present invention also provide a storage medium. Optionally, in the embodiment, the foregoing storage medium may be configured to store program code for performing the following steps:
S1,当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进或快退请求中包含的倍速选取I帧,得到I帧序列;S1, when receiving the fast forward or fast reverse request, selecting an I frame according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward or fast reverse request, to obtain an I frame. sequence;
S2,每间隔预先设置的第一时长,向服务器发送一个数据请求消息, 且数据请求消息中依次携带I帧序列中的I帧的索引信息;S2, sending a data request message to the server every interval of the preset first time duration, And the data request message carries the index information of the I frame in the I frame sequence in sequence;
S3,接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧数据。S3. Receive and decode the I frame data fed back by the output server according to the received index information of the I frame.
可选地,存储介质还被设置为存储用于执行以下步骤的程序代码:Optionally, the storage medium is further arranged to store program code for performing the following steps:
S1,当接收到快进请求或快退请求时,根据快进或快退的倍速确定第二时长;S1, when receiving the fast forward request or the fast reverse request, determining the second duration according to the double speed of fast forward or fast reverse;
S2,根据当前节目已播放时长,第二时长及当前节目的各I帧的时间点选取I帧,得到I帧序列,I帧的时间点包含在I帧的索引信息中。S2: Select an I frame according to the current duration of the program, the second duration, and the time point of each I frame of the current program, to obtain an I frame sequence, where the time point of the I frame is included in the index information of the I frame.
可选地,在本实施例中,上述存储介质可以包括但不限于:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储程序代码的介质。Optionally, in this embodiment, the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory. A variety of media that can store program code, such as a disc or a disc.
可选地,本实施例中的具体示例可以参考上述实施例及可选实施方式中所描述的示例,本实施例在此不再赘述。For example, the specific examples in this embodiment may refer to the examples described in the foregoing embodiments and the optional embodiments, and details are not described herein again.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对相关技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本发明各个实施例的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the foregoing embodiment method can be implemented by means of software plus a necessary general hardware platform, and of course, can also be through hardware, but in many cases, the former is better. Implementation. Based on such understanding, the technical solution of the present invention in essence or the contribution to the related art can be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk, CD-ROM). The instructions include a number of instructions for causing a terminal device (which may be a cell phone, computer, server, air conditioner, or network device, etc.) to perform the methods of various embodiments of the present invention.
以上仅为本发明的优选实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。 The above are only the preferred embodiments of the present invention, and are not intended to limit the scope of the invention, and the equivalent structure or equivalent process transformations made by the description of the present invention and the drawings are directly or indirectly applied to other related technical fields. The same is included in the scope of patent protection of the present invention.
工业实用性Industrial applicability
在本发明实施例中,在接收到快进或快退请求时,终端根据当前节目已播放时长、预先保存的当前节目的各I帧的索引信息及快进快退请求中包含的倍速选取I帧,得到I帧序列,且每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且发送的数据请求消息中依次携带该I帧序列中的一个I帧,终端还将接收并解码输出服务器根据接收到的I帧的索引信息反馈的I帧的数据,以实现快进快退。由于选取的I帧为当前节目的一部分I帧,使得在实现快进快退时,不需要将当前节目的所有I帧的I帧数据都下载下来,能够在实现快进快退的输出效果的同时有效的减少I帧数据的下载量,且I帧数据下载量的降低能够有效降低对宽带的要求。 In the embodiment of the present invention, when receiving the fast forward or fast reverse request, the terminal selects I according to the current program play duration, the index information of each I frame of the current program saved in advance, and the double speed included in the fast forward rewind request. The frame obtains an I frame sequence, and sends a data request message to the server every time the interval is preset, and the data request message carries one I frame in the I frame sequence, and the terminal also receives and decodes. The output server feeds back the data of the I frame according to the index information of the received I frame to implement fast forward and rewind. Since the selected I frame is a part of the I frame of the current program, when the fast forward and rewind are implemented, it is not necessary to download the I frame data of all the I frames of the current program, and the output effect of the fast forward and rewind can be realized. At the same time, the download amount of the I frame data is effectively reduced, and the reduction of the I frame data download amount can effectively reduce the requirement for the broadband.

Claims (10)

  1. 一种快进快退的处理方法,包括:A fast forward and rewind processing method, including:
    当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列;When receiving the fast forward or fast reverse request, the I frame is obtained according to the current program play duration, the index information of each I frame of the current program saved in advance, and the multiple speed included in the fast forward or fast reverse request. I frame sequence;
    每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且所述数据请求消息中依次携带所述I帧序列中的I帧的索引信息;Sending a data request message to the server, and the data request message carries the index information of the I frame in the I frame sequence in sequence;
    接收并解码输出所述服务器根据接收到的所述I帧的索引信息反馈的I帧数据。Receiving and decoding output I frame data fed back by the server according to the received index information of the I frame.
  2. 根据权利要求1所述的处理方法,其中,所述当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列,包括:The processing method according to claim 1, wherein when the fast forward or fast reverse request is received, the index information of each I frame of the current program saved in advance according to the current program play duration and the fast The I frame is selected at the double speed included in the incoming or rewind request to obtain an I frame sequence, including:
    当接收到快进请求或快退请求时,根据所述快进或快退的倍速确定第二时长;When receiving the fast forward request or the fast reverse request, determining the second duration according to the double speed of the fast forward or fast reverse;
    根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,所述I帧的时间点包含在所述I帧的索引信息中。Determining, according to the duration of the current program, the second duration and the time point of each I frame of the current program, selecting an I frame, and obtaining the I frame sequence, where the time point of the I frame is included in the I frame In the index information.
  3. 根据权利要求2所述的处理方法,其中,所述根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,包括:The processing method according to claim 2, wherein the I frame is selected according to the current program played duration, the second duration, and the time points of each I frame of the current program, to obtain the I frame sequence. ,include:
    若为快进,则m的初始值为0,执行以下步骤:If fast forward, the initial value of m is 0, perform the following steps:
    步骤1:将所述当前节目已播放时长加上m倍的所述第二时长的和作为有效时间点;Step 1: the sum of the second duration of the current program played duration plus m times is taken as an effective time point;
    步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往后是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
    步骤3:若所述有效时间点往后还有I帧,则往后选取时间点与所述 有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then select the time point and the The most recent I frame of the effective time point is used as the m+1th frame of the I frame sequence, so that m=m+1, returning to step 1;
    步骤4:若所述有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame after the valid time point, the selection of the I frame ends.
  4. 根据权利要求2所述的处理方法,其中,所述根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的索引信息中包含的I帧的时间点选取I帧,得到所述I帧序列,包括:The processing method according to claim 2, wherein the time point of the I frame included in the index information of each I frame of the current program is selected according to the duration of the current program, the second duration, and the I frame included in the index information of each I frame of the current program. Frame, obtaining the sequence of I frames, including:
    若为快退,则m的初始值为0,执行以下步骤:If it is fast rewind, the initial value of m is 0, perform the following steps:
    步骤1:将所述当前节目已播放时长减去m倍的所述第二时长的差作为有效时间点;Step 1: subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
    步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往前是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
    步骤3:若所述有效时间点往前还有I帧,则往前选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame in front of the valid time point, an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
    步骤4:若所述有效时间点往前没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
  5. 根据权利要求1所述的处理方法,其中,所述预先设置的第一时长为预先设置的小于或等于1秒的时间值,或者为基于所述倍速计算得到的小于或等于1秒的时间值。The processing method according to claim 1, wherein the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed .
  6. 一种终端,包括:A terminal comprising:
    选取模块,设置为当接收到快进或快退请求时,根据当前节目已播放时长、预先保存的所述当前节目的各I帧的索引信息及所述快进或快退请求中包含的倍速选取I帧,得到I帧序列;The selection module is configured to, according to the current program played duration, the pre-stored index information of each I frame of the current program, and the double speed included in the fast forward or rewind request, when the fast forward or fast reverse request is received Selecting an I frame to obtain an I frame sequence;
    发送模块,设置为在所述选取模块得到所述I帧序列之后,每间隔预先设置的第一时长,向服务器发送一个数据请求消息,且所述数据请求消息中依次携带所述I帧序列中的I帧的索引信息; The sending module is configured to send a data request message to the server, and the data request message sequentially carries the I frame sequence in the sequence of the first time period that is preset before the selection module obtains the I frame sequence. Index information of the I frame;
    接收输出模块,设置为在所述发送模块发送数据请求消息之后,接收并解码输出所述服务器根据接收到的所述I帧的索引信息反馈的I帧数据。The receiving output module is configured to receive and decode the I frame data that the server feeds back according to the received index information of the I frame after the sending module sends the data request message.
  7. 根据权利要求6所述的终端,其中,所述选取模块包括:The terminal of claim 6, wherein the selection module comprises:
    时长确定模块,设置为当接收到快进请求或快退请求时,根据所述快进或快退的倍速确定第二时长;a duration determining module, configured to determine a second duration according to the fast forward or fast reverse multiple speed when receiving the fast forward request or the fast reverse request;
    帧选取模块,设置为在所述时长确定模块确定所述第二时长之后,根据所述当前节目已播放时长,所述第二时长及所述当前节目的各I帧的时间点选取I帧,得到所述I帧序列,所述I帧的时间点包含在所述I帧的索引信息中。a frame selection module, configured to: after the duration determining module determines the second duration, select an I frame according to the current duration of the current program, the second duration, and the time point of each I frame of the current program. Obtaining the I frame sequence, where the time point of the I frame is included in the index information of the I frame.
  8. 根据权利要求7所述的终端,其中,所述帧选取模块具体设置为:The terminal according to claim 7, wherein the frame selection module is specifically configured to:
    若为快进,则m的初始值为0,执行以下步骤:If fast forward, the initial value of m is 0, perform the following steps:
    步骤1:将所述当前节目已播放时长加上m倍的所述第二时长的和作为有效时间点;Step 1: the sum of the second duration of the current program played duration plus m times is taken as an effective time point;
    步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往后是否还有I帧;Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame later in the valid time point;
    步骤3:若所述有效时间点往后还有I帧,则往后选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame later in the valid time point, then an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
    步骤4:若所述有效时间点往后没有I帧,则结束对I帧的选取。Step 4: If there is no I frame after the valid time point, the selection of the I frame ends.
  9. 根据权利要求7所述的终端,其中,所述帧选取模块具体设置为:The terminal according to claim 7, wherein the frame selection module is specifically configured to:
    若为快退,则m的初始值为0,执行以下步骤:If it is fast rewind, the initial value of m is 0, perform the following steps:
    步骤1:将所述当前节目已播放时长减去m倍的所述第二时长的差作为有效时间点;Step 1: subtracting, as the effective time point, the difference of the second duration of the current program played duration by m times;
    步骤2:根据所述当前节目的各I帧的时间点,判断所述有效时间点往前是否还有I帧; Step 2: determining, according to the time point of each I frame of the current program, whether there is an I frame in the effective time point;
    步骤3:若所述有效时间点往前还有I帧,则往前选取时间点与所述有效时间点最近的一个I帧作为所述I帧序列的第m+1个帧,令m=m+1,返回执行步骤1;Step 3: If there is an I frame in front of the valid time point, an I frame closest to the effective time point is selected as the m+1th frame of the I frame sequence, so that m= m+1, return to step 1;
    步骤4:若所述有效时间点往前没有I帧,则结束对I帧的选取。Step 4: If there is no I frame in the effective time point, the selection of the I frame ends.
  10. 根据权利要求6所述的终端,其中,所述预先设置的第一时长为预先设置的小于或等于1秒的时间值,或者为基于所述倍速计算得到的小于或等于1秒的时间值。 The terminal according to claim 6, wherein the preset first duration is a preset time value less than or equal to 1 second, or a time value less than or equal to 1 second calculated based on the double speed.
PCT/CN2016/099377 2015-10-26 2016-09-19 Fast forward/rewind processing method and terminal WO2017071428A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510703222.4A CN106612462B (en) 2015-10-26 2015-10-26 Fast forward and fast backward processing method and terminal
CN201510703222.4 2015-10-26

Publications (1)

Publication Number Publication Date
WO2017071428A1 true WO2017071428A1 (en) 2017-05-04

Family

ID=58613792

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/099377 WO2017071428A1 (en) 2015-10-26 2016-09-19 Fast forward/rewind processing method and terminal

Country Status (2)

Country Link
CN (1) CN106612462B (en)
WO (1) WO2017071428A1 (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114173202A (en) * 2021-11-23 2022-03-11 武汉市烽视威科技有限公司 RTSP (real time streaming protocol) -based continuous speed doubling playing method and related equipment
CN114501166A (en) * 2021-11-18 2022-05-13 武汉市烽视威科技有限公司 DASH on-demand fast-forward and fast-backward method and system

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109348280B (en) * 2018-10-23 2021-11-09 深圳Tcl新技术有限公司 Network television program switching method, intelligent television and computer readable storage medium
CN112188254A (en) * 2020-09-29 2021-01-05 深圳创维-Rgb电子有限公司 Video playing double-speed switching processing method and device based on television terminal

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2985703B2 (en) * 1995-01-19 1999-12-06 日本ビクター株式会社 Image compression recording medium playback device
CN101018323A (en) * 2007-02-08 2007-08-15 华为技术有限公司 A method and stream media server for fast-forward and fast back of the video data
CN101841692A (en) * 2010-04-23 2010-09-22 深圳市茁壮网络股份有限公司 Method for fast forwarding and fast rewinding video stream
CN103369351A (en) * 2012-03-29 2013-10-23 深圳市龙视传媒有限公司 Streaming media fast-forward and fast-backward processing method, video server and system

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101480469B1 (en) * 2008-12-01 2015-01-09 엘지전자 주식회사 Image display device, image transmitting device, method for transmitting image and recording medium
CN102025956B (en) * 2009-09-23 2013-01-23 华为技术有限公司 Processing method, device and system for fast forward and fast backward playing of network stream media
CN102487458A (en) * 2010-12-02 2012-06-06 中兴通讯股份有限公司 Method for broadcasting and processing TS (Transport Stream) document and device thereof
CN102761524B (en) * 2011-04-27 2017-06-23 中兴通讯股份有限公司 A kind of Streaming Media storage, player method and corresponding system
CN102550038A (en) * 2011-11-16 2012-07-04 华为技术有限公司 Method, terminal, server and system for playing media files
CN103024440B (en) * 2013-01-11 2014-12-31 德科仕通信(上海)有限公司 Video quality evaluation and fault diagnosis method aiming at HAS (HTTP Adaptive Streaming)
CN103096132B (en) * 2013-02-05 2016-09-28 北京赛科世纪数码科技有限公司 The method and device of TS file fast forwarding and fast rewinding
CN103581693B (en) * 2013-11-12 2017-02-15 北京清源新创科技有限公司 Internet-oriented large-scale live time shifting method and system based on fragment transmission

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2985703B2 (en) * 1995-01-19 1999-12-06 日本ビクター株式会社 Image compression recording medium playback device
CN101018323A (en) * 2007-02-08 2007-08-15 华为技术有限公司 A method and stream media server for fast-forward and fast back of the video data
CN101841692A (en) * 2010-04-23 2010-09-22 深圳市茁壮网络股份有限公司 Method for fast forwarding and fast rewinding video stream
CN103369351A (en) * 2012-03-29 2013-10-23 深圳市龙视传媒有限公司 Streaming media fast-forward and fast-backward processing method, video server and system

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114501166A (en) * 2021-11-18 2022-05-13 武汉市烽视威科技有限公司 DASH on-demand fast-forward and fast-backward method and system
CN114173202A (en) * 2021-11-23 2022-03-11 武汉市烽视威科技有限公司 RTSP (real time streaming protocol) -based continuous speed doubling playing method and related equipment

Also Published As

Publication number Publication date
CN106612462A (en) 2017-05-03
CN106612462B (en) 2021-02-19

Similar Documents

Publication Publication Date Title
US11785066B2 (en) Systems, methods, and media for controlling delivery of content
US7860996B2 (en) Media streaming with seamless ad insertion
WO2017063399A1 (en) Video playback method and device
US9979931B2 (en) Transmitting a digital media stream that is already being transmitted to a first device to a second device and inhibiting presenting transmission of frames included within a sequence of frames until after an initial frame and frames between the initial frame and a requested subsequent frame have been received by the second device
US8244897B2 (en) Content reproduction apparatus, content reproduction method, and program
WO2017071428A1 (en) Fast forward/rewind processing method and terminal
US20140109156A1 (en) Method, terminal, server and system for playing media file
US10326704B2 (en) Enabling continuous content playback
US9876840B2 (en) Method and apparatus for dynamically generating media sequences on demand for HTTP live streaming
CN109587514B (en) Video playing method, medium and related device
US9832493B2 (en) Method and apparatus for processing audio/video file
CN111447455A (en) Live video stream playback processing method and device and computing equipment
WO2012068893A1 (en) Method, device and terminal for replaying live program
CN113141522B (en) Resource transmission method, device, computer equipment and storage medium
WO2017071234A1 (en) Design method for sharing video clip in real time
CN106791994B (en) Low-delay quick broadcasting method and device
WO2013185514A1 (en) System and method for playing streaming media
CN113727199A (en) HLS slice rapid playing starting method
CN111726657A (en) Live video playing processing method and device and server
US9161088B2 (en) Method in a streaming client for handling video streaming data, streaming client, computer programs and computer program products
CN111385660B (en) Video on demand method, device, equipment and storage medium
WO2017076009A1 (en) Program watch-back method, player and terminal
US20170150206A1 (en) Online video player and its method
US8386632B2 (en) Method, device, and system for controlling streaming media play
US20150026711A1 (en) Method and apparatus for video content distribution

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16858864

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16858864

Country of ref document: EP

Kind code of ref document: A1