WO2022247032A1 - 视频编码数据存储方法、装置及可读存储介质 - Google Patents

视频编码数据存储方法、装置及可读存储介质 Download PDF

Info

Publication number
WO2022247032A1
WO2022247032A1 PCT/CN2021/115033 CN2021115033W WO2022247032A1 WO 2022247032 A1 WO2022247032 A1 WO 2022247032A1 CN 2021115033 W CN2021115033 W CN 2021115033W WO 2022247032 A1 WO2022247032 A1 WO 2022247032A1
Authority
WO
WIPO (PCT)
Prior art keywords
image
knowledge
images
sequence
bin
Prior art date
Application number
PCT/CN2021/115033
Other languages
English (en)
French (fr)
Inventor
赵海武
王国中
范涛
李国平
Original Assignee
上海国茂数字技术有限公司
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 上海国茂数字技术有限公司 filed Critical 上海国茂数字技术有限公司
Publication of WO2022247032A1 publication Critical patent/WO2022247032A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/134Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the element, parameter or criterion affecting or controlling the adaptive coding
    • H04N19/157Assigned coding mode, i.e. the coding mode being predefined or preselected to be further used for selection of another element or parameter
    • H04N19/159Prediction type, e.g. intra-frame, inter-frame or bidirectional frame prediction
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/10Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
    • H04N19/169Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding
    • H04N19/177Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding characterised by the coding unit, i.e. the structural portion or semantic portion of the video signal being the object or the subject of the adaptive coding the unit being a group of pictures [GOP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/42Methods or arrangements for coding, decoding, compressing or decompressing digital video signals characterised by implementation details or hardware specially adapted for video compression or decompression, e.g. dedicated software implementation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/60Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using transform coding
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/76Television signal recording
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/18Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast

Definitions

  • the present invention relates to the field of image technology, in particular to a video encoding data storage method, device and readable storage medium.
  • Video storage technology is to store multiple frames of images in a sequence in the video into the storage medium, so as to realize the preservation and application of video data.
  • the purpose of the present invention is to provide a video coding data storage method, device and readable storage medium to solve the problem of wasting storage space caused by repeated storage of video sequence header data in traditional storage methods in order to provide random access function.
  • a video coding data storage method including:
  • each of the image groups is in one-to-one correspondence with each of the knowledge images, and all the knowledge images form a knowledge image sequence, and the knowledge image sequence is denoted as, wherein, is the (Kth +1) knowledge images corresponding to image groups, which is the number of knowledge images;
  • SHx.bin where x represents any legal character string that can be used for the file name
  • the character strings SHx.bin and Ds.bin are added in front of it, and its own sequence number and the sequence numbers of all the knowledge images it refers to are added in front of it.
  • the images in the same image group maintain a certain correlation.
  • the knowledge image is an image in the corresponding image group.
  • the knowledge image is an image formed by combining corresponding images.
  • the knowledge image sequence is encoded, and the number of generalized reference images of each knowledge image in the knowledge image sequence is not greater than a preset value during encoding, and the generalized reference images are the knowledge image sequences of the knowledge image sequence. knowledge image.
  • the method for encoding the knowledge image sequence includes lossy encoding, lossless encoding, intra-frame predictive encoding, inter-frame predictive encoding, transform encoding and statistical encoding.
  • intra-frame predictive coding is used to encode the knowledge image sequence; when the preset value is 1, the generalized reference image is a direct reference image; when the When the preset value is greater than or equal to 2, the generalized reference image includes two direct reference images or one direct reference image and one indirect reference image.
  • both the strings SHx.bin and Ds.bin end with a null character.
  • a video encoding data storage device including:
  • a grouping module used to divide all images included in the video sequence into several image groups
  • a search module configured to search for a knowledge image for each of the image groups, each of the image groups is in one-to-one correspondence with each of the knowledge images, and all the knowledge images constitute a knowledge image sequence, and the knowledge image sequence is denoted as, wherein , is the knowledge image corresponding to the (K+1)th image group, and is the number of knowledge images;
  • the first encoding module is used to encode the knowledge image sequence to obtain the encoded data of each knowledge image, which is denoted as the encoded data of the knowledge image;
  • the second encoding module is used to encode the image group corresponding to the knowledge image with reference to the knowledge image in the knowledge image sequence to obtain the encoded data of each image group, which is denoted as the (K+1)th image group the encoded data;
  • the first data processing module is used to organize the public information data required for decoding the video sequence into a video sequence header, which is denoted as SH. If the number of bits of SH and sum is not a multiple of 32, then fill 0 at its end until its bit The number is a multiple of 32, and the processed SH is stored as a file, and the file name is SHx.bin, where x represents any legal character string that can be used for the file name;
  • the second data processing module is used to supplement the character string SHx.bin in the front, supplement the serial number of itself and the serial numbers of all its generalized reference images in the front, and then store the processed files as a file in ascending order of K,
  • the file name is Ds.bin, where x represents any legal string that can be used for the file name;
  • the third data processing module is used to add character strings SHx.bin and Ds.bin to the front, to add its own serial number and the serial numbers of all the knowledge images it refers to.
  • a readable storage medium on which a program is stored, and when the program is executed, the method for storing video encoding data is realized.
  • the present invention provides a video encoding data storage method, device and readable storage medium, which solves the problem of wasting storage space caused by repeated storage of data such as video sequence headers in traditional storage methods in order to provide random access functions.
  • Fig. 1 is a step diagram of the video encoding data storage method provided by the present embodiment
  • FIG. 2 is a schematic diagram of a video encoding data storage device provided in this embodiment
  • the singular forms “a”, “an” and “the” include plural referents unless the content clearly dictates otherwise.
  • the term “or” is generally employed in its sense including “and/or” unless the content clearly dictates otherwise.
  • the term “several” is generally used in the meaning including “at least one”, unless the content clearly states otherwise.
  • the term “at least two” is generally used in the meaning including “two or more”, unless the content clearly states otherwise.
  • the terms “first”, “second”, and “third” are used for descriptive purposes only, and cannot be interpreted as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, a feature defined as “first”, “second” and “third” may explicitly or implicitly include one or at least two of these features.
  • the core idea of the present invention is to provide a video encoding data storage method, device and readable storage medium to solve the problem of wasting storage space caused by repeated storage of video sequence header data in traditional storage methods in order to provide random access function.
  • FIG. 1 is a step diagram of a method for storing video encoding data provided by this embodiment.
  • This embodiment provides a method for storing video encoding data, including the following steps:
  • each of the image groups corresponds to each of the knowledge images, and all the knowledge images form a knowledge image sequence, and the knowledge image sequence is denoted as, wherein, is the first
  • the knowledge images corresponding to (K+1) image groups are the number of knowledge images;
  • S7 store the processed SH as a file, and the file name is SHx.bin, where x represents any legal character string that can be used for the file name;
  • step S1 is executed to divide all the images included in the video sequence into several groups of pictures (GOP).
  • the images in the same image group maintain a certain correlation, that is, the images with higher correlation are divided into the same pixel group In order to facilitate the subsequent encoding of the knowledge image sequence and improve the compression efficiency.
  • step S2 is performed to find a knowledge image for each of the image groups, each of the image groups is in one-to-one correspondence with each of the knowledge images, and all the knowledge images constitute a knowledge image sequence, and the knowledge image sequence is denoted as, wherein , is the knowledge image corresponding to the (K+1)th image group, and is the number of knowledge images. For example, if all the images included in the video sequence are divided into 5 image groups, the knowledge image sequence can be recorded as the knowledge image corresponding to the first image group.
  • the knowledge image is an image in the corresponding image group.
  • the knowledge image is an image formed by combining corresponding images.
  • step S3 is executed to encode the sequence of knowledge images to obtain the encoded data of each knowledge image, denoted as the encoded data of the th knowledge image.
  • the compression efficiency of the knowledge image is improved by encoding the knowledge image sequence.
  • the knowledge image sequence is encoded, and the number of generalized reference images of each knowledge image in the knowledge image sequence is not greater than a preset value during encoding, and the generalized reference image is the knowledge of the knowledge image sequence image.
  • the method for encoding the knowledge image sequence includes lossy encoding, lossless encoding, intra-frame predictive encoding, inter-frame predictive encoding, transform encoding and statistical encoding.
  • the preset value is 0, it means that the knowledge image has no generalized reference image, so the sequence of knowledge images can only be encoded by intra-frame predictive coding.
  • the preset value is 1, it means that the generalized reference picture may have one generalized reference picture, and the generalized reference picture is a direct reference picture.
  • the generalized reference image may have two direct reference images or one direct reference image and one indirect reference image.
  • the knowledge image sequence is ⁇ 1, 2, 3, 4, 5 ⁇ , which means that it includes five knowledge images with sequence numbers 1, 2, 3, 4, and 5 respectively.
  • the knowledge image sequence is ⁇ 1, 2, 3, 4, 5 ⁇ which can only be encoded by intra-frame predictive coding; when 2, 3, 4, 5 can only be predicted by 1, then 1 is a direct reference image; when 3 can be directly used for intra-frame prediction through 1, 5 can be used for intra-frame prediction through 3, and can also be used for inter-frame prediction through 1, then 1 is a direct reference image for 3, and 3 is a direct reference for 5 Image, 1 is also an indirect reference image for 5.
  • step S4 refer to the knowledge image in the knowledge image sequence to encode the image group corresponding to the knowledge image, and obtain the encoded data of each image group, which is denoted as the encoding of the (K+1)th image group data. That is to say, each image group corresponds to a knowledge image, for example, the (K+1)th GOP corresponds to the knowledge image, and each image in the (K+1)th GOP can refer to the knowledge image, which is equivalent to There are encoding methods based on adding a reference image for each image.
  • step S5 is executed to organize the public information data required for decoding the video sequence into a video sequence header, denoted as SH.
  • the public information data is, for example, video sequence resolution, shooting time and other data.
  • step S6 if SH and the number of bits are not a multiple of 32, fill 0 at the end until the number of bits is a multiple of 32;
  • Execute step S7 store the processed SH as a file, and the file name is SHx.bin, where x represents any legal character string that can be used for the file name;
  • Execute step S8 add the character string SHx.bin in front, add its own serial number and the serial numbers of all its generalized reference images in front, and then store the processed ones in order of K from small to large as a file, and the file name is Ds .bin, where x represents any legal string that can be used for a filename.
  • each serial number is represented by four bytes, especially, 0xFFFFFFFF indicates the end of the generalized reference image serial number.
  • Execute step S9 add character strings SHx.bin and Ds.bin in front, and add its own serial number and serial numbers of all knowledge images it refers to in front of .
  • each serial number is represented by four bytes, in particular, 0xFFFFFFFF indicates the end of the knowledge image serial number.
  • the character strings SHx.bin and Ds.bin both end with a null character, that is, there is a character whose ASCII code is 0 at the end.
  • FIG. 2 is a schematic diagram of a video encoding data storage device provided by this embodiment.
  • the present invention also provides a video coding data storage device, including:
  • a grouping module 100 configured to divide all images included in the video sequence into several image groups
  • the search module 200 is configured to search for a knowledge image for each of the image groups, each of the image groups is in one-to-one correspondence with each of the knowledge images, and all the knowledge images form a knowledge image sequence, and the knowledge image sequence is denoted as, Wherein, is the knowledge image corresponding to the (K+1)th image group, and is the number of knowledge images;
  • the first encoding module 300 is configured to encode the sequence of knowledge images to obtain the encoded data of each knowledge image, denoted as the encoded data of the th knowledge image;
  • the second encoding module 400 is used to encode the image group corresponding to the knowledge image with reference to the knowledge image in the knowledge image sequence to obtain the encoded data of each image group, which is denoted as the (K+1)th image the encoded data of the group;
  • the first data processing module 500 is used to organize the public information data required for decoding the video sequence into a video sequence header, denoted as SH, if the number of bits of SH and sum is not a multiple of 32, then fill 0 at the end until it The number of bits is a multiple of 32, and the processed SH is stored as a file, and the file name is SHx.bin, where x represents any legal character string that can be used for the file name;
  • the second data processing module 600 is used to add the character string SHx.bin to the front, add its own serial number and the serial numbers of all its generalized reference images to the front, and then store the processed files as a file in ascending order of K , the file name is Ds.bin, where x represents any legal string that can be used for the file name;
  • the third data processing module 700 is used to add character strings SHx.bin and Ds.bin to the front, to add its own serial number and the serial numbers of all the knowledge images it refers to.
  • the images in the same image group maintain a certain correlation.
  • the search module 200 searches for a knowledge image for each of the image groups
  • the knowledge image may be an image in the corresponding image group, or an image formed by combining corresponding images.
  • the method for encoding the knowledge image sequence by the first encoding module 300 includes lossy encoding, lossless encoding, intra-frame predictive encoding, inter-frame predictive encoding, transform encoding and statistical encoding.
  • the first coding module 300 uses intra-frame predictive coding to code the knowledge image sequence; when the preset value is 1, the generalized reference image is For direct reference images, when the preset value is greater than or equal to 2, the generalized reference images include two direct reference images or one direct reference image and one indirect reference image.
  • the character strings SHx.bin and Ds.bin both end with a null character, that is, there is a character whose ASCII code is 0 at the end.
  • the present invention also provides a readable storage medium, on which a program is stored, and when the program is executed, the method for storing video encoding data is realized.
  • the embodiments of the present invention provide a video encoding data storage method, device and readable storage medium, which solves the problem of wasting storage space caused by repeated storage of data such as video sequence headers in traditional storage methods in order to provide random access functions.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Abstract

本发明提供了一种视频编码数据存储方法、装置及可读存储介质,方法包括:把视频序列包含的图像分成若干个图像组;为每个图像组寻找一个知识图像,构成一个知识图像序列;对知识图像序列进行编码,得到编码数据,记为;对图像组进行编码,得到编码数据,记为;将解码所需的公共信息数据组织成视频序列头,记为SH;使SH、和的比特数为32的倍数;把处理后的SH存储为SHx.bin;在前面补充SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将按照K从小到大的顺序存储为Ds.bin;在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号,解决了需要重复存储视频序列头等数据导致存储空间浪费的问题。

Description

视频编码数据存储方法、装置及可读存储介质 技术领域
本发明涉及图像技术领域,尤其涉及一种视频编码数据存储方法、装置及可读存储介质。
背景技术
基于视频传输或视频监控等需求,常需要对视频数据进行数据存储。随着互联网的发展,视频存储技术已经得到越来越广泛的应用,尤其在视频监控领域。视频存储技术是将视频中具有先后顺序的多帧图像存储到存储介质中,以此实现对视频数据的保存和应用。
目前,大部分视频存储技术主要采用图像编码技术压缩视频数据,再对压缩后的视频数据进行存储。在现有的视频数据存储方法中,为了提供随机访问功能,往往需要重复存储视频序列头等数据,浪费了大量存储空间。
发明内容
本发明的目的在于提供一种视频编码数据存储方法、装置及可读存储介质,以解决传统存储方法中为了提供随机访问功能,需要重复存储视频序列头等数据导致存储空间浪费的问题。
为了达到上述目的,作为本发明的第一个方面,提供了一种视频编码数据存储方法,包括:
把视频序列包含的所有图像分成若干个图像组;
为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据;
参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
将解码视频序列所需的公共信息数据组织成视频序列头,记为SH;
若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为 32的倍数为止;
把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。
可选的,把视频序列包含的所有图像分成若干个图像组时,使同一个所述图像组中的图像保持一定的相关性。
可选的,所述知识图像为对应的图像组中的某个图像。
可选的,所述知识图像为对应的图像组合成的图像。
可选的,对所述知识图像序列进行编码,编码时使所述知识图像序列中的各个知识图像的广义参考图像的数量不大于预设值,所述广义参考图像为所述知识图像序列的知识图像。
可选的,对所述知识图像序列进行编码的方法包括有损编码、无损编码、帧内预测编码、帧间预测编码、变换编码及统计编码。
可选的,当所述预设值为0时,采用帧内预测编码对所述知识图像序列进行编码;当所述预设值为1时,所述广义参考图像为直接参考图像;当所述预设值为大于或等于2时,所述广义参考图像包括两个直接参考图像或一个直接参考图像和一个间接参考图像。
可选的,所述字符串SHx.bin和Ds.bin均以空字符结束。
为了达到上述目的,作为本发明的第二个方面,提供了一种视频编码数据存储装置,包括:
分组模块,用于把视频序列包含的所有图像分成若干个图像组;
查找模块,用于为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
第一编码模块,用于对所述知识图像序列进行编码,得到各个知识图像的 编码数据,记为,为第个知识图像的编码数据;
第二编码模块,用于参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
第一数据处理模块,用于将解码视频序列所需的公共信息数据组织成视频序列头,记为SH,若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为32的倍数为止,并把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
第二数据处理模块,用于在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
第三数据处理模块,用于在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。
为了达到上述目的,作为本发明的第三个方面,提供了一种可读存储介质,其上存储有程序,所述程序被执行时实现所述的视频编码数据存储方法。
本发明提供了一种视频编码数据存储方法、装置及可读存储介质,解决了传统存储方法中为了提供随机访问功能,需要重复存储视频序列头等数据导致存储空间浪费的问题。
附图说明
本领域的普通技术人员应当理解,提供的附图用于更好地理解本发明,而不对本发明的范围构成任何限定。其中:
图1为本实施例提供的视频编码数据存储方法的步骤图;
图2为本实施例提供的视频编码数据存储装置的示意图;
附图中:
100-分组模块;200-查找模块;300-第一编码模块;400-第二编码模块;500-第一数据处理模块;600-第二数据处理模块;700-第三数据处理模块。
具体实施方式
为使本发明的目的、优点和特征更加清楚,以下结合附图和具体实施例对 本发明作进一步详细说明。需说明的是,附图均采用非常简化的形式且未按比例绘制,仅用以方便、明晰地辅助说明本发明实施例的目的。此外,附图所展示的结构往往是实际结构的一部分。特别的,各附图需要展示的侧重点不同,有时会采用不同的比例。
如在本发明中所使用的,单数形式“一”、“一个”以及“该”包括复数对象,除非内容另外明确指出外。如在本发明中所使用的,术语“或”通常是以包括“和/或”的含义而进行使用的,除非内容另外明确指出外。如在本发明中所使用的,术语“若干”通常是以包括“至少一个”的含义而进行使用的,除非内容另外明确指出外。如在本发明中所使用的,术语“至少两个”通常是以包括“两个或两个以上”的含义而进行使用的,除非内容另外明确指出外。此外,术语“第一”、“第二”、“第三”仅用于描述目的,而不能理解为指示或暗示相对重要性或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”、“第三”的特征可以明示或者隐含地包括一个或者至少两个该特征。
本发明的核心思想在于提供一种视频编码数据存储方法、装置及可读存储介质,以解决传统存储方法中为了提供随机访问功能,需要重复存储视频序列头等数据导致存储空间浪费的问题。
以下参考附图进行描述。
请参照图1,图1为本实施例提供的视频编码数据存储方法的步骤图。本实施例提供了一种视频编码数据存储方法,包括以下步骤:
S1、把视频序列包含的所有图像分成若干个图像组;
S2、为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
S3、对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据;
S4、参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
S5、将解码视频序列所需的公共信息数据组织成视频序列头,记为SH;
S6、若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特 数为32的倍数为止;
S7、把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
S8、在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
S9、在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。
首先,执行步骤S1,把视频序列包含的所有图像分成若干个图像组(GOP)。
进一步的,把视频序列包含的所有图像分成若干个图像组时,使同一个所述图像组中的图像保持一定的相关性,也就是说,将相关性较高的图像划分至同一个像素组中,以便于后续对知识图像序列进行编码,提高压缩效率。
然后执行步骤S2,为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量。例如,把视频序列包含的所有图像分成5个图像组,则所述知识图像序列可记为,为第一个图像组对应的知识图像。
进一步的,所述知识图像为对应的图像组中的某个图像。或者,所述知识图像为对应的图像组合成的图像。
接着执行步骤S3,对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据。通过对所述知识图像序列进行编码,以改善知识图像的压缩效率。
进一步的,对所述知识图像序列进行编码,编码时使所述知识图像序列中的各个知识图像的广义参考图像的数量不大于预设值,所述广义参考图像为所述知识图像序列的知识图像。
进一步的,对所述知识图像序列进行编码的方法包括有损编码、无损编码、帧内预测编码、帧间预测编码、变换编码及统计编码。
更进一步的,当所述预设值为0时,说明所述知识图像没有广义参考图像,故只能采用帧内预测编码对所述知识图像序列进行编码。
当所述预设值为1时,说明所述广义参考图像可以有一个广义参考图像, 且该广义参考图像为直接参考图像。
当所述预设值为大于或等于2时,所述广义参考图像可以有两个直接参考图像或一个直接参考图像和一个间接参考图像。
以下通过一个具体实施例来说明直接参考图像和间接参考图像的区别。
例如所述知识图像序列为{1、2、3、4、5},表示包括序号分别为1、2、3、4、5这五个知识图像,当五个所述知识图像之间不存在广义参考图像时,则所述知识图像序列为{1、2、3、4、5}只能采用帧内预测编码进行编码;当2、3、4、5只能通过1进行预测时,则1为直接参考图像;当3可直接通过1进行帧内预测,5可以通过3进行帧内预测,也可以通过1进行帧间预测,则1为3的直接参考图像,3为5的直接参考图像,1同时又是5的间接参考图像。
应当注意的是,对所述知识图像序列进行编码时,应保证编码再解码后图像的质量较高。
接着执行步骤S4,参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据。也就是说,每个图像组均对应一个知识图像,例如,第(K+1)个GOP对应知识图像,第(K+1)个GOP中每个图像都可以参考知识图像,相当于在现有编码方法的基础上为每一个图像增加了一个参考图像。
接着执行步骤S5,将解码视频序列所需的公共信息数据组织成视频序列头,记为SH。所述公共信息数据例如为视频序列的分辨率、拍摄时间等数据。
然后执行步骤S6,若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为32的倍数为止;
执行步骤S7,把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
执行步骤S8,在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串。本实施例中,每个序号用四个字节表示,特别地,0xFFFFFFFF表示广义参考图像序号结束。
执行步骤S9,在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。本实施例中,每个序号用四个字节表 示,特别地,0xFFFFFFFF表示知识图像序号结束。
进一步的,所述的字符串SHx.bin和Ds.bin,都是以空字符结束,即末尾有一个ASCII码为0的字符。
基于此,请参照图2,图2为本实施例提供的视频编码数据存储装置的示意图。本发明还提供了一种视频编码数据存储装置,包括:
分组模块100,用于把视频序列包含的所有图像分成若干个图像组;
查找模块200,用于为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
第一编码模块300,用于对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据;
第二编码模块400,用于参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
第一数据处理模块500,用于将解码视频序列所需的公共信息数据组织成视频序列头,记为SH,若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为32的倍数为止,并把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
第二数据处理模块600,用于在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
第三数据处理模块700,用于在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。
进一步的,通过所述分组模把视频序列包含的所有图像分成若干个图像组时,使同一个所述图像组中的图像保持一定的相关性。
进一步的,所述查找模块200为每个所述图像组寻找知识图像时,所述知识图像可以为对应的图像组中的某个图像,也可以为对应的图像组合成的图像。
进一步的,所述第一编码模块300对所述知识图像序列进行编码的方法包 括有损编码、无损编码、帧内预测编码、帧间预测编码、变换编码及统计编码。
进一步的,当所述预设值为0时,所述第一编码模块300采用帧内预测编码对所述知识图像序列进行编码,当所述预设值为1时,所述广义参考图像为直接参考图像,当所述预设值为大于或等于2时,所述广义参考图像包括两个直接参考图像或一个直接参考图像和一个间接参考图像。
进一步的,所述的字符串SHx.bin和Ds.bin,都是以空字符结束,即末尾有一个ASCII码为0的字符。
本发明还提供了一种可读存储介质,其上存储有程序,所述程序被执行时实现根据所述的视频编码数据存储方法。
综上,本发明实施例提供了一种视频编码数据存储方法、装置及可读存储介质,解决了传统存储方法中为了提供随机访问功能,需要重复存储视频序列头等数据导致存储空间浪费的问题。
此外还应该认识到,虽然本发明已以较佳实施例披露如上,然而上述实施例并非用以限定本发明。对于任何熟悉本领域的技术人员而言,在不脱离本发明技术方案范围情况下,都可利用上述揭示的技术内容对本发明技术方案作出许多可能的变动和修饰,或修改为等同变化的等效实施例。因此,凡是未脱离本发明技术方案的内容,依据本发明的技术实质对以上实施例所做的任何简单修改、等同变化及修饰,均仍属于本发明技术方案保护的范围。

Claims (10)

  1. 一种视频编码数据存储方法,其特征在于,包括:
    把视频序列包含的所有图像分成若干个图像组;
    为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
    对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据;
    参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
    将解码视频序列所需的公共信息数据组织成视频序列头,记为SH;
    若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为32的倍数为止;
    把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
    在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
    在前面补充字符串SHx.bin和Ds.bin,在的前面补充本身的序号和它参考的所有知识图像的序号。
  2. 如权利要求1所述的视频编码数据存储方法,其特征在于,把视频序列包含的所有图像分成若干个图像组时,使同一个所述图像组中的图像保持一定的相关性。
  3. 如权利要求1所述的视频编码数据存储方法,其特征在于,所述知识图像为对应的图像组中的某个图像。
  4. 如权利要求1所述的视频编码数据存储方法,其特征在于,所述知识图像为对应的图像组合成的图像。
  5. 如权利要求1所述的视频编码数据存储方法,其特征在于,对所述知识图像序列进行编码,编码时使所述知识图像序列中的各个知识图像的广义参考图像的数量不大于预设值,所述广义参考图像为所述知识图像序列的知识图像。
  6. 如权利要求5所述的视频编码数据存储方法,其特征在于,对所述知识图像序列进行编码的方法包括有损编码、无损编码、帧内预测编码、帧间预测编码、变换编码及统计编码。
  7. 如权利要求5所述的视频编码数据存储方法,其特征在于,当所述预设值为0时,采用帧内预测编码对所述知识图像序列进行编码;当所述预设值为1时,所述广义参考图像为直接参考图像;当所述预设值为大于或等于2时,所述广义参考图像包括两个直接参考图像或一个直接参考图像和一个间接参考图像。
  8. 如权利要求1所述的视频编码数据存储方法,其特征在于,所述字符串SHx.bin和Ds.bin均以空字符结束。
  9. 一种视频编码数据存储装置,其特征在于,包括:
    分组模块,用于把视频序列包含的所有图像分成若干个图像组;
    查找模块,用于为每个所述图像组寻找一个知识图像,各个所述图像组与各个所述知识图像一一对应,所有知识图像构成一个知识图像序列,所述知识图像序列记为,其中,为第(K+1)个图像组对应的知识图像,为知识图像的数量;
    第一编码模块,用于对所述知识图像序列进行编码,得到各个知识图像的编码数据,记为,为第个知识图像的编码数据;
    第二编码模块,用于参考所述知识图像序列中的知识图像对所述知识图像对应的图像组进行编码,得到各个图像组的编码数据,记为,为第(K+1)个图像组的编码数据;
    第一数据处理模块,用于将解码视频序列所需的公共信息数据组织成视频序列头,记为SH,若SH、和的比特数不是32的倍数,则在其末尾填充0,直到其比特数为32的倍数为止,并把处理后的SH作为一个文件存储,文件名为SHx.bin,其中,x表示可用于文件名的任意合法字符串;
    第二数据处理模块,用于在前面补充字符串SHx.bin,在前面补充本身的序号和它的所有广义参考图像的序号,然后将处理后的按照K从小到大的顺序存储为一个文件,文件名为Ds.bin,其中,x表示可用于文件名的任意合法字符串;
    第三数据处理模块,用于在前面补充字符串SHx.bin和Ds.bin,在的前面 补充本身的序号和它参考的所有知识图像的序号。
  10. 一种可读存储介质,其上存储有程序,其特征在于,所述程序被执行时实现根据权利要求1~8中任一项所述的视频编码数据存储方法。
PCT/CN2021/115033 2021-05-27 2021-08-27 视频编码数据存储方法、装置及可读存储介质 WO2022247032A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110617428.0A CN113347424B (zh) 2021-05-27 2021-05-27 视频编码数据存储方法、装置及可读存储介质
CN202110617428.0 2021-05-27

Publications (1)

Publication Number Publication Date
WO2022247032A1 true WO2022247032A1 (zh) 2022-12-01

Family

ID=77473075

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/115033 WO2022247032A1 (zh) 2021-05-27 2021-08-27 视频编码数据存储方法、装置及可读存储介质

Country Status (2)

Country Link
CN (1) CN113347424B (zh)
WO (1) WO2022247032A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113973210B (zh) * 2021-10-25 2022-09-20 腾讯科技(深圳)有限公司 媒体文件封装方法、装置、设备及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008009880A1 (en) * 2006-06-17 2008-01-24 British Telecommunications Public Limited Company Decoding media content
CN107635142A (zh) * 2016-07-18 2018-01-26 浙江大学 一种视频数据的处理方法及装置
CN108243339A (zh) * 2016-12-27 2018-07-03 浙江大学 图像编解码方法及装置
CN111416976A (zh) * 2019-01-08 2020-07-14 华为技术有限公司 视频解码方法、视频编码方法、装置、设备及存储介质

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE102006057983A1 (de) * 2006-12-08 2008-06-12 Siemens Ag Verfahren zur Vidoecodierung einer Folge digitalisierter Bilder
GB2531271A (en) * 2014-10-14 2016-04-20 Nokia Technologies Oy An apparatus, a method and a computer program for image sequence coding and decoding
CN104902279B (zh) * 2015-05-25 2018-11-13 浙江大学 一种视频处理方法及装置
CN109495749A (zh) * 2018-12-24 2019-03-19 上海国茂数字技术有限公司 一种视频编解码、检索方法及装置
CN111405291B (zh) * 2019-01-02 2021-10-19 浙江大学 视频编解码方法与装置
CN109714598B (zh) * 2019-01-31 2021-05-14 上海国茂数字技术有限公司 视频的编码方法、解码方法、处理方法以及视频处理系统
CN111526368B (zh) * 2019-02-03 2021-09-03 华为技术有限公司 视频解码方法、视频编码方法、装置、设备及存储介质

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2008009880A1 (en) * 2006-06-17 2008-01-24 British Telecommunications Public Limited Company Decoding media content
CN107635142A (zh) * 2016-07-18 2018-01-26 浙江大学 一种视频数据的处理方法及装置
CN108243339A (zh) * 2016-12-27 2018-07-03 浙江大学 图像编解码方法及装置
CN111416976A (zh) * 2019-01-08 2020-07-14 华为技术有限公司 视频解码方法、视频编码方法、装置、设备及存储介质

Also Published As

Publication number Publication date
CN113347424A (zh) 2021-09-03
CN113347424B (zh) 2022-08-05

Similar Documents

Publication Publication Date Title
WO2018184458A1 (zh) 一种图片文件处理方法、装置及存储介质
US7366319B2 (en) Embedding a multi-resolution compressed thumbnail image in a compressed image file
TWI672939B (zh) 圖片文件處理方法、裝置及存儲介質
JP5935695B2 (ja) 埋め込みグラフィック符号化:並列復号に向けて並べ替えられたビットストリーム
JP2012138883A5 (zh)
CN109194962B (zh) 一种图片文件处理方法及系统
CN103826028A (zh) 一种无损压缩图片的方法和装置
Husseen et al. Image compression using proposed enhanced run length encoding algorithm
WO2022247032A1 (zh) 视频编码数据存储方法、装置及可读存储介质
US7689047B2 (en) Reduced buffer size for JPEG encoding
BR112021001807A2 (pt) codificação de entropia para codificação de aprimoramento de sinal
WO2022095797A1 (zh) 图像的压缩方法、装置、智能终端及计算机可读存储介质
US7986350B2 (en) Mobile terminal and operating method thereof
US10515092B2 (en) Structured record compression and retrieval
US20140301641A1 (en) Tile-Based Compression and Decompression for Graphic Applications
US20150023609A1 (en) Method and apparatus for decoding a progressive jpeg image
WO2020107268A1 (zh) Gdr码流编码方法、终端设备、机器可读存储介质
CN108184113B (zh) 一种基于图像间参考的图像压缩编码方法和系统
WO2022247031A1 (zh) 基于知识图像的视频编码方法、装置及可读存储介质
US8363968B2 (en) Image coding method for facilitating run length coding and image encoding device thereof
WO2020258188A1 (zh) 解码方法、解码器和解码系统
TWI454150B (zh) 影像檔案的處理方法
TWI236296B (en) System and method for controlling bit stream in digital data
CN102833547B (zh) 一种应用于jpeg图像的快速嵌入显性信息的方法
WO2020258189A1 (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: 21942599

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21942599

Country of ref document: EP

Kind code of ref document: A1