WO2019227366A1 - 一种基于切片的rtp流媒体存储、读取方法及装置 - Google Patents

一种基于切片的rtp流媒体存储、读取方法及装置 Download PDF

Info

Publication number
WO2019227366A1
WO2019227366A1 PCT/CN2018/089156 CN2018089156W WO2019227366A1 WO 2019227366 A1 WO2019227366 A1 WO 2019227366A1 CN 2018089156 W CN2018089156 W CN 2018089156W WO 2019227366 A1 WO2019227366 A1 WO 2019227366A1
Authority
WO
WIPO (PCT)
Prior art keywords
slice
rtp
information
index file
description information
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
PCT/CN2018/089156
Other languages
English (en)
French (fr)
Inventor
洪家明
杨燕伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hytera Communications Corp Ltd
Original Assignee
Hytera Communications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hytera Communications Corp Ltd filed Critical Hytera Communications Corp Ltd
Priority to PCT/CN2018/089156 priority Critical patent/WO2019227366A1/zh
Publication of WO2019227366A1 publication Critical patent/WO2019227366A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/40Network security protocols

Definitions

  • the invention belongs to the technical field of streaming media, and particularly relates to a method and device for storing and reading RTP streaming media based on slices.
  • Real-time Transport Protocol is a real-time streaming media protocol.
  • the RTP protocol is widely used in streaming media-related communications and entertainment, including telephone, video conferencing, video surveillance, television, and network-based push-to-talk services (similar to intercom calls).
  • the object of the present invention is to provide a method and a device for storing and reading RTP streaming media based on slices, so as to solve the technical problem that traditional RTP streaming media does not store and read slices.
  • this application provides a slice-based RTP streaming media storage method, including:
  • RTP stream file based on an RTP slice, where the RTP slice includes slice data and first description information, and the first description information includes information used to characterize the attributes of the RTP slice;
  • An index file capable of locating the RTP slice is generated according to the second description information of the RTP slice.
  • generating an index file capable of locating the RTP slice according to the second description information of the RTP slice includes:
  • the slice index file including a slice name, a slice type, a slice length, a slice storage location, a slice serial number, and a slice size of the RTP slice , Stream time and / or stream source;
  • a total index file is generated according to a slice index file corresponding to each RTP stream, and the total index file includes an RTP stream name, an RTP stream type, an RTP stream length, and / or an event related to the RTP stream, and a storage location of the slice index file.
  • generating the storage association description information of the RTP slice includes:
  • the method further includes: encrypting and storing the index file.
  • the index file is stored in a TLV format.
  • the first description information includes slice association information and slice attribute information
  • the slice association information represents an association relationship between different RTP slices in a same RTP stream
  • the slice attribute information represents an attribute of the RTP slice itself Information
  • the first description information further includes flow association information used to characterize different RTP flows.
  • the slice data in each RTP slice includes at least one data packet capable of being independently decoded.
  • this application provides a slice-based RTP streaming media reading method, including:
  • slice search information includes RTP slice information
  • An index file is used to find a storage location of the RTP slice that matches the slice search information, and the index file includes information capable of locating the RTP slice.
  • the index file includes a slice index file
  • the use of an index file to find a storage location of an RTP slice that matches the slice search information includes:
  • the index file includes a slice index file and a total index file;
  • the slice search information includes RTP stream information and RTP slice information;
  • the searching for a storage location of an RTP slice matching the slice search information by using an index file includes:
  • the present application provides a slice-based RTP streaming media storage device, including:
  • a first obtaining module configured to obtain an RTP stream file based on an RTP slice, where the RTP slice includes slice data and first description information, and the first description information includes information used to characterize the attributes of the RTP slice;
  • a first information generating module configured to generate storage association description information of each of the RTP slices, where the storage association description information represents information associated with storing the RTP slice;
  • a second information generating module configured to add the storage association description information of the RTP slice to the first description information corresponding to the RTP slice to obtain the second description information corresponding to the RTP slice;
  • a storage module configured to store second description information and slice data corresponding to the RTP slice
  • An index generation module is configured to generate an index file capable of locating the RTP slice according to the second description information of the RTP slice.
  • the present application provides a slice-based RTP streaming media reading device, including:
  • An obtaining module configured to obtain slice search information, where the slice search information includes RTP slice information
  • the searching module is configured to use an index file to find a storage location of the RTP slice matching the slice search information, and the index file includes information capable of locating the RTP slice.
  • the present application provides a computing device including a memory and a processor.
  • the memory stores a program that can be run on the processor.
  • the processor executes the program, the first and second aspects are implemented. The method described in any possible implementation.
  • the present application provides a storage medium executable by a computing device.
  • the storage medium stores a program, and when the program is executed by the computing device, any possible implementation of the first aspect and the second aspect is implemented. The method described.
  • the slice-based RTP streaming media storage method receives an RTP slice-based RTP stream file, wherein the RTP slice includes slice data and first description information; generates storage association description information of the RTP slice, and The storage association description information is added to the first description information to obtain the second description information of the RTP slice. Storing the second description information and slice data corresponding to the RTP slice; and generating an index file according to the second description information of the RTP slice.
  • the time required to find an RTP slice is greatly shortened, and the reading speed of the RTP slice is improved.
  • FIG. 1 is a flowchart of a slice-based RTP streaming media storage method according to an embodiment of the present application
  • FIG. 2 is a schematic diagram of a file format of an RTP slice according to an embodiment of the present application.
  • FIG. 3 is a schematic diagram of a relationship between an index file and an RTP file according to an embodiment of the present application
  • FIG. 4 is a flowchart of a slice-based RTP streaming media reading method according to an embodiment of the present application
  • FIG. 5 is a flowchart of a process of finding an RTP slice according to an embodiment of the present application.
  • FIG. 6 is a block diagram of a slice-based RTP streaming media storage device according to an embodiment of the present application.
  • FIG. 7 is a block diagram of a slice-based RTP streaming media reading device according to an embodiment of the present application.
  • FIG. 1 a flowchart of a slice-based RTP streaming media storage method according to an embodiment of the present application is shown.
  • the method is applied to a server.
  • the method may include the following steps:
  • the server receives the RTP stream-based RTP stream file sent by the RTP stream generator, that is, the RTP stream generator divides the RTP stream into a series of RTP slices.
  • the generated RTP slice includes slice data and first description information.
  • the slice data refers to content data of an RTP slice, that is, a plurality of RTP packets.
  • the first description information is used to characterize an association relationship between RTP slices.
  • the first description information includes slice association information and slice attribute information.
  • the slice association information represents the association relationship between different RTP slices in the same RTP stream, such as the predecessor fragment, the current fragment, and the subsequent fragment;
  • the slice attribute information represents the RTP slice itself attributes, such as slice size, number of packets, and synchronization time Stamp, duration, name, etc.
  • the first description information includes not only slice association information, slice attribute information, but also Including stream association information;
  • the flow association information represents the association relationship between different RTP streams, for example, composite association, synchronous association, and adaptive association.
  • FIG. 2 illustrates a schematic file format of an RTP slice according to an embodiment of the present application.
  • each RTP stream is formed by connecting multiple independent RTP slices, and each RTP slice is decoded independently.
  • Each RTP slice includes a description area and one or more RTP independent decoding units, where the description area is an independent index packet attached to the front of the RTP slice data and has a specific RTP payload type.
  • the description area includes a stream association description area, a slice association description area, and a slice attribute description area; each RTP independent decoding unit includes one or more RTP data packets, and the one or more RTP independent decoding units are the above-mentioned slice data.
  • the stream association description area stores stream association information, which is used to describe what kind of association exists between the current RTP stream and which RTP streams.
  • the association type includes composite, synchronous, and adaptive.
  • the slice association description area stores slice association information. Used to describe 1-2 predecessor slices and 1 subsequent slice of the current RTP slice; the slice attribute description area is used to describe the slice attribute information of the current RTP slice, including slice size, slice name, slice type, slice serial number, timestamp, Encrypted information, etc.
  • the transmission process requires data packets to be as concise as possible, so the information in this description area is as concise as possible.
  • the time stamps of the RTP slices are uniformly defined, and the time stamps may be relative time or absolute time.
  • the absolute time and the relative time are both based on the same time reference to ensure that the timestamps of the associated RTP streams remain the same.
  • the slice association information concatenates a series of RTP slices to form slice-based RTP streaming media, and each RTP slice is decoded independently, that is, the same RTP stream can have RTP slices with different media formats, decoding parameters, etc., without affecting transmission Play.
  • the stream association information associates multiple RTP streams based on RTP slices to form a composite RTP stream, which can associate multiple RTP streams with a certain relationship for transmission, association storage, association positioning, association playback, association encryption, and the like.
  • the same-origin RTP stream synchronization association can define lip tone synchronization, main and auxiliary stream synchronization, and so on.
  • the storage association description information represents information associated with storing the RTP slice.
  • the storage association description information is storage location information of the RTP slice.
  • the storage location of the RTP stream can be determined.
  • the RTP stream can be stored in the order of the pre-configured storage locations.
  • RTP slices in the same RTP stream are stored in a file, so the storage location of the RTP slice can be determined before the RTP slice is stored.
  • the storage association description information corresponding to the RTP slice generated in the previous step is added to the first description information of the RTP slice to obtain the second description information corresponding to the RTP slice.
  • S140 Store second description information and slice data corresponding to the RTP slice.
  • the second description information and slice data corresponding to the RTP slice are stored in a corresponding storage space in the server.
  • the second description information and the slice data may be stored separately.
  • the second description information of each RTP slice is stored in the first storage space
  • the slice data is stored in the second storage space.
  • the description information and slice data corresponding to the same RTP slice are stored in the same storage space.
  • RTP slices When storing RTP slices, they are stored in the format shown in FIG. 2, and RTP slices of the same RTP stream are stored in the same file.
  • the RTP slice contains slice data and corresponding description information, thereby associating the code stream with the service.
  • the description information includes the name, type, event, and association relationship between RTP streams; the event of the stream represents a certain service, and the association relationship between the streams reflects the relationship on the service.
  • the storage association information can be obtained before the RTP slice is stored, and then the second description information is generated according to the storage association information.
  • the storage association information may be generated after the RTP slice is stored, and then the second description information is generated according to the storage association information.
  • a slice index file is maintained in the server to record slice description information of different RTP slices of the same RTP stream.
  • the index file can be used to quickly locate the RTP slice to be found in the RTP stream.
  • the additional description information includes some information in the first description information and storage associated description information.
  • the index file includes a slice index file and a total index file; wherein the slice index file is used to store storage information between multiple RTP slices in the RTP stream, forming a relationship between slices, Used to index RTP slices in the same RTP stream.
  • the overall index file associates a series of RTP streams to form a composite RTP stream, which contains index information of different RTP streams, and is used to quickly locate the RTP stream.
  • the slice index file includes, but is not limited to, slice name, slice type, slice length, slice storage location, slice size, stream time, and / or stream source.
  • the slice storage location may be an absolute address of a storage space where the slice is stored, or the slice storage location may be a start storage address and an address offset of an RTP stream to which the RTP slice belongs.
  • the starting storage location is the storage location of the RTP stream.
  • the stream time includes the duration of the RTP slice, and / or, the offset time of the RTP slice relative to the first RTP slice of the current RTP stream.
  • the offset time can be used to locate the start time of the RTP slice, and the duration can be determined The end time of this RTP slice.
  • the stream source is used to characterize which RTP stream the RTP slice belongs to.
  • the total index file includes, but is not limited to, the stream name, stream type, stream length, and / or events involved in the RTP stream, the storage location of the slice index file, and the like.
  • FIG. 3 a schematic diagram of a relationship between an index file and an RTP slice according to an embodiment of the present application is shown.
  • an RTP stream includes n RTP slices, and a slice index file corresponding to each RTP stream is used to record information of each RTP slice in the RTP stream.
  • a slice index file corresponding to stream 1 is stream 1 slice.
  • the slice index file corresponding to stream 2 is the stream 2 slice index
  • the slice index file corresponding to stream 3 is the stream 3 slice index.
  • the total index file is the total index in the figure and is used to locate the RTP stream.
  • a slice index file of the RTP stream is used to locate a specific RTP slice.
  • Additional description information is stored in the slice index file and the total index file, which can indicate the storage location of the RTP slice and the storage location of the RTP stream, etc., in order to read the RTP slice quickly and accurately in the subsequent.
  • the slice index file and the total index file are stored in a TLV format, and the format is simple, efficient, and clear.
  • TLV is a variable format
  • T is an abbreviation for Type
  • L is an abbreviation for Length
  • V is an abbreviation for Value.
  • the Type field is information about the label and encoding format
  • the Length field is the length that defines the value
  • the Value field represents the actual value.
  • the slice index file and the total index file may be encrypted and stored to encrypt and protect sensitive information.
  • RTP slice, slice index file, and total index file can be disk files or data blocks in the file; the storage location is expressed by a URL, and the URL can be a relative path or an absolute path. Can be distributed storage.
  • the path can be a relative path, an absolute path, or a URL on the network, that is, RTP slices are available on the entire network, and distributed storage can also be used to implement end-to-end transmission of RTP streams.
  • the slice-based RTP streaming media storage method receives an RTP slice-based RTP stream, and the RTP slice includes slice data and first description information; generates storage association description information of the RTP slice, and stores the storage association description information It is added to the first description information to obtain the second description information of the RTP slice. Storing the second description information and slice data corresponding to the RTP slice; and generating an index file according to the second description information of the RTP slice.
  • the time required to find an RTP slice is greatly shortened, and the reading speed of the RTP slice is improved.
  • FIG. 4 shows a flowchart of a slice-based RTP streaming media reading method according to an embodiment of the present application.
  • the method is applied to a server. After the server stores the RTP streaming media by using the method shown in FIG.
  • the reading method provided in the embodiment reads the RTP slice.
  • the reading method may include the following steps:
  • the slice search information includes at least one of RTP stream information and RTP slice information.
  • RTP stream information includes at least one of RTP stream information and RTP slice information.
  • the reading process of RTP slices is gradual, and coarse positioning is performed first, and then precise positioning is performed in the coarse positioning result. Therefore, to locate an RTP slice usually requires more than one slice search information to achieve accurate positioning.
  • the index file includes a slice index file and a total index file.
  • the process of finding an RTP slice may include the following steps:
  • the search information for locating the RTP stream may include one or more index entries stored in the total index file, for example, a stream name, a stream type, a stream length, and an event.
  • the search information for locating the RTP slice may include one or more index entries stored in the slice index file, such as slice name, slice type, time, and so on.
  • the slice-based RTP streaming media reading method provided in this embodiment obtains slice search information, and then uses the total index file to quickly locate the location of the slice index file, and then uses the obtained slice index file to quickly locate the RTP slice, which greatly shortens The time required to find RTP slices is improved, and the efficiency of reading RTP slices is improved.
  • this application also provides an embodiment of a device for storing RTP streaming media based on slices.
  • FIG. 6 a block diagram of a slice-based RTP streaming media storage device according to an embodiment of the present application is shown.
  • the device is applied to a server.
  • the device includes: a first obtaining module 110, a first information generating module 120, a second information generating module 130, a storage module 140, and an index generating module 150.
  • the first obtaining module 110 is configured to obtain an RTP stream file based on an RTP slice.
  • the RTP slice includes slice data and first description information, and the first description information includes information used to characterize the attributes of the RTP slice.
  • the first information generating module 120 is configured to generate storage association description information of each RTP slice, where the storage association description information represents information associated with the storage RTP slice.
  • the first information generating module 120 is specifically configured to:
  • the second information generating module 130 is configured to add the storage association description information of the RTP slice to the first description information corresponding to the RTP slice to obtain the second description information corresponding to the RTP slice.
  • the storage module 140 is configured to store second description information and slice data corresponding to the RTP slice.
  • the index generating module 150 is configured to generate an index file capable of locating the RTP slice according to the second description information of the RTP slice.
  • the index generating module 150 is specifically configured to:
  • the slice index file includes the slice name, slice type, slice length, slice storage location, slice sequence number, slice size, stream time, and / or stream source of the RTP slice. .
  • a total index file is generated according to a slice index file corresponding to each RTP stream, and the total index file includes an RTP stream name, an RTP stream type, an RTP stream length, and / or an event related to the RTP stream and a storage location of the slice index file.
  • the index file is encrypted and stored to improve data security.
  • the slice-based RTP streaming media storage device receives an RTP slice-based RTP stream file, where the RTP slice includes slice data and first description information; generates storage association description information of the RTP slice, and The storage association description information is added to the first description information to obtain the second description information of the RTP slice. Storing the second description information and slice data corresponding to the RTP slice; and generating an index file according to the second description information of the RTP slice.
  • the time required to find an RTP slice is greatly shortened, and the reading speed of the RTP slice is improved.
  • this application also provides an embodiment of a slice-based RTP streaming media reading device.
  • FIG. 7 a block diagram of a slice-based RTP streaming media reading device according to an embodiment of the present application is shown.
  • the device is applied to a server.
  • the apparatus may include: an obtaining module 210 and a searching module 220.
  • the obtaining module 210 is configured to obtain slice search information, where the slice search information includes RTP slice information.
  • the RTP slice information may include the slice related information and slice attribute information described above.
  • the searching module 220 is configured to use an index file to find a storage location of the RTP slice matching the slice search information, and the index file includes information capable of locating the RTP slice.
  • the index file includes only a slice index file.
  • the search module is specifically configured to store the target RTP slice storage location that matches the RTP slice information from the slice index file.
  • the index file includes a slice index file and a total index file, and the total index file is an index of the slice index file.
  • the slice search information includes RTP slice information and RTP stream information.
  • the search module 220 is specifically configured to: find the storage location of the slice index file that matches the RTP stream information by using the total index file; read the target slice index file according to the storage location of the slice index file; The index file finds the storage location of the target RTP slice that matches the RTP slice information in the slice search information.
  • the slice-based RTP streaming media reading device obtaineds slice search information, and then uses the total index file to quickly locate the location of the slice index file, and then uses the obtained slice index file to quickly locate the RTP slice, greatly reducing The time required to find RTP slices is improved, and the efficiency of reading RTP slices is improved.
  • An embodiment of the present application provides a computing device.
  • the computing device includes a processor and a memory, and the memory stores a program that can run on the processor.
  • the processor implements the following steps while running the program stored in memory:
  • RTP stream file based on an RTP slice, where the RTP slice includes slice data and first description information, and the first description information includes information used to characterize the attributes of the RTP slice;
  • An index file capable of locating the RTP slice is generated according to the second description information of the RTP slice.
  • generating an index file capable of locating the RTP slice according to the second description information of the RTP slice includes:
  • the slice index file including a slice name, a slice type, a slice length, a slice storage location, a slice serial number, and a slice size of the RTP slice , Stream time and / or stream source;
  • a total index file is generated according to a slice index file corresponding to each RTP stream, and the total index file includes an RTP stream name, an RTP stream type, an RTP stream length, and / or an event related to the RTP stream and a storage location of the slice index file.
  • generating the storage association description information of the RTP slice includes:
  • the method further includes: encrypting and storing the index file.
  • the index file is stored in a TLV format.
  • the first description information includes slice association information and slice attribute information
  • the slice association information represents an association relationship between different RTP slices in a same RTP stream.
  • the slice attribute information represents information about the attributes of the RTP slice itself.
  • the first description information further includes flow association information used to characterize different RTP flows.
  • the slice data in each RTP slice includes at least one data packet capable of being independently decoded.
  • slice search information includes RTP slice information
  • An index file is used to find a storage location of the RTP slice matching the slice search information, and the index file includes information capable of locating the RTP slice.
  • the index file includes a slice index file
  • the use of an index file to find a storage location of an RTP slice that matches the slice search information includes:
  • the index file includes a slice index file and a total index file;
  • the slice search information includes RTP stream information and RTP slice information;
  • the searching for a storage location of an RTP slice matching the slice search information by using an index file includes:
  • the present application also provides a storage medium executable by a computing device.
  • the storage medium stores a program.
  • the program is executed by the computing device, the slice-based RTP streaming media storage method and slice-based RTP streaming media reading are implemented. method.
  • the memory in this document may include non-persistent memory, random access memory (RAM) and / or non-volatile memory in computer-readable media, such as read-only memory (ROM) or flash memory (RAM), memory Includes at least one memory chip.
  • RAM random access memory
  • ROM read-only memory
  • RAM flash memory
  • the processor contains a kernel, and the kernel fetches the corresponding program from the memory.
  • the kernel can set one or more.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

