WO2016192254A1 - 网络视频在线播放的方法和装置 - Google Patents

网络视频在线播放的方法和装置 Download PDF

Info

Publication number
WO2016192254A1
WO2016192254A1 PCT/CN2015/090429 CN2015090429W WO2016192254A1 WO 2016192254 A1 WO2016192254 A1 WO 2016192254A1 CN 2015090429 W CN2015090429 W CN 2015090429W WO 2016192254 A1 WO2016192254 A1 WO 2016192254A1
Authority
WO
WIPO (PCT)
Prior art keywords
video
time segment
data
video data
online
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2015/090429
Other languages
English (en)
French (fr)
Inventor
江中央
周文杰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen TCL Digital Technology Co Ltd
Original Assignee
Shenzhen TCL Digital Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen TCL Digital Technology Co Ltd filed Critical Shenzhen TCL Digital Technology Co Ltd
Publication of WO2016192254A1 publication Critical patent/WO2016192254A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/433Content storage operation, e.g. storage operation in response to a pause request, caching operations
    • H04N21/4334Recording operations
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/61Network streaming of media packets for supporting one-way streaming services, e.g. Internet radio
    • 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/8456Structuring of content, e.g. decomposing content into time segments by decomposing the content in the time domain, e.g. in time segments

Definitions

  • the present invention relates to the field of network video playback technologies, and in particular, to a method and apparatus for online video playback.
  • terminals such as mobile phones, TVs, tablets, desktop computers, and all-in-ones to obtain network video and realize online video watching TV dramas, movies, variety shows and other online videos.
  • the terminal calculates the playback frame offset of the video file according to the specified time point, and resends the video data acquisition request to the video server, and obtains the video file from the server.
  • the video data starting at the frame offset is played, and the video data after the playback frame offset is stored.
  • the terminal replays the video from the specified time point.
  • the terminal needs to reacquire the video data after the specified time point to the server, the response speed is slow and time consuming, resulting in inconsistent video playback after the progress bar is dragged, and the playback waiting time is too long.
  • the main object of the present invention is to provide a method and device for online video playing, which can quickly play video data after the progress bar is dragged to a specified time point, thereby improving the response speed of the video playing.
  • the invention provides a method for online play of network video, comprising the steps of:
  • the video data is played from the start frame of the time segment to which the specified time point belongs.
  • the method further includes:
  • the video data after the time segment s seconds to which the specified time point belongs is downloaded and stored from the server.
  • the step of downloading and storing video data within a second s of each time segment from the server comprises:
  • the step of downloading and storing the video data after the time segment s seconds of the specified time point from the server comprises:
  • the method for online video playing of the network video further includes: step:
  • the downloading of the subsequent video data that is being downloaded is stopped, and the subsequent video data is continuously downloaded after the time segment s seconds to which the specified time point belongs.
  • the method for online video playing of the network video further includes: step:
  • the downloading of the subsequent video data that is being downloaded is stopped, and the subsequent video data is continuously downloaded from the other time segments s seconds.
  • the method before the step of playing the video data from the start frame of the time segment to which the specified time point belongs, the method further includes:
  • the data of the player buffer is cleared, and the video data within the start s of the time segment to which the stored specified time point belongs is extracted to the player buffer.
  • the invention also provides an apparatus for online play of network video, comprising:
  • a segmentation module configured to divide the current video into multiple time segments when the play starts or when the segment instruction arrives;
  • Downloading a storage module configured to download and store video data within a second s of each time segment from a server, where the s seconds are preset durations;
  • a calculation module configured to determine a time segment to which the specified time point belongs when the progress bar of the current video is dragged to the specified time point;
  • a playing module configured to play the video data from a start frame of the time segment to which the specified time point belongs.
  • the download storage module is further configured to download and store video data after the time segment s seconds to which the specified time point belongs from the server.
  • the calculating module is further configured to: acquire an offset of a start frame of each time segment relative to a current video start frame; and calculate a data frame length within a start s of each time segment;
  • the download storage module is further configured to send a first video acquisition request to the server, where the first video acquisition request includes an offset corresponding to each time segment start frame and a data frame length within a start s second Receiving and storing video data within a second s of each time segment obtained by the server according to the first video acquisition request.
  • the calculating module is further configured to: acquire an offset of the s second data frame of the time segment to which the specified time point belongs, with respect to the current video start frame;
  • the download storage module is further configured to send a second video acquisition request to the server, where the second video acquisition request includes an offset corresponding to the s second data frame of the time segment to which the specified time point belongs; And storing video data after the time segment s seconds to which the specified time point belongs according to the second video acquisition request.
  • the downloading storage module is further configured to stop downloading the subsequent video data being downloaded when the video jumps to the start frame of the time segment to which the specified time point belongs, from the time segment s seconds to which the specified time point belongs. Continue to download subsequent video data.
  • the download storage module is further configured to stop downloading subsequent video data being downloaded when the video jumps to other time segments, and then continue to download subsequent video data after another time segment s seconds.
  • the playing module is further configured to clear data of the player buffer area, and extract video data within a start s second of the time segment to which the stored specified time point belongs to the player buffer area.
  • the terminal of the present invention plays the network video online
  • the video data in the second s of each time segment is downloaded and stored in advance from the server.
  • the terminal does not need to request the server to reacquire the specified time point.
  • the video data is directly played back to the start frame of the time segment to which the specified time point belongs, which reduces the waiting buffer time and improves the response speed of the video playback.
  • FIG. 1 is a flowchart of a first embodiment of a method for online play of network video according to the present invention
  • FIG. 2 is a flowchart of a second embodiment of a method for online play of network video according to the present invention
  • FIG. 3 is a flowchart of a third embodiment of a method for online play of network video according to the present invention.
  • FIG. 4 is a flowchart of a fourth embodiment of a method for online play of network video according to the present invention.
  • FIG. 5 is a flowchart of a fifth embodiment of a method for online play of network video according to the present invention.
  • FIG. 6 is a schematic block diagram of an embodiment of an apparatus for online playback of network video according to the present invention.
  • FIG. 1 is a flowchart of a first embodiment of a method for online play of network video according to the present invention.
  • the method for online play of network video mentioned in this embodiment includes the following steps:
  • Step S10 dividing the current video into multiple time segments when the play starts or when the segment instruction arrives;
  • the user views the network video online through a client player or a web player of a mobile phone, a computer, a television, a PAD, or the like.
  • the player divides the current video file into multiple time segments, and buffers the video data in the initial period of each time segment separately; or presses the default to start playback.
  • the normal playback mode buffers the frontmost segment of the current video, and sets a segmentation function control in the player. The user can select the control, start the segmentation function, and generate a segmentation instruction.
  • the terminal may first download the video data of the foremost part of the video file from the server, parse and decode the part of the video data, obtain the front-end audio and video data, and play the current video through the player.
  • the frontmost section according to the total duration of the current video, the video files are divided according to time, and multiple time segments are obtained, and the number of time segments can be pre-configured.
  • the duration of each time segment can be equal, that is, the time segments are equally divided.
  • the duration of each time segment can be divided into different levels according to a preset rule, for example, when the content of the current video is more exciting, the time is more divided. Short time segments, other parts that are not very exciting are divided into time segments with longer durations.
  • Step S20 downloading and storing video data within a second s of each time segment from the server;
  • the terminal sends a request to the server to obtain the video data of the first s seconds of each time segment, and the s seconds are preset durations, and the preset duration is less than the total duration of each time segment.
  • the preset duration can be a fixed length of time, or can be set according to the percentage of the duration of a time segment. For example, the duration of each time segment is divided into different according to a preset rule, and the duration of each time segment is determined.
  • Ti download the video data of 20%*Ti in front of each time segment.
  • the terminal stores the video data of the first s second of each time segment downloaded in the memory or disk of the terminal.
  • Step S30 When the progress bar of the current video is dragged to the specified time point, determine a time segment to which the specified time point belongs;
  • the terminal determines the corresponding time point according to the position of the progress indication point, that is, the specified time point, for example, the total length of the progress bar is Lc, and the corresponding time length
  • the terminal For each time segment of the above division, the terminal records the start time and the end time of the time segment, when the specified time point Tb is greater than or equal to the start time of the i-th time segment, and is less than or equal to the i-th time segment. At the end time, the specified time point Tb belongs to the i-th time segment.
  • step S40 the video data is played from the start frame of the time segment to which the specified time point belongs.
  • the terminal plays the video through the player, it does not need to be accurate to the specified time point for playing, and can jump to the start frame of the time segment to which the specified time point belongs to start playing. . Since each time segment has previously downloaded and stored the video data in the first s seconds from the server, the terminal does not need to request the server to reacquire the video data at the specified time point when the progress bar is dragged to the specified time point. It is to directly jump the video to the start frame of the time segment to which the specified time point belongs, which reduces the waiting time for buffering and improves the response speed of the video playback.
  • FIG. 2 is a flowchart of a second embodiment of a method for online play of network video according to the present invention. This embodiment includes all the steps in the embodiment shown in FIG. 1. After step S40, the method further includes:
  • step S50 the video data after the time segment s seconds to which the specified time point belongs is downloaded and stored from the server.
  • the subsequent download may be stopped after downloading the video data within the first s seconds of each time segment, if the user does not drag After the progress bar, the subsequent video data after the current playing time point is continuously downloaded; when the video jumps to the start frame of the time segment to which the specified time point belongs, the downloading of the subsequent video data that is being downloaded is stopped, from the specified time point.
  • the time segment continues to download subsequent video data after s seconds.
  • the downloading of the subsequent video data that is being downloaded is stopped, and the subsequent video data is continuously downloaded from the other time segments s seconds.
  • FIG. 3 is a flowchart of a third embodiment of a method for online play of network video according to the present invention. This embodiment includes all the steps in the embodiment shown in FIG. 1. Specifically, step S20 includes:
  • Step S21 Obtain an offset of a start frame of each time segment relative to a current video start frame.
  • Step S22 calculating a data frame length within a second s of each time segment
  • Step S23 sending a first video acquisition request to the server, where the first video acquisition request includes an offset corresponding to each time segment start frame and a data frame length within a start s second;
  • Step S24 receiving and storing video data within a second s of each time segment obtained by the server according to the first video acquisition request.
  • the offset of the start frame of the i-th time segment relative to the current video start frame is Pi
  • the ith The data frame length in the first s of the time segment is Zi
  • the terminal sends Pi and Zi to the server
  • the server extracts the current video offset Pi to Pi+ Zi's video data is returned to the terminal.
  • the start time of the time segment is converted into a data frame offset
  • the time length is converted into a data frame length
  • the data frame offset and the data frame length are added to the request together. Sent to the server.
  • the server When the server extracts the video data, it does not extract according to the time, but extracts the data according to the data frame offset and the data frame length, omitting the process of converting the time data into the data frame offset and the frame length, which is beneficial to simplifying the server. Process flow to improve download speed.
  • FIG. 4 is a flowchart of a fourth embodiment of a method for online play of network video according to the present invention. This embodiment includes all the steps in the embodiment shown in FIG. 2.
  • the specific step S50 includes:
  • Step S51 acquiring an offset of the s second data frame of the time segment to which the specified time point belongs with respect to the current video start frame;
  • Step S52 sending a second video acquisition request to the server, where the second video acquisition request includes an offset corresponding to the s second data frame of the time segment to which the specified time point belongs;
  • Step S53 receiving and storing the video data after the time segment s seconds to which the specified time point obtained by the server according to the second video acquisition request belongs.
  • the offset of the start frame of the i-th time segment relative to the current video start frame is Pi, and the data frame length within the first s second of the i-th time slice.
  • the offset of the sth second snippet data frame relative to the current video start frame is Pi+ Zi
  • the terminal sends Pi+Zi to the server
  • the server extracts the video data after the current video offset Pi+Zi and returns it to the terminal.
  • the video data after the time segment s seconds corresponding to the specified time point is continuously downloaded, and the video data of the other time segments is not used to occupy too much network speed, which is convenient for quickly downloading the specified time. Subsequent video data, and also converts the start time of the download to the data frame offset.
  • the server When the server extracts the video data, it does not extract according to the time, but extracts the data according to the data frame offset, omitting the server to time data.
  • the process of converting to a data frame offset helps to simplify the processing flow of the server and increase the download speed.
  • FIG. 5 is a flowchart of a fifth embodiment of a method for online play of network video according to the present invention. This embodiment includes all the steps in the embodiment shown in FIG. 1. Before step S40, the method further includes:
  • Step S60 the data of the player buffer area is cleared, and the video data within the start s seconds of the time segment to which the stored specified time point belongs is extracted to the player buffer area.
  • the subsequent data of the video data played before the progress bar is dragged is stored in the player buffer area.
  • the terminal needs to clear the player buffer in order to play the video of the time segment to which the specified time point belongs.
  • the data of the zone, and the stored data to be played is extracted to the player buffer. Since the video data to be played is already stored in the memory or disk of the terminal in advance, before the video jumps, the terminal only needs to transfer the video data to the player buffer area locally, without downloading the video data to be played from the server, thereby reducing Waiting for the buffer time is beneficial to improve the response speed of video playback.
  • FIG. 6 is a schematic block diagram of an embodiment of an apparatus for online playback of network video according to the present invention.
  • the device for playing online video on the network mentioned in this embodiment includes:
  • the segmentation module 10 is configured to divide the current video into multiple time segments when the play starts or when the segment instruction arrives;
  • the storage module 20 is configured to download and store video data within a second s of each time segment from the server, and the s seconds are preset durations;
  • the calculating module 30 is configured to determine a time segment to which the specified time point belongs when the progress bar of the current video is dragged to the specified time point;
  • the playing module 40 is configured to play the video data from the start frame of the time segment to which the specified time point belongs.
  • the user views the network video online through a client player or a web player of a mobile phone, a computer, a television, a PAD, or the like.
  • the player divides the current video file into multiple time segments, and buffers the video data in the initial period of each time segment separately; or presses the default to start playback.
  • the normal playback mode buffers the frontmost segment of the current video, and sets a segmentation function control in the player. The user can select the control, start the segmentation function, and generate a segmentation instruction.
  • the terminal may first download the video data of the foremost part of the video file from the server, parse and decode the part of the video data, obtain the front-end audio and video data, and play the current video through the player.
  • the frontmost section according to the total duration of the current video, the video files are divided according to time, and multiple time segments are obtained, and the number of time segments can be pre-configured.
  • the duration of each time segment can be equal, that is, the time segments are equally divided.
  • the duration of each time segment can be divided into different levels according to a preset rule, for example, when the content of the current video is more exciting, the time is more divided. Short time segments, other parts that are not very exciting are divided into time segments with longer durations.
  • the terminal sends a request to the server to obtain the video data of the first s seconds of each time segment, and the s seconds are preset durations, and the preset duration is less than the total duration of each time segment.
  • the preset duration can be a fixed length of time, or can be set according to the percentage of the duration of a time segment. For example, the duration of each time segment is divided into different according to a preset rule, and the duration of each time segment is determined.
  • Ti download the video data of 20%*Ti in front of each time segment.
  • the terminal stores the video data of the first s second of each time segment downloaded in the memory or disk of the terminal.
  • the terminal determines the corresponding time point according to the position of the progress indication point, that is, the specified time point, for example, the total length of the progress bar is Lc, and the corresponding time length
  • the terminal For each time segment of the above division, the terminal records the start time and the end time of the time segment, when the specified time point Tb is greater than or equal to the start time of the i-th time segment, and is less than or equal to the i-th time segment. At the end time, the specified time point Tb belongs to the i-th time segment.
  • the terminal plays the video through the player, it does not need to be accurate to the specified time point for playing, and can jump to the start frame of the time segment to which the specified time point belongs to start playing. . Since each time segment has previously downloaded and stored the video data in the first s seconds from the server, the terminal does not need to request the server to reacquire the video data at the specified time point when the progress bar is dragged to the specified time point. It is to directly jump the video to the start frame of the time segment to which the specified time point belongs, which reduces the waiting time for buffering and improves the response speed of the video playback.
  • the download storage module 20 is further configured to download and store the video data after the time segment s seconds to which the specified time point belongs from the server.
  • the subsequent download may be stopped after downloading the video data within the first s seconds of each time segment, if the user does not drag After the progress bar, the subsequent video data after the current playing time point is continuously downloaded; when the video jumps to the start frame of the time segment to which the specified time point belongs, the downloading of the subsequent video data that is being downloaded is stopped, from the specified time point.
  • the time segment continues to download subsequent video data after s seconds.
  • the downloading of the subsequent video data that is being downloaded is stopped, and the subsequent video data is continuously downloaded from the other time segments s seconds.
  • the calculating module 30 is further configured to: acquire an offset of a start frame of each time segment relative to a current video start frame; and calculate a data frame length within a start s of each time segment;
  • the download storage module 20 is further configured to send a first video acquisition request to the server, where the first video acquisition request includes an offset corresponding to each time segment start frame and a data frame length within a start s second; receiving and storing the server The video data within s seconds of each time segment obtained according to the first video acquisition request.
  • the offset of the start frame of the i-th time segment relative to the current video start frame is Pi
  • the ith The data frame length in the first s of the time segment is Zi
  • the terminal sends Pi and Zi to the server
  • the server extracts the current video offset Pi to Pi+ Zi's video data is returned to the terminal.
  • the start time of the time segment is converted into a data frame offset
  • the time length is converted into a data frame length
  • the data frame offset and the data frame length are added to the request together. Sent to the server.
  • the server When the server extracts the video data, it does not extract according to the time, but extracts the data according to the data frame offset and the data frame length, omitting the process of converting the time data into the data frame offset and the frame length, which is beneficial to simplifying the server. Process flow to improve download speed.
  • calculation module 30 is further configured to: acquire an offset of the s second data frame of the time segment to which the specified time point belongs, with respect to the current video start frame;
  • the download storage module 20 is further configured to send a second video acquisition request to the server, where the second video acquisition request includes an offset corresponding to the s second data frame of the time segment to which the specified time point belongs; the receiving and storing server acquires according to the second video.
  • the offset of the start frame of the i-th time segment relative to the current video start frame is Pi, and the data frame length within the first s second of the i-th time slice.
  • the offset of the sth second snippet data frame relative to the current video start frame is Pi+ Zi
  • the terminal sends Pi+Zi to the server
  • the server extracts the video data after the current video offset Pi+Zi and returns it to the terminal.
  • the video data after the time segment s seconds corresponding to the specified time point is continuously downloaded, and the video data of the other time segments is not used to occupy too much network speed, which is convenient for quickly downloading the specified time. Subsequent video data, and also converts the start time of the download to the data frame offset.
  • the server When the server extracts the video data, it does not extract according to the time, but extracts the data according to the data frame offset, omitting the server to time data.
  • the process of converting to a data frame offset helps to simplify the processing flow of the server and increase the download speed.
  • the playing module 40 is further configured to clear the data of the player buffer area, and extract the video data within the start s seconds of the time segment to which the stored specified time point belongs to the player buffer area.
  • the subsequent data of the video data played before the progress bar is dragged is stored in the player buffer area.
  • the terminal needs to clear the player buffer in order to play the video of the time segment to which the specified time point belongs.
  • the data of the zone, and the stored data to be played is extracted to the player buffer. Since the video data to be played is already stored in the memory or disk of the terminal in advance, before the video jumps, the terminal only needs to transfer the video data to the player buffer area locally, without downloading the video data to be played from the server, thereby reducing Waiting for the buffer time is beneficial to improve the response speed of video playback.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
  • Television Signal Processing For Recording (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

本发明公开了一种网络视频在线播放的方法,包括步骤:在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;从服务器下载并存储每个时间片段起始s秒内的视频数据,所述s秒为预设时长;在当前视频的进度条拖动至指定时间点时,确定所述指定时间点所属的时间片段;从所述指定时间点所属的时间片段的起始帧开始播放视频数据。本发明还公开了一种网络视频在线播放的装置。本发明在线播放网络视频时,预先下载并存储每个时间片段起始一段时间内的视频数据,当进度条拖动到指定时间点时,无须重新获取指定时间点的视频数据,而是直接跳转到指定时间点所属的时间片段的起始帧播放,减少了等待缓冲的时间,提高了视频播放的响应速度。

Description

网络视频在线播放的方法和装置
技术领域
本发明涉及网络视频播放技术领域,特别涉及网络视频在线播放的方法和装置。
背景技术
目前,随着互联网技术的发展,用户通过手机、电视、平板电脑、台式电脑、一体机等终端连接网络,获取网络视频,实现在线观看电视剧、电影、综艺节目等网络视频。用户在线观看视频时,可拖动进度条到指定的时间点,终端根据指定时间点计算视频文件的播放帧偏移量,并向视频服务器重新发送视频数据获取请求,从服务器获取视频文件中从播放帧偏移量处开始的视频数据,并存储播放帧偏移量之后的视频数据,在视频数据存储到一定量后,终端从指定时间点开始重新播放视频。然而,由于此过程终端需要向服务器重新获取指定时间点之后的视频数据,响应速度慢,耗时长,造成拖动进度条后视频播放不连贯,播放等待时间过长的问题。
发明内容
本发明的主要目的为提供一种网络视频在线播放的方法和装置,在进度条拖动到指定时间点后,能快速播放视频数据,提高了视频播放的响应速度。
本发明提出一种网络视频在线播放的方法,包括步骤:
在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
从服务器下载并存储每个时间片段起始s秒内的视频数据,所述s秒为预设时长;
在当前视频的进度条拖动至指定时间点时,确定所述指定时间点所属的时间片段;
从所述指定时间点所属的时间片段的起始帧开始播放视频数据。
优选地,所述从指定时间点所属的时间片段的起始帧开始播放视频数据的步骤之后还包括:
从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据。
优选地,所述从服务器下载并存储每个时间片段起始s秒内的视频数据的步骤包括:
获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;
计算每个时间片段起始s秒内的数据帧长度;
向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;
接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
优选地,所述从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据的步骤包括:
获取所述指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
向所述服务器发送第二视频获取请求,所述第二视频获取请求包括所述指定时间点所属的时间片段第s秒数据帧对应的偏移量;
接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据。
优选地,所述接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据的步骤之后,所述网络视频在线播放的方法还包括步骤:
在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。
优选地,所述接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据的步骤之后,所述网络视频在线播放的方法还包括步骤:
当视频跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。
优选地,所述从指定时间点所属的时间片段的起始帧开始播放视频数据的步骤之前还包括:
清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
本发明还提出一种网络视频在线播放的装置,包括:
分段模块,用于在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
下载存储模块,用于从服务器下载并存储每个时间片段起始s秒内的视频数据,所述s秒为预设时长;
计算模块,用于在当前视频的进度条拖动至指定时间点时,确定所述指定时间点所属的时间片段;
播放模块,用于从所述指定时间点所属的时间片段的起始帧开始播放视频数据。
优选地,所述下载存储模块还用于,从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据。
优选地,所述计算模块还用于,获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;计算每个时间片段起始s秒内的数据帧长度;
所述下载存储模块还用于,向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
优选地,所述计算模块还用于,获取所述指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
所述下载存储模块还用于,向所述服务器发送第二视频获取请求,所述第二视频获取请求包括所述指定时间点所属的时间片段第s秒数据帧对应的偏移量;接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据。
优选地,所述下载存储模块,还用于在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。
优选地,所述下载存储模块,还用于当视频跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。
优选地,所述播放模块还用于,清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
本发明的终端在线播放网络视频时,预先从服务器下载并存储每个时间片段起始s秒内的视频数据,当进度条拖动到指定时间点时,终端无须向服务器请求重新获取指定时间点的视频数据,而是直接将视频跳转到指定时间点所属的时间片段的起始帧播放,减少了等待缓冲的时间,提高了视频播放的响应速度。
附图说明
图1为本发明网络视频在线播放的方法的第一实施例的流程图;
图2为本发明网络视频在线播放的方法的第二实施例的流程图;
图3为本发明网络视频在线播放的方法的第三实施例的流程图;
图4为本发明网络视频在线播放的方法的第四实施例的流程图;
图5为本发明网络视频在线播放的方法的第五实施例的流程图;
图6为本发明网络视频在线播放的装置的实施例的模块示意图。
本发明目的的实现、功能特点及优点将结合实施例,参照附图做进一步说明。
具体实施方式
应当理解,此处所描述的具体实施例仅仅用以解释本发明,并不用于限定本发明。
如图1所示,图1为本发明网络视频在线播放的方法的第一实施例的流程图。本实施例提到的网络视频在线播放的方法,包括步骤:
步骤S10,在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
本实施例用户通过手机、电脑、电视机、PAD等终端的客户端播放器或网页播放器在线观看网络视频。播放器可默认在当前视频文件启动播放时,就将当前视频文件划分为多个时间片段,并分别对每一个时间片段的起始一段时长内的视频数据进行缓冲下载;或默认启动播放时按照正常的播放方式缓冲当前视频的最前段,在播放器中设置一分段功能控件,用户可选择该控件,启动分段功能,生成分段指令。
以默认在播放启动时进行分段为例,用户选择某一网络视频进行播放时,根据该视频的网络地址向网络视频的服务器发送请求,获取该视频文件的信息,包括视频的总时长。在分段前为了避免用户等待,终端可先从服务器下载该视频文件的最前段部分的视频数据,对该部分视频数据解析和解码,获得最前端的音视频数据,并通过播放器播放当前视频的最前段。在分段时,根据当前视频的总时长,按照时间划分视频文件,获得多个时间片段,时间片段的数量可预先配置。每一个时间片段的时长可相等,即平均划分各个时间片段;也可将每一个时间片段的时长按照预设规则划分为不等,例如在当前视频的内容比较精彩的部分多划分几个时长较短的时间片段,其他不是很精彩的部分则划分为一个时长较长的时间片段。
步骤S20,从服务器下载并存储每个时间片段起始s秒内的视频数据;
在完成时间片段划分后,终端向服务器发送请求,获取每一个时间片段的前s秒的视频数据,s秒为预设时长,该预设时长小于每一个时间片段的总时长。预设时长可为固定的时间长度,也可以是按照一个时间片段的时长百分比来设定,例如上述将每一个时间片段的时长按照预设规则划分为不等,则针对每一个时间片段的时长Ti,下载每一个时间片段前20%*Ti的视频数据。终端将下载的每个时间片段的前s秒的视频数据存储在终端的内存或磁盘中。
步骤S30,在当前视频的进度条拖动至指定时间点时,确定指定时间点所属的时间片段;
当用户在播放界面上将进度条的进度指示点拖动到指定位置时,终端根据进度指示点所在位置确定对应的时间点,即指定时间点,例如进度条总长度为Lc,对应的时间长度为当前视频的总时长Tc,拖动后进度条的进度指示点所在位置距离进度条起始点的长度为Lb,则指定时间点Tb=Tc*(Lb/Lc)。对于上述划分的每一个时间片段,终端记录有时间片段的起始时间和终止时间,当指定时间点Tb大于或等于第i个时间片段的起始时间、且小于或等于第i个时间片段的终止时间时,指定时间点Tb属于第i个时间片段。
步骤S40,从指定时间点所属的时间片段的起始帧开始播放视频数据。
考虑到在拖动进度条时,可能存在一定的误差,则终端通过播放器播放视频时,无须精确到指定时间点进行播放,可跳转到指定时间点所属的时间片段的起始帧开始播放。由于每个时间片段预先都已经从服务器下载并存储了起始s秒内的视频数据,因此在进度条拖动到指定时间点时,终端无须向服务器请求重新获取指定时间点的视频数据,而是直接将视频跳转到指定时间点所属的时间片段的起始帧播放,减少了等待缓冲的时间,提高了视频播放的响应速度。
如图2所示,图2为本发明网络视频在线播放的方法的第二实施例的流程图。本实施例包括图1所示实施例中的所有步骤,在步骤S40之后还包括:
步骤S50,从服务器下载并存储指定时间点所属的时间片段s秒之后的视频数据。
本实施例由于预先同时下载了多个时间片段的视频数据,为了避免占用过多网速,可在下载完每个时间片段起始s秒内的视频数据后就停止后续下载,如果用户没有拖动进度条,则继续下载当前播放时间点之后的后续视频数据;在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。当视频又跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。这样一来,不会因为下载其他时间片段的视频数据而占用过多网速,有利于指定时间点的后续视频数据。当然,在网速条件允许的情况下,也可以不等到视频跳转,而是在下载完每个时间片段起始s秒内的视频数据后继续下载后续视频数据。
如图3所示,图3为本发明网络视频在线播放的方法的第三实施例的流程图。本实施例包括图1所示实施例中的所有步骤,具体的,步骤S20包括:
步骤S21,获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;
步骤S22,计算每个时间片段起始s秒内的数据帧长度;
步骤S23,向服务器发送第一视频获取请求,第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;
步骤S24,接收并存储服务器根据第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
本实施例以n个时间片段为例,对于第i个时间片段,1≤i≤n,第i个时间片段的起始帧相对于当前视频起始帧的偏移量为Pi,第i个时间片段的起始s秒内的数据帧长度为Zi,终端将Pi和Zi发送给服务器,服务器提取当前视频偏移量Pi至Pi+ Zi的视频数据,并返回给终端。本实施例将时间片段的起始时间转换为数据帧偏移量,将时间长度转换为数据帧长度,并在下载视频数据时,将数据帧偏移量和数据帧长度一并添加到请求中发送给服务器。服务器在提取视频数据时,不是根据时间提取,而是根据数据帧偏移量和数据帧长度提取数据,省略了服务器将时间数据转换为数据帧偏移量和帧长的过程,有利于简化服务器的处理流程,提高下载速度。
如图4所示,图4为本发明网络视频在线播放的方法的第四实施例的流程图。本实施例包括图2所示实施例中的所有步骤,具体的步骤S50包括:
步骤S51,获取指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
步骤S52,向服务器发送第二视频获取请求,第二视频获取请求包括指定时间点所属的时间片段第s秒数据帧对应的偏移量;
步骤S53,接收并存储服务器根据第二视频获取请求获得的指定时间点所属的时间片段s秒之后的视频数据。
本实施例对于第i个时间片段,在视频跳转到第i个时间片段的起始帧开始播放时,由于第i个时间片段起始s秒内的视频数据已预先下载,此时只需要继续下载s秒之后的视频数据。以图3所述实施例的数据为例,第i个时间片段的起始帧相对于当前视频起始帧的偏移量为Pi,第i个时间片段的起始s秒内的数据帧长度为Zi,则第i个时间片段第s秒数据帧相对于当前视频起始帧的偏移量为Pi+ Zi,在继续下载视频数据时,终端将Pi+Zi发送给服务器,服务器提取当前视频偏移量Pi+Zi之后的视频数据,并返回给终端。本实施例在视频跳转播放时,继续下载指定时间点所属的时间片段s秒之后的视频数据,不会因为下载其他时间片段的视频数据而占用过多网速,有利于快速下载指定时间的后续视频数据,同时还将继续下载的起始时间转换为数据帧偏移量,服务器在提取视频数据时,不是根据时间提取,而是根据数据帧偏移量提取数据,省略了服务器将时间数据转换为数据帧偏移量的过程,有利于简化服务器的处理流程,提高下载速度。
如图5所示,图5为本发明网络视频在线播放的方法的第五实施例的流程图。本实施例包括图1所示实施例中的所有步骤,在步骤S40之前还包括:
步骤S60,清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至播放器缓存区。
本实施例在拖动进度条前播放的视频数据的后续数据存储在播放器缓存区内,当用户拖动进度条后,为了播放指定时间点所属的时间片段的视频,终端需清空播放器缓存区的数据,并将已存储的待播放数据提取至播放器缓存区。由于待播放的视频数据预先已经存储在终端的内存或磁盘中,在视频跳转前,终端只需要在本地将视频数据转移到播放器缓存区,无须从服务器下载待播放的视频数据,因此减少了等待缓冲的时间,有利于提高视频播放的响应速度。
如图6所示,图6为本发明网络视频在线播放的装置的实施例的模块示意图。本实施例提到的网络视频在线播放的装置,包括:
分段模块10,用于在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
下载存储模块20,用于从服务器下载并存储每个时间片段起始s秒内的视频数据,s秒为预设时长;
计算模块30,用于在当前视频的进度条拖动至指定时间点时,确定指定时间点所属的时间片段;
播放模块40,用于从指定时间点所属的时间片段的起始帧开始播放视频数据。
本实施例用户通过手机、电脑、电视机、PAD等终端的客户端播放器或网页播放器在线观看网络视频。播放器可默认在当前视频文件启动播放时,就将当前视频文件划分为多个时间片段,并分别对每一个时间片段的起始一段时长内的视频数据进行缓冲下载;或默认启动播放时按照正常的播放方式缓冲当前视频的最前段,在播放器中设置一分段功能控件,用户可选择该控件,启动分段功能,生成分段指令。
以默认在播放启动时进行分段为例,用户选择某一网络视频进行播放时,根据该视频的网络地址向网络视频的服务器发送请求,获取该视频文件的信息,包括视频的总时长。在分段前为了避免用户等待,终端可先从服务器下载该视频文件的最前段部分的视频数据,对该部分视频数据解析和解码,获得最前端的音视频数据,并通过播放器播放当前视频的最前段。在分段时,根据当前视频的总时长,按照时间划分视频文件,获得多个时间片段,时间片段的数量可预先配置。每一个时间片段的时长可相等,即平均划分各个时间片段;也可将每一个时间片段的时长按照预设规则划分为不等,例如在当前视频的内容比较精彩的部分多划分几个时长较短的时间片段,其他不是很精彩的部分则划分为一个时长较长的时间片段。
在完成时间片段划分后,终端向服务器发送请求,获取每一个时间片段的前s秒的视频数据,s秒为预设时长,该预设时长小于每一个时间片段的总时长。预设时长可为固定的时间长度,也可以是按照一个时间片段的时长百分比来设定,例如上述将每一个时间片段的时长按照预设规则划分为不等,则针对每一个时间片段的时长Ti,下载每一个时间片段前20%*Ti的视频数据。终端将下载的每个时间片段的前s秒的视频数据存储在终端的内存或磁盘中。
当用户在播放界面上将进度条的进度指示点拖动到指定位置时,终端根据进度指示点所在位置确定对应的时间点,即指定时间点,例如进度条总长度为Lc,对应的时间长度为当前视频的总时长Tc,拖动后进度条的进度指示点所在位置距离进度条起始点的长度为Lb,则指定时间点Tb=Tc*(Lb/Lc)。对于上述划分的每一个时间片段,终端记录有时间片段的起始时间和终止时间,当指定时间点Tb大于或等于第i个时间片段的起始时间、且小于或等于第i个时间片段的终止时间时,指定时间点Tb属于第i个时间片段。
考虑到在拖动进度条时,可能存在一定的误差,则终端通过播放器播放视频时,无须精确到指定时间点进行播放,可跳转到指定时间点所属的时间片段的起始帧开始播放。由于每个时间片段预先都已经从服务器下载并存储了起始s秒内的视频数据,因此在进度条拖动到指定时间点时,终端无须向服务器请求重新获取指定时间点的视频数据,而是直接将视频跳转到指定时间点所属的时间片段的起始帧播放,减少了等待缓冲的时间,提高了视频播放的响应速度。
进一步的,下载存储模块20还用于,从服务器下载并存储指定时间点所属的时间片段s秒之后的视频数据。
本实施例由于预先同时下载了多个时间片段的视频数据,为了避免占用过多网速,可在下载完每个时间片段起始s秒内的视频数据后就停止后续下载,如果用户没有拖动进度条,则继续下载当前播放时间点之后的后续视频数据;在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。当视频又跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。这样一来,不会因为下载其他时间片段的视频数据而占用过多网速,有利于指定时间点的后续视频数据。当然,在网速条件允许的情况下,也可以不等到视频跳转,而是在下载完每个时间片段起始s秒内的视频数据后继续下载后续视频数据。
进一步的,计算模块30还用于,获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;计算每个时间片段起始s秒内的数据帧长度;
下载存储模块20还用于,向服务器发送第一视频获取请求,第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;接收并存储服务器根据第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
本实施例以n个时间片段为例,对于第i个时间片段,1≤i≤n,第i个时间片段的起始帧相对于当前视频起始帧的偏移量为Pi,第i个时间片段的起始s秒内的数据帧长度为Zi,终端将Pi和Zi发送给服务器,服务器提取当前视频偏移量Pi至Pi+ Zi的视频数据,并返回给终端。本实施例将时间片段的起始时间转换为数据帧偏移量,将时间长度转换为数据帧长度,并在下载视频数据时,将数据帧偏移量和数据帧长度一并添加到请求中发送给服务器。服务器在提取视频数据时,不是根据时间提取,而是根据数据帧偏移量和数据帧长度提取数据,省略了服务器将时间数据转换为数据帧偏移量和帧长的过程,有利于简化服务器的处理流程,提高下载速度。
进一步的,计算模块30还用于,获取指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
下载存储模块20还用于,向服务器发送第二视频获取请求,第二视频获取请求包括指定时间点所属的时间片段第s秒数据帧对应的偏移量;接收并存储服务器根据第二视频获取请求获得的指定时间点所属的时间片段s秒之后的视频数据。
本实施例对于第i个时间片段,在视频跳转到第i个时间片段的起始帧开始播放时,由于第i个时间片段起始s秒内的视频数据已预先下载,此时只需要继续下载s秒之后的视频数据。以图3所述实施例的数据为例,第i个时间片段的起始帧相对于当前视频起始帧的偏移量为Pi,第i个时间片段的起始s秒内的数据帧长度为Zi,则第i个时间片段第s秒数据帧相对于当前视频起始帧的偏移量为Pi+ Zi,在继续下载视频数据时,终端将Pi+Zi发送给服务器,服务器提取当前视频偏移量Pi+Zi之后的视频数据,并返回给终端。本实施例在视频跳转播放时,继续下载指定时间点所属的时间片段s秒之后的视频数据,不会因为下载其他时间片段的视频数据而占用过多网速,有利于快速下载指定时间的后续视频数据,同时还将继续下载的起始时间转换为数据帧偏移量,服务器在提取视频数据时,不是根据时间提取,而是根据数据帧偏移量提取数据,省略了服务器将时间数据转换为数据帧偏移量的过程,有利于简化服务器的处理流程,提高下载速度。
进一步的,播放模块40还用于,清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至播放器缓存区。
本实施例在拖动进度条前播放的视频数据的后续数据存储在播放器缓存区内,当用户拖动进度条后,为了播放指定时间点所属的时间片段的视频,终端需清空播放器缓存区的数据,并将已存储的待播放数据提取至播放器缓存区。由于待播放的视频数据预先已经存储在终端的内存或磁盘中,在视频跳转前,终端只需要在本地将视频数据转移到播放器缓存区,无须从服务器下载待播放的视频数据,因此减少了等待缓冲的时间,有利于提高视频播放的响应速度。
以上所述仅为本发明的优选实施例,并非因此限制本发明的专利范围,凡是利用本发明说明书及附图内容所作的等效结构或等效流程变换,或直接或间接运用在其他相关的技术领域,均同理包括在本发明的专利保护范围内。

Claims (18)

  1. 一种网络视频在线播放的方法,其特征在于,包括步骤:
    在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
    从服务器下载并存储每个时间片段起始s秒内的视频数据,所述s秒为预设时长;
    在当前视频的进度条拖动至指定时间点时,确定所述指定时间点所属的时间片段;
    从所述指定时间点所属的时间片段的起始帧开始播放视频数据。
  2. 如权利要求1所述的网络视频在线播放的方法,其特征在于,所述从指定时间点所属的时间片段的起始帧开始播放视频数据的步骤之后还包括:
    从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据。
  3. 如权利要求1所述的网络视频在线播放的方法,其特征在于,所述从服务器下载并存储每个时间片段起始s秒内的视频数据的步骤包括:
    获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;
    计算每个时间片段起始s秒内的数据帧长度;
    向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;
    接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
  4. 如权利要求2所述的网络视频在线播放的方法,其特征在于,所述从服务器下载并存储每个时间片段起始s秒内的视频数据的步骤包括:
    获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;
    计算每个时间片段起始s秒内的数据帧长度;
    向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;
    接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
  5. 如权利要求2所述的网络视频在线播放的方法,其特征在于,所述从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据的步骤包括:
    获取所述指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
    向所述服务器发送第二视频获取请求,所述第二视频获取请求包括所述指定时间点所属的时间片段第s秒数据帧对应的偏移量;
    接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据。
  6. 如权利要求5所述的网络视频在线播放的方法,其特征在于,所述接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据的步骤之后,所述网络视频在线播放的方法还包括步骤:
    在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。
  7. 如权利要求5所述的网络视频在线播放的方法,其特征在于,所述接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据的步骤之后,所述网络视频在线播放的方法还包括步骤:
    当视频跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。
  8. 如权利要求1所述的网络视频在线播放的方法,其特征在于,所述从指定时间点所属的时间片段的起始帧开始播放视频数据的步骤之前还包括:
    清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
  9. 如权利要求2所述的网络视频在线播放的方法,其特征在于,所述从指定时间点所属的时间片段的起始帧开始播放视频数据的步骤之前还包括:
    清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
  10. 一种网络视频在线播放的装置,其特征在于,包括:
    分段模块,用于在播放启动时或分段指令到达时,将当前视频划分为多个时间片段;
    下载存储模块,用于从服务器下载并存储每个时间片段起始s秒内的视频数据,所述s秒为预设时长;
    计算模块,用于在当前视频的进度条拖动至指定时间点时,确定所述指定时间点所属的时间片段;
    播放模块,用于从所述指定时间点所属的时间片段的起始帧开始播放视频数据。
  11. 如权利要求10所述的网络视频在线播放的装置,其特征在于,所述下载存储模块还用于,从服务器下载并存储所述指定时间点所属的时间片段s秒之后的视频数据。
  12. 如权利要求10所述的网络视频在线播放的装置,其特征在于,所述计算模块还用于,获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;计算每个时间片段起始s秒内的数据帧长度;
    所述下载存储模块还用于,向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
  13. 如权利要求11所述的网络视频在线播放的装置,其特征在于,所述计算模块还用于,获取每个时间片段的起始帧相对于当前视频起始帧的偏移量;计算每个时间片段起始s秒内的数据帧长度;
    所述下载存储模块还用于,向所述服务器发送第一视频获取请求,所述第一视频获取请求包括每个时间片段起始帧对应的偏移量和起始s秒内的数据帧长度;接收并存储所述服务器根据所述第一视频获取请求获得的每个时间片段起始s秒内的视频数据。
  14. 如权利要求11所述的网络视频在线播放的装置,其特征在于,所述计算模块还用于,获取所述指定时间点所属的时间片段第s秒数据帧相对于当前视频起始帧的偏移量;
    所述下载存储模块还用于,向所述服务器发送第二视频获取请求,所述第二视频获取请求包括所述指定时间点所属的时间片段第s秒数据帧对应的偏移量;接收并存储所述服务器根据所述第二视频获取请求获得的所述指定时间点所属的时间片段s秒之后的视频数据。
  15. 如权利要求14所述的网络视频在线播放的方法,其特征在于,所述下载存储模块,还用于在视频跳转到指定时间点所属的时间片段的起始帧播放时,停止下载正在下载的后续视频数据,从指定时间点所属的时间片段s秒之后继续下载后续视频数据。
  16. 如权利要求14所述的网络视频在线播放的方法,其特征在于,所述下载存储模块,还用于当视频跳转到其他时间片段时,则停止下载正在下载的后续视频数据,转为从其他时间片段s秒之后继续下载后续视频数据。
  17. 如权利要求10所述的网络视频在线播放的装置,其特征在于,所述播放模块还用于,清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
  18. 如权利要求11所述的网络视频在线播放的装置,其特征在于,所述播放模块还用于,清空播放器缓存区的数据,将已存储的指定时间点所属的时间片段起始s秒内的视频数据提取至所述播放器缓存区。
PCT/CN2015/090429 2015-06-02 2015-09-23 网络视频在线播放的方法和装置 Ceased WO2016192254A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510295476.7 2015-06-02
CN201510295476.7A CN105681874A (zh) 2015-06-02 2015-06-02 网络视频在线播放的方法和装置

Publications (1)

Publication Number Publication Date
WO2016192254A1 true WO2016192254A1 (zh) 2016-12-08

Family

ID=56946792

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/090429 Ceased WO2016192254A1 (zh) 2015-06-02 2015-09-23 网络视频在线播放的方法和装置

Country Status (2)

Country Link
CN (1) CN105681874A (zh)
WO (1) WO2016192254A1 (zh)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109413443A (zh) * 2017-08-16 2019-03-01 中国移动通信有限公司研究院 一种时移功能的实现方法及装置
CN109547516A (zh) * 2017-09-22 2019-03-29 杭州海康威视系统技术有限公司 播放视频的方法和装置
WO2019196890A1 (en) * 2018-04-11 2019-10-17 Beijing Didi Infinity Technology And Development Co., Ltd. System and method for storing multimedia resources
CN111277903A (zh) * 2018-12-05 2020-06-12 阿里巴巴集团控股有限公司 多媒体资源的播放方法、装置及存储介质
CN115499401A (zh) * 2022-10-18 2022-12-20 康键信息技术(深圳)有限公司 一种播放语音数据的方法、系统、计算机设备及介质

Families Citing this family (20)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106162311A (zh) * 2016-07-21 2016-11-23 青岛海信电器股份有限公司 一种播放网络视频的方法和终端设备
CN107959888B (zh) * 2016-10-14 2019-03-19 视联动力信息技术股份有限公司 一种网页播放器动态更新视频总时长的方法及系统
CN106507181B (zh) * 2016-11-30 2019-11-05 北京酷我科技有限公司 一种获取并存储在线视频数据的方法
US10979331B2 (en) 2017-05-16 2021-04-13 Apple Inc. Reducing startup delays for presenting remote media items
CN107707978B (zh) * 2017-09-28 2021-08-10 惠州Tcl移动通信有限公司 一种视频选择播放的控制方法、移动终端及存储介质
CN108737908B (zh) * 2018-05-21 2021-11-30 腾讯科技(深圳)有限公司 一种媒体播放方法、装置及存储介质
CN110545470A (zh) * 2018-05-29 2019-12-06 北京字节跳动网络技术有限公司 一种媒体文件加载方法、装置及存储介质
CN108833968B (zh) * 2018-05-29 2021-09-07 武汉斗鱼网络科技有限公司 一种缓存视频的方法以及相关设备
CN109194979B (zh) * 2018-10-30 2022-06-17 湖南天鸿瑞达集团有限公司 音视频的处理方法及装置、移动终端、可读存储介质
CN109710707A (zh) * 2018-12-06 2019-05-03 北斗天地股份有限公司 一种大数据轨迹回放的方法及装置
CN111698536B (zh) * 2019-03-15 2023-03-28 瑞昱半导体股份有限公司 视频处理方法与系统
CN110198494B (zh) * 2019-06-28 2021-07-20 广州市百果园信息技术有限公司 一种视频播放方法、装置、设备和存储介质
CN111757144B (zh) * 2020-04-13 2022-03-08 湖南化工职业技术学院(湖南工业高级技工学校) 一种网络计算机多媒体视频播放方法和系统
CN112584255B (zh) * 2020-12-04 2023-05-26 广州虎牙科技有限公司 一种流媒体数据的播放方法、装置、计算机设备和存储介质
CN112929711B (zh) * 2021-01-26 2023-04-28 广州欢网科技有限责任公司 适用于智能电视的短视频feed流动态加载方法及设备
CN113163255B (zh) * 2021-03-31 2022-07-15 成都欧珀通信科技有限公司 视频播放方法、装置、终端及存储介质
CN113271475B (zh) * 2021-04-12 2023-01-10 北京奇艺世纪科技有限公司 一种数据处理方法、系统、电子设备及存储介质
CN114125509B (zh) * 2021-11-30 2024-01-19 深圳Tcl新技术有限公司 一种视频播放方法、装置、电子设备和存储介质
CN116264627B (zh) * 2021-12-15 2025-11-28 北京金山云网络技术有限公司 媒体流切片方法、装置、存储介质以及电子设备
CN114915850B (zh) * 2022-04-22 2023-09-12 网易(杭州)网络有限公司 一种视频播放控制方法、装置、电子设备及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101345852A (zh) * 2008-05-13 2009-01-14 深圳市迅雷网络技术有限公司 一种在线视频片段选播方法和系统
CN101415069A (zh) * 2008-10-22 2009-04-22 清华大学 一种服务器及其在线播放视频的发送方法
US20110191679A1 (en) * 2010-02-02 2011-08-04 Futurewei Technologies, Inc. System and Method for Online Media Preview
CN104244079A (zh) * 2013-06-07 2014-12-24 腾讯科技(深圳)有限公司 一种视频下载方法及装置

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101217638B (zh) * 2007-12-28 2012-10-24 深圳市迅雷网络技术有限公司 视频文件分段下载的方法、系统及装置
CN101695131A (zh) * 2009-10-16 2010-04-14 深圳市五巨科技有限公司 一种移动终端播放在线音视频的方法和装置
CN103024456B (zh) * 2011-09-27 2016-02-24 腾讯科技(深圳)有限公司 一种在线视频播放方法及视频播放服务器

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101345852A (zh) * 2008-05-13 2009-01-14 深圳市迅雷网络技术有限公司 一种在线视频片段选播方法和系统
CN101415069A (zh) * 2008-10-22 2009-04-22 清华大学 一种服务器及其在线播放视频的发送方法
US20110191679A1 (en) * 2010-02-02 2011-08-04 Futurewei Technologies, Inc. System and Method for Online Media Preview
CN104244079A (zh) * 2013-06-07 2014-12-24 腾讯科技(深圳)有限公司 一种视频下载方法及装置

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109413443A (zh) * 2017-08-16 2019-03-01 中国移动通信有限公司研究院 一种时移功能的实现方法及装置
CN109413443B (zh) * 2017-08-16 2021-03-16 中国移动通信有限公司研究院 一种时移功能的实现方法及装置
CN109547516A (zh) * 2017-09-22 2019-03-29 杭州海康威视系统技术有限公司 播放视频的方法和装置
CN109547516B (zh) * 2017-09-22 2022-09-16 杭州海康威视系统技术有限公司 播放视频的方法和装置
WO2019196890A1 (en) * 2018-04-11 2019-10-17 Beijing Didi Infinity Technology And Development Co., Ltd. System and method for storing multimedia resources
CN111277903A (zh) * 2018-12-05 2020-06-12 阿里巴巴集团控股有限公司 多媒体资源的播放方法、装置及存储介质
CN111277903B (zh) * 2018-12-05 2022-09-02 阿里巴巴集团控股有限公司 多媒体资源的播放方法、装置及存储介质
CN115499401A (zh) * 2022-10-18 2022-12-20 康键信息技术(深圳)有限公司 一种播放语音数据的方法、系统、计算机设备及介质

Also Published As

Publication number Publication date
CN105681874A (zh) 2016-06-15

Similar Documents

Publication Publication Date Title
WO2017084311A1 (zh) 单分片视频播放加速方法及装置
WO2015085765A1 (zh) 推送资讯信息的方法和智能终端
WO2019080406A1 (zh) 电视机语音交互方法、语音交互控制装置及存储介质
WO2016192270A1 (zh) 媒体文件的快速启播方法及装置
WO2016091011A1 (zh) 字幕切换方法及装置
WO2017177524A1 (zh) 音视频同步播放的方法及装置
WO2019119771A1 (zh) 语音交互方法、装置及计算机可读存储介质
WO2018018681A1 (zh) 视频节目预览方法及装置
WO2017063368A1 (zh) 视频广告的插播方法及装置
WO2017107378A1 (zh) 基于hls流媒体的视频数据加速下载方法及装置
WO2018032693A1 (zh) 电视显示内容的处理方法、装置及系统
WO2018023926A1 (zh) 电视与移动终端的互动方法及系统
WO2015058570A1 (zh) 自动识别网络运营商以实现数据配置的方法及装置
WO2017036209A1 (zh) 基于智能电视的音频数据播放方法、智能电视及系统
WO2016090991A1 (zh) 流媒体数据的下载方法及装置
WO2016029502A1 (zh) 信号源的切换方法及装置
WO2017016310A1 (zh) 遥控功能数据动态配置的方法和装置
WO2017084301A1 (zh) 音频数据播放方法、装置及智能电视机
WO2019080401A1 (zh) 脚本语句转换方法、装置及计算机可读存储介质
WO2017012419A1 (zh) 流媒体解密方法及装置
WO2017049948A1 (zh) 图片共享方法及装置
WO2017032120A1 (zh) 音频切换时的播放处理方法及装置
WO2017166430A1 (zh) 字幕显示方法及装置
WO2019024472A1 (zh) 数据操作方法、装置及计算机可读存储介质
WO2016090665A1 (zh) 流媒体数据的播放方法及装置

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: 15893906

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 19.04.2018)

122 Ep: pct application non-entry in european phase

Ref document number: 15893906

Country of ref document: EP

Kind code of ref document: A1