CN110113623A - A kind of audio-video slice transmission platform based on Session Initiation Protocol - Google Patents

A kind of audio-video slice transmission platform based on Session Initiation Protocol Download PDF

Info

Publication number
CN110113623A
CN110113623A CN201910312919.7A CN201910312919A CN110113623A CN 110113623 A CN110113623 A CN 110113623A CN 201910312919 A CN201910312919 A CN 201910312919A CN 110113623 A CN110113623 A CN 110113623A
Authority
CN
China
Prior art keywords
sip
slice
module
stream
media
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
CN201910312919.7A
Other languages
Chinese (zh)
Other versions
CN110113623B (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.)
Zhejiang University of Technology ZJUT
Original Assignee
Zhejiang University of Technology ZJUT
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 Zhejiang University of Technology ZJUT filed Critical Zhejiang University of Technology ZJUT
Priority to CN201910312919.7A priority Critical patent/CN110113623B/en
Publication of CN110113623A publication Critical patent/CN110113623A/en
Application granted granted Critical
Publication of CN110113623B publication Critical patent/CN110113623B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/1066Session management
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/1066Session management
    • H04L65/1073Registration or de-registration
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/1066Session management
    • H04L65/1101Session protocols
    • H04L65/1104Session initiation protocol [SIP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/75Media network packet handling
    • H04L65/764Media network packet handling at the destination 
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/21Server components or server architectures
    • H04N21/218Source of audio or video content, e.g. local disk arrays
    • H04N21/2187Live feed
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/20Servers specifically adapted for the distribution of content, e.g. VOD servers; Operations thereof
    • H04N21/23Processing of content or additional data; Elementary server operations; Server middleware
    • H04N21/231Content storage operation, e.g. caching movies for short term storage, replicating data over plural servers, prioritizing data for deletion
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/439Processing of audio elementary streams
    • H04N21/4394Processing of audio elementary streams involving operations for analysing the audio stream, e.g. detecting features or characteristics in audio streams
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/439Processing of audio elementary streams
    • H04N21/4398Processing of audio elementary streams involving reformatting operations of audio signals
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/44008Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving operations for analysing video streams, e.g. detecting features or characteristics in the video stream
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/44Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs
    • H04N21/4402Processing of video elementary streams, e.g. splicing a video clip retrieved from local storage with an incoming video stream, rendering scenes according to MPEG-4 scene graphs involving reformatting operations of video signals for household redistribution, storage or real-time display
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/83Generation or processing of protective or descriptive data associated with content; Content structuring
    • H04N21/845Structuring of content, e.g. decomposing content into time segments
    • H04N21/8456Structuring of content, e.g. decomposing content into time segments by decomposing the content in the time domain, e.g. in time segments
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/80Generation or processing of content or additional data by content creator independently of the distribution process; Content per se
    • H04N21/85Assembly of content; Generation of multimedia applications
    • H04N21/854Content authoring
    • H04N21/8547Content authoring involving timestamps for synchronizing content

Abstract

A kind of audio-video slice transmission platform based on Session Initiation Protocol, including SIP signalling module, stream media information is interactive and resource distribution module, Media Stream are sliced memory module, wherein SIP signalling module is signal server, and stream media information is interactive to belong to streaming media server with resource distribution module and Media Stream slice memory module;The interfaces such as the request from sip terminal, including registration, heartbeat keep-alive, notice media server, link acquisition and forwarding are received by SIP signalling module;Terminal first passes through sip message and is registered to SIP signalling module, and SIP signalling module will do it a series of encryption identifying procedures.The present invention can play the role of serving as caching, improve video quality;The exploitation of decoder module can be skipped using the present invention, the time for reducing development difficulty, saving exploitation internet adapter software.

Description

A kind of audio-video slice transmission platform based on Session Initiation Protocol
Technical field
The present invention relates to Signalling exchanges and audio video transmission technical field, more particularly to a kind of sound based on Session Initiation Protocol Video flowing acquisition, slice, the platform stored.
Background technique
With the development of society, the convenience of traffic, the circle of people's life is increasing, aspectant between men to accompany Companion has become a kind of luxury with communication.And with the arrival of cybertimes, people's lives are increasingly digitized with communication, I Can be realized by modern science and technology communication and accompany.Under this overall situation, Signalling exchange is ground with audio video transmission technology It sends out also more and more with application.And have company a lot of with the product of communication function on the market now, especially in old labor market , and every the same product has the Signalling exchange and audio-video transmission system of oneself a set of independent completion.Although every suit system Core technology it is similar, but specific to technical detail again there are many deviation, this causes the plateform system per the same product several It is all independent not intercommunication.So it may be desired to open on the basis of existing technology specific to different application scenarios One suitable Signalling exchange of hair and audio video transmission platform.
SIP (Session Initiation Protocol, Session initiation Protocol) is by IETF (Internet Engineering Task Force, Internet Engineering Task group) the IP phone signaling protocol that proposes is using UTF-8 character The text protocol for collecting to be encoded.SIP is a kind of communication protocol, is defined how in communication equipment (computer, phone, hand Machine etc.) between be connected with each other and information exchange, SIP be also a kind of signaling control protocol, can configure and manage and is any kind of Peer-to-peer communication session, but it is not relevant for medium type (voice, short message, game, video etc.).Session Initiation Protocol has good Good expansible characteristic, increases definition, is embedded in various user terminals and realizes new function rapidly in which can be convenient;Have stronger mutual Operational capacity, good opening.Session Initiation Protocol rely on its powerful technical advantage, be applied to it is multiple have Signalling exchange with In the product of audio video transmission function.However, the product based on Session Initiation Protocol mostly uses greatly plug-flow in terms of audio video transmission Mode, the product that this completes encoding and decoding in sip terminal be not very friendly.On the one hand, when network condition is poor, video The case where stream is not able to maintain continuously during conveying, and the video that user sees will appear Caton or contain mosaic, platform Or the terminal cache module that needs to redevelop could be alleviated or solve;On the other hand, in a corresponding user software of terminal development When, for whole system to be adapted to, it is necessary to do independent audio/video encoding/decoding playing module, workload just greatly increases.And show The mode that solution there are many in the market, such as live streaming draw stream, only needs a chained address, and it is only to may not need oneself exploitation Formwork erection block can be carried out the broadcasting of audio-video, but on the market there is no based on Session Initiation Protocol take again audio-video drawing stream mode into The platform of row transmission of video, this generates the demands for developing such platform.
Summary of the invention
That there are quality in terms of audio video transmission in order to solve the system based on Session Initiation Protocol is bad, adaptation exploitation is difficult asks Topic, the present invention provides a kind of audio-video slice transmission platform based on Session Initiation Protocol, the platform signaling moiety are based on Session Initiation Protocol, Audio video transmission part is stored temporarily on server by the way that entire stream is divided into file small one by one, by sip terminal according to Link the transmission mode that voluntarily pulls, realize that audio-video listens to the function of viewing or video exchange, so as to improve video quality, gram The difficult problem of clothes adaptation exploitation.
The technical solution adopted by the present invention to solve the technical problems is:
A kind of audio-video slice transmission platform based on Session Initiation Protocol, including SIP signalling module, stream media information interaction with Resource distribution module, Media Stream be sliced memory module, wherein SIP signalling module be signal server, stream media information interaction with Resource distribution module and Media Stream slice memory module belong to streaming media server.
The request from sip terminal, including registration, heartbeat keep-alive, notice media services are received by SIP signalling module Device, link obtain and the interfaces such as forwarding.Sip terminal passes through SIP message first and is registered to SIP signalling module, SIP signaling Module carries out a series of encryption identifying procedures.It one is authentication mode is compared with database by encrypted password Right, successful match then authenticates success.It is sip terminal by identifying code comparison there are also a kind of authentication mode, compares correct then Xiang Ping Platform sends the registration message that message content is PASS, and platform receives the registration message that content is PASS and is then judged as that certification passes through. If certification passes through, SIP signalling module is using the user name of the sip terminal as the Session conduct between key, with sip terminal Value saves in memory in the form of key-value pair;In responds SIP terminal message, Session is found by user name, Pass through the Session response message again.In order to guarantee to be constantly in attached state with sip terminal, sip terminal is at regular intervals Need to SIP signalling module sending method be Register, the message that content is heartbeat, SIP signalling module receives 200OK message is replied afterwards.If it exceeds certain time does not receive the heartbeat message from sip terminal, in SIP signaling The session with current sip terminal is nullified in module.
Further, before initiating video request, sip terminal to SIP signalling module sending method be OPTIONS, content For the message of query, SIP signalling module is transmitted to requested SIP terminal, and requested sip terminal replys 200OK if online, If not online, SIP signalling module directly replys 400.According to online situation, sip terminal is retransmited to SIP signalling module later The message that method is INVITE, content is media, message include video parameter.SIP signalling module forwards messages to stream matchmaker Session is established in body information exchange and resource distribution module, preparation.
Further, SIP signalling module replys the information of sip terminal 100Trying, then stream media information interaction and resource Distribution module is the port numbers that video session is distributed between 8000-10000, this numerical intervals can be modified.Further according to requested Sip terminal user name looks for whether to exist under specified path using the user name as the file of name, if creating one without if A, this file is sliced the path temporarily stored as Media Stream, and the path and port numbers are mentioned respectively as a temporary variable Medium for supplying stream is sliced memory module.It is replied to later by port numbers and according to the link for drawing stream that folder path generates SIP signalling module, SIP signalling module forwards the information such as port numbers to give request sip terminal, and replys 200OK.
Further, after replying sip terminal, sip terminal is no longer operated, in waiting coomand mode.SIP signalling module To requested sip terminal sending method be INVITE, the message that content is media, include session establishment necessary information, asked 200OK is replied after asking sip terminal to receive, SIP signalling module replys ACK expression again after receiving can start to send media code Stream.After requested sip terminal receives the ACK message of confirmation, start to be sliced the Media Stream that memory module sends standard to Media Stream.
Further, Media Stream slice memory module receives Media Stream, carries out integration slice to Media Stream, number of sections with Length can generate the index file of a m3u8 format with sets itself, each slice with the encapsulation of TS format, and Media Stream is cut Piece and index file are all placed on to be requested in the file of sip terminal user name name.To guarantee audio-visual synchronization, audio-video Slice need to be to minimize differential technique in accordance with certain method, core algorithm, comprising the following steps:
(1) elementary stream is parsed, video flowing is obtained, is point of penetration, and then acquisition video flowing slice immediately with I frame every IDR frame Timestamp is directly that slice node is sliced video flowing with this time stamp;
(2) audio stream is parsed, obtains PTS and DTS information, and then obtain the timestamp sequence of the random point of penetration of audio stream Column;
(3) difference of the audio stream actually obtained slice length and preset slice length, Wo Mengen are indicated with DV DV is accomplished to minimize by the timestamp sequence and preset slice length obtained according to (2), trial.It is poor using minimizing herein The slice computation model of value method optimization method, mathematic(al) representation are as follows:
To each k=1,2 ..., Kj, successively execute
s.t.d>di,j,k-1
According to the d being calculatedi,j,kSequential value obtains the slice timestamp sequential value of i-th of audio stream:
Wherein:
D: independent variable
{ti(0),ti(1),ti(2),……,ti(Di) }: the timestamp of the random point of penetration of i-th of audio stream, ti(0)= 0,ti(Di)=L, L are the duration of audio stream
Kj: the slice number of Media Stream
di,j,k: the serial number of the slice timestamp of Media Stream belongs to set { 0,1,2 ... ..., Di, to all k, 0≤k≤ Kj,di,j,0=0,
tj(nj,k): the slice timestamp of video media stream
ti,j(di,j,k-1): the initial time stamp of k-th of slice
ti,j(di,j,k): the ending time stamp of k-th of slice
The optimal sequence value of the slice timestamp of audio stream is calculated, the slice timestamp being calculated according to described in Optimal sequence value, is sliced audio stream;
(4) video flowing slice and audio stream slice are subjected to audio-video encapsulation, generate m3u8 index file.
Index file is constantly updated according to the passage of time.After index file generates, streaming media server passes through stream matchmaker Body information exchange and resource distribution module notify SIP signalling module, and SIP signalling module sends ACK confirmation message to sip terminal, Sip terminal is fetched automatically by the chain received before watches the video that requested sip terminal is sent.When certain side wants to terminate When, the message for being BYE to SIP signalling module sending method forwards the message to another after SIP signalling module replys 200OK Sip terminal, sip terminal reply 200OK to indicate to acknowledge receipt of.Latter two right sip terminal stops the transmission and viewing of code stream.Most Afterwards, the interaction of SIP signalling module notice stream media information and resource distribution module, the module release port, and delete specified file Slice and index file under folder cause to delete no successful fortuitous event, slice and rope if there is server crash etc. Quotation part also disappears in certain time after server starting automatically.
Technical concept of the invention are as follows: present equipment and system based on Session Initiation Protocol on the market, when transmitting real-time video It is commonly present Caton phenomenon, needing to develop cache module could alleviate, and in the software of exploitation adaptation, need to do independent decoding Playing module, this greatly improves development difficulty and equipment pressure all, largely extends the development cycle of project and opens Send out cost.Using such a slice transmission mechanism based on SIP, slice is equivalent to caching, and sip terminal can be by drawing stream side Formula carries out video-see, and Android is supported by linking drawing stream viewing video with ios device on the market now.It is big in this way The time for developing software for adaption system is improved greatly, is improved video quality, is saved a large amount of human and material resources and time, Improve user experience, engineering significance with higher and market value.
Audio-video slice transmission platform based on SIP of the invention, it is real by the integration to prior art resource on the market The relatively good utilisation to current Android and IOS prior art is showed, in conjunction with sip technique, sip terminal etc. can be applied perfectly to Equipment and system based on Session Initiation Protocol.It can be improved based on the Session Initiation Protocol competitiveness of product in market, help Session Initiation Protocol preferably It integrates with market.
Beneficial effects of the present invention are mainly manifested in: (1) part SIP platform transmitting real-time media stream at present on the market When, there are Catons to fall frame phenomenon for video, and the present invention can play the role of serving as caching, improve video quality;(2) current market On part SIP platform when developing internet adapter software audio/video decoding playing module development difficulty it is big, can be jumped using the present invention The exploitation of decoder module is crossed, the time for reducing development difficulty, saving exploitation internet adapter software;(3) present invention can help sip terminal It is preferably merged with Android and IOS environment, expands the usage scenario of product.
Detailed description of the invention
The system framework figure that Fig. 1 is made of signal server of the invention, streaming media server and sip terminal.
Fig. 2 is process of side's sip terminal video request initiation to end.
Specific embodiment
The invention will be further described below in conjunction with the accompanying drawings.
Referring to Figures 1 and 2, a kind of audio-video slice transmission system platform based on Session Initiation Protocol.The frame of whole system is as schemed Shown in 1.The present invention is terrace part therein, is specifically divided into SIP signal server and streaming media server, wherein SIP signaling Server includes SIP signalling module, and streaming media server includes that stream media information interaction is cut with resource distribution module and Media Stream Piece memory module.The function of SIP signalling module mainly receives, processing or forwarding come from sip terminal or streaming media server Signaling or message, be the bridge linked up between each module, be whole system operation key component.Stream media information interaction with Resource distribution module is mainly responsible for exchanging between streaming media server and SIP signalling module, while being also responsible for audio video transmission The resource allocations such as preceding port, IP, file.Media Stream slice memory module is mainly responsible for reception Media Stream and integrates slice, Then the media file for generating index file and TS encapsulation is stored on the server, draws stream to watch view by link for sip terminal Frequently.Whole system is all based on SIP, and sip terminal can be the SIP equipment of customization, is also possible to be mounted on the electronics such as portable computer Application software in equipment.The interaction of sip terminal and platform all first passes through SIP signalling module, if there are also the transmission of audio-video Request, SIP signalling module carry out information exchange with streaming media server again, then carry out the transmission of Media Stream.
Sip terminal initiates video request to the process terminated referring to Fig. 2 to another sip terminal.
When initiating video request, the sip terminal of initiation to SIP signalling module sending method be INVITE, content is The message of media, message include video parameter.SIP signalling module forwards messages to stream media information interaction and resource allocation Module, SIP signalling module reply the information of SIP terminal 100Trying, and informing is try to distribution resource.Then Streaming Media is believed Breath is interactive and resource distribution module sends the user name of message according to sip terminal, for both sides' sip terminal distribute 8000-10000 it Between TCP port number, this numerical intervals can modify.Further according to the user name of the requested sip terminal in message, in specified circuit It is found under diameter using the user name as the file of name, if creating one without if, this file is temporary as Media Stream slice The path of storage.The interaction of streaming media server later, i.e. stream media information and resource distribution module are by port numbers and according to file Folder coordinates measurement draws the link of stream to reply to SIP signalling module, and SIP signalling module forwards the information such as port numbers to request Sip terminal, and reply 200OK.
After replying request sip terminal, request sip terminal is no longer operated, in waiting coomand mode.SIP signalling module To requested sip terminal sending method be INVITE, the message that content is media, include session establishment necessary information, including Requested sip terminal sends the port numbers etc. of stream medium data.Requested sip terminal replys 200OK, SIP signaling mould after receiving Block replys ACK expression again after receiving can start to send media code stream.Requested SIP terminal receives the ACK message of confirmation Afterwards, start to be sliced the Media Stream that memory module sends standard to Media Stream.
Media Stream slice memory module receives Media Stream, carries out integration slice to Media Stream, and number of sections and length can be with Sets itself, each slice generate the index file of a m3u8 format with the encapsulation of TS format, Media Stream slice and rope Quotation part is all placed on to be requested in the file of SIP terminal user name name.Dicing method the following steps are included:
(1) elementary stream is parsed, video flowing is obtained, is point of penetration, and then acquisition video flowing slice immediately with I frame every IDR frame Timestamp is directly that slice node is sliced video flowing with this time stamp;
(2) audio stream is parsed, obtains PTS and DTS information, and then obtain the timestamp sequence of the random point of penetration of audio stream Column;
(3) difference of the audio stream actually obtained slice length and preset slice length, Wo Mengen are indicated with DV DV is accomplished to minimize by the timestamp sequence and preset slice length obtained according to (2), trial.It is poor using minimizing herein The slice computation model of value method optimization method, mathematic(al) representation are as follows:
To each k=1,2 ..., Kj, successively execute
s.t.d>di,j,k-1
According to the d being calculatedi,j,kSequential value obtains the slice timestamp sequential value of i-th of audio stream:
Wherein:
D: independent variable
{ti(0),ti(1),ti(2),……,ti(Di) }: the timestamp of the random point of penetration of i-th of audio stream, ti(0)= 0,ti(Di)=L, L are the duration of audio stream
Kj: the slice number of Media Stream
di,j,k: the serial number of the slice timestamp of Media Stream belongs to set { 0,1,2 ... ..., Di, to all k, 0≤k≤ Kj,di,j,0=0,
tj(nj,k): the slice timestamp of video media stream
ti,j(di,j,k-1): the initial time stamp of k-th of slice
ti,j(di,j,k): the ending time stamp of k-th of slice
The optimal sequence value of the slice timestamp of audio stream is calculated, the slice timestamp being calculated according to described in Optimal sequence value, is sliced audio stream;
(4) video flowing slice and audio stream slice are subjected to audio-video encapsulation, generate m3u8 index file.
Index file is constantly updated according to the passage of time.After index file generates, streaming media server passes through stream matchmaker To SIP signalling module transmission ACK confirmation message, SIP signalling module sends ACK confirmation for body information exchange and resource distribution module For message to sip terminal, the chain that sip terminal receives before, which fetches, watches the video that requested sip terminal is sent.
When certain side want terminate video session when, herein we by request sip terminal initiation terminate for (Fig. 2 be also with For request sip terminal initiation terminates).The message for requesting sip terminal to be BYE to SIP signalling module sending method, is tied simultaneously Beam viewing.SIP signalling module replys 200OK to indicate to acknowledge receipt of, and then forwards BYE to requested sip terminal, is requested Sip terminal replys 200OK to indicate to acknowledge receipt of, and is requested the transmission that sip terminal stops code stream later.Finally, SIP signaling mould Block notifies stream media information interaction and resource distribution module, and stream media information is interactive to receive rear release end with resource distribution module Mouthful, resetting storage port and the temporary variable for being sliced storage address, and be sliced and disappear automatically within a certain period of time with index file.
It is to be herein pointed out the specific implementation in the present invention only lists individual example of the invention, this is used The scheme that the design philosophy and its equivalence changes of invention are realized, is within the scope of protection of the invention.

Claims (1)

1. a kind of audio-video slice transmission platform based on Session Initiation Protocol, it is characterised in that: believe including SIP signalling module, Streaming Media Breath is interactive to be sliced memory module with resource distribution module, Media Stream, and wherein SIP signalling module is signal server, Streaming Media letter Breath is interactive to belong to streaming media server with resource distribution module and Media Stream slice memory module;
The request from sip terminal, including registration, heartbeat keep-alive, notice media server, chain are received by SIP signalling module It obtains and takes and forwarding interface;Sip terminal passes through sip message first and is registered to SIP signalling module, and SIP signalling module carries out A series of encryption identifying procedures;To be compared to by encrypted password with database one is authentication mode, matching at Function then authenticates success;It is sip terminal by identifying code comparison there are also a kind of authentication mode, compares correct then to platform transmission message Content is the registration message of PASS, and platform receives the registration message that content is PASS and is then judged as that certification passes through;If certification is logical It crosses, SIP signalling module regard the user name of the sip terminal as value as the Session between key, with sip terminal, with key-value Pair form save in memory;In responds SIP terminal message, Session is found by user name, then by being somebody's turn to do Session response message;In order to guarantee to be constantly in attached state with sip terminal, sip terminal need at regular intervals to SIP signalling module sending method is Register, and content is the message of heartbeat, and SIP signalling module is replied after receiving 200 OK message;If it exceeds certain time does not receive the heartbeat message from sip terminal, SIP signalling module nullify with The session of current sip terminal;
Before initiating video request, sip terminal can be OPTIONS to SIP signalling module sending method, and content is query's Message, SIP signalling module are transmitted to requested sip terminal, and requested sip terminal can reply 200OK if online, if not existing Line, SIP signalling module directly reply 400;According to online situation, sip terminal retransmits method to SIP signalling module and is later INVITE, the message that content is media, message include video parameter;SIP signalling module forwards messages to stream media information friendship Mutually and session is established in resource distribution module, preparation;
SIP signalling module replys the information of sip terminal 100Trying, and then stream media information interaction is with resource distribution module The port numbers in video session distribution default value section;Further according to requested sip terminal user name, found under specified path With the presence or absence of using the user name as the file of name, if creating one without if, this file is temporary as Media Stream slice The path of storage, the path and port numbers are supplied to Media Stream slice memory module respectively as a temporary variable;Later will Port numbers and SIP signalling module is replied to according to the link for drawing stream that folder path generates, SIP signalling module forwards port Number etc. information give request sip terminal, and reply 200OK;
After replying sip terminal, sip terminal is no longer operated, in waiting coomand mode;SIP signalling module is whole to requested SIP Hold sending method be INVITE, the message that content is media, session establishment necessary information is included, after requested sip terminal receives 200OK is replied, SIP signalling module replys ACK expression again after receiving can start to send media code stream;Requested sip terminal After the ACK message for receiving confirmation, start to be sliced the Media Stream that memory module sends standard to Media Stream;
Media Stream slice memory module receives Media Stream, carries out integration slice to Media Stream, each slice is with the encapsulation of TS format, together The index file of mono- m3u8 format of Shi Shengcheng, Media Stream slice and index file are all placed on to be requested sip terminal user name In the file of name;For guarantee audio-visual synchronization, audio-video slice the following steps are included:
(1) elementary stream is parsed, video flowing is obtained, is point of penetration, and then acquisition video flowing slice time immediately with I frame every IDR frame Stamp is directly that slice node is sliced video flowing with this time stamp;
(2) audio stream is parsed, obtains PTS and DTS information, and then obtain the timestamp sequence of the random point of penetration of audio stream;
(3) difference that the audio stream actually obtained slice length and preset slice length are indicated with DV, obtains according to (2) Timestamp sequence and preset slice length, trial DV is accomplished to minimize;Herein using minimum differential technique optimization The slice computation model of method, mathematic(al) representation are as follows:
To each k=1,2 ..., Kj, successively execute
St.d=, dI, i, k-1
According to the d being calculatedI, j, kSequential value obtains the slice timestamp sequential value of i-th of audio stream:
Wherein:
D: independent variable
{ti(0), ti(1), ti(2) ..., ti(Di)]: the timestamp of the random point of penetration of i-th of audio stream, ti(0)=0, ti(Di)=L, L are the duration of audio stream
Kj: the slice number of Media Stream
dI, j, k: Media Stream slice timestamp serial number, belong to set 0,1,2 ..., Di, to all k, 0≤k≤Kj, dI, j, 0=0
tj(nJ, k): the slice timestamp of video media stream
tI, j(dI, j, k-1): the initial time stamp of k-th of slice
tI, j(dI, j, k): the ending time stamp of k-th of slice
The optimal sequence value of the slice timestamp of audio stream is calculated, what is be calculated according to described in is sliced the best of timestamp Sequential value is sliced audio stream;
(4) video flowing slice and audio stream slice are subjected to audio-video encapsulation, generate m3u8 index file;
Index file is constantly updated according to the passage of time;After index file generates, streaming media server is believed by Streaming Media Breath is interactive to be notified that SIP signalling module, SIP signalling module send ACK confirmation message to sip terminal, SIP with resource distribution module Terminal will be fetched automatically by the chain received before watches the video that requested sip terminal is sent;When certain side wants to terminate When, the message for being BYE to SIP signalling module sending method forwards the message to another after SIP signalling module replys 200OK Sip terminal, sip terminal can also reply 200OK to indicate to acknowledge receipt of;Latter two right sip terminal stops the transmission and sight of code stream It sees;Finally, the notice stream media information interaction of SIP signalling module and resource distribution module, SIP signalling module meeting release port, And slice and index file under specified folder are deleted, cause to delete without successfully unexpected if there is server crash etc. Situation, slice and index file disappear in certain time automatically after server starting.
CN201910312919.7A 2019-04-18 2019-04-18 Audio and video slice transmission platform based on SIP protocol Active CN110113623B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910312919.7A CN110113623B (en) 2019-04-18 2019-04-18 Audio and video slice transmission platform based on SIP protocol

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910312919.7A CN110113623B (en) 2019-04-18 2019-04-18 Audio and video slice transmission platform based on SIP protocol

Publications (2)

Publication Number Publication Date
CN110113623A true CN110113623A (en) 2019-08-09
CN110113623B CN110113623B (en) 2021-07-27

Family

ID=67485883

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910312919.7A Active CN110113623B (en) 2019-04-18 2019-04-18 Audio and video slice transmission platform based on SIP protocol

Country Status (1)

Country Link
CN (1) CN110113623B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111182322A (en) * 2019-12-31 2020-05-19 北京达佳互联信息技术有限公司 Director control method and device, electronic equipment and storage medium
CN111479121A (en) * 2020-04-08 2020-07-31 北京智能工场科技有限公司 Live broadcasting method and system based on streaming media server
CN113099252A (en) * 2021-03-29 2021-07-09 浙江工业大学 Remote feeder video pushing system based on SIP and RTMP

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102263775A (en) * 2010-05-31 2011-11-30 上海贝尔股份有限公司 Method and device for controlling local session initiation protocol (SIP) calling
CN102932670A (en) * 2012-11-29 2013-02-13 百视通网络电视技术发展有限责任公司 Method and system for segmenting streaming media
CN103491106A (en) * 2013-10-11 2014-01-01 深圳市邦彦信息技术有限公司 Method and system for recording IP (internet protocol) calls based on SIP (session initiation protocol) protocol
US9667665B1 (en) * 2015-02-25 2017-05-30 Spring Communications Company L.P. Session initiation protocol (SIP) communications over trusted hardware
CN107306438A (en) * 2016-04-23 2017-10-31 华为技术有限公司 A kind of generation method of wireless access network section, wireless access network and section manager
CN108605168A (en) * 2016-02-17 2018-09-28 高通股份有限公司 The storage of virtual reality video in media file
CN109640324A (en) * 2017-05-05 2019-04-16 华为技术有限公司 A kind of communication means and relevant apparatus

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102263775A (en) * 2010-05-31 2011-11-30 上海贝尔股份有限公司 Method and device for controlling local session initiation protocol (SIP) calling
CN102932670A (en) * 2012-11-29 2013-02-13 百视通网络电视技术发展有限责任公司 Method and system for segmenting streaming media
CN103491106A (en) * 2013-10-11 2014-01-01 深圳市邦彦信息技术有限公司 Method and system for recording IP (internet protocol) calls based on SIP (session initiation protocol) protocol
US9667665B1 (en) * 2015-02-25 2017-05-30 Spring Communications Company L.P. Session initiation protocol (SIP) communications over trusted hardware
CN108605168A (en) * 2016-02-17 2018-09-28 高通股份有限公司 The storage of virtual reality video in media file
CN107306438A (en) * 2016-04-23 2017-10-31 华为技术有限公司 A kind of generation method of wireless access network section, wireless access network and section manager
CN109640324A (en) * 2017-05-05 2019-04-16 华为技术有限公司 A kind of communication means and relevant apparatus

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
蒋维: "实时流媒体传输系统中关键技术的研究与实现", 《中国博士学位论文全文数据库》 *
钟添华: "一种低码率的视频直播系统 ", 《福建电脑》 *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111182322A (en) * 2019-12-31 2020-05-19 北京达佳互联信息技术有限公司 Director control method and device, electronic equipment and storage medium
CN111479121A (en) * 2020-04-08 2020-07-31 北京智能工场科技有限公司 Live broadcasting method and system based on streaming media server
CN113099252A (en) * 2021-03-29 2021-07-09 浙江工业大学 Remote feeder video pushing system based on SIP and RTMP

Also Published As

Publication number Publication date
CN110113623B (en) 2021-07-27

Similar Documents

Publication Publication Date Title
KR100971609B1 (en) Method and system for improving performance of connection to receiver
US9014349B2 (en) Media instant messaging for mobile device
US8379544B2 (en) Communications
CN110113623A (en) A kind of audio-video slice transmission platform based on Session Initiation Protocol
CN109327493A (en) A kind of remote medical monitoring system based on cloud and monitoring method
CN1989710A (en) Pt service system and method
CN109951519A (en) A kind of control method and device of convention business
CN111385666B (en) Communication link establishing method, device, equipment and storage medium
WO2013127163A1 (en) Call terminal enrollment method and device
CN112019889A (en) Cloud-based screen projection system and screen projection method
CN101640736B (en) Method and system for realizing visual customer service
CN108182121A (en) In a kind of Android control large-size screen monitors system module between communication means and system
CN110740161A (en) system and method for adapting converged communication
US8639279B2 (en) Method of requesting a communication session using segmented signaling messages
CN111202980B (en) Information transmission method, streaming media cloud platform and computer readable storage medium
CN101350741A (en) Method, apparatus and system for notifying real time stream protocol event
US20080025306A1 (en) Internet protocol television system, method for providing internet protocol multicast TV signal, TV transferring apparatus, and TV receiving apparatus
CN108810475B (en) Android video monitoring device based on Onvif standard and Sip protocol
WO2015089974A1 (en) Method, device, and system for processing instant messaging
US7945686B2 (en) Communication control apparatus and method
JP2008522484A (en) Method and apparatus for communicating messages in a communication network
WO2007112649A1 (en) A system, device and method for accessing database based on session initiation protocol
WO2007124662A1 (en) A method,system,subscribing device,informing device for centrally controlling the subscription
CN1984309A (en) Method for realizing dialing set in multi-medium video-signal system
CN111193621B (en) Method for guaranteeing data communication between RTOS (real time operating System) equipment side and server side of Internet of things

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