本申请提供了一种基于切片的RTP流媒体存储、读取方法及装置,该存储方法具体包括接收基于RTP切片的RTP流文件,其中,该RTP切片包括切片数据和第一描述信息;生成该RTP切片的存储关联描述信息,并将该存储关联描述信息添加到第一描述信息中,得到该RTP切片的第二描述信息。存储该RTP切片对应的第二描述信息及切片数据;以及,根据该RTP切片的第二描述信息生成索引文件。以便快速读取某个RTP切片,大大缩短了查找RTP切片所需的时间,提高RTP切片的读取速度。

Description

一种基于切片的RTP流媒体存储、读取方法及装置 技术领域
本发明属于流媒体技术领域,尤其涉及一种基于切片的RTP流媒体存储、读取方法及装置。
背景技术
实时传输协议(Real-time Transport Protocol,RTP)是一种实时流媒体协议。RTP协议广泛应用于流媒体相关的通讯和娱乐,包括电话、视频会议、视频监控、电视和基于网络的一键通业务(类似对讲机的通话)。
由于目前的RTP流媒体协议中没有关于如何基于切片进行存储和定位RTP流文件的统一定义,很难实现基于RTP流媒体的切片技术方案。而相关技术中,成熟的切片技术例如,HLS(HTTP Live Streaming)、MPEG-DASH、HDS基本都是基于HTTP协议。目前尚未针对RTP协议的切片技术。
发明内容
有鉴于此,本发明的目的在于提供一种基于切片的RTP流媒体存储、读取方法及装置,以解决传统的RTP流媒体没有针对切片的存储和读取的技术问题。
第一方面,本申请提供了一种基于切片的RTP流媒体存储方法,包括:
获取基于RTP切片的RTP流文件,所述RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息;
对于每一个RTP切片执行以下步骤:
生成所述RTP切片的存储关联描述信息,所述存储关联描述信息表征与存储所述RTP切片相关联的信息;
将所述存储关联描述信息添加到所述第一描述信息中,得到所述RTP切片对应的第二描述信息;
存储与所述RTP切片对应的第二描述信息及切片数据;
根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件。
可选地,根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件,包括:
根据所述RTP切片对应的第二描述信息生成所述RTP切片对应的索引项;
将所述索引项存储到所述RTP切片所属RTP流的切片索引文件中,所述切片索引文件包括所述RTP切片的切片名称、切片类型、切片长度、切片存储位置、切片序列号、切片大小、流时间和/或流来源;
根据各个RTP流对应的切片索引文件生成总索引文件,所述总索引文件包括RTP流名称、RTP流类型、RTP流长度和/或RTP流涉及的事件以及所述切片索引文件的存储位置。
可选地,生成所述RTP切片的存储关联描述信息,包括:
确定用于存储所述RTP切片的存储位置;
根据所述存储位置得到所述存储关联描述信息。
可选地,所述方法还包括:对所述索引文件进行加密存储。
可选地,所述索引文件采用TLV格式存储。
可选地,所述第一描述信息包括切片关联信息和切片属性信息,所述切片关联信息表征同一个RTP流内不同的RTP切片之间的关联关系,所述切片属性信息表征RTP切片自身属性的信息。
可选地,所述第一描述信息还包括用于表征不同RTP流之间的流关联信息。
可选地,每个RTP切片内的切片数据包括至少一个能够独立解码的数据包。
第二方面,本申请提供了一种基于切片的RTP流媒体读取方法,包括:
获取切片搜索信息,所述切片搜索信息包括RTP切片信息;
利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置, 所述索引文件包括能够定位所述RTP切片的信息。
可选地,所述索引文件包括切片索引文件;
所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置包括:
从切片索引文件中查找与所述RTP切片信息相匹配的目标RTP切片的存储位置。
可选地,所述索引文件包括切片索引文件和总索引文件;所述切片搜索信息包括RTP流信息和RTP切片信息;
所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,包括:
利用所述总索引文件查找到与所述切片搜索信息中的RTP流信息相匹配的切片索引文件的存储位置;
根据所述切片索引文件的存储位置读取目标切片索引文件;
利用所述目标切片索引文件查找到与所述切片搜索信息中的RTP切片信息相匹配的目标RTP切片的存储位置。
第三方面,本申请提供了一种基于切片的RTP流媒体存储装置,包括:
第一获取模块,用于获取基于RTP切片的RTP流文件,所述RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息;
第一信息生成模块,用于生成每一所述RTP切片的存储关联描述信息,所述存储关联描述信息表征与存储所述RTP切片相关联的信息;
第二信息生成模块,用于将所述RTP切片的存储关联描述信息添加到所述RTP切片对应的第一描述信息中,得到所述RTP切片对应的第二描述信息;
存储模块,用于存储与所述RTP切片对应的第二描述信息及切片数据;
索引生成模块,用于根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件。
第四方面,本申请提供了一种基于切片的RTP流媒体读取装置,包括:
获取模块,用于获取切片搜索信息,所述切片搜索信息包括RTP切片信息;
查找模块,用于利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,所述索引文件包括能够定位所述RTP切片的信息。
第五方面,本申请提供了一种计算设备,包括存储器和处理器,所述存储器内存储有可在处理器上运行的程序,处理器执行所述程序时实现第一方面和第二方面中任一种可能的实现方式所述的方法。
第六方面,本申请提供了一种计算设备可执行的存储介质,所述存储介质中存储有程序,所述程序由计算设备执行时实现第一方面和第二方面中任一种可能的实现方式所述的方法。
本申请实施例提供的基于切片的RTP流媒体存储方法,接收基于RTP切片的RTP流文件,其中,该RTP切片包括切片数据和第一描述信息;生成该RTP切片的存储关联描述信息,并将该存储关联描述信息添加到第一描述信息中,得到该RTP切片的第二描述信息。存储该RTP切片对应的第二描述信息及切片数据;以及,根据该RTP切片的第二描述信息生成索引文件。以便快速读取某个RTP切片,大大缩短了查找RTP切片所需的时间,提高RTP切片的读取速度。
附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本申请实施例一种基于切片的RTP流媒体存储方法的流程图;
图2是本申请实施例一种RTP切片的文件格式示意图;
图3是本申请实施例一种索引文件与RTP文件之间的关系示意图;
图4是本申请实施例一种基于切片的RTP流媒体读取方法的流程图;
图5是本申请实施例一种查找RTP切片过程的流程图;
图6是本申请实施例一种基于切片的RTP流媒体存储装置的框图;
图7是本申请实施例一种基于切片的RTP流媒体读取装置的框图。
具体实施方式
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
请参见图1,示出了本申请实施例一种基于切片的RTP流媒体存储方法的流程图,该方法应用于服务器中,如图1所示,该方法可以包括以下步骤:
S110,接收基于RTP切片的RTP流文件。
服务器接收RTP流生成方发送的基于RTP切片的RTP流文件,即,RTP流生成方将RTP流分割成一系列RTP切片。生成的RTP切片包括切片数据和第一描述信息。切片数据是指RTP切片的内容数据,即,多个RTP数据包。第一描述信息用于表征RTP切片之间的关联关系。
在本申请一种可能的应用场景中,同一时刻只需处理一个RTP流,例如,双方通话,此种应用场景下,,第一描述信息包括切片关联信息、切片属性信息。
其中,切片关联信息表征同一个RTP流内不同RTP切片之间的关联关系,例如,前驱片段、当前片段和后继片段;切片属性信息表征RTP切片自身属性,例如,切片大小、包数、同步时间戳、时长、名称等。
在本申请的另一种可能的应用场景中,同一时刻需要处理多个RTP流,例如,多方通话、视频会议等,此种应用场景下第一描述信息不仅包括切片关联信息、切片属性信息还包括流关联信息;
流关联信息表征不同RTP流之间的关联关系,例如,复合关联、同步关联、自适应关联。
请参见图2,示出了本申请实施例一种RTP切片的文件格式示意图,如图 2所示,每一个RTP流由多个独立的RTP切片连接而成,每个RTP切片独立解码。
每一个RTP切片包括描述区和一个或多个RTP独立解码单元,其中,描述区是附加在RTP切片数据前面的独立索引包,具有特定的RTP载荷类型。该描述区包括流关联描述区、切片关联描述区和切片属性描述区;每一个RTP独立解码单元包括一个或多个RTP数据包,该一个或多个RTP独立解码单元即上述的切片数据。
其中,流关联描述区存储流关联信息,用于描述当前RTP流与哪些RTP流之间的存在哪种关联类型,关联类型包括复合、同步和自适应;切片关联描述区存储切片关联信息,用于描述当前RTP切片的1-2个前驱切片和1个后继切片;切片属性描述区用于描述当前RTP切片的切片属性信息,包括切片大小、切片名称、切片类型、切片序列号、时间戳、加密信息等。传输过程要求数据包尽量精简,因此,该描述区内的信息尽量精简。
在本申请的一个实施例中,RTP切片的时间戳实现统一定义,该时间戳可以是相对时间或绝对时间。其中,绝对时间和相对时间都基于相同的时间基准,以保证相关联的各个RTP流的时间戳保持一致。
切片关联信息将一系列RTP切片串联形成基于切片的RTP流媒体,而且,各个RTP切片之间独立解码,即,同一个RTP流中可以有不同媒体格式、解码参数等的RTP切片,不影响传输、播放。
流关联信息将多个基于RTP切片的RTP流关联形成复合RTP流,能够将具有一定关系的多个RTP流关联传输、关联存储、关联定位、关联播放、关联加密等。例如,同源RTP流同步关联,可定义唇音同步、主辅流同步等。
S120,生成该RTP切片的存储关联描述信息。
存储关联描述信息表征与存储该RTP切片相关联的信息。在本申请的一个实施例中,该存储关联描述信息即该RTP切片的存储位置信息。
在接收到RTP流之后该RTP流的存储位置就能够确定,例如,可以按照预先配置的存储位置顺序进行存储。通常,同一个RTP流中的RTP切片存储 在一个文件中,因此,在存储RTP切片之前能够确定该RTP切片的存储位置。
S130,将该存储关联描述信息添加到RTP切片的第一描述信息中,得到第二描述信息。
将上一步骤生成的该RTP切片对应的存储关联描述信息添加到该RTP切片的第一描述信息中,得到该RTP切片对应的第二描述信息。
S140,存储与该RTP切片对应的第二描述信息及切片数据。
将该RTP切片对应的第二描述信息及切片数据存储到服务器中的相应存储空间中。
在本申请的一个实施例中,该第二描述信息和切片数据可以分开存储,例如,每一个RTP切片的第二描述信息均存储在第一存储空间内,切片数据均存储在第二存储空间内。
在本申请的另一个实施例中,同一RTP切片对应的描述信息和切片数据存储在同一存储空间内。
存储RTP切片时,以图2所示的格式进行存储,将同一个RTP流的RTP切片存储在同一个文件中。
RTP切片中包含切片数据和对应的描述信息,从而将码流与业务关联起来。该描述信息中包含RTP流的名称、类型、事件、RTP流间的关联关系;流的事件表示某种业务,流间的关联关系反应业务上的关系。
本实施例中,在存储RTP切片之前就能获得存储关联信息,然后,根据该存储关联信息生成第二描述信息。
在本申请的其它实施例中,存储关联信息可以在存储RTP切片之后生成,然后,再根据存储关联信息生成第二描述信息。
S150,根据该RTP切片文件的第二描述信息生成用于定位RTP切片的索引文件。
在服务器中维护一个切片索引文件记录同一个RTP流的不同RTP切片的切片描述信息。利用该索引文件能够在该RTP流中快速定位到要找的RTP切片。
根据RTP切片的第二描述信息生成该RTP切片的附加描述信息,并将该附加描述信息作为索引项添加到该RTP切片所属RTP流的切片索引文件中切片索引文件中。其中,附加描述信息包括第一描述信息中部分信息及存储关联描述信息。
在本申请的一个优选实施例中,索引文件包括切片索引文件和总索引文件;其中,切片索引文件用于存储该RTP流内多个RTP切片之间的存储信息,形成一个切片间的关系,用于索引定位同一个RTP流中的RTP切片。总索引文件将一系列RTP流关联形成复合RTP流,包含不同RTP流的索引信息,用于快速定位RTP流。
切片索引文件包括但不限于切片名称、切片类型、切片长度、切片存储位置、切片大小、流时间和/或流来源。
其中,切片存储位置可以是存储该切片的存储空间的绝对地址,或者,该切片存储位置可以是该RTP切片所属RTP流的起始存储地址和地址偏移量,此种方式中的RTP流的起始存储位置即该RTP流的存储位置。
流时间包括该RTP切片的时长,和/或,该RTP切片相对于当前RTP流的第一RTP切片的偏移时间,通过该偏移时间能够定位该RTP切片的起始时刻,通过时长能够确定该RTP切片的终止时刻。流来源用于表征该RTP切片属于哪个RTP流。
总索引文件包括但不限于流名称、流类型、流长度和/或RTP流所涉及的事件、切片索引文件的存储位置等。
请参见图3,示出了本申请实施例一种索引文件与RTP切片之间的关系示意图。
如图3所示,一个RTP流包括n个RTP切片,每一个RTP流对应的切片索引文件用于记录该RTP流内各个RTP切片的信息,例如,流1对应的切片索引文件即流1切片索引,流2对应的切片索引文件即流2切片索引,流3对应的切片索引文件即流3切片索引。总索引文件即图中的总索引,用于定位RTP流。然后,利用该RTP流的切片索引文件定位具体的RTP切片。
在切片索引文件和总索引文件中存储了附加描述信息,可以表示RTP切片的存储位置和RTP流的存储位置等,以便后续快速、准确地读取RTP切片。
在本申请的一个优选实施例中,切片索引文件和总索引文件采用TLV格式存储,格式简单高效且清晰易懂。TLV是一种可变的格式,T是Type(类型)的缩写,L是Length(长度)的缩写,V是Value(值)的缩写。Type字段是关于标签和编码格式的信息;Length字段是定义数值的长度;Value字段表示实际的数值。
在本申请的另一个优选实施例中,切片索引文件和总索引文件可以加密存储从而对敏感信息进行加密保护。
需要说明的是,RTP切片、切片索引文件和总索引文件可以是磁盘文件、文件中的数据块;存储位置采用URL表达,URL可以是相对路径或绝对路径,即,RTP切片全网可用,因此可以分布式存储。
路径可以是相对路径、绝对路径或者是网络上的一个URL,即,RTP切片全网可用,可以分布式存储也可以实现RTP流的端到端传输。
本实施例提供的基于切片的RTP流媒体存储方法,接收基于RTP切片的RTP流,RTP切片包括切片数据和第一描述信息;生成该RTP切片的存储关联描述信息,并将该存储关联描述信息添加到第一描述信息中,得到该RTP切片的第二描述信息。存储该RTP切片对应的第二描述信息及切片数据;以及,根据该RTP切片的第二描述信息生成索引文件。以便快速读取某个RTP切片,大大缩短了查找RTP切片所需的时间,提高RTP切片的读取速度。
请参见图4,示出了本申请实施例一种基于切片的RTP流媒体读取方法的流程图,该方法应用于服务器中,服务器利用图1所示的方法存储RTP流媒体之后,利用本实施例提供的读取方法读取RTP切片。
如图4所示,该读取方法可以包括以下步骤:
S210,获取切片搜索信息。
该切片搜索信息包括RTP流信息和RTP切片信息中的至少一个。通常,RTP切片的读取过程是渐进的,先进行粗略定位,再在粗略定位结果中进行精 确定位。因此,要定位一个RTP切片通常需要不止一个切片搜索信息才能实现精确定位。
S220,利用索引文件查找与该切片搜索信息相匹配的RTP切片的存储位置。
在本申请的一个实施例中,索引文件包括切片索引文件和总索引文件;如图5所示,查找RTP切片的过程可以包括以下步骤:
S221,利用总索引文件查找与切片搜索信息中的RTP流信息相匹配的切片索引文件的存储位置。
定位RTP流的搜索信息可以包括总索引文件中存储的一个或多个索引项,例如,流名称、流类型、流长度、事件。
S222,利用该切片索引文件查找到与切片搜索信息中的RTP切片信息相匹配的目标RTP切片的存储位置。
定位RTP切片的搜索信息可以包括切片索引文件中存储的一个或多个索引项,例如,切片名称、切片类型、时间等。
S230,读取该存储位置对应存储空间所存储的RTP切片文件。
本实施例提供的基于切片的RTP流媒体读取方法,获取切片搜索信息,然后,利用总索引文件快速定位切片索引文件的位置,然后,利用定位得到的切片索引文件快速定位RTP切片,大大缩短了查找RTP切片所需的时间,提高了读取RTP切片的效率。
对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本发明并不受所描述的动作顺序的限制,因为依据本发明,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于优选实施例,所涉及的动作和模块并不一定是本发明所必须的。
相应于上述的基于切片的RTP流媒体存储方法实施例,本申请还提供了基于切片的RTP流媒体存储装置实施例。
请参见图6,示出了本申请实施例一种基于切片的RTP流媒体存储装置 的框图,该装置应用于服务器中。如图6所示,该装置包括:第一获取模块110、第一信息生成模块120、第二信息生成模块130、存储模块140和索引生成模块150。
第一获取模块110,用于获取基于RTP切片的RTP流文件。
RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息。
第一信息生成模块120,用于生成每一RTP切片的存储关联描述信息,该存储关联描述信息表征与存储RTP切片相关联的信息。
在本申请一个可能的实施例中,第一信息生成模块120具体用于:
确定用于存储所述RTP切片的存储位置;以及,根据该存储位置得到存储关联描述信息。
第二信息生成模块130,用于将RTP切片的存储关联描述信息添加到RTP切片对应的第一描述信息中,得到RTP切片对应的第二描述信息。
存储模块140,用于存储与RTP切片对应的第二描述信息及切片数据。
索引生成模块150,用于根据RTP切片的第二描述信息生成能够定位RTP切片的索引文件。
在本申请一个可能的实施例中,索引生成模块150具体用于:
根据RTP切片对应的第二描述信息生成RTP切片对应的索引项;
将索引项存储到RTP切片所属RTP流的切片索引文件中,切片索引文件包括RTP切片的切片名称、切片类型、切片长度、切片存储位置、切片序列号、切片大小、流时间和/或流来源。
根据各个RTP流对应的切片索引文件生成总索引文件,总索引文件包括RTP流名称、RTP流类型、RTP流长度和/或RTP流涉及的事件及切片索引文件的存储位置。
在本申请的一个优选实施例中,生成索引文件后,对该索引文件进行加密存储,提高数据的安全性。
本实施例提供的基于切片的RTP流媒体存储装置,接收基于RTP切片的 RTP流文件,其中,该RTP切片包括切片数据和第一描述信息;生成该RTP切片的存储关联描述信息,并将该存储关联描述信息添加到第一描述信息中,得到该RTP切片的第二描述信息。存储该RTP切片对应的第二描述信息及切片数据;以及,根据该RTP切片的第二描述信息生成索引文件。以便快速读取某个RTP切片,大大缩短了查找RTP切片所需的时间,提高RTP切片的读取速度。
相应于上述的基于切片的RTP流媒体读取方法实施例,本申请还提供了基于切片的RTP流媒体读取装置实施例。
请参见图7,示出了本申请实施例一种基于切片的RTP流媒体读取装置的框图,该装置应用于服务器中。如图7所示,该装置可以包括:获取模块210和查找模块220。
获取模块210,用于获取切片搜索信息,切片搜索信息包括RTP切片信息。
RTP切片信息可以包括上述的切片关联信息和切片属性信息。
查找模块220,用于利用索引文件查找与切片搜索信息相匹配的RTP切片的存储位置,索引文件包括能够定位RTP切片的信息。
在本申请的一个应用场景中,索引文件仅包括切片索引文件,此时,查找模块具体用于从切片索引文件中与RTP切片信息相匹配的目标RTP切片的存储位置。
在本申请的另一个应用场景中,索引文件包括切片索引文件和总索引文件,总索引文件是切片索引文件的索引。此种应用场景中,切片搜索信息包括RTP切片信息和RTP流信息。
此种应用场景下,查找模块220具体用于:利用总索引文件查找到与RTP流信息相匹配的切片索引文件的存储位置;根据切片索引文件的存储位置读取目标切片索引文件;利用目标切片索引文件查找到与切片搜索信息中的RTP切片信息相匹配的目标RTP切片的存储位置。
本实施例提供的基于切片的RTP流媒体读取装置,获取切片搜索信息,然后,利用总索引文件快速定位切片索引文件的位置,然后,利用定位得到的 切片索引文件快速定位RTP切片,大大缩短了查找RTP切片所需的时间,提高了读取RTP切片的效率。
本申请实施例提供了一种计算设备,该计算设备包括处理器和存储器,该存储器内存储有可在处理器上运行的程序。
该处理器运行存储器内存储的该程序时实现以下步骤:
获取基于RTP切片的RTP流文件,所述RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息;
对于每一个RTP切片执行以下步骤:
生成所述RTP切片的存储关联描述信息,所述存储关联描述信息表征与存储所述RTP切片相关联的信息;
将所述存储关联描述信息添加到所述第一描述信息中,得到所述RTP切片对应的第二描述信息;
存储与所述RTP切片对应的第二描述信息及切片数据;
根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件。
在本申请一种可能的实现方式中,根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件,包括:
根据所述RTP切片对应的第二描述信息生成所述RTP切片对应的索引项;
将所述索引项存储到所述RTP切片所属RTP流的切片索引文件中,所述切片索引文件包括所述RTP切片的切片名称、切片类型、切片长度、切片存储位置、切片序列号、切片大小、流时间和/或流来源;
根据各个RTP流对应的切片索引文件生成总索引文件,所述总索引文件包括RTP流名称、RTP流类型、RTP流长度和/或RTP流涉及的事件及所述切片索引文件的存储位置。
在本申请另一种可能的实现方式中,生成所述RTP切片的存储关联描述信息,包括:
确定用于存储所述RTP切片的存储位置;
根据所述存储位置得到所述存储关联描述信息。
在本申请又一种可能的实现方式中,所述方法还包括:对所述索引文件进行加密存储。
在本申请再一种可能的实现方式中,所述索引文件采用TLV格式存储。
在本申请另一种可能的实现方式中,所述第一描述信息包括切片关联信息和切片属性信息,所述切片关联信息表征同一个RTP流内不同的RTP切片之间的关联关系,所述切片属性信息表征RTP切片自身属性的信息。
在本申请又一种可能的实现方式中,所述第一描述信息还包括用于表征不同RTP流之间的流关联信息。
在本申请再一种可能的实现方式中,每个RTP切片内的切片数据包括至少一个能够独立解码的数据包。
该计算设备中的存储器中还存储有另一种程序,该程序被处理器执行时实现以下步骤:
获取切片搜索信息,所述切片搜索信息包括RTP切片信息;
利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,所述索引文件包括能够定位所述RTP切片的信息。
在本申请一种可能的实现方式中,所述索引文件包括切片索引文件;
所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置包括:
从切片索引文件中查找与所述RTP切片信息相匹配的目标RTP切片的存储位置。
在本申请另一种可能的实现方式中,所述索引文件包括切片索引文件和总索引文件;所述切片搜索信息包括RTP流信息和RTP切片信息;
所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,包括:
利用所述总索引文件查找到与所述切片搜索信息中的RTP流信息相匹配的切片索引文件的存储位置;
根据所述切片索引文件的存储位置读取目标切片索引文件;
利用所述目标切片索引文件查找到与所述切片搜索信息中的RTP切片信息相匹配的目标RTP切片的存储位置。
本申请还提供了一种计算设备可执行的存储介质,该存储介质中存储有程序,该程序由计算设备执行时实现上述的基于切片的RTP流媒体存储方法及基于切片的RTP流媒体读取方法。
本文中的存储器可能包括计算机可读介质中的非永久性存储器,随机存取存储器(RAM)和/或非易失性内存等形式,如只读存储器(ROM)或闪存(flash RAM),存储器包括至少一个存储芯片。
处理器中包含内核,由内核取存储器中调取相应的程序,内核可以设置一个或以上。
需要说明的是,本说明书中的各个实施例均采用递进的方式描述,每个实施例重点说明的都是与其他实施例的不同之处,各个实施例之间相同相似的部分互相参见即可。对于装置类实施例而言,由于其与方法实施例基本相似,所以描述的比较简单,相关之处参见方法实施例的部分说明即可。
最后,还需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。而且,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。
对所公开的实施例的上述说明,使本领域技术人员能够实现或使用本发明。对这些实施例的多种修改对本领域技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本发明的精神或范围的情况下,在其它实施例中实现。因此,本发明将不会被限制于本文所示的这些实施例,而是要符合与 本文所公开的原理和新颖特点相一致的最宽的范围。
以上所述仅是本发明的优选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本发明原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本发明的保护范围。

