CN102857834A - Video progress reading method - Google Patents

Video progress reading method Download PDF

Info

Publication number
CN102857834A
CN102857834A CN2012103425269A CN201210342526A CN102857834A CN 102857834 A CN102857834 A CN 102857834A CN 2012103425269 A CN2012103425269 A CN 2012103425269A CN 201210342526 A CN201210342526 A CN 201210342526A CN 102857834 A CN102857834 A CN 102857834A
Authority
CN
China
Prior art keywords
video
file
time
frame
timestamp
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN2012103425269A
Other languages
Chinese (zh)
Other versions
CN102857834B (en
Inventor
张检
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sichuan Changhong Electric Co Ltd
Original Assignee
Sichuan Changhong Electric 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 Sichuan Changhong Electric Co Ltd filed Critical Sichuan Changhong Electric Co Ltd
Priority to CN201210342526.9A priority Critical patent/CN102857834B/en
Publication of CN102857834A publication Critical patent/CN102857834A/en
Application granted granted Critical
Publication of CN102857834B publication Critical patent/CN102857834B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Television Signal Processing For Recording (AREA)

Abstract

The invention relates to a video progress reading method. The video progress reading method includes extracting timestamp files of different frames in a video file, and combining the different timestamp files to form a time index file according to a time sequence; finding out the corresponding timestamp files in the time index file according to frame time and frame index position on the basis of the input video reading time, and then directly reading video at corresponding addresses in the video file according to frame video positions of the timestamp files. Each timestamp file includes the frame time, the frame index position and the frame video position. Since the video file reading position is found out in the time index file, and content of the position is read directly in the video file, so that video file reading efficiency is increased greatly, time for searching the reading position is shortened, and user experience is improved effectively.

Description

Read the method for video progress
Technical field
The present invention relates to video technique, is the method that reads the video progress concretely.
Background technology
The linear fashion that content in the video file normally increases progressively with the time is stored in equipment or the server.Every frame in the video is all with the regular time stamp, to show the corresponding time of this frame in video reads and plays.It is to compare one by one with the time of reading of input and the timestamp of frame that traditional video reads, until find equal timestamp or from that nearest frame of timestamp.Clearly but when video file was very long, this method that reads of relatively searching one by one needed long time, obviously will reduce the reading efficiency of file, the user video file is carried out random time when reading picture easily to stagnate be exactly this reason.
Summary of the invention
For above-mentioned problem, the invention provides a kind of method that reads the video progress, when reading video file, increase substantially the reading efficiency of file, improve user's experience property.
The present invention reads the method for video progress, comprising:
Settling time index: the timestamp file that extracts each frame in the video file, with each timestamp file makeup time index file in chronological order, in each timestamp file, comprise respectively frame time, frame index position and frame video location, wherein frame time is the timestamp of frame in video file, the address of mapping frame in the time index file, frame index position, the address of frame video location mapping frame in video file;
Load Game: the video according to input reads the time, in the time index file, find corresponding timestamp file by described frame time and frame index position, directly read again the video of corresponding address in the video file according to the frame video location of timestamp file.
Usually the speed that reads index file is more many soon than the speed of reading of content file, therefore set up the time index file with audio video synchronization, obtain video and read the correspondence position of time in video file by reading the time index file, then directly remove to read video file to this position, progressively search in the video file and not be used in, significantly improved thus and searched the time of reading the position, improved reading efficiency.
Concrete, described Load Game comprises:
A. judge in the timestamp file that the video of input reads the difference of time and video zero-time;
B. in the timestamp file take the video zero-time as starting point, be offset backward described difference;
C. read the address of frame in video file of the frame video location mapping of the rear timestamp file of skew;
D. read the corresponding content of address described in the video file.
Preferably, step a is before judging described difference, and the video of judging first input reads the time whether in the video time scope, if would continue to carry out, if not video read termination.
Preferably, step b judges that the frame time of current time stamp file and the video of input read the error of time, if error amount in accuracy rating, then continues to carry out, if greater than accuracy rating, then carry out the position adjustment according to error amount after the described difference of skew.
On above-mentioned basis, the described a kind of optional method that carries out the position adjustment according to error amount is: the point centered by the position of current time stamp file of circulation, plus or minus according to error amount, corresponding left or right avertence shift error value 1/2 after, the frame time that reads again current time stamp file carries out describedly reading the error judgment of time with video, until described error amount is in accuracy rating.Adopting the span of 1/2 error amount to adjust, is to set according to the searching algorithm of " dichotomy ", also can adjust according to other span, and for example 1/3 error amount is offset etc. frame by frame.
Preferably, described video file is the video file, and method of the present invention is not suitable for using at real-time video.
The method that reads the video progress of the present invention, by find the position of reading video file at the time index file, then on video file, directly read the content of this position, significantly improved the efficient that reads video file, shortened and searched the time of reading the position, effectively raised user's experience property.
Below in conjunction with the embodiment of embodiment, foregoing of the present invention is described in further detail again.But this should be interpreted as that the scope of the above-mentioned theme of the present invention only limits to following example.Do not breaking away from the above-mentioned technological thought situation of the present invention, various replacements or change according to ordinary skill knowledge and customary means are made all should comprise within the scope of the invention.
Embodiment
The present invention reads the method for video progress, comprising:
Settling time index: the timestamp file that extracts each frame in the video file, with each timestamp file makeup time index file in chronological order, in each timestamp file, comprise respectively frame time, frame index position and frame video location, wherein frame time is the timestamp of frame in video file, the address of mapping frame in the time index file, frame index position, the address of frame video location mapping frame in video file;
Load Game:
A. the video of judging input reads time q whether in the video time scope, if would continue to carry out, if not video read termination.
Judge that in the timestamp file of setting up the video of input reads the difference d of time q and video zero-time s;
B. in the timestamp file take video zero-time s as starting point, be offset backward described difference d.The frame time of the current time stamp file after the judgement skew and the video of input read the error of time q, if error amount m in accuracy rating, then continues to carry out; If greater than accuracy rating, point centered by the position of current time stamp file, when error amount m is timing, left 1/2 of offset error value m, when error amount m when negative, to the right 1/2 of offset error value m, read again afterwards the frame time of current time stamp file, with described frame time repeating step b read the error judgment of time with video, until error is in accuracy rating;
C. read the address of frame in video file of the frame video location mapping of timestamp file after skew is finished;
D. read the corresponding content of address described in the video file.
Video file described in the present embodiment is the video file.
Obtain video and read the correspondence position of time in video file by reading the time index file, then directly remove to read video file to this position, progressively search in the video file and not be used in, significantly improved thus and searched the time of reading the position, improved reading efficiency.

Claims (6)

1. read the method for video progress, its feature comprises:
Settling time index: the timestamp file that extracts each frame in the video file, with each timestamp file makeup time index file in chronological order, in each timestamp file, comprise respectively frame time, frame index position and frame video location, wherein frame time is the timestamp of frame in video file, the address of mapping frame in the time index file, frame index position, the address of frame video location mapping frame in video file;
Load Game: the video according to input reads the time, in the time index file, find corresponding timestamp file by described frame time and frame index position, directly read again the video of corresponding address in the video file according to the frame video location of timestamp file.
2. the method that reads the video progress as claimed in claim 1, it is characterized by: described Load Game comprises:
A. judge in the timestamp file that the video of input reads the difference of time and video zero-time;
B. in the timestamp file take the video zero-time as starting point, be offset backward described difference;
C. read the address of frame in video file of the frame video location mapping of the rear timestamp file of skew;
D. read the corresponding content of address described in the video file.
3. the method that reads the video progress as claimed in claim 2 is characterized by: step a is before judging described difference, and the video of judging first input reads the time whether in the video time scope, if would continue to carry out, if not video read termination.
4. the method that reads the video progress as claimed in claim 2, it is characterized by: step b is after the described difference of skew, judge that the frame time of current time stamp file and the video of input read the error of time, if error amount is in accuracy rating, then continue to carry out, if greater than accuracy rating, then carry out the position adjustment according to error amount.
5. the method that reads the video progress as claimed in claim 4, it is characterized by: describedly carry out the position according to error amount and be adjusted into: the point centered by the position of current time stamp file of circulation, plus or minus according to error amount, corresponding left or right avertence shift error value 1/2 after, the frame time that reads again current time stamp file carries out describedly reading the error judgment of time with video, until described error amount is in accuracy rating.
6. such as the described method that reads the video progress of one of claim 1 to 5, it is characterized by: described video file is the video file.
CN201210342526.9A 2012-09-17 2012-09-17 Read the method for video progress Expired - Fee Related CN102857834B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210342526.9A CN102857834B (en) 2012-09-17 2012-09-17 Read the method for video progress

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210342526.9A CN102857834B (en) 2012-09-17 2012-09-17 Read the method for video progress

Publications (2)

Publication Number Publication Date
CN102857834A true CN102857834A (en) 2013-01-02
CN102857834B CN102857834B (en) 2016-06-15

Family

ID=47403960

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210342526.9A Expired - Fee Related CN102857834B (en) 2012-09-17 2012-09-17 Read the method for video progress

Country Status (1)

Country Link
CN (1) CN102857834B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104918120A (en) * 2014-03-12 2015-09-16 联想(北京)有限公司 Playing progress adjustment method and electronic apparatus
CN105657427A (en) * 2016-01-25 2016-06-08 成都国铁电气设备有限公司 High-definition image compression method and system suitable for catenary
CN112558873A (en) * 2020-12-14 2021-03-26 上海创米科技有限公司 Embedded audio and video data storage, retrieval and deletion method and device and memory

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101217638A (en) * 2007-12-28 2008-07-09 深圳市迅雷网络技术有限公司 A downloading method, system and device of video file fragmentation
CN101325681A (en) * 2008-07-25 2008-12-17 北京声迅电子有限公司 Method for storing AVS encoding file format for video recorder and video server
CN101873355A (en) * 2010-06-28 2010-10-27 深圳市迅雷网络技术有限公司 Method, device and system for downloading file
CN102131106A (en) * 2010-12-22 2011-07-20 华为技术有限公司 Method, device and system for playing streaming media contents
CN102510519A (en) * 2011-10-11 2012-06-20 成都市华为赛门铁克科技有限公司 Streaming media data processing method, playing method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101217638A (en) * 2007-12-28 2008-07-09 深圳市迅雷网络技术有限公司 A downloading method, system and device of video file fragmentation
CN101325681A (en) * 2008-07-25 2008-12-17 北京声迅电子有限公司 Method for storing AVS encoding file format for video recorder and video server
CN101873355A (en) * 2010-06-28 2010-10-27 深圳市迅雷网络技术有限公司 Method, device and system for downloading file
CN102131106A (en) * 2010-12-22 2011-07-20 华为技术有限公司 Method, device and system for playing streaming media contents
CN102510519A (en) * 2011-10-11 2012-06-20 成都市华为赛门铁克科技有限公司 Streaming media data processing method, playing method and device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104918120A (en) * 2014-03-12 2015-09-16 联想(北京)有限公司 Playing progress adjustment method and electronic apparatus
CN104918120B (en) * 2014-03-12 2019-03-29 联想(北京)有限公司 A kind of playback progress adjusting method and electronic equipment
CN105657427A (en) * 2016-01-25 2016-06-08 成都国铁电气设备有限公司 High-definition image compression method and system suitable for catenary
CN112558873A (en) * 2020-12-14 2021-03-26 上海创米科技有限公司 Embedded audio and video data storage, retrieval and deletion method and device and memory
US11250888B1 (en) 2020-12-14 2022-02-15 Shanghai Imilab Technology Co., Ltd. Flash memory and method for storing and retrieving embedded audio video data

Also Published As

Publication number Publication date
CN102857834B (en) 2016-06-15

Similar Documents

Publication Publication Date Title
CN106162293B (en) A kind of method and device of video sound and image synchronization
TWI672044B (en) Subtitle data processing method and system
BR112014024849A8 (en) low delay video buffering in video encoding
CN102857834A (en) Video progress reading method
RU2011139997A (en) DIFFERENT FILE AND SYSTEM RECOVERY FROM SINGLE-RANGE NETWORKS AND GLOBAL NETWORKS
WO2013028824A3 (en) Storing and reading multiplexed content
GB201214349D0 (en) Image capture for later refocusing or focus-manipulation
CN105611428A (en) Video evidence preserving and verifying method and device
MY170276A (en) Method and system for synchronizing operations of multiple groups
WO2016026407A3 (en) System and method for metadata enhanced inventory management of a communications system
RU2016114565A (en) INFORMATION PROCESSING DEVICE, METHOD AND PROGRAM
CA2931525C (en) Data stream identifying method and device
CN104581193A (en) Generation method of highlight live video
CN103605772A (en) Multimedia file playing control method and player
US20150227587A1 (en) Method and apparatus for searching node by using tree index
CN106649722A (en) Storing and inquiring method for high-frequency data of monitoring system
CN102375890A (en) Data synchronization method for source terminal table of database without major key
CN105657246A (en) Time-lapse photographing method and apparatus
CN104778252A (en) Index storage method and index storage device
CN103064935B (en) A kind of multi-medium data parallel processing system (PPS) and method
CN104535827A (en) Defective point removing method and system used in AD sampling
CN103024605A (en) Cloud transcoding method and system for video files
TW200636674A (en) Gamma correction system and method thereof
US20150363426A1 (en) Method and Device for Recording System Log
CN102647622B (en) Play progress management method for streaming media clip and play progress management system for streaming media clip

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20160615

Termination date: 20180917