CN112004094A - A method of saving pixel storage space - Google Patents
A method of saving pixel storage space Download PDFInfo
- Publication number
- CN112004094A CN112004094A CN201910445851.XA CN201910445851A CN112004094A CN 112004094 A CN112004094 A CN 112004094A CN 201910445851 A CN201910445851 A CN 201910445851A CN 112004094 A CN112004094 A CN 112004094A
- Authority
- CN
- China
- Prior art keywords
- frame
- pixel
- space
- starting point
- storage space
- 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.)
- Pending
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/50—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
- H04N19/503—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/10—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using adaptive coding
- H04N19/169—Methods 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/182—Methods 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 pixel
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04N—PICTORIAL COMMUNICATION, e.g. TELEVISION
- H04N19/00—Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
- H04N19/42—Methods 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
- H04N19/423—Methods 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 characterised by memory arrangements
- H04N19/426—Methods 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 characterised by memory arrangements using memory downsizing methods
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
本申请提供了一种像素存储空间的节省方法,所述方法具体包括以下步骤:S1,第1帧写重建像素起点与第1帧写重建像素终点之间为一帧空间;所述第1帧写重建像素终点位置为存储空间的可配置的扩展空间的起点;S2,第2帧写重建像素起点是步骤S2中第1帧的可配置的扩展空间的起点,第2帧写重建像素到存储空间终点后,再回到所述空间起点处写后面的像素;S3,后面帧以此类推重复步骤S1‑S2,依次向上跳转扩展行数开始写重建数据,上一帧的写重建像素起点变为当前帧的读重建像素起点。
The present application provides a method for saving pixel storage space, the method specifically includes the following steps: S1, a frame space is between the starting point of the first frame writing and reconstructing pixel and the first frame writing and reconstructing pixel end point; the first frame The end position of the write reconstruction pixel is the starting point of the configurable expansion space of the storage space; S2, the starting point of the second frame writing and reconstructing pixel is the starting point of the configurable expansion space of the first frame in step S2, and the second frame writes the reconstructed pixel to the storage space. After the end of the space, go back to the starting point of the space to write the following pixels; S3, repeat steps S1-S2 in the following frame and so on, jump up and expand the number of lines to start writing the reconstruction data, and write the reconstructed pixel starting point of the previous frame. Becomes the starting point of the read reconstructed pixel for the current frame.
Description
技术领域technical field
本发明涉及图像处理技术领域,特别涉及一种像素存储空间的节省方法。The invention relates to the technical field of image processing, in particular to a method for saving pixel storage space.
背景技术Background technique
当今社会是一个信息化的社会,图像材料也越来越多。需要存储图像材料的存储空间要求也越来越大,在应用过程中,特别是在视频编解码器中,如图1和2所示,需要不断与片外存储器进行数据交换,包括重建帧写入,参考帧获取等。这样就需要至少两倍的一帧像素空间进行存储。即图像的传输也需要占用一定的存储空间。如果能够有减少图像的存储空间,将极大的节约资源,提高传输效率。Today's society is an information society, and there are more and more image materials. The storage space requirements for storing image material are also increasing, and during the application process, especially in video codecs, as shown in Figures 1 and 2, there is a need for constant data exchange with off-chip memory, including reconstructed frame writing input, reference frame acquisition, etc. This requires at least twice the pixel space of a frame for storage. That is, the image transmission also needs to occupy a certain storage space. If the storage space of images can be reduced, resources will be greatly saved and transmission efficiency will be improved.
现有技术使用两帧的空间来分别存储重建帧和参考帧,对内存大小要求严格,如果加入其它一些技术比如多参考帧,那么内存资源得使用更加紧张。In the prior art, the space of two frames is used to store the reconstructed frame and the reference frame respectively, which has strict requirements on the memory size. If other technologies such as multiple reference frames are added, the use of memory resources will be more intensive.
传统方法中,如图3所示,以图3中的第1帧和第2帧举例。第1帧编码完的重建帧像素写入第1帧重建帧像素存储空间。用于第2帧编码时做帧间预测。同时第2帧在编码时也有重建像素写入第2帧重建帧像素存储空间。但是第1帧前几行重建像素在第2帧后期编码时就没有作用了,帧间预测不会搜索很远的位置,也就是存在着存储冗余。In the conventional method, as shown in FIG. 3 , the first frame and the second frame in FIG. 3 are used as examples. The encoded reconstructed frame pixels of the first frame are written into the reconstructed frame pixel storage space of the first frame. It is used for inter-frame prediction when encoding the second frame. At the same time, the second frame also has reconstructed pixels written into the second frame reconstructed frame pixel storage space during encoding. However, the reconstructed pixels in the first few lines of the first frame have no effect in the post-encoding of the second frame, and the inter-frame prediction will not search for a very far position, that is, there is storage redundancy.
发明内容SUMMARY OF THE INVENTION
为了解决上述现有技术中存在的问题,本发明的目的在于:减少内存占用,在不影响编码的情况下,做到内存共享使用,从而节省存储空间。In order to solve the problems existing in the above-mentioned prior art, the purpose of the present invention is to reduce memory occupation, and achieve shared use of memory without affecting coding, thereby saving storage space.
本申请提供了一种像素存储空间的节省方法,所述存储空间设置为一帧空间和可配置空间大小的扩展空间;当前帧写重建像素起点与下一帧写重建像素终点之间为一帧空间;所述下一帧写重建像素终点位置为存储空间的可配置的扩展空间的起点。The present application provides a method for saving pixel storage space, wherein the storage space is set as a frame space and an expansion space with a configurable space size; a frame is between the starting point of the writing and reconstructing pixels of the current frame and the ending point of the writing and reconstructing pixels of the next frame. space; the end position of the write reconstruction pixel of the next frame is the start point of the configurable expansion space of the storage space.
所述方法具体包括以下步骤:The method specifically includes the following steps:
S1,第1帧写重建像素起点与第1帧写重建像素终点之间为一帧空间;所述第1帧写重建像素终点位置为存储空间的可配置的扩展空间的起点;S1, the 1st frame write reconstruction pixel start point and the 1st frame write reconstruction pixel end point is a frame of space; Described 1st frame write reconstruction pixel end point position is the start point of the configurable expansion space of the storage space;
S2,第2帧写重建像素起点是步骤S2中第1帧的可配置的扩展空间的起点,第2帧写重建像素到存储空间终点后,再回到所述空间起点处写后面的像素;S2, the starting point of the 2nd frame writing and reconstructing pixel is the starting point of the configurable expansion space of the 1st frame in step S2, and after the 2nd frame writing and reconstructing the pixel to the end point of the storage space, it returns to the starting point of the space to write the following pixels;
S3,后面帧以此类推重复步骤S1-S2,依次向上跳转扩展行数开始写重建数据,上一帧的写重建像素起点变为当前帧的读重建像素起点。S3, repeating steps S1-S2 in the same way for subsequent frames, jumping upward to expand the number of lines to start writing reconstruction data, and the starting point of the writing reconstruction pixel of the previous frame becomes the starting point of the reading reconstruction pixel of the current frame.
所述步骤S3中如果跳转后,小于空间起点地址则剩余部分从空间终点向前跳转。In the step S3, if the jump is smaller than the address of the starting point of the space, the remaining part will jump forward from the ending point of the space.
所述扩展空间可配置的行数为64的倍数,且不大于一帧的高度。The configurable number of lines in the expansion space is a multiple of 64, and is not greater than the height of one frame.
所述扩展空间的理论最小值为64行像素。The theoretical minimum value of the expansion space is 64 lines of pixels.
所述步骤中,即使后一帧的重建像素从空间起点开始写,覆盖了前一帧的重建像素,因为搜索范围的约束,此时此起点的像素已是无用参考像素,因而是可被覆盖的。In the above steps, even if the reconstructed pixels of the next frame are written from the starting point of space and cover the reconstructed pixels of the previous frame, because of the constraints of the search range, the pixels of this starting point are useless reference pixels at this time, so they can be covered. of.
附图说明Description of drawings
此处所说明的附图用来提供对本发明的进一步理解,构成本申请的一部分,并不构成对本发明的限定。The accompanying drawings described herein are used to provide a further understanding of the present invention, and constitute a part of the present application, and do not constitute a limitation to the present invention.
图1是现有技术中视频编码解码器中进行数据交换的示意框图。FIG. 1 is a schematic block diagram of data exchange in a video codec in the prior art.
图2是现有技术中第1帧重建像素存储空间和第2帧重建像素存储空间存储的示意框图。FIG. 2 is a schematic block diagram of the storage space of the reconstructed pixel of the first frame and the storage space of the reconstructed pixel of the second frame in the prior art.
图3是现有技术中第1帧重建像素存储空间和第2帧重建像素存储空间使用的示意框图。FIG. 3 is a schematic block diagram of the use of the first frame reconstructed pixel storage space and the second frame reconstructed pixel storage space in the prior art.
图4是本申请新的存储空间和可配置的扩展空间的示意图。FIG. 4 is a schematic diagram of the new storage space and configurable expansion space of the present application.
图5是本申请第1帧写重建像素起点和终点位置的示意图。FIG. 5 is a schematic diagram of the start and end positions of the reconstructed pixels in the first frame of the present application.
图6是本申请第2帧写重建像素起点和第2帧写重建像素到空间终点后,再回到空间起点处写后面的像素的示意图。FIG. 6 is a schematic diagram of writing the starting point of the reconstructed pixel in the second frame of the present application and writing the following pixels after returning to the starting point of the space after the second frame writing the reconstructed pixel to the spatial end point.
图7是本申请第2帧、第3帧和第4帧写重建像素起点的示意图。FIG. 7 is a schematic diagram of writing the starting point of a reconstructed pixel in the second frame, the third frame and the fourth frame of the present application.
图8是本申请第4帧、第5帧和第6帧写重建像素起点的示意图。FIG. 8 is a schematic diagram of writing the starting point of the reconstructed pixel in the fourth frame, the fifth frame and the sixth frame of the present application.
具体实施方式Detailed ways
目前,在图像存储技术中常用的术语有:At present, the commonly used terms in image storage technology are:
扩展空间:基于原内存空间扩展的像素空间,以像素行为单元。Expansion space: The pixel space expanded based on the original memory space, in pixel row units.
原始帧:原始视频图像中的一帧。Raw Frame: A frame in the raw video image.
重建帧:对原始帧编码并且解码后的重建图像。Reconstructed frame: The reconstructed image after encoding and decoding the original frame.
参考帧:对原始帧编码时,用于参考做预测的帧,通常是已编码的重建帧。Reference frame: When encoding the original frame, the frame used for reference for prediction, usually the encoded reconstructed frame.
帧间预测:基于参考帧搜索最佳匹配的像素单元的预测方式。Inter prediction: A prediction method that searches for the best matching pixel unit based on the reference frame.
如图4所示,内存优化。既然在实际应用中存在着冗余,那么我们无需两倍的内存空间,只需要在一块内存空间的基础上扩展一些像素行数,无用参考区域可以被写重建像素。也即,形成新的存储空间和参考空间组合:一帧空间和可配的扩展空间。As shown in Figure 4, memory optimization. Since there is redundancy in practical applications, we do not need twice the memory space, but only need to expand some pixel rows on the basis of a memory space, and the useless reference area can be written to reconstruct pixels. That is, a new combination of storage space and reference space is formed: one frame space and configurable expansion space.
如图5所示,显示第1帧如何写重建帧。第1帧写重建像素起点,第1帧写重建像素终点;所述写重建像素终点位置为存储空间的新的可配的扩展空间的起点。Figure 5 shows how frame 1 writes the reconstructed frame. The starting point of the reconstruction pixel is written in the first frame, and the end point of the reconstructed pixel is written in the first frame; the position of the end point of the writing reconstruction pixel is the starting point of the new configurable expansion space of the storage space.
如图6所示,显示进行第2帧时如何写重建帧和读参考帧。第2帧写重建像素起点是原来第1帧的可配的扩展空间的起点,第2帧写重建像素到原来存储空间终点后,再回到所述空间起点处写后面的像素。As shown in Figure 6, it shows how to write the reconstructed frame and read the reference frame when the second frame is performed. The starting point of writing and reconstructing pixels of the second frame is the starting point of the configurable expansion space of the original first frame. After writing the reconstructed pixels of the second frame to the ending point of the original storage space, it returns to the starting point of the space to write the following pixels.
其中,可配置的扩展空间是直接关系到帧间预测的搜索范围,所以不能很小,理论最小值64行像素,可配置的扩展空间行数为64的倍数,不大于一帧的高度即可。Among them, the configurable expansion space is directly related to the search range of inter-frame prediction, so it cannot be very small. The theoretical minimum value is 64 lines of pixels, and the number of lines in the configurable expansion space is a multiple of 64, not greater than the height of one frame. .
特别地,这里还存在像素覆盖问题,即使第2帧的重建像素从空间起点开始写,覆盖了第1帧的重建像素,因为搜索范围的约束,此时此起点的像素已是无用参考像素。因而是可以被覆盖。In particular, there is a pixel coverage problem here, even if the reconstructed pixels of the second frame are written from the spatial starting point and cover the reconstructed pixels of the first frame, because of the constraints of the search range, the pixels at this starting point are useless reference pixels at this time. So it can be overwritten.
后面帧依次向上跳转扩展行数开始写重建数据,上一帧的写重建像素起点变为当前帧的读重建像素起点。如果跳转后小于空间起点地址则剩余部分从空间终点向前跳转。The subsequent frames jump upward in turn to expand the number of lines to start writing reconstruction data, and the starting point of the writing reconstruction pixel of the previous frame becomes the starting point of the reading reconstruction pixel of the current frame. If the jump is smaller than the start address of the space, the remaining part will jump forward from the end point of the space.
具体地,如图7所示,显示第2帧写重建像素起点向上跳转扩展行数开始写重建数据,第1帧写重建像素起点变为当前帧的读重建像素起点;依次类推,第3帧写重建像素起点向上跳转扩展行数开始写重建数据,第2帧写重建像素起点变为当前帧的读重建像素起点;第4帧写重建像素起点向上跳转扩展行数开始写重建数据,第4帧写重建像素起点变为当前帧的读重建像素起点;如图8所示,如果跳转后小于空间起点地址则剩余部分从空间终点向前跳转,即,第5帧跳转后小于空间起点地址,则第6帧写重建像素起点从空间终点向前跳转。Specifically, as shown in FIG. 7 , the starting point of the writing and reconstructing pixels of the second frame is shown to jump upward to expand the number of lines to start writing the reconstructed data, and the starting point of the writing and reconstructing pixels of the first frame becomes the starting point of the reading and reconstructing pixels of the current frame; and so on, the third The starting point of the frame write reconstruction pixel jumps upward to expand the number of lines to start writing the reconstructed data, the starting point of the second frame write reconstruction pixel becomes the starting point of the read reconstruction pixel of the current frame; the starting point of the fourth frame write reconstruction pixel jumps upward to expand the number of lines to start writing the reconstructed data , the starting point of the write reconstruction pixel of the 4th frame becomes the starting point of the read reconstruction pixel of the current frame; as shown in Figure 8, if the jump is smaller than the address of the space start point, the remaining part will jump forward from the space end point, that is, the 5th frame jumps If it is smaller than the address of the starting point of the space, the starting point of the write reconstruction pixel in the sixth frame jumps forward from the ending point of the space.
以上所述仅为本发明的优选实施例而已,并不用于限制本发明,对于本领域的技术人员来说,本发明实施例可以有各种更改和变化。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. For those skilled in the art, various modifications and changes may be made to the embodiments of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention shall be included within the protection scope of the present invention.
Claims (6)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910445851.XA CN112004094A (en) | 2019-05-27 | 2019-05-27 | A method of saving pixel storage space |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910445851.XA CN112004094A (en) | 2019-05-27 | 2019-05-27 | A method of saving pixel storage space |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112004094A true CN112004094A (en) | 2020-11-27 |
Family
ID=73461572
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910445851.XA Pending CN112004094A (en) | 2019-05-27 | 2019-05-27 | A method of saving pixel storage space |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112004094A (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003111083A (en) * | 2001-07-26 | 2003-04-11 | Matsushita Electric Ind Co Ltd | Area expansion apparatus, area expansion method, and area expansion program |
CN1589027A (en) * | 2004-07-29 | 2005-03-02 | 联合信源数字音视频技术(北京)有限公司 | Image boundarg pixel extending system and its realizing method |
CN1878306A (en) * | 2006-07-14 | 2006-12-13 | 杭州国芯科技有限公司 | Video decode image memory space managing method |
CN101193305A (en) * | 2006-11-21 | 2008-06-04 | 安凯(广州)软件技术有限公司 | Inter-frame prediction data storage and exchange method for video coding and decoding chip |
US20080267295A1 (en) * | 2007-04-26 | 2008-10-30 | Chih-Ta Star Sung | Video decompression, de-interlacing and frame rate conversion with frame buffer compression |
US20120044383A1 (en) * | 2010-08-18 | 2012-02-23 | Te-Wei Lee | High resolution digital image capturing apparatus and reference pixel memory storage space configuration method |
CN105323586A (en) * | 2015-04-07 | 2016-02-10 | 佛山世寰智能科技有限公司 | Shared memory interface used for multi-core parallel video coding and decoding |
-
2019
- 2019-05-27 CN CN201910445851.XA patent/CN112004094A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2003111083A (en) * | 2001-07-26 | 2003-04-11 | Matsushita Electric Ind Co Ltd | Area expansion apparatus, area expansion method, and area expansion program |
CN1589027A (en) * | 2004-07-29 | 2005-03-02 | 联合信源数字音视频技术(北京)有限公司 | Image boundarg pixel extending system and its realizing method |
CN1878306A (en) * | 2006-07-14 | 2006-12-13 | 杭州国芯科技有限公司 | Video decode image memory space managing method |
CN101193305A (en) * | 2006-11-21 | 2008-06-04 | 安凯(广州)软件技术有限公司 | Inter-frame prediction data storage and exchange method for video coding and decoding chip |
US20080267295A1 (en) * | 2007-04-26 | 2008-10-30 | Chih-Ta Star Sung | Video decompression, de-interlacing and frame rate conversion with frame buffer compression |
US20120044383A1 (en) * | 2010-08-18 | 2012-02-23 | Te-Wei Lee | High resolution digital image capturing apparatus and reference pixel memory storage space configuration method |
CN105323586A (en) * | 2015-04-07 | 2016-02-10 | 佛山世寰智能科技有限公司 | Shared memory interface used for multi-core parallel video coding and decoding |
Non-Patent Citations (1)
Title |
---|
袁基炜;国辉;: "H.264编码器参考帧内存优化方法", 电视技术, no. 08 * |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
ES2660663T3 (en) | Encoding procedure for moving images, decoding procedure for moving images and their devices | |
CN110708609A (en) | Video playing method and device | |
US20100149202A1 (en) | Cache memory device, control method for cache memory device, and image processing apparatus | |
US20070092008A1 (en) | Context-aware frame memory scheme for motion compensation in video decoding | |
TWI601075B (en) | Motion compensation image processing apparatus and image processing method | |
US10757430B2 (en) | Method of operating decoder using multiple channels to reduce memory usage and method of operating application processor including the decoder | |
US6940909B2 (en) | Video decoding during I-frame decode at resolution change | |
US7400683B2 (en) | Device with virtual tilized image memory | |
CN112004094A (en) | A method of saving pixel storage space | |
JP5139322B2 (en) | Memory organization scheme and controller architecture for image and video processing | |
CN102111615B (en) | Method and system for implementing video filtering in DMA removal | |
US7420567B2 (en) | Memory access method for video decoding | |
CN114697675B (en) | Decoding display system and memory access method thereof | |
KR100646577B1 (en) | How to save a specific image in a video CD | |
US9307259B2 (en) | Image decoding methods and image decoding devices | |
CN103916674B (en) | Storage device and method, mapping method, encoding and decoding apparatus and image processing apparatus | |
JP2009130599A (en) | Moving picture decoder | |
US8155204B2 (en) | Image decoding apparatus and image decoding method | |
JP2010136260A (en) | Apparatus and method for processing information | |
JP5556082B2 (en) | Memory controller, image processing system, and memory access control method | |
CN113873256B (en) | Method and system for storing motion vectors of adjacent blocks in HEVC (high efficiency video coding) | |
US7583732B2 (en) | Managing bursts of data | |
CN114125464B (en) | Video decoding method and video decoding device | |
WO2022206212A1 (en) | Video data storage method and apparatus, and electronic device and readable storage medium | |
KR102105644B1 (en) | Apparatus for Storing Images in MLC STT-MRAM and Method Thereof |
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 | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20201127 |
|
RJ01 | Rejection of invention patent application after publication |