Claims (15)

  1. 一种基于切片的RTP流媒体存储方法,包括:
    获取基于RTP切片的RTP流文件,所述RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息;
    对于每一个RTP切片执行以下步骤:
    生成所述RTP切片的存储关联描述信息,所述存储关联描述信息表征与存储所述RTP切片相关联的信息;
    将所述存储关联描述信息添加到所述第一描述信息中,得到所述RTP切片对应的第二描述信息;
    存储与所述RTP切片对应的第二描述信息及切片数据;
    根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件。
  2. 根据权利要求1所述的方法,其中,根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件,包括:
    根据所述RTP切片对应的第二描述信息生成所述RTP切片对应的索引项;
    将所述索引项存储到所述RTP切片所属RTP流的切片索引文件中,所述切片索引文件包括所述RTP切片的切片名称、切片类型、切片长度、切片存储位置、切片序列号、切片大小、流时间和/或流来源;
    根据各个RTP流对应的切片索引文件生成总索引文件,所述总索引文件包括RTP流名称、RTP流类型、RTP流长度和/或RTP流涉及的事件以及所述切片索引文件的存储位置。
  3. 根据权利要求1或2所述的方法,其中,生成所述RTP切片的存储关联描述信息,包括:
    确定用于存储所述RTP切片的存储位置;
    根据所述存储位置得到所述存储关联描述信息。
  4. 根据权利要求1-3任一项所述的方法,其中,所述方法还包括:对所述索引文件进行加密存储。
  5. 根据权利要求1-3任一项所述的方法,其中,所述索引文件采用TLV格式存储。
  6. 根据权利要求1-3任一项所述的方法,其中,所述第一描述信息包括切片关联信息和切片属性信息,所述切片关联信息表征同一个RTP流内不同的RTP切片之间的关联关系,所述切片属性信息表征RTP切片自身属性的信息。
  7. 根据权利要求6所述的方法,其中,所述第一描述信息还包括用于表征不同RTP流之间的流关联信息。
  8. 根据权利要求1-3任一项所述的方法,其中,每个RTP切片内的切片数据包括至少一个能够独立解码的数据包。
  9. 一种基于切片的RTP流媒体读取方法,其中,包括:
    获取切片搜索信息,所述切片搜索信息包括RTP切片信息;
    利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,所述索引文件包括能够定位所述RTP切片的信息。
  10. 根据权利要求9所述的方法,其中,所述索引文件包括切片索引文件;
    所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置包括:
    从切片索引文件中查找与所述RTP切片信息相匹配的目标RTP切片的存储位置。
  11. 根据权利要求9所述的方法,其中,所述索引文件包括切片索引文件和总索引文件;所述切片搜索信息包括RTP流信息和RTP切片信息;
    所述利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,包括:
    利用所述总索引文件查找到与所述切片搜索信息中的RTP流信息相匹配的切片索引文件的存储位置;
    根据所述切片索引文件的存储位置读取目标切片索引文件;
    利用所述目标切片索引文件查找到与所述切片搜索信息中的RTP切片信 息相匹配的目标RTP切片的存储位置。
  12. 一种基于切片的RTP流媒体存储装置,,包括:
    第一获取模块,用于获取基于RTP切片的RTP流文件,所述RTP切片包括切片数据和第一描述信息,所述第一描述信息包括用于表征所述RTP切片属性的信息;
    第一信息生成模块,用于生成每一所述RTP切片的存储关联描述信息,所述存储关联描述信息表征与存储所述RTP切片相关联的信息;
    第二信息生成模块,用于将所述RTP切片的存储关联描述信息添加到所述RTP切片对应的第一描述信息中,得到所述RTP切片对应的第二描述信息;
    存储模块,用于存储与所述RTP切片对应的第二描述信息及切片数据;
    索引生成模块,用于根据所述RTP切片的第二描述信息生成能够定位所述RTP切片的索引文件。
  13. 一种基于切片的RTP流媒体读取装置,,包括:
    获取模块,用于获取切片搜索信息,所述切片搜索信息包括RTP切片信息;
    查找模块,用于利用索引文件查找与所述切片搜索信息相匹配的RTP切片的存储位置,所述索引文件包括能够定位所述RTP切片的信息。
  14. 一种计算设备,,包括存储器和处理器,所述存储器内存储有可在处理器上运行的程序,处理器执行所述程序时实现权利要求1-11任一项所述的方法。
  15. 一种计算设备可执行的存储介质,所述存储介质中存储有程序,所述程序由计算设备执行时实现权利要求1-11任一项所述的方法。
