CN107872716A - A streaming data analysis method, device and electronic equipment with post-packaging - Google Patents
A streaming data analysis method, device and electronic equipment with post-packaging Download PDFInfo
- Publication number
- CN107872716A CN107872716A CN201610846684.6A CN201610846684A CN107872716A CN 107872716 A CN107872716 A CN 107872716A CN 201610846684 A CN201610846684 A CN 201610846684A CN 107872716 A CN107872716 A CN 107872716A
- Authority
- CN
- China
- Prior art keywords
- data
- rearmounted
- index
- frame
- encapsulation
- 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
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/80—Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
- H04N21/85—Assembly of content; Generation of multimedia applications
- H04N21/854—Content authoring
- H04N21/8547—Content authoring involving timestamps for synchronizing content
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing 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/434—Disassembling of a multiplex stream, e.g. demultiplexing audio and video streams, extraction of additional data from a video stream; Remultiplexing of multiplex streams; Extraction or processing of SI; Disassembling of packetised elementary stream
- H04N21/4345—Extraction or processing of SI, e.g. extracting service information from an MPEG stream
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/40—Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
- H04N21/43—Processing 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/439—Processing of audio elementary streams
- H04N21/4394—Processing of audio elementary streams involving operations for analysing the audio stream, e.g. detecting features or characteristics in audio streams
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N21/00—Selective content distribution, e.g. interactive television or video on demand [VOD]
- H04N21/80—Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
- H04N21/85—Assembly of content; Generation of multimedia applications
- H04N21/854—Content authoring
- H04N21/85406—Content authoring involving a specific file format, e.g. MP4 format
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Computer Security & Cryptography (AREA)
- Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)
Abstract
Embodiments of the invention disclose a kind of stream data analytic method, device and the electronic equipment of rearmounted encapsulation, are related to data analytic technique, can lift streaming analyzing efficiency.The stream data analytic method of the rearmounted encapsulation includes:It is determined that the data in the file received are the stream data using rearmounted encapsulation;The information of the preceding first threshold byte of the stream data of the rearmounted encapsulation is parsed, obtains atomic structure information;The information of Second Threshold byte after extracting in atomic structure information, obtains type structure information, and the first threshold is twice of the Second Threshold;It is determined that the type structure message identification be index structure after, the data of request are parsed according to the index structure.The stream data that the present invention is applied to the rearmounted encapsulation of MP4 is parsed.
Description
Technical field
The present invention relates to data analytic technique, more particularly to a kind of stream data analytic method of rearmounted encapsulation, device and
Electronic equipment.
Background technology
MP4 is a set of for audio, the compression and coding standard of video information, by International Organization for standardization (ISO) and the world
The dynamic image expert group (MPEG, Moving Picture ExpertsGroup) of the electrician committee (IEC) subordinate is formulated, MP4
File is a kind of media file being packaged based on ISO/IEC 14496-12 standards, is encapsulated compared to using other encapsulation format
Media file, for example, the media file such as RMVB, AVI, FLV, WMV, MKV, MP4 files have higher practicality and popularization
Property, thus be widely used.
Include in order to apply in different scenes, the encapsulation format of MP4 files:The preposition encapsulation of MP4-, MP4- are rearmounted
Encapsulation, MP4-H5 encapsulation and MP4-DASH encapsulation.Wherein, the rearmounted encapsulation of MP4- is mainly used in file data scene, less
Applied to stream data scene, MP4-H5 encapsulation and MP4-DASH encapsulation are mainly used in stream data scene, the preposition envelopes of MP4-
Dress both can apply to file data scene, can be used for stream data scene.For file data scene, in client pair
When the MP4 files (data) of encapsulation are parsed, the file handle in MP4 files (data) that can be by obtaining encapsulation, profit
Searched for and indexed with file handle, realize the positioning and parsing to data according to index, and commence play out from the data of positioning.For
Stream data scene, because the index of the preposition encapsulation of MP4-, MP4-H5 encapsulation and MP4-DASH encapsulation (refers in particular to MOOV or MOOF
Box structures, the structure specify that the important informations such as specific codec parameters, frame length, vertical shift, frame time stamp, frame position)
Before load data, when carrying out streaming parsing, indexed by obtaining, the load data of foundation index parsing below,
It is not in the sequential logic problem in parsing;But for the rearmounted encapsulation of MP4-, it is located at due to indexing behind load data, because
And when client is parsed, it is necessary to by target MP4 files (data) download and store into caching, carry out in the buffer
Parsing, but this method after whole target MP4 file downloads, it is necessary to will could be parsed, longer the time required to parsing, stream
Formula analyzing efficiency is relatively low;Further, if file destination it is bigger, it is necessary to spatial cache it is also bigger, it is necessary to consume substantial amounts of
Memory source;Moreover, when carrying out streaming parsing, because index is behind load data, in fact it could happen that in parsing when
Sequence logical problem, so as to cause streaming parsing failure.
The content of the invention
In view of this, the embodiment of the present invention provides a kind of stream data analytic method, device and the electronics of rearmounted encapsulation and set
It is standby, streaming analyzing efficiency can be lifted, to solve in the stream data analytic method of existing rearmounted encapsulation, it is necessary to by whole mesh
The problem of longer, streaming analyzing efficiency is relatively low the time required to parsing caused by could being parsed after mark MP4 file downloads.
In a first aspect, the embodiment of the present invention provides a kind of stream data analytic method of rearmounted encapsulation, including:
It is determined that the data in the file received are the stream data using rearmounted encapsulation;
The information of the preceding first threshold byte of the stream data of the rearmounted encapsulation is parsed, obtains atomic structure information;
The information of Second Threshold byte, obtains type structure information, the first threshold after extracting in atomic structure information
For twice of the Second Threshold;
It is determined that the type structure message identification be index structure after, the data of request are entered according to the index structure
Row parsing.
With reference in a first aspect, in the first embodiment of first aspect, the data in the file for determining to receive
To be included using the stream data of rearmounted encapsulation:
The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and application
Data in stream data scene, the then file received are the stream data using rearmounted encapsulation.
With reference in a first aspect, in second of embodiment of first aspect, the first threshold is 8, and Second Threshold is
4。
It is described it is determined that the type structure information with reference in a first aspect, in the third embodiment of first aspect
After being identified as index structure, carrying out parsing to the data of request according to the index structure includes:
If the type structure message identification is not index structure, according to preceding Second Threshold in the atomic structure information
The information computation index skew of byte;
From request data at the index offset, and perform preceding the first of the stream data of the parsing rearmounted encapsulation
The step of information of threshold byte;
If the type structure message identification is index structure, the index structure is parsed, is indexed;
Request data, the data of request are parsed according to the index.
It is described according to institute in the 4th kind of embodiment of first aspect with reference to the third embodiment of first aspect
Stating the information computation index skew of preceding Second Threshold byte in atomic structure information includes:
Obtain the reserved index offset of storage;
Length corresponding to the information of the preceding Second Threshold byte is added with the reserved index offset of the storage, obtained
Index offset;
The reserved index offset of the storage is updated using the index offset.
With reference to the 4th kind of embodiment of first aspect, in the 5th kind of embodiment of first aspect, if the class
Type structural information is identified as index structure, and methods described also includes:
The reserved index offset of storage is emptied.
With reference to the third embodiment of first aspect, in the 6th kind of embodiment of first aspect, the number of request
According to carrying out parsing to the data of request according to the index includes:
Obtain and play positioning time point;
Ask the data from the broadcasting positioning time point and parse broadcasting.
With reference to the 6th kind of embodiment of first aspect, in the 7th kind of embodiment of first aspect, the request from
The data for playing positioning time point include:
Frame time stamp in cumulative client in track of video timestamp-frame corresponding table structure box;
From cumulative frame time stamp, obtain and the broadcasting corresponding frame of the immediate frame time stamp of positioning time point
Number;
Using block offset information watchcase of track of video, video vertical shift corresponding to the frame number is inquired about;
Asked to server from the data at the video vertical shift.
With reference to the 7th kind of embodiment of first aspect, in the 8th kind of embodiment of first aspect, the frame of video
Offset as I-frame video vertical shift.
With reference to the 6th kind of embodiment of first aspect, in the 9th kind of embodiment of first aspect, the request from
The data for playing positioning time point include:
According to frame duration and frame naming rule, frame number corresponding to the broadcasting positioning time point is calculated;
Using block offset information watchcase of track of video, video vertical shift corresponding to the frame number is inquired about;
Asked to server from the data at the video vertical shift.
With reference to the 6th kind of embodiment of first aspect, in the tenth kind of embodiment of first aspect, the parsing is broadcast
Put including:
The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P
Frame, if the first frame is I frames, it is pass-through to broadcast layer and plays out;
If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
Second aspect, the embodiment of the present invention provide a kind of stream data resolver of rearmounted encapsulation, including:Rearmounted encapsulation
Determining module, atomic structure parsing module, type structure extraction module and data resolution module, wherein,
Rearmounted encapsulation determining module, the data in file for determining reception are the stream data using rearmounted encapsulation;
Atomic structure parsing module, the letter of the preceding first threshold byte of the stream data for parsing the rearmounted encapsulation
Breath, obtains atomic structure information;
Type structure extraction module, for the information of Second Threshold byte after extracting in atomic structure information, obtain type
Structural information, the first threshold are twice of the Second Threshold;
Data resolution module, for it is determined that the type structure message identification be index structure after, according to the index
Structure parses to the data of request.
With reference to second aspect, in the first embodiment of second aspect, the data in the file for determining to receive
To be included using the stream data of rearmounted encapsulation:
The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and application
Data in stream data scene, the then file received are the stream data using rearmounted encapsulation.
With reference to second aspect, in second of embodiment of second aspect, the first threshold is 8, and Second Threshold is
4。
With reference to second aspect, in the third embodiment of second aspect, the data resolution module includes:Judge single
Member, index offset computing unit, request of data unit, index acquiring unit and data resolution unit, wherein,
Judging unit, for judging whether the type structure message identification is index structure, if it is, notice index obtains
Unit is taken, if it is not, notice index offset computing unit;
Index offset computing unit, rope is calculated for the information according to preceding Second Threshold byte in the atomic structure information
Draw skew;
Request of data unit, for from request data at the index offset, exporting to atomic structure parsing module;
Acquiring unit is indexed, for parsing the index structure, is indexed;
Data resolution unit, for request data, the data of request are parsed according to the index.
With reference to the third embodiment of second aspect, in the 4th kind of embodiment of second aspect, the index is inclined
Moving computing unit includes:Reserved index offset obtains subelement, index offset computation subunit and renewal subelement, wherein,
Reserved index offset obtains subelement, for obtaining the reserved index offset of storage;
Index offset computation subunit, for by length corresponding to the information of the preceding Second Threshold byte and the storage
Reserved index offset be added, obtain index offset;
Subelement is updated, for updating the reserved index offset of the storage using the index offset.
With reference to the 4th kind of embodiment of second aspect, in the 5th kind of embodiment of second aspect, the index is inclined
Moving computing unit also includes:
Empty subelement, for receive judging unit export to index acquiring unit notice after, by the pre- of storage
Index offset is stayed to empty.
With reference to the third embodiment of second aspect, in the 6th kind of embodiment of second aspect, the data solution
Analysis unit includes:Play positioning time point and obtain subelement and parsing broadcasting subelement, wherein,
Play positioning time point and obtain subelement, positioning time point is played for obtaining;
Parsing plays subelement, for asking the data from the broadcasting positioning time point and parsing broadcasting.
With reference to the 6th kind of embodiment of second aspect, in the 7th kind of embodiment of second aspect, the parsing is broadcast
Putting subelement includes:Accumulator, frame number getter, requestor, data requestor and parsing player, wherein,
Accumulator, for the frame time stamp in track of video timestamp in the client that adds up-frame corresponding table structure box;
Frame number getter, for from cumulative frame time stamp, obtaining and the broadcasting positioning time immediate frame of point
Frame number corresponding to timestamp;
Requestor, for block offset information watchcase using track of video, it is inclined to inquire about frame of video corresponding to the frame number
Move;
Data requestor, for being asked to server from the data at the video vertical shift;
Player is parsed, for being played out after the data parsing by request.
With reference to the 7th kind of embodiment of second aspect, in the 8th kind of embodiment of second aspect, the frame of video
Offset as I-frame video vertical shift.
With reference to the 6th kind of embodiment of second aspect, in the 9th kind of embodiment of second aspect, the parsing is broadcast
Putting subelement includes:Frame number calculator, frame of video deviator, data requestor and parsing player, wherein,
Frame number calculator, for according to frame duration and frame naming rule, calculating corresponding to the broadcasting positioning time point
Frame number;
Frame of video deviator, for block offset information watchcase using track of video, inquire about and regarded corresponding to the frame number
Frequency vertical shift;
Data requestor, for being asked to server from the data at the video vertical shift;
Player is parsed, for being played out after the data parsing by request.
With reference to the 6th kind of embodiment of second aspect, in the tenth kind of embodiment of second aspect, the parsing is broadcast
Put including:
The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P
Frame, if the first frame is I frames, it is pass-through to broadcast layer and plays out;
If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
The third aspect, the embodiment of the present invention provide a kind of electronic equipment, and the electronic equipment includes:Housing, processor, deposit
Reservoir, circuit board and power circuit, wherein, circuit board is placed in the interior volume that housing surrounds, and processor and memory are set
On circuit boards;Power circuit, for each circuit or the device power supply for above-mentioned electronic equipment;Memory is used to store and can hold
Line program code;The executable program code that processor is stored by reading in memory is run and executable program code pair
The program answered, for performing the stream data analytic method of foregoing any described rearmounted encapsulation.
Stream data analytic method, device and the electronic equipment of a kind of rearmounted encapsulation provided in an embodiment of the present invention, pass through
It is determined that the data in the file received are the stream data using rearmounted encapsulation;Before the stream data for parsing the rearmounted encapsulation
The information of first threshold byte, obtain atomic structure information;The information of Second Threshold byte, is obtained after extracting in atomic structure information
To type structure information, the first threshold is twice of the Second Threshold;It is determined that the type structure message identification is
After index structure, the data of request are parsed according to the index structure, streaming analyzing efficiency can be lifted, it is existing to solve
, it is necessary to will could be parsed after whole target MP4 file downloads in the stream data analytic method for the rearmounted encapsulation having
The problem of longer, streaming analyzing efficiency is relatively low the time required to caused parsing.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to embodiment or existing
There is the required accompanying drawing used in technology description to be briefly described, it should be apparent that, drawings in the following description are only this
Some embodiments of invention, for those of ordinary skill in the art, on the premise of not paying creative work, can be with
Other accompanying drawings are obtained according to these accompanying drawings.
Fig. 1 is the stream data analytic method schematic flow sheet of one rearmounted encapsulation of embodiments of the invention;
Fig. 2 is existing play operation schematic diagram;
Fig. 3 is the play operation schematic diagram of the present embodiment;
Fig. 4 is the stream data analytic method schematic flow sheet of two rearmounted encapsulation of embodiments of the invention;
Fig. 5 is the stream data analytic method schematic flow sheet of three rearmounted encapsulation of embodiments of the invention;
Fig. 6 is the stream data resolver structural representation of four rearmounted encapsulation of embodiments of the invention;
Fig. 7 is the structural representation of electronic equipment one embodiment of the present invention.
Embodiment
The embodiment of the present invention is described in detail below in conjunction with the accompanying drawings.
It will be appreciated that described embodiment is only part of the embodiment of the present invention, rather than whole embodiments.Base
Embodiment in the present invention, those of ordinary skill in the art obtained under the premise of creative work is not made it is all its
Its embodiment, belongs to the scope of protection of the invention.
Fig. 1 is the stream data analytic method schematic flow sheet of one rearmounted encapsulation of embodiments of the invention, as shown in figure 1,
The method of the present embodiment can include:
Step 101, it is determined that the data in the file received are the stream data using rearmounted encapsulation;
In the present embodiment, as an alternative embodiment, it is determined that the data in the file received are the stream using rearmounted encapsulation
Formula data include:
The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and application
Data in stream data scene, the then file received are the stream data using rearmounted encapsulation.
In the present embodiment, for MP4 files, according to the regulation of ISO/IEC 14496-12 standards, using MP4 encapsulation format
File or data with file type box (FTYP Box, File Type Box) structure as initial structure, files classes flask
Attached bag contains file type (FTYP, File Type) field, and this document type field is located at the original position of file, for marking
Know MP4 forms.
In the present embodiment, if the file type field mark of parsing for the rearmounted encapsulation of MP4- and is not applied to stream data
Scene, then handled according to prior art flow.
Step 102, the information of the preceding first threshold byte of the stream data of the rearmounted encapsulation is parsed, obtains atomic structure
Information;
In the present embodiment, as an alternative embodiment, first threshold 8.
In the present embodiment, the media file of the rearmounted encapsulation of MP4- is used as a MDAT (data)+MOOV (index) structure,
Wherein, MOOV is to index, and is a rope for including the information such as codec parameters, frame time stamp, vertical shift, frame length, frame position
Guiding structure, MDAT (Media Data) is multi-medium data, i.e. the encapsulating structure of load data (uncorrected data).
According to the regulation of ISO/IEC 14496-12 standards and definition, no matter which kind of encapsulating structure, can all follow substantially former
The description of minor structure, i.e., in preceding 8 byte of a stream data (frame), using the atom for including length structure and type structure
Structure describing mode, wherein, preceding 4 byte is length structure, and identification load data (length of MDAT data), rear 4 byte is class
Type structure, identify the type of the stream data (frame).Thus, in the present embodiment, by the atom knot for obtaining stream data (frame)
Structure information, it can be determined whether using atomic structure information for index.
Step 103, the information of Second Threshold byte, obtains type structure information after extracting in atomic structure information, described
First threshold is twice of the Second Threshold;
In the present embodiment, as an alternative embodiment, first threshold 8, Second Threshold 4.
Step 104, it is determined that the type structure message identification be index structure after, according to the index structure to request
Data parsed.
In the present embodiment, index is the foundation and key for carrying out stream data parsing, due to the index of the rearmounted encapsulation of MP4-
Behind load data, thus so that prior art is needed after all having received stream data, could be solved in the buffer
Analysis, causes to parse that the required time is longer, streaming analyzing efficiency is relatively low.Thus, if it is possible to quick obtaining indexes, and will directly carry
Up-flow analyzing efficiency.
In the present embodiment, by parsing 8 bytes before data, atomic structure information is obtained, and utilize atomic structure information
In the type structure information of rear 4 byte judge whether current structure is required index (MOOV Box) structure, if
Type structure information shows that current structure is not index structure, then the length type that can be indicated according to preceding 4 byte notifies service
Device skips the atomic structure of current non-index structure, i.e., using the type structure of rear 4 bytes in atomic structure information, judges such
Whether type structure is index structure, if it is not, the length information (load data length) of the length structure instruction according to preceding 4 sections
Skip the structure so that server skips the stream data of the length information, untill jumping to type structure as index structure,
Without the length data of conveying length type identification, without being parsed to the length data, effectively reduce needed for parsing
Time, lifting streaming analyzing efficiency.
In the present embodiment, as an alternative embodiment, after it is determined that the type structure message identification is index structure, according to
Carrying out parsing to the data of request according to the index structure includes:
A11, if the type structure message identification is not index structure, according in the atomic structure information preceding second
The information computation index skew of threshold byte;
In the present embodiment, the information of preceding Second Threshold byte is the length structure in atomic structure information, instruction load number
According to length.
In the present embodiment, as an alternative embodiment, the letter according to preceding Second Threshold byte in the atomic structure information
Breath computation index skew includes:
B11, obtain the reserved index offset of storage;
In the present embodiment, if not being stored with reserved index offset in the memory block pre-set, the pre- of storage is set
It is zero to stay index offset.
B12, length corresponding to the information of the preceding Second Threshold byte is added with the reserved index offset of the storage,
Obtain index offset;
In the present embodiment, if being currently not MOOV Box structures, computation index skew:With the data length parsed
Plus the length of current atomic structure, server is sent to after obtaining the data length for needing to offset.Server can be from request
Starting to send data at deviation post corresponding to the data length of skew, client continues to analyze after getting new data, then
Secondary to judge whether current structure is MOOV Box, so circulation is gone down, until document analysis terminates or found MOOV Box.Example
Such as, it is assumed that for the first time parse after 4 bytes field type structure, if it is determined that be not index structure, then according to before 4 bytes length
Information is spent, the data that notice server skips the length information are transmitted again, and then are sentenced according to preceding 8 bytes sent
It is disconnected, if the field type structure of rear 4 byte is not also index structure, the data-bias of this time is calculated, i.e. the last time skips
Data length is with specifically needing the data length sum skipped.
B13, the reserved index offset of the storage is updated using the index offset.
A12, from request data at the index offset, and before performing the stream data of the parsing rearmounted encapsulation
The step of information of first threshold byte;
In the present embodiment, notice server skips the stream data of the load data length of length structure instruction, i.e., from meter
Start to transmit stream data at obtained index offset, and for the stream data before index offset, without transmission.
A13, if the type structure message identification is index structure, the index structure is parsed, is indexed;
In the present embodiment, index (MOOV Box) includes:Codec parameters, frame length, vertical shift, frame time stamp, framing bit
The information such as put.Obtain index, it is possible to realize the parsing of streaming data, i.e., after client receives MOOV Box, just
Streaming parsing can be carried out.
In the present embodiment, as an alternative embodiment, if the type structure message identification is index structure, this method
Also include:
The reserved index offset of storage is emptied.
A14, request data, the data of request are parsed according to the index.
In the present embodiment, as an alternative embodiment, request data, the data of request are parsed according to the index
Including:
C11, obtain and play positioning time point;
In the present embodiment, user can choose in playing process and play positioning time point, and it is fixed can not also to choose broadcasting
At position time point, played out from default time point.
In the present embodiment, as an alternative embodiment, obtaining broadcasting positioning time point includes:
Obtain the positioning action location point that user is carried out on the player progress bar of client;
According to total reproduction time, progress bar total length and current positioning action location point, calculate and play positioning time point.
In the present embodiment, the broadcasting positioning time point being calculated is a positioning timestamp.
C12, ask the data from the broadcasting positioning time point and parse broadcasting.
In the present embodiment, as an alternative embodiment, the data from the broadcasting positioning time point are asked to include:
D11, add up client in track of video timestamp-frame corresponding table structure box (STTS Box, TimetoSample
Box the frame time stamp in);
D12, from cumulative frame time stamp, obtain corresponding with the broadcasting immediate frame time stamp of positioning time point
Frame number;
In the present embodiment, the frame time in STTS Box texture fields is stabbed and added up one by one according to linked list order, until frame
Timestamp sum, which reaches, plays positioning time point, obtains frame number corresponding to last accumulated frame time stamp.
In the present embodiment, for the first frame of multi-medium data, significant figure is only by the media data started of I frames
According to (complete picture can not be independently presented in B/P frames, can cause Huaping phenomenon), thus, in the present embodiment, as an optional implementation
Example, frame number is I frame frame numbers.I.e. from cumulative frame time stamp, when obtaining I frames frame immediate with the broadcasting positioning time point
Between stamp corresponding to I frame frame numbers.Specifically, it is synchronized samples watchcase is sub (STSS Box, Sync Sample Box), i.e., all I
I frames frame number in frame frame number record sheet is specific timestamp by STTS Box thaumatropies, and order compares the time of conversion
Stamp with play positioning time point, choose with play a positioning time point immediate timestamp (an i.e. hithermost I frame, therefore
Error is up to a GOP duration, and minimum 0, half of GOP duration of average out to), the timestamp is restored into back I frame frame numbers, and
The skew corresponding to frame of video I frame frame numbers is searched in STCO Box.
D13, it is sub (STCO Box, Chunk Offset Box) using the block offset information watchcase of track of video, inquire about institute
State video vertical shift corresponding to frame number;
In the present embodiment, as an alternative embodiment, video vertical shift is I-frame video vertical shift.
In the present embodiment, for audio-visual synchronization, audio will also look for corresponding data, directly search audio STCOBox, obtain
First skew more than the video vertical shift is taken, obtains audio offset.
D14, asked to server from the data at the video vertical shift.
In the present embodiment, STCO Box are the offset information table of each sample (frame) relative file head.
In the present embodiment, user carries out positioning action on the player progress bar of client, can according to total reproduction time,
Progress bar total length and current anchor point position pro rata calculate a positioning timestamp, and the timestamp passes through cumulative in client
Track of video (only with reference to frame of video, the calculating of other track frames will be with current video frame synchronization for the calculating of timestamp) STTS Box
In frame time stamp, obtain closest to the positioning time stamp frame number, then by the STCO Box of track of video, search this
Skew (skew is accurate video vertical shift), is finally sent to server, server by the shift value corresponding to frame number
Data at the request skew are returned to client, client subsequently according to the index being previously obtained carry out uncorrected data parsing and
Play.
In the present embodiment, as another alternative embodiment, the data from the broadcasting positioning time point are asked to include:
E11, according to frame duration and frame naming rule, calculate frame number corresponding to the broadcasting positioning time point;
E12, it is sub (STCO Box, Chunk Offset Box) using the block offset information watchcase of track of video, inquire about institute
State video vertical shift corresponding to frame number;
E13, asked to server from the data at the video vertical shift.
In the present embodiment, audio STCO Box are searched, first skew more than the video vertical shift is obtained, obtains sound
Frequency deviation is moved.
In the present embodiment, as an alternative embodiment, parsing broadcasting includes:
The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P
Frame, if the first frame is I frames, it is pass-through to broadcast layer and plays out;
If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
In the present embodiment, if above-mentioned frame number is I frame frame numbers, the data of analysis request, the first frame is I frames, transparent transmission
To broadcast layer;If frame number is not I frame frame numbers, the data of analysis request, the first frame can be I frames, or B
Frame, can also be P frames.Because in the first frame, complete picture can not be independently presented in B frames or P frames, can cause Huaping phenomenon,
Only valid data are only by the media data started of I frames.In the present embodiment, by adding nearest I frames in position fixing process
Location mechanism, that is, position I frame frame numbers;And the first frame treatment mechanism is provided in analytic sheaf, it can not only mitigate top level control layer
Load, and the broadcast time-delay of average half of GOP duration can be improved.
Fig. 2 is existing play operation schematic diagram.Referring to Fig. 2, exemplified by playing positioning time point T2, in play operation,
Accurate frame (T1 time points) data order played corresponding to positioning time point can be input to key-course by the analytic sheaf of bottom, by
Key-course carries out the filtering of valid data, i.e. invalid frame data before I frames are all lost, shown in figure between T1 to T4
Data, the data finally really commenced play out are the I frames at T4 time points.So, invalid data between T1 to T4 is not only generated
Parsing (request, send, receive, parsing, filtering etc.) delay, and play total duration reduce (T4-T1) duration.
Fig. 3 is the play operation schematic diagram of the present embodiment.Referring to Fig. 3, exemplified by playing positioning time point T2, the present embodiment
In, it is nearest to be played positioning time point T1 by using the positioning action of nearest I positioning mechanism frames by the analytic sheaf of bottom for distance
I frame times point TO and data afterwards are directly transparent to broadcast layer, and key-course need not carry out the filtering of valid data again, completely
The delay of transmission, reception and the parsing of invalid data is avoided, and 1 is had more compared to traditional targeting scheme by total duration is played
GOP durations (T4-T1+T1-T0=T4-T0), can enable client to play valid data, Neng Gouyou within the most short time
Effect avoids producing Huaping phenomenon, mitigates top level control logic load, mean error is half of image sets (GOP, Group Of
Picture) duration, wherein, GOP refers to I frames and relies on other frames of the I frame decodings behind.
Fig. 4 is the stream data analytic method schematic flow sheet of two rearmounted encapsulation of embodiments of the invention, as shown in figure 4,
The method of the present embodiment can include:
Step 401, server sends data to client;
In the present embodiment, the data that server is sent are the stream data (file) of the rearmounted encapsulation of MP4-.
Step 402, client location index position, the data of index offset (offset1) are asked to server;
Step 403, server sends data at index offset, and client parsing obtains index;
Step 404, client carries out positioning action, calculates video vertical shift corresponding to positioning action, is asked to server
The data of video vertical shift (offset2);
Step 405, server sends data, client parsing data at video vertical shift.
Fig. 5 is the stream data analytic method schematic flow sheet of three rearmounted encapsulation of embodiments of the invention, as shown in figure 5,
The method of the present embodiment can include:
Step 501, parsing receives the file type of data;
In the present embodiment, file type (FTYP, File Type) is located at the original position of file, for identifying MP4 lattice
Formula, if the rearmounted encapsulation of MP4-, perform step 502.
Step 502, non-MOOV length is parsed;
In the present embodiment, non-MOOV length is atomic structure information, if the type information in atomic structure information shows
It is not index structure, performs step 503.
Step 503, computation index is offset;
In the present embodiment, calculated according to the length structure information in atomic structure information and the reserved index offset of storage
Index offset.
Step 504, data at index offset are asked;
Step 505, determine whether MOOV Box, step 502 is performed if it is not, returning, if it is, performing step
506;
Step 506, parsing index;
Step 507, if need to position, if it is, step 508 is performed, if it is not, performing step 512;
In the present embodiment, after carrying out positioning action, the data of user end to server request are valid data, that is, load number
According to.
Step 508, shift to new management mechanisms and handled according to the skew pre-set;
In the present embodiment, skew is shifted to new management mechanisms as nearest I positioning mechanism frames.
Step 509, request data;
In the present embodiment, foundation positions obtained video vertical shift request data.
Step 510, data are parsed;
In the present embodiment, the media data that parsing data refer to be packaged goes to encapsulate or decapsulated, and is allowed to as naked stream
Data.
Step 511, the last frame of data is determined whether, if it is, terminating flow, if it is not, return to step
507;
Step 512, order obtains data, performs step 510.
The stream data analytic method of the rearmounted encapsulation of the present embodiment, the data in file by determining reception are after using
Put the stream data of encapsulation;The information of the preceding first threshold byte of the stream data of the rearmounted encapsulation is parsed, obtains atom knot
Structure information;The information of Second Threshold byte, obtains type structure information, the first threshold is after extracting in atomic structure information
Twice of the Second Threshold;It is determined that the type structure message identification be index structure after, according to the index structure pair
The data of request are parsed.So, type structure information judgement is carried out by atomic structure information, can effectively obtains rope
Draw, without whole target MP4 file downloads are finished, it is possible to achieve the parsing to MP4 files, short, streaming the time required to parsing
Analyzing efficiency is high;Simultaneously, it is necessary to which the data of caching are smaller, memory source consumption is low;, can be with moreover, indexed by quick obtaining
The sequential logic problem in parsing is avoided the occurrence of, power is parsed into so as to improve streaming.Specifically, it is a kind of fast by proposing
Fast, accurate and effective streaming parsing and location mechanism, have following advantageous effects:
1, quick obtaining index.Wherein, obtaining index includes:It is determined that the deviation post and the complete rope of acquisition of index
Draw, wherein,
It is determined that the deviation post of index, the media file of the rearmounted encapsulation of MP4- is a MDAT (data)+MOOV's (index)
Structure, wherein, MOOV is to index, and MDAT (Media Data) is multi-medium data, i.e. the encapsulation of load data (uncorrected data)
Structure.By the length field in MDAT fields, the length of load data is obtained, then notifies server to skip the number of the length
It is believed that breath, until jumping to MOOV, after client receives MOOV, it is possible to carry out streaming parsing, so, can quickly determine
The deviation post of index.
It is small more compared to for load data due to indexing it is determined that after the deviation post of index, therefore, it is possible to quickly obtain
Complete index is taken, for user, it is short to carry out the response time that streaming parsing needs wait.
2, accurately.Shifted to new management mechanisms during positioning action using timestamp (or frame number)-skew, provide the user frame number and time
Two kinds of regioselective schemes are stabbed, client request is accurate data offset locations, can avoid redundant data parsing institute band
The extra time-consuming and wait come;
3, effectively.Nearest I positioning mechanism frames are used during positioning action, client can be enabled to be broadcast within the most short time
Valid data are put, i.e., the data using I frames as beginning, can effectively avoid producing Huaping phenomenon, mitigate top level control logic burden.
Fig. 6 is the stream data resolver structural representation of four rearmounted encapsulation of embodiments of the invention, as shown in fig. 6,
The device of the present embodiment can include:Rearmounted encapsulation determining module 61, atomic structure parsing module 62, type structure extraction module
63 and data resolution module 64, wherein,
Rearmounted encapsulation determining module 61, the data in file for determining reception are the streaming number using rearmounted encapsulation
According to;
In the present embodiment, as an alternative embodiment, it is determined that the data in the file received are the stream using rearmounted encapsulation
Formula data include:
The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and application
Data in stream data scene, the then file received are the stream data using rearmounted encapsulation.
In the present embodiment, if the file type field mark of parsing for the rearmounted encapsulation of MP4- and is not applied to stream data
Scene, then handled according to prior art flow.
Atomic structure parsing module 62, the letter of the preceding first threshold byte of the stream data for parsing the rearmounted encapsulation
Breath, obtains atomic structure information;
Type structure extraction module 63, for the information of Second Threshold byte after extracting in atomic structure information, obtain class
Type structural information, the first threshold are twice of the Second Threshold;
In the present embodiment, as an alternative embodiment, first threshold 8, Second Threshold 4.
In the present embodiment, preceding 4 byte is length structure, and identification load data (length of MDAT data), rear 4 byte is class
Type structure, identify the type of the stream data (frame).Thus, in the present embodiment, by the atom knot for obtaining stream data (frame)
Structure information, it can be determined whether using atomic structure information for index.
Data resolution module 64, for it is determined that the type structure message identification be index structure after, according to the rope
Guiding structure parses to the data of request.
In the present embodiment, by parsing 8 bytes before data, atomic structure information is obtained, and utilize atomic structure information
In the type structure information of rear 4 byte judge whether current structure is required index (MOOV Box) structure, if
Type structure information shows that current structure is not index structure, then the length type that can be indicated according to preceding 4 byte notifies service
Device skips the atomic structure of current non-index structure.
In the present embodiment, as an alternative embodiment, data resolution module 64 includes:Judging unit, index offset calculate
Unit, request of data unit, index acquiring unit and data resolution unit (not shown), wherein,
Judging unit, for judging whether the type structure message identification is index structure, if it is, notice index obtains
Unit is taken, if it is not, notice index offset computing unit;
Index offset computing unit, rope is calculated for the information according to preceding Second Threshold byte in the atomic structure information
Draw skew;
In the present embodiment, as an alternative embodiment, index offset computing unit includes:It is single that reserved index offset obtains son
Member, index offset computation subunit and renewal subelement, wherein,
Reserved index offset obtains subelement, for obtaining the reserved index offset of storage;
In the present embodiment, if not being stored with reserved index offset in the memory block pre-set, the pre- of storage is set
It is zero to stay index offset.
Index offset computation subunit, for by length corresponding to the information of the preceding Second Threshold byte and the storage
Reserved index offset be added, obtain index offset;
Subelement is updated, for updating the reserved index offset of the storage using the index offset.
As another alternative embodiment, index offset computing unit also includes:
Empty subelement, for receive judging unit export to index acquiring unit notice after, by the pre- of storage
Index offset is stayed to empty.
Request of data unit, for from request data at the index offset, exporting to atomic structure parsing module;
Acquiring unit is indexed, for parsing the index structure, is indexed;
Data resolution unit, for request data, the data of request are parsed according to the index.
In the present embodiment, as an alternative embodiment, data resolution unit includes:Play positioning time point and obtain subelement
And parsing plays subelement, wherein,
Play positioning time point and obtain subelement, positioning time point is played for obtaining;
In the present embodiment, user carries out positioning action on the player progress bar of client, can according to total reproduction time,
Progress bar total length and current anchor point position pro rata calculate a positioning timestamp, when positioning time stamp is plays positioning
Between point.
Parsing plays subelement, for asking the data from the broadcasting positioning time point and parsing broadcasting.
In the present embodiment, as an alternative embodiment, parsing, which plays subelement, to be included:Accumulator, frame number getter, inquiry
Device, data requestor and parsing player, wherein,
Accumulator, for the frame time stamp in track of video timestamp in the client that adds up-frame corresponding table structure box;
Frame number getter, for from cumulative frame time stamp, obtaining and the broadcasting positioning time immediate frame of point
Frame number corresponding to timestamp;
In the present embodiment, as an alternative embodiment, video vertical shift is I-frame video vertical shift.
In the present embodiment, for audio-visual synchronization, audio will also look for corresponding data, directly search audio STCO Box,
First skew more than the video vertical shift is obtained, obtains audio offset.
Requestor, for block offset information watchcase using track of video, it is inclined to inquire about frame of video corresponding to the frame number
Move;
Data requestor, for being asked to server from the data at the video vertical shift;
Player is parsed, for being played out after the data parsing by request.
In the present embodiment, as another alternative embodiment, parsing, which plays subelement, to be included:Frame number calculator, frame of video are inclined
Device, data requestor and parsing player are moved, wherein,
Frame number calculator, for according to frame duration and frame naming rule, calculating corresponding to the broadcasting positioning time point
Frame number;
Frame of video deviator, for block offset information watchcase using track of video, inquire about and regarded corresponding to the frame number
Frequency vertical shift;
Data requestor, for being asked to server from the data at the video vertical shift;
Player is parsed, for being played out after the data parsing by request.
In the present embodiment, as an alternative embodiment, parsing broadcasting includes:
The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P
Frame, if the first frame is I frames, it is pass-through to broadcast layer and plays out;
If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
In the present embodiment, if above-mentioned frame number is I frame frame numbers, the data of analysis request, the first frame is I frames, transparent transmission
To broadcast layer;If frame number is not I frame frame numbers, the data of analysis request, the first frame can be I frames, or B
Frame, can also be P frames.Because in the first frame, complete picture can not be independently presented in B frames or P frames, can cause Huaping phenomenon,
Only valid data are only by the media data started of I frames.In the present embodiment, by adding nearest I frames in position fixing process
Location mechanism, that is, position I frame frame numbers;And the first frame treatment mechanism is provided in analytic sheaf, it can not only mitigate top level control layer
Load, and the broadcast time-delay of average half of GOP duration can be improved.
The device of the present embodiment, it can be used for the technical scheme for performing embodiment of the method shown in Fig. 1 to Fig. 5, it realizes former
Reason is similar with technique effect, and here is omitted.
It should be noted that herein, such as first and second or the like relational terms are used merely to a reality
Body or operation make a distinction with another entity or operation, and not necessarily require or imply and deposited between these entities or operation
In any this actual relation or order.Moreover, term " comprising ", "comprising" or its any other variant are intended to
Nonexcludability includes, so that process, method, article or equipment including a series of elements not only will including those
Element, but also the other element including being not expressly set out, or it is this process, method, article or equipment also to include
Intrinsic key element.In the absence of more restrictions, the key element limited by sentence " including one ... ", it is not excluded that
Other identical element in the process including the key element, method, article or equipment also be present.
Each embodiment in this specification is described by the way of related, identical similar portion between each embodiment
Divide mutually referring to what each embodiment stressed is the difference with other embodiment.
For device embodiment, because it is substantially similar to embodiment of the method, so the comparison of description is simple
Single, the relevent part can refer to the partial explaination of embodiments of method.
Expression or logic and/or step described otherwise above herein in flow charts, for example, being considered use
In the order list for the executable instruction for realizing logic function, may be embodied in any computer-readable medium, for
Instruction execution system, device or equipment (such as computer based system including the system of processor or other can be held from instruction
The system of row system, device or equipment instruction fetch and execute instruction) use, or combine these instruction execution systems, device or set
It is standby and use.For the purpose of this specification, " computer-readable medium " can any can be included, store, communicate, propagate or pass
Defeated program is for instruction execution system, device or equipment or the dress used with reference to these instruction execution systems, device or equipment
Put.The more specifically example (non-exhaustive list) of computer-readable medium includes following:Electricity with one or more wiring
Connecting portion (electronic installation), portable computer diskette box (magnetic device), random access memory (RAM), read-only storage
(ROM), erasable edit read-only storage (EPROM or flash memory), fiber device, and portable optic disk is read-only deposits
Reservoir (CDROM).In addition, computer-readable medium, which can even is that, to print the paper of described program thereon or other are suitable
Medium, because can then enter edlin, interpretation or if necessary with it for example by carrying out optical scanner to paper or other media
His suitable method is handled electronically to obtain described program, is then stored in computer storage.
It should be appreciated that each several part of the present invention can be realized with hardware, software, firmware or combinations thereof.
In the above-described embodiment, multiple steps or method can use storage to be performed in memory and by suitable instruction
The software or firmware that system performs are realized.If for example, being realized with hardware, with another embodiment, can use
Any one of following technology well known in the art or their combination are realized:With for realizing logic work(to data-signal
The discrete logic of the logic gates of energy, there is the application specific integrated circuit of suitable combinational logic gate circuit, programmable gate
Array (PGA), field programmable gate array (FPGA) etc..
The embodiment of the present invention also provides a kind of electronic equipment, and the electronic equipment includes the dress described in foregoing any embodiment
Put.
Fig. 7 is the structural representation of electronic equipment one embodiment of the present invention, it is possible to achieve is implemented shown in Fig. 1-6 of the present invention
The flow of example, as shown in fig. 7, above-mentioned electronic equipment can include:Housing 71, processor 72, memory 73, circuit board 74 and electricity
Source circuit 75, wherein, circuit board 74 is placed in the interior volume that housing 71 surrounds, and processor 72 and memory 73 are arranged on circuit
On plate 74;Power circuit 75, for each circuit or the device power supply for above-mentioned electronic equipment;Memory 73 is used to store and can hold
Line program code;Processor 72 is run and executable program generation by reading the executable program code stored in memory 73
Program corresponding to code, for performing the stream data analytic method of the rearmounted encapsulation described in foregoing any embodiment.
Processor 72 to the specific implementation procedures of above-mentioned steps and processor 72 by run executable program code come
The step of further performing, the description of Fig. 1-6 illustrated embodiments of the present invention is may refer to, will not be repeated here.
The electronic equipment exists in a variety of forms, includes but is not limited to:
(1) mobile communication equipment:The characteristics of this kind equipment is that possess mobile communication function, and to provide speech, data
Communicate as main target.This Terminal Type includes:Smart mobile phone (such as iPhone), multimedia handset, feature mobile phone, and it is low
Hold mobile phone etc..
(2) super mobile personal computer equipment:This kind equipment belongs to the category of personal computer, there is calculating and processing work(
Can, typically also possess mobile Internet access characteristic.This Terminal Type includes:PDA, MID and UMPC equipment etc., such as iPad.
(3) portable entertainment device:This kind equipment can show and play content of multimedia.The kind equipment includes:Audio,
Video player (such as iPod), handheld device, e-book, and intelligent toy and portable car-mounted navigation equipment.
(4) server:The equipment for providing the service of calculating, the composition of server are total including processor, hard disk, internal memory, system
Line etc., server is similar with general computer architecture, but due to needing to provide highly reliable service, therefore in processing energy
Power, stability, reliability, security, scalability, manageability etc. require higher.
(5) other electronic equipments with data interaction function.
Those skilled in the art are appreciated that to realize all or part of step that above-described embodiment method carries
Suddenly it is that by program the hardware of correlation can be instructed to complete, described program can be stored in a kind of computer-readable storage medium
In matter, the program upon execution, including one or a combination set of the step of embodiment of the method.
For convenience of description, it is to be divided into various units/modules with function to describe respectively to describe apparatus above.Certainly, exist
The function of each unit/module can be realized in same or multiple softwares and/or hardware when implementing of the invention.
As seen through the above description of the embodiments, those skilled in the art can be understood that the present invention can
Realized by the mode of software plus required general hardware platform.Based on such understanding, technical scheme essence
On the part that is contributed in other words to prior art can be embodied in the form of software product, the computer software product
It can be stored in storage medium, such as ROM/RAM, magnetic disc, CD, including some instructions are causing a computer equipment
(can be personal computer, server, either network equipment etc.) performs some of each embodiment of the present invention or embodiment
Method described in part.
The foregoing is only a specific embodiment of the invention, but protection scope of the present invention is not limited thereto, any
Those familiar with the art the invention discloses technical scope in, the change or replacement that can readily occur in, all should
It is included within the scope of the present invention.Therefore, protection scope of the present invention should be defined by scope of the claims.
Claims (23)
- A kind of 1. stream data analytic method of rearmounted encapsulation, it is characterised in that including:It is determined that the data in the file received are the stream data using rearmounted encapsulation;The information of the preceding first threshold byte of the stream data of the rearmounted encapsulation is parsed, obtains atomic structure information;The information of Second Threshold byte, obtains type structure information, the first threshold is institute after extracting in atomic structure information State Second Threshold twice;It is determined that the type structure message identification be index structure after, the data of request are solved according to the index structure Analysis.
- 2. the stream data analytic method of rearmounted encapsulation according to claim 1, it is characterised in that described to determine what is received Data in file are to be included using the stream data of rearmounted encapsulation:The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and applied to stream Formula data scene, the then data in the file received are the stream data using rearmounted encapsulation.
- 3. the stream data analytic method of rearmounted encapsulation according to claim 1, it is characterised in that the first threshold is 8, Second Threshold 4.
- 4. the stream data analytic method of rearmounted encapsulation according to claim 1, it is characterised in that described it is determined that described Type structure message identification is after index structure, carrying out parsing to the data of request according to the index structure includes:If the type structure message identification is not index structure, according to preceding Second Threshold byte in the atomic structure information Information computation index skew;From request data at the index offset, and perform the preceding first threshold of the stream data of the parsing rearmounted encapsulation The step of information of byte;If the type structure message identification is index structure, the index structure is parsed, is indexed;Request data, the data of request are parsed according to the index.
- 5. the stream data analytic method of rearmounted encapsulation according to claim 4, it is characterised in that described according to the original The information computation index skew of preceding Second Threshold byte includes in minor structure information:Obtain the reserved index offset of storage;Length corresponding to the information of the preceding Second Threshold byte is added with the reserved index offset of the storage, indexed Skew;The reserved index offset of the storage is updated using the index offset.
- 6. the stream data analytic method of rearmounted encapsulation according to claim 5, it is characterised in that if the type knot Structure message identification is index structure, and methods described also includes:The reserved index offset of storage is emptied.
- 7. the stream data analytic method of rearmounted encapsulation according to claim 4, it is characterised in that the request data, Carrying out parsing to the data of request according to the index includes:Obtain and play positioning time point;Ask the data from the broadcasting positioning time point and parse broadcasting.
- 8. the stream data analytic method of rearmounted encapsulation according to claim 7, it is characterised in that described to ask from described Playing the data of positioning time point includes:Frame time stamp in cumulative client in track of video timestamp-frame corresponding table structure box;From cumulative frame time stamp, obtain and the broadcasting corresponding frame number of the immediate frame time stamp of positioning time point;Using block offset information watchcase of track of video, video vertical shift corresponding to the frame number is inquired about;Asked to server from the data at the video vertical shift.
- 9. the stream data analytic method of rearmounted encapsulation according to claim 8, it is characterised in that the video vertical shift For I-frame video vertical shift.
- 10. the stream data analytic method of rearmounted encapsulation according to claim 7, it is characterised in that described to ask from institute Stating the data of broadcasting positioning time point includes:According to frame duration and frame naming rule, frame number corresponding to the broadcasting positioning time point is calculated;Using block offset information watchcase of track of video, video vertical shift corresponding to the frame number is inquired about;Asked to server from the data at the video vertical shift.
- 11. the stream data analytic method of rearmounted encapsulation according to claim 7, it is characterised in that the parsing plays Including:The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P frames, such as The frame of fruit first is I frames, is pass-through to broadcast layer and plays out;If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
- A kind of 12. stream data resolver of rearmounted encapsulation, it is characterised in that including:Rearmounted encapsulation determining module, atom knot Structure parsing module, type structure extraction module and data resolution module, wherein,Rearmounted encapsulation determining module, the data in file for determining reception are the stream data using rearmounted encapsulation;Atomic structure parsing module, the information of the preceding first threshold byte of the stream data for parsing the rearmounted encapsulation, is obtained To atomic structure information;Type structure extraction module, for the information of Second Threshold byte after extracting in atomic structure information, obtain type structure Information, the first threshold are twice of the Second Threshold;Data resolution module, for it is determined that the type structure message identification be index structure after, according to the index structure The data of request are parsed.
- 13. the stream data resolver of rearmounted encapsulation according to claim 12, it is characterised in that described to determine to receive File in data be to be included using the stream data of rearmounted encapsulation:The file type field of the file received is parsed, if file type field is identified as the rearmounted encapsulation of MP4- and applied to stream Formula data scene, the then data in the file received are the stream data using rearmounted encapsulation.
- 14. the stream data resolver of rearmounted encapsulation according to claim 12, it is characterised in that the first threshold For 8, Second Threshold 4.
- 15. the stream data resolver of rearmounted encapsulation according to claim 12, it is characterised in that the data parsing Module includes:Judging unit, index offset computing unit, request of data unit, index acquiring unit and data resolution unit, Wherein,Judging unit, for judging whether the type structure message identification is index structure, if it is, notice index obtains list Member, if it is not, notice index offset computing unit;Index offset computing unit, it is inclined for the information computation index according to preceding Second Threshold byte in the atomic structure information Move;Request of data unit, for from request data at the index offset, exporting to atomic structure parsing module;Acquiring unit is indexed, for parsing the index structure, is indexed;Data resolution unit, for request data, the data of request are parsed according to the index.
- 16. the stream data resolver of rearmounted encapsulation according to claim 15, it is characterised in that the index offset Computing unit includes:Reserved index offset obtains subelement, index offset computation subunit and renewal subelement, wherein,Reserved index offset obtains subelement, for obtaining the reserved index offset of storage;Index offset computation subunit, for by the pre- of length corresponding to the information of the preceding Second Threshold byte and the storage Stay index offset to be added, obtain index offset;Subelement is updated, for updating the reserved index offset of the storage using the index offset.
- 17. the stream data resolver of rearmounted encapsulation according to claim 16, it is characterised in that the index offset Computing unit also includes:Empty subelement, for receive judging unit export to index acquiring unit notice after, by the reserved rope of storage Draw skew to empty.
- 18. the stream data resolver of rearmounted encapsulation according to claim 15, it is characterised in that the data parsing Unit includes:Play positioning time point and obtain subelement and parsing broadcasting subelement, wherein,Play positioning time point and obtain subelement, positioning time point is played for obtaining;Parsing plays subelement, for asking the data from the broadcasting positioning time point and parsing broadcasting.
- 19. the stream data resolver of rearmounted encapsulation according to claim 18, it is characterised in that the parsing plays Subelement includes:Accumulator, frame number getter, requestor, data requestor and parsing player, wherein,Accumulator, for the frame time stamp in track of video timestamp in the client that adds up-frame corresponding table structure box;Frame number getter, for from cumulative frame time stamp, obtaining and the broadcasting positioning time immediate frame time of point Frame number corresponding to stamp;Requestor, for block offset information watchcase using track of video, inquire about video vertical shift corresponding to the frame number;Data requestor, for being asked to server from the data at the video vertical shift;Player is parsed, for being played out after the data parsing by request.
- 20. the stream data resolver of rearmounted encapsulation according to claim 19, it is characterised in that the frame of video is inclined Move as I-frame video vertical shift.
- 21. the stream data resolver of rearmounted encapsulation according to claim 18, it is characterised in that the parsing plays Subelement includes:Frame number calculator, frame of video deviator, data requestor and parsing player, wherein,Frame number calculator, for according to frame duration and frame naming rule, calculating frame number corresponding to the broadcasting positioning time point;Frame of video deviator, for block offset information watchcase using track of video, inquire about frame of video corresponding to the frame number Skew;Data requestor, for being asked to server from the data at the video vertical shift;Player is parsed, for being played out after the data parsing by request.
- 22. the stream data resolver of rearmounted encapsulation according to claim 18, it is characterised in that the parsing plays Including:The data of analytic sheaf analysis request, if the first frame, and the first frame is B frames or P frames, abandons the B frames or P frames, such as The frame of fruit first is I frames, is pass-through to broadcast layer and plays out;If not the first frame, obtained B frames or P frames will be parsed or I frames are pass-through to broadcast layer and played out.
- 23. a kind of electronic equipment, it is characterised in that the electronic equipment includes:Housing, processor, memory, circuit board and electricity Source circuit, wherein, circuit board is placed in the interior volume that housing surrounds, and processor and memory are set on circuit boards;Power supply Circuit, for each circuit or the device power supply for above-mentioned electronic equipment;Memory is used to store executable program code;Processing The executable program code that device is stored by reading in memory runs program corresponding with executable program code, for holding The stream data analytic method of rearmounted encapsulation described in the foregoing any claim 1-11 of row.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610846684.6A CN107872716B (en) | 2016-09-23 | 2016-09-23 | A streaming data analysis method, device and electronic equipment with post-packaging |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610846684.6A CN107872716B (en) | 2016-09-23 | 2016-09-23 | A streaming data analysis method, device and electronic equipment with post-packaging |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107872716A true CN107872716A (en) | 2018-04-03 |
CN107872716B CN107872716B (en) | 2019-12-06 |
Family
ID=61751638
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610846684.6A Active CN107872716B (en) | 2016-09-23 | 2016-09-23 | A streaming data analysis method, device and electronic equipment with post-packaging |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107872716B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110248245A (en) * | 2019-06-21 | 2019-09-17 | 维沃移动通信有限公司 | A kind of video locating method, device, mobile terminal and storage medium |
CN110267062A (en) * | 2019-07-26 | 2019-09-20 | 深圳Tcl新技术有限公司 | Optimization method, device, readable storage medium storing program for executing and the system of assembled video frame |
CN113542764A (en) * | 2021-07-12 | 2021-10-22 | 中国电信股份有限公司 | Method, apparatus, electronic device, and computer-readable medium for quick start of video |
Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030188182A1 (en) * | 2002-03-29 | 2003-10-02 | Jun Sato | Data structure of multimedia file format, encrypting method and device thereof, and decrypting method and device thereof |
CN1516184A (en) * | 2003-01-10 | 2004-07-28 | 华为技术有限公司 | A kind of processing method of multimedia data |
CN101060623A (en) * | 2006-04-20 | 2007-10-24 | 佳能株式会社 | Moving image reproducing apparatus and method |
CN101146212A (en) * | 2006-09-11 | 2008-03-19 | 思华科技(上海)有限公司 | Stream media encapsulation and unpacking method and system for video order network |
US20090263099A1 (en) * | 2008-04-21 | 2009-10-22 | Canon Kabushiki Kaisha | Image processing apparatus, control method therefor, and program |
CN102754444A (en) * | 2010-01-08 | 2012-10-24 | 索尼公司 | Image processing device, information recording medium, image processing medium, and program |
US20150063467A1 (en) * | 2012-03-16 | 2015-03-05 | Lg Electronics Inc | Method for storing image information, method for parsing image information and apparatus using same |
CN105915935A (en) * | 2016-05-30 | 2016-08-31 | 乐视控股(北京)有限公司 | Video transmission control method and video transmission control device |
-
2016
- 2016-09-23 CN CN201610846684.6A patent/CN107872716B/en active Active
Patent Citations (8)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20030188182A1 (en) * | 2002-03-29 | 2003-10-02 | Jun Sato | Data structure of multimedia file format, encrypting method and device thereof, and decrypting method and device thereof |
CN1516184A (en) * | 2003-01-10 | 2004-07-28 | 华为技术有限公司 | A kind of processing method of multimedia data |
CN101060623A (en) * | 2006-04-20 | 2007-10-24 | 佳能株式会社 | Moving image reproducing apparatus and method |
CN101146212A (en) * | 2006-09-11 | 2008-03-19 | 思华科技(上海)有限公司 | Stream media encapsulation and unpacking method and system for video order network |
US20090263099A1 (en) * | 2008-04-21 | 2009-10-22 | Canon Kabushiki Kaisha | Image processing apparatus, control method therefor, and program |
CN102754444A (en) * | 2010-01-08 | 2012-10-24 | 索尼公司 | Image processing device, information recording medium, image processing medium, and program |
US20150063467A1 (en) * | 2012-03-16 | 2015-03-05 | Lg Electronics Inc | Method for storing image information, method for parsing image information and apparatus using same |
CN105915935A (en) * | 2016-05-30 | 2016-08-31 | 乐视控股(北京)有限公司 | Video transmission control method and video transmission control device |
Non-Patent Citations (1)
Title |
---|
ISO OFFICE: "AMENDMENT 2: Support for image file format", 《INTERNATIONAL STANDARD》 * |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110248245A (en) * | 2019-06-21 | 2019-09-17 | 维沃移动通信有限公司 | A kind of video locating method, device, mobile terminal and storage medium |
CN110267062A (en) * | 2019-07-26 | 2019-09-20 | 深圳Tcl新技术有限公司 | Optimization method, device, readable storage medium storing program for executing and the system of assembled video frame |
CN110267062B (en) * | 2019-07-26 | 2022-07-08 | 深圳Tcl新技术有限公司 | Optimization method and device for assembled video frame and readable storage medium |
CN113542764A (en) * | 2021-07-12 | 2021-10-22 | 中国电信股份有限公司 | Method, apparatus, electronic device, and computer-readable medium for quick start of video |
Also Published As
Publication number | Publication date |
---|---|
CN107872716B (en) | 2019-12-06 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US8886896B2 (en) | Storage format for media streams | |
KR101703179B1 (en) | Switching between adaptation sets during media streaming | |
JP6655091B2 (en) | Low latency video streaming | |
US9282131B2 (en) | System and method for splicing media files | |
CN107979783A (en) | A kind of stream data analytic method, device and electronic equipment | |
KR101206698B1 (en) | Apparatus and method for providing streaming contents | |
EP3167621B1 (en) | Error handling for files exchanged over a network | |
EP2853075B1 (en) | Content-specific identification and timing behavior in dynamic adaptive streaming over hypertext transfer protocol | |
US10924801B2 (en) | Method and device for playing media file while switching resolution in webpage and storage medium | |
CN104394380A (en) | Video monitoring management system and playback method of video monitoring record | |
CN103081433A (en) | Manifest file updates for network streaming of coded video data | |
CN104602105B (en) | The player method and user equipment of video file | |
US11563992B2 (en) | Video playback quality detection method and apparatus | |
JP6969013B2 (en) | Synchronous playback method, device and storage medium for media files | |
CN102611690A (en) | Container format conversion method on basis of hypertext transfer protocol (HTTP) streaming | |
CN108259998B (en) | Player, play control method and device, electronic equipment and play system | |
CN105611395B (en) | A kind of method and system that MP4 format video plays online | |
CN102118539B (en) | Multimedia playing terminal as well as playing method and device for dragging multimedia files | |
CN103081488A (en) | Signals video samples for trick mode video representation | |
CN108174242A (en) | Live data multiplexing method, device, storage medium and equipment | |
US20200413146A1 (en) | Webpage Playing Method and Device and Storage Medium for Non-Streaming Media File | |
CN107872716A (en) | A streaming data analysis method, device and electronic equipment with post-packaging | |
KR20090017027A (en) | Method for generating media object based metadata, playback method and apparatus therefor | |
WO2009137469A1 (en) | Playlist processing | |
WO2013097091A1 (en) | Video distribution method and system and video playing method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right | ||
TR01 | Transfer of patent right |
Effective date of registration: 20250729 Address after: Rooms 602 and 605, No. 85 Xiangxue Avenue Middle, Huangpu District, Guangzhou City, Guangdong Province 510000 Patentee after: Guangzhou Gaohang Technology Transfer Co.,Ltd. Country or region after: China Address before: Hangzhou City, Zhejiang province 310051 Binjiang District Qianmo Road No. 555 Patentee before: Hangzhou Hikvision Digital Technology Co.,Ltd. Country or region before: China |