PCT/CN2018/089156 2018-05-31 2018-05-31 一种基于切片的rtp流媒体存储、读取方法及装置 Ceased WO2019227366A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/089156 WO2019227366A1 (zh) 2018-05-31 2018-05-31 一种基于切片的rtp流媒体存储、读取方法及装置

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/089156 WO2019227366A1 (zh) 2018-05-31 2018-05-31 一种基于切片的rtp流媒体存储、读取方法及装置

Publications (1)

Publication Number Publication Date
WO2019227366A1 true WO2019227366A1 (zh) 2019-12-05

Family

ID=68697760

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/089156 Ceased WO2019227366A1 (zh) 2018-05-31 2018-05-31 一种基于切片的rtp流媒体存储、读取方法及装置

Country Status (1)

Country Link
WO (1) WO2019227366A1 (zh)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114697025A (zh) * 2022-04-12 2022-07-01 京东方科技集团股份有限公司 数据加解密方法及相关设备
CN115473672A (zh) * 2022-08-03 2022-12-13 广西电网有限责任公司电力科学研究院 一种基于在线交互式web动态防御的防漏洞探测方法
CN115756926A (zh) * 2022-11-18 2023-03-07 济南浪潮数据技术有限公司 一种文件存储位置的测试方法、装置及可读存储介质

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102217313A (zh) * 2011-05-26 2011-10-12 华为技术有限公司 重排、抽取分片中媒体数据的方法、设备及系统
CN106549916A (zh) * 2015-09-18 2017-03-29 中兴通讯股份有限公司 组播传输方法、装置及系统
CN107634930A (zh) * 2016-07-18 2018-01-26 华为技术有限公司 一种媒体数据的获取方法和装置

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102217313A (zh) * 2011-05-26 2011-10-12 华为技术有限公司 重排、抽取分片中媒体数据的方法、设备及系统
CN106549916A (zh) * 2015-09-18 2017-03-29 中兴通讯股份有限公司 组播传输方法、装置及系统
CN107634930A (zh) * 2016-07-18 2018-01-26 华为技术有限公司 一种媒体数据的获取方法和装置

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114697025A (zh) * 2022-04-12 2022-07-01 京东方科技集团股份有限公司 数据加解密方法及相关设备
CN115473672A (zh) * 2022-08-03 2022-12-13 广西电网有限责任公司电力科学研究院 一种基于在线交互式web动态防御的防漏洞探测方法
CN115473672B (zh) * 2022-08-03 2024-03-29 广西电网有限责任公司电力科学研究院 一种基于在线交互式web动态防御的防漏洞探测方法
CN115756926A (zh) * 2022-11-18 2023-03-07 济南浪潮数据技术有限公司 一种文件存储位置的测试方法、装置及可读存储介质

Similar Documents

Publication Publication Date Title
US10650119B2 (en) Multimedia data processing method, apparatus, system, and storage medium
US10425427B2 (en) Template uniform resource locator signing
US10902474B2 (en) Targeted advertisement insertion for streaming media data
JP6106775B2 (ja) ダウンローディング及びストリーミングをサポートするパケット受信方法
US10691748B2 (en) Methods and apparatus to process call packets collected in a communications network
CN107800795A (zh) 区块信息的处理方法及装置
WO2016184229A1 (zh) 直播视频的录制方法和系统
US10334302B2 (en) Method and system for segment based recording
US11792254B2 (en) Use of in-band metadata as basis to access reference fingerprints to facilitate content-related action
CN101197840A (zh) 下载和存储文件的方法、系统、装置及生成标识的方法
US9591379B2 (en) Systems and methods for providing an advertisement calling proxy server
WO2015000137A1 (zh) 一种流媒体处理的方法、装置及系统
CN102438004B (zh) 获取媒体文件的元数据信息的方法、系统及多媒体播放器
WO2019227366A1 (zh) 一种基于切片的rtp流媒体存储、读取方法及装置
US20250386083A1 (en) Media streaming systems and methods
CN109977137B (zh) 一种数据查询方法和装置
CN108769789B (zh) 一种基于切片的rtp流媒体存储、读取方法及装置
CN111125426B (zh) 一种数据存储和查询的方法及装置
CN106658150B (zh) 一种实现回看处理的方法及装置
US12244572B2 (en) Client-side encryption of content for virtual meetings
CN106134156B (zh) 自适应流媒体的取证标记的信号发送和处理的方法及设备
CN115244943B (zh) 用于传输媒体数据的方法、设备和计算机可读存储介质
CN106534137B (zh) 媒体流传输方法及装置
CN110611666B (zh) 一种视联网信息的处理方法及装置
CN119052353A (zh) 一种数据传输方法、通信装置及存储介质

Legal Events

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

Ref document number: 18921116

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

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

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205 DATED 21/04/2021)

122 Ep: pct application non-entry in european phase

Ref document number: 18921116

Country of ref document: EP

Kind code of ref document: A1