WO2010052837A1 - 画像復号装置、画像復号方法、集積回路及びプログラム - Google Patents
画像復号装置、画像復号方法、集積回路及びプログラム Download PDFInfo
- Publication number
- WO2010052837A1 WO2010052837A1 PCT/JP2009/005476 JP2009005476W WO2010052837A1 WO 2010052837 A1 WO2010052837 A1 WO 2010052837A1 JP 2009005476 W JP2009005476 W JP 2009005476W WO 2010052837 A1 WO2010052837 A1 WO 2010052837A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- decoding
- macroblock
- block
- decoded
- Prior art date
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
- H04N19/51—Motion estimation or motion compensation
- H04N19/573—Motion compensation with multiple frame prediction using two or more reference frames in a given prediction direction
-
- 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
-
- 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/436—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 using parallelised computational arrangements
-
- 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/44—Decoders specially adapted therefor, e.g. video decoders which are asymmetric with respect to the encoder
Definitions
- the present invention relates to an image decoding apparatus, an image decoding method, an integrated circuit, and a program for decoding encoded image data.
- MPEG Motion Pictures Experts Group
- the MPEG encoding method uses the property of moving images that a frame close in time to the current frame is similar. By utilizing this property and predicting the current frame from temporally close frames and encoding only the difference between the input image and the predicted image, the amount of data can be reduced.
- the predicted image is generated using the image at the position shifted by the amount of movement as the reference image. is doing.
- a high compression ratio is realized by encoding the difference between the predicted image thus generated and the input image and this motion information (this is referred to as a motion vector). Such processing is called motion compensation prediction.
- Decoding processing or encoding processing including motion compensation prediction is performed by dividing one screen (picture) into blocks (luminance components: 16 pixels ⁇ 16 pixels) having a predetermined number of pixels. This pixel block is called a macro block.
- an image at a position corresponding to a motion vector is acquired from a memory as a reference image for each macroblock, and motion compensation prediction is performed.
- the data amount of one pixel is 1 byte.
- MPEG-2 ISO / IEC13818-2
- MPEG-4 ISO / IEC14496-2
- H.C. H.264 / MPEG-4 AVC ISO / IEC 14496-10) (hereinafter simply referred to as “H.264”)
- VC-1 SMPTE 421M
- H.264 realizes a compression rate 2 to 4 times that of the conventional MPEG-2, and is often used for compression of high-definition images such as Full HD (High Definition) (1920 pixels ⁇ 1080 pixels). It has been.
- a method for realizing high computing performance by performing parallel processing using a plurality of existing full HD image decoding devices can be considered.
- H. In a new encoding method typified by H.264, when a certain macroblock is encoded, the compression rate is increased by utilizing the correlation with neighboring neighboring macroblocks.
- Figure 1 shows H. 2 is a diagram illustrating a decoding method for increasing the compression rate by using the correlation with neighboring neighboring macroblocks in H.264.
- FIG. 2 is a diagram for explaining a decoding method of a conventional image decoding apparatus.
- Each block shown in the figure represents a macroblock in a picture, the number given to the macroblock indicates the processing time, and the macroblocks with the same number are decoded in parallel at the same time.
- the conventional image decoding apparatus instantaneously transfers a lot of data from the memory. For this reason, it is necessary to use a memory capable of transferring a large amount of data, which increases the memory bandwidth required for the memory used in the image decoding apparatus.
- the image decoding device shares a memory with another device, and there is an instantaneous increase in the data transfer amount of the image decoding device, the other device can be used. Since the memory bandwidth is reduced and the transfer of other devices is hindered, the processing of other devices is delayed. Thus, the conventional image decoding apparatus has a problem with respect to the memory bandwidth.
- the present invention solves the above-described conventional problems, and suppresses an instantaneous increase in data transfer amount and enables image data parallel decoding of image data with a small memory bandwidth, an image decoding method, and an integrated circuit And to provide a program.
- an image decoding apparatus decodes encoded image data divided and encoded for each block having a predetermined number of pixels, for each block.
- a storage unit storing reference image data to be referred to when the encoded image data is decoded, and a reference when the encoded image data is decoded for each block.
- a predecode unit that decodes reference information indicating the number of reference images to be read, and is read from the storage unit when the encoded image data is decoded for each block using the reference information Using the data transfer amount prediction unit that calculates the predicted data amount of the reference image and the calculated prediction data amount, the variation in the data amount read from the storage unit is reduced. Includes a block determining section for determining a plurality of blocks of the encoded image data decoding the column is performed, and a plurality of block decoding unit for decoding a plurality of blocks of the determined said coded image data in parallel.
- the prediction data amount of the reference image is calculated from the number of reference images, and the plurality of blocks of the encoded image data to be decoded in parallel are determined, so that the plurality of blocks are decoded in parallel.
- the predicted data amount is double that required when one reference image is required. That is, for example, H.I.
- image data encoded by an MPEG encoding method such as H.264 is decoded in parallel, the amount of data to be acquired from the memory can be accurately predicted in advance.
- the blocks to be decoded in parallel can be appropriately selected so as to be smaller. As a result, an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the image decoding apparatus shares a storage unit with another apparatus and the data transfer amount of the other apparatus is large, the data transfer amount of the image decoding apparatus is reduced. By doing so, the transfer of the other device can be prevented, and the processing of the other device is not affected. Further, when the data transfer amount of the other device is small, the image decoding process itself of the image decoding device can be speeded up by increasing the data transfer amount of the image decoding device.
- the predecoding unit performs variable-length decoding using macroblock type information of a macroblock, which is the block, included in the encoded image data as the reference information
- the data transfer amount prediction unit includes: The predicted data amount is calculated by multiplying the number of reference images indicated by the macroblock type information by the data amount of the reference image.
- the macro block type information is decoded as the reference information indicating the number of reference images.
- the reference information indicating the number of reference images.
- zero reference images are required for decoding an I macroblock type macroblock
- one reference image is required for decoding a P macroblock type macroblock
- a B macroblock type macroblock is Two reference images are necessary for decoding.
- the number of reference images can be easily acquired, an increase in the instantaneous data transfer amount can be suppressed, and parallel decoding of image data can be performed with a small memory bandwidth.
- the reference image is referred to in units of divided blocks obtained by dividing each block of the encoded image data into smaller blocks.
- the predecoding unit further decodes block division pattern information indicating the size of the divided block included in the encoded image data, and the data transfer amount prediction unit is indicated by the block division pattern information
- the data amount of the reference image at the integer pixel position and the probability that the reference image at the integer pixel position is referenced and the probability that the reference image at the decimal pixel position is referred to
- the predicted data amount is calculated by weighting the data amount of the reference image at the decimal pixel position.
- prediction is performed by weighting the data amount of the reference image at integer pixel positions and the data amount of the reference image at decimal pixel positions for each divided block. Calculate the amount of data.
- the predicted data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected. Therefore, even when it is necessary to refer to the reference image in units of divided blocks, it is possible to suppress the instantaneous increase in data transfer amount and perform parallel decoding of image data with a small memory bandwidth.
- the data transfer amount prediction unit sets, for each of the divided blocks, a first probability that a first reference image whose horizontal position and vertical position are both integer pixel positions is referred to as a first probability, and the horizontal position is a decimal number.
- the probability that the second reference image having the pixel position and the vertical position is the integer pixel position is referred to as the second probability
- the third reference image in which the horizontal position is the integer pixel position and the vertical position is the fractional pixel position is referred to.
- the third probability, and the fourth probability that the fourth reference image whose horizontal position and vertical position are both decimal pixel positions is referred to as the fourth probability, and the first reference image, the second reference image, the third
- the predicted data amount is calculated by multiplying the data amounts of the reference image and the fourth reference image by the first probability, the second probability, the third probability, and the fourth probability, respectively, and adding them.
- the predicted data amount is calculated using the probability that a reference image whose horizontal position or vertical position is an integer pixel position or a decimal pixel position is referred to.
- the calculation is performed in consideration of whether the horizontal position or the vertical position is an integer pixel position or a fractional pixel position, so that the predicted data amount can be calculated more accurately.
- an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the predecoding unit further decodes motion information indicating a motion amount between an image of the block to be decoded and a reference image for each block, and the data transfer amount prediction unit includes the block Each time, the predicted data amount may be calculated using the motion information.
- the predicted data amount is calculated using the motion information. Therefore, since the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected. As a result, an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the data transfer amount prediction unit determines whether the position of the reference image indicated by the motion information is a decimal pixel position, and determines that the position of the reference image is a decimal pixel position.
- the data amount of the reference image at the decimal pixel position is calculated as the predicted data amount.
- the data amount of the reference image at the decimal pixel position is calculated as the predicted data amount.
- the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected.
- an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the data transfer amount prediction unit determines whether the address of the reference image indicated by the motion information is an aligned address, and determines that the address of the reference image is not an aligned address. In this case, the predicted data amount is calculated by correcting the address of the reference image to an aligned address.
- the predicted data amount is calculated by correcting the address of the reference image to the aligned address.
- the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected.
- an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the block determination unit uses the predicted data amount to change the decoding order of the blocks of the encoded image data so that a variation in the data amount read from the storage unit is reduced.
- a plurality of blocks of the encoded image data to be decoded in parallel are determined.
- the block determination unit uses the predicted data amount to change the number of blocks of the encoded image data to be decoded in parallel so that the fluctuation of the data amount read from the storage unit is reduced. Thus, a plurality of blocks of the encoded image data to be decoded in parallel may be determined.
- the block determination unit is configured such that an average value of predicted data amounts of a plurality of blocks of the encoded image data to be decoded in parallel approaches an average value of predicted data amounts of a predetermined number of blocks.
- a plurality of blocks of the encoded image data to be decoded in parallel are determined.
- a plurality of blocks to be decoded in parallel are determined so that the average value of the prediction data amounts of the plurality of blocks approaches the average value of the prediction data amounts of a predetermined number of blocks.
- the prediction data amount of the block in which parallel decoding is performed becomes an average value. Accordingly, it is possible to perform parallel decoding of image data with a small memory bandwidth while suppressing an instantaneous increase in data transfer amount.
- the block determination unit is configured such that a total value of predicted data amounts of a plurality of blocks of the encoded image data to be decoded in parallel is different from a maximum data amount that can be transferred from the storage unit.
- the plurality of blocks of the encoded image data to be decoded in parallel are determined so as to approach the difference data amount that is the data amount obtained by subtracting the data amount to which the data transfer is performed.
- the block determination unit performs decoding in parallel so that a total value of predicted data amounts of a plurality of blocks of the encoded image data to be decoded in parallel is increased.
- a plurality of blocks of encoded image data are determined.
- the block determination unit performs decoding in parallel so that a total value of predicted data amounts of a plurality of blocks of the encoded image data to be decoded in parallel is small. A plurality of blocks of the encoded image data to be determined is determined.
- the plurality of blocks to be decoded in parallel are determined so that the total value of the prediction data amounts of the plurality of blocks to be decoded in parallel approaches the difference data amount. That is, when the difference data amount is large, the total value of the prediction data amounts of a plurality of blocks to be decoded in parallel is increased, and when the difference data amount is small, the plurality of blocks to be decoded in parallel are decoded. A plurality of blocks to be decoded in parallel are determined so that the total value of the predicted data amount is small. Thereby, parallel decoding of image data can be performed with a preset memory bandwidth.
- the present invention can be realized not only as such an image decoding device but also as an integrated circuit including each processing unit constituting the device, or as a method using the processing of each processing unit as a step. Can be realized. Furthermore, the present invention can be realized as a program for causing a computer to execute these steps, as a recording medium such as a computer-readable CD-ROM in which the program is recorded, or as information, data, or a signal indicating the program. It can also be realized. These programs, information, data, and signals may be distributed via a communication network such as the Internet.
- the image decoding apparatus of the present invention it is possible to perform parallel decoding of image data with a small memory bandwidth while suppressing an instantaneous increase in data transfer amount.
- the image decoding device shares a memory with another device and the data transfer amount of the other device is large, the data transfer amount of the image decoding device is reduced.
- the transfer of another device can be prevented, and the processing of the other device is not affected.
- the image decoding process itself of the image decoding device can be speeded up by increasing the data transfer amount of the image decoding device.
- FIG. 2 is a diagram illustrating a decoding method for increasing the compression rate by using the correlation with neighboring neighboring macroblocks in H.264.
- FIG. 2 is a diagram for explaining a decoding method of a conventional image decoding apparatus.
- FIG. 3 is a block diagram illustrating a functional configuration of the image decoding apparatus according to the first embodiment.
- FIG. 4 is a block diagram showing a functional configuration of the macroblock decoding unit in the first embodiment.
- FIG. 2 is a diagram illustrating a configuration of an H.264 encoded stream.
- FIG. 6 is a flowchart illustrating an example of the operation of the image decoding apparatus according to the first embodiment.
- FIG. 7 is a flowchart illustrating an example of processing in which the data transfer amount prediction unit according to Embodiment 1 calculates the predicted data amount.
- FIG. 8 is a diagram illustrating a macroblock type and a macroblock division pattern in a P slice.
- FIG. 9 is a diagram illustrating a macroblock type and a macroblock division pattern in a B slice.
- FIG. 10 is a flowchart illustrating an example of processing for determining macroblocks to be decoded in parallel by the block determination unit according to the first embodiment.
- FIG. 11 is a flowchart illustrating an example of processing in which the macroblock decoding unit according to Embodiment 1 decodes a macroblock.
- FIG. 8 is a diagram illustrating a macroblock type and a macroblock division pattern in a P slice.
- FIG. 9 is a diagram illustrating a macroblock type and a macroblock division pattern in a B slice.
- FIG. 10 is a flowchart illustrating an example of processing for determining
- FIG. 12 is a flowchart illustrating an example of processing in which the data transfer amount prediction unit according to the second embodiment calculates the predicted data amount.
- FIG. 13 is a diagram for explaining a macroblock division pattern.
- FIG. 14 is a diagram for explaining a sub-macroblock division pattern.
- FIG. 15 is a diagram illustrating sub-macroblock types and sub-macroblock division patterns in a P macroblock.
- FIG. 16 is a diagram showing sub-macroblock types and sub-macroblock division patterns in the B macroblock.
- FIG. 17 shows the H.264 in the second embodiment. It is a figure which shows the calculation method of the pixel value of a reference image of the decimal position pixel in H.264 motion compensation prediction.
- FIG. 13 is a diagram for explaining a macroblock division pattern.
- FIG. 14 is a diagram for explaining a sub-macroblock division pattern.
- FIG. 15 is a diagram illustrating sub-macroblock types and sub-ma
- FIG. 19 is a flowchart illustrating an example of a process in which the data transfer amount prediction unit according to the third embodiment calculates a predicted data amount.
- FIG. 20 is a flowchart illustrating an example of processing for calculating a predicted data amount when the data transfer amount prediction unit according to the third embodiment has a macroblock division pattern of 8 pixels ⁇ 8 pixels.
- FIG. 21 is a flowchart illustrating an example of processing for calculating a predicted data amount when the data transfer amount prediction unit according to the third embodiment has a macroblock division pattern other than 8 pixels ⁇ 8 pixels.
- FIG. 19 is a flowchart illustrating an example of a process in which the data transfer amount prediction unit according to the third embodiment calculates a predicted data amount.
- FIG. 20 is a flowchart illustrating an example of processing for calculating a predicted data amount when the data transfer amount prediction unit according to the third embodiment has a macroblock division pattern of 8 pixels ⁇ 8 pixels.
- FIG. 21 is a flowchart illustrating an example of processing for
- FIG. 22 is a flowchart illustrating an example of processing for calculating a predicted data amount when the data transfer amount prediction unit according to the fourth embodiment has a macroblock division pattern of 8 pixels ⁇ 8 pixels.
- FIG. 23 is a diagram illustrating that the data transfer amount prediction unit according to the fourth embodiment corrects the reference image to the aligned address.
- FIG. 24 is a flowchart illustrating an example of processing for calculating a predicted data amount when the data transfer amount prediction unit according to the fourth embodiment has a macroblock division pattern other than 8 pixels ⁇ 8 pixels.
- FIG. 25 is a flowchart illustrating an example of processing in which the block determination unit according to Embodiment 5 determines macroblocks to be decoded in parallel.
- FIG. 26 is a diagram illustrating that the block determination unit according to the fifth embodiment determines the number of macroblocks to be decoded in parallel.
- FIG. 27 is a block diagram illustrating a functional configuration when another device according to Embodiment 6 accesses the external memory of the image decoding device.
- FIG. 28 is a flowchart illustrating an example of processing for determining macroblocks to be decoded in parallel by the block determination unit according to the sixth embodiment.
- FIG. 29 is a diagram illustrating an example of an integrated circuit that controls the image decoding apparatus.
- H.264 An embodiment in which the present invention is applied to an image decoding apparatus compatible with the H.264 encoding method will be described with reference to the drawings. In the present embodiment, H.264 is used. Although an image decoding device corresponding to the H.264 encoding method is shown, any image decoding device corresponding to a moving image encoding method that performs motion compensation prediction can be realized in the same form.
- FIG. 3 is a block diagram showing a functional configuration of the image decoding apparatus 100 according to Embodiment 1 of the present invention.
- the image decoding apparatus 100 is an apparatus that performs decoding of encoded image data divided and encoded for each block having a predetermined number of pixels for each block.
- the block having a predetermined number of pixels is a macro block.
- the image decoding apparatus 100 includes an external memory 110, a stream parser unit 120, a decoding control unit 130, a macroblock decoding unit 140, a macroblock decoding unit 150, a macroblock decoding unit 160, and a deblocking filter unit 170. , And an adjacent MB information memory 180.
- the adjacent MB information memory 180 stores information on neighboring adjacent macroblocks necessary for the macroblock decoding process.
- the external memory 110 stores an encoded stream, a decoded stream, a reference image, and a decoded image.
- the encoded stream is input encoded image data.
- the decoded stream is encoded image data that has been variable-length decoded by the stream parser unit 120.
- the reference image is an image that is referred to when encoded image data is decoded.
- the decoded image is an image obtained by decoding the encoded image data.
- the external memory 110 corresponds to a “storage unit” described in the claims.
- the external memory 110 may be shared with a memory of another device different from the image decoding device 100 of the present embodiment.
- the external memory 110 stores data other than the encoded stream, the decoded stream, the reference image, and the decoded image.
- the stream parser unit 120 performs variable length decoding of the encoded stream, generates a decoded stream, and decodes parameters necessary for predicting the data amount of the reference image acquired from the external memory 110 during macroblock decoding. To the unit 130.
- the stream parser unit 120 is H.264.
- An encoded stream encoded by H.264 is read from the external memory 110, variable length decoding is performed, and the decoded decoded stream is written back to the external memory 110.
- at least reference information indicating the number of reference images that are referred to for each macroblock when decoding the encoded image data is performed. Is sent to the decoding control unit 130.
- the reference information is macroblock type information of a macroblock included in the encoded image data.
- the stream parser unit 120 corresponds to the “predecode unit” recited in the claims.
- the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 read the decoded stream from the external memory 110 in accordance with the instruction from the decoding control unit 130, perform the decoding process of the macroblock in parallel, and reconfigured Pixel data is output to the deblocking filter unit 170.
- the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 read pixel data of a reference image used for motion compensation prediction from the external memory 110 as necessary.
- Each of the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 corresponds to a “block decoding unit” described in the claims.
- the deblocking filter unit 170 performs a deblocking filter process for removing block noise on the reconstructed pixel data, and outputs the decoded image to the external memory 110. At this time, the decoded image used as the reference image in the subsequent decoding process is also stored in the external memory as the reference image.
- the decoding control unit 130 issues a processing start instruction to the stream parser unit 120, the macroblock decoding unit 140, the macroblock decoding unit 150, the macroblock decoding unit 160, and the deblocking filter unit 170, and performs the entire image decoding process. Control is in progress.
- the decoding control unit 130 includes a data transfer amount prediction unit 131 and a block determination unit 132.
- the data transfer amount prediction unit 131 uses the macro block type information for each macro block to calculate the prediction data amount of the reference image read from the external memory 110 when the encoded image data is decoded. That is, the data transfer amount prediction unit 131 uses the parameters sent from the stream parser unit 120 to calculate the amount of reference image data that needs to be acquired from the external memory 110 when performing motion compensation prediction in the macroblock decoding process. Predict by unit.
- the data transfer amount prediction unit 131 calculates the predicted data amount by multiplying the number of reference images indicated by the macroblock type information by the data amount of the reference image.
- the block determination unit 132 determines a plurality of macroblocks to be decoded in parallel using the predicted data amount calculated by the data transfer amount prediction unit 131 so that the fluctuation of the data amount read from the external memory 110 is reduced. To do. Specifically, the block determination unit 132 predetermines the macroblock decoding order based on the predicted data amount so that the amount of reference image data acquired from the external memory 110 does not increase instantaneously during macroblock decoding. Decide.
- the decoding control unit 130 controls the macroblock decoding processes of the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 according to a predetermined decoding order.
- the decoding control unit 130 issues a decoding start instruction to the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160
- the neighboring adjacent information necessary for decoding the macroblock to be decoded is read from the adjacent MB information memory 180.
- the macroblock information is read and passed to the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160.
- the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 decode a plurality of macroblocks determined by the block determination unit 132 in parallel.
- the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 finish the decoding process of the macroblock, it is necessary as the neighboring adjacent macroblock information for the subsequent decoding process among the decoded macroblock information.
- Information is passed to the decoding control unit 130.
- the decoding control unit 130 stores this in the adjacent MB information memory 180.
- the configuration of the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 will be described in detail.
- the configuration of the macroblock decoding unit 140 will be described below.
- FIG. 4 is a block diagram illustrating a functional configuration of the macroblock decoding unit 140 according to the first embodiment.
- the macroblock decoding unit 140 includes an inverse quantization unit 141, an inverse orthogonal transform unit 142, an intra-screen prediction unit 143, a motion compensation prediction unit 144, and an addition circuit 145.
- the inverse quantization unit 141 reads the quantized coefficient data from the decoded stream read from the external memory 110, performs inverse quantization, and outputs the coefficient data to the inverse orthogonal transform unit 142.
- the inverse orthogonal transform unit 142 performs inverse orthogonal transform on the coefficient data to generate pixel data in the spatial domain.
- One of the intra-screen prediction unit 143 and the motion compensation prediction unit 144 is activated depending on the prediction mode read from the decoded stream, and generates pixel data of the predicted image.
- the intra-screen prediction unit 143 is activated when the prediction mode is intra prediction, and generates pixel data of a predicted image by performing intra-screen prediction.
- the motion compensation prediction unit 144 is activated when the prediction mode is inter prediction, acquires pixel data of a reference image corresponding to the decoded motion vector, and performs motion compensation prediction, thereby performing pixel compensation of the predicted image. Generate data.
- intra-screen prediction unit 143 and the motion compensation prediction unit 144 perform intra-screen prediction and motion compensation prediction using information on neighboring neighboring macroblocks passed from the decoding control unit 130.
- the adder circuit 145 adds the pixel data output from the inverse orthogonal transform unit 142 and the pixel data of the predicted image output from the in-screen prediction unit 143 or the motion compensation prediction unit 144, and outputs reconstructed pixel data. To do.
- Figure 5 shows a typical H.264.
- 2 is a diagram illustrating a configuration of an H.264 encoded stream.
- FIG. 5 is a diagram illustrating a configuration of an H.264 encoded stream.
- SPS Sequence Parameter Set
- PPS Picture Parameter Set
- a start code (SC: Start Code) 501 indicating a data delimiter is inserted at the head of the SPS header 502, the PPS header 503, and the slice header 504. Therefore, by performing a start code search for the encoded stream and analyzing the data following the start code 501, the SPS header 502, the PPS header 503, and the slice header 504 can be searched from the encoded stream. .
- SC Start Code
- a PPS header 503 exists at the head of a picture, and a series of data until the next PPS header 503 appears is data for one picture.
- one picture data there are as many sets of slice headers 504 and slice data 505 as the number of slices present in the picture.
- FIG. 6 is a flowchart showing an example of the operation of the image decoding apparatus 100 according to Embodiment 1 of the present invention.
- the stream parser unit 120 reads the encoded stream from the external memory 110, and sequentially performs decoding of the SPS header 502 (S102), decoding of the PPS header 503 (S104), and decoding of the slice header 504 (S106).
- the stream parser unit 120 performs only variable length decoding of the macroblock included in the slice data and generates a decoded stream (S108).
- an MB (Macroblock) start code is inserted at the head of the macroblock so that the head of the macroblock can be recognized when the macroblock is decoded in parallel in the subsequent processing.
- the MB start code is set to 0x000001F0.
- the MB start code may be anything as long as it is a unique value that does not overlap with other codes.
- the stream parser unit 120 includes mb_type (Macroblock Type), sub_mb_type (Sub-Macroblock Type), ref_idx (Reference Index), ffdor, etc. among the decoded parameters.
- the parameter necessary for calculating the motion vector is sent to the decoding control unit 130.
- the stream parser unit 120 sends at least mb_type of the decoded parameters to the decoding control unit 130. Also, mb_type is included in the “macroblock type information” described in the claims.
- the stream parser unit 120 determines whether the decoded slice is the end of the picture (S110).
- the number of slices included in the picture can be determined by decoding num_slice_groups_minus1 in the PPS header 503. Therefore, if the number obtained by subtracting 1 from the number of decoded slices matches num_slice_groups_minus1, it is determined that the picture is at the end of the picture.
- the stream parser unit 120 determines that it is not the end of the picture (NO in S110), it sequentially performs decoding of the slice header 504 (S106) and variable length decoding (S108) of the slice data 505 until the end of the picture is reached. .
- the data transfer amount prediction unit 131 of the decoding control unit 130 performs an external process during the motion compensation prediction in the decoding process of the macroblock.
- the predicted data amount of the reference image that must be acquired from the memory 110 is calculated for each macroblock (S112). Details of the process of calculating the predicted data amount by the data transfer amount prediction unit 131 will be described later.
- the block determination unit 132 determines a plurality of macroblocks to be decoded in parallel according to the prediction value. (S114). Specifically, the block determination unit 132 determines the decoding order of macroblocks. The details of the process in which the block determination unit 132 determines macroblocks to be decoded in parallel will be described later.
- the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 are each read from the external memory 110 according to the instruction of the decoding control unit 130.
- the decoded stream is read, and decoding processing of the decoding target macroblock is performed in parallel (S116). Details of a process in which each of the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 decodes a macroblock will be described later.
- the decoding control unit 130 instructs the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 to start decoding in units of macroblocks according to the decoding order determined by the block determination unit 132.
- the decoding control unit 130 determines whether the decoded macroblock is the end of the picture. Is determined (S118).
- the decoding control unit 130 determines that the decoded macroblock is not the end of the picture (NO in S118), the macroblock decoding unit 140, the macroblock decoding unit 150, and the macroblock decoding unit 160 The macroblock decoding process (S116) is performed until the end of.
- the deblocking filter unit 170 applies the deblocking filter to the reconstructed pixel data for one picture. Processing is performed (S120).
- the decoding control unit 130 determines whether or not the picture on which the deblocking filter process has been performed is the end of the stream (S122).
- the decoding control unit 130 determines that the picture is not the end of the stream (NO in S122), and the stream parser unit 120 performs decoding of the PPS header 503 again (S104).
- the encoded stream is decoded one after another.
- the process ends.
- the data transfer amount prediction unit 131 calculates the predicted data amount by a prediction method based on a macroblock type using mb_type in the macroblock layer.
- FIG. 7 is a flowchart illustrating an example of processing in which the data transfer amount prediction unit 131 according to the first embodiment calculates the predicted data amount.
- the process of calculating the prediction data amount for one macroblock is shown, but the data transfer amount prediction unit 131 performs the process shown in the figure for all the macroblocks in the picture.
- the data transfer amount prediction unit 131 acquires the macroblock type of the macroblock to be decoded from the mb_type decoded by the stream parser unit 120 (S202).
- mb_type is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent from the stream parser unit 120 to the decoding control unit 130 in advance.
- I macroblock type there are three types of macroblock types: I macroblock type, P macroblock type, and B macroblock type. For this reason, it will be described below which of the three macroblock types the data transfer amount prediction unit 131 acquires from the mb_type.
- FIG. 8 is a diagram showing a macroblock type and a macroblock division pattern in a P slice.
- FIG. 9 is a diagram showing a macroblock type and a macroblock division pattern in a B slice.
- the slice type of I slice, P slice, or B slice is obtained.
- the P slice is composed of P macroblocks and I macroblocks. Specifically, a macroblock whose mb_type is “0 to 4” is a P macroblock, and a macroblock whose mb_type is “5 to 25” is an I macroblock.
- the data transfer amount prediction unit 131 is the P macro block type
- the mb_type is “5 to 25”
- the macro block type is acquired assuming that the macro block is the I macro block type.
- the B slice is composed of B macroblocks and I macroblocks.
- macroblocks with mb_type “0 to 22” are B macroblocks
- macroblocks with mb_type “23 to 25” are I macroblocks.
- the data transfer amount prediction unit 131 is the B macroblock type
- the mb_type is “23 to 25”
- the macro block type is acquired assuming that the macro block is the I macro block type.
- the I slice consists of only I macroblocks. For this reason, the data transfer amount prediction unit 131 acquires the macroblock type on the assumption that the macroblock of the I slice is the I macroblock type.
- the data transfer amount prediction unit 131 determines which macroblock type is the acquired macroblock type (S204).
- the data transfer amount prediction unit 131 calculates that the predicted data amount is 0 bytes (S206).
- the macroblock of the I macroblock type does not require reference image data because a predicted image is generated by intra prediction and no motion compensation prediction is performed.
- the data transfer amount prediction unit 131 calculates that the predicted data amount is 256 bytes (S208).
- the macro block of the P macro block type performs motion compensation prediction using one temporally close frame as a reference image
- one macro block that is, 256 bytes (16 pixels ⁇ 16 pixels ⁇ 1). Reference image data is required.
- the data transfer amount prediction unit 131 calculates that the predicted data amount is 512 bytes (S210).
- the macro block of the B macro block type performs motion compensation prediction using two temporally close frames as reference images, it is equivalent to two macro blocks, that is, 512 bytes (16 pixels ⁇ 16 pixels ⁇ 2). Reference image data is required.
- the prediction data amount of the reference image necessary for motion compensation prediction can be calculated according to the macroblock type. That is, in the prediction method using the macroblock type according to the present embodiment, it is assumed that this prediction data amount is the prediction data amount of the reference image acquired from the external memory 110.
- the block determination unit 132 is configured so that the average value of the prediction data amounts of a plurality of macroblocks that are decoded in parallel approaches the average value of the prediction data amounts of a predetermined number of macroblocks.
- a plurality of macroblocks to be decoded in parallel are determined by changing the decoding order of the blocks.
- FIG. 10 is a flowchart illustrating an example of a process for determining a macroblock to be decoded in parallel by the block determination unit 132 according to the first embodiment.
- the block determination unit 132 calculates an average value of the predicted data amounts of a predetermined number of macroblocks (S302).
- the predetermined number of macroblocks may be all macroblocks in the picture, or may be macroblocks for which the block determining unit 132 has already determined the decoding order.
- the block determination unit 132 performs the macro decoding in parallel so that the average value of the prediction data amounts of the plurality of macro blocks that are decoded in parallel approaches the average value of the prediction data amounts of the predetermined number of macro blocks.
- a block is selected (S304). Here, it is assumed that the predetermined number of macroblocks are all macroblocks in the picture.
- the block determination unit 132 calculates the average value of the predicted data amount (S302) and selects macroblocks to be decoded in parallel (S304) will be specifically described.
- the decoding order of the macro blocks is performed in the order shown in FIG. However, in this embodiment, since there are only three macroblock decoding units, if there are more than three macroblocks that can be decoded in parallel, macroblocks with the same number cannot be decoded at once.
- the block determination unit 132 decodes the macroblocks decoded in parallel so that the average value of the prediction data amount of the reference image of the macroblocks decoded in parallel is as close as possible to the average value of the prediction data amount of each macroblock. Select. This is because the block determination unit 132 obtains all combination patterns of macroblocks to be decoded in parallel, calculates the average value of the prediction data amount of the reference image for each combination pattern, and the combination that is closest to the overall average value To do.
- the block determination unit 132 changes the decoding order of the macroblocks so that the selected plurality of macroblocks are decoded in parallel (S306).
- H.264 encoded image data can be decoded in parallel.
- the data transfer necessary for decoding the H.264 encoded image is other than the acquisition and transfer of the reference image for motion compensation prediction.
- the acquisition transfer of the reference image occupies most of the data transfer amount necessary for decoding, the memory bandwidth of the external memory 110 is reduced by suppressing an instantaneous increase in the data transfer amount of the reference image acquisition. Can be suppressed.
- FIG. 11 is a flowchart showing an example of processing in which the macroblock decoding unit 140 according to the first embodiment decodes a macroblock. Note that the process of performing macroblock decoding by the macroblock decoding unit 150 and the macroblock decoding unit 160 is the same as the process of decoding the macroblock by the macroblock decoding unit 140, and is therefore omitted.
- the macroblock decoding unit 140 when receiving a macroblock decoding start instruction from the decoding control unit 130, the macroblock decoding unit 140 reads the decoding stream of the decoding target macroblock from the external memory 110 (S402).
- the macroblock decoding unit 140 reads the prediction mode from the decoded stream, and determines whether the prediction mode is intra prediction or inter prediction (S404).
- the intra prediction unit 143 is activated to perform intra prediction processing, and to obtain pixel data of the prediction block. Generate (S406).
- the motion compensation prediction unit 144 is activated to perform motion compensation prediction processing, and to obtain pixel data of the prediction block. Generate (S408).
- the macroblock decoding unit 140 reads prediction error data from the decoded stream, performs inverse quantization by the inverse quantization unit 141, and performs inverse orthogonal transform by the inverse orthogonal transform unit 142, thereby converting the prediction error pixel data for the prediction block.
- the macroblock decoding unit 140 adds the pixel data of the prediction block and the prediction error pixel data by the addition circuit 145 to obtain reconstructed pixel data (S412).
- the macroblock decoding unit 140 notifies the decoding control unit 130 of the completion of the macroblock (S414). At the same time, the macroblock decoding unit 140 passes information to be used as neighboring adjacent macroblock information for subsequent decoding among the decoded macroblock information to the decoding control unit 130.
- the predicted data amount of the reference image is calculated from the number of reference images, and a plurality of blocks of encoded image data to be decoded in parallel are determined.
- a plurality of blocks are decoded in parallel. That is, when the encoded image data is decoded in parallel, the predicted data amount acquired from the memory can be accurately calculated in advance, so that the variation in the data amount read from the external memory 110 is reduced in parallel. It is possible to appropriately select a block to be decoded.
- the macro block type information is decoded as reference information indicating the number of reference images. Thereby, the number of reference images can be easily obtained.
- a plurality of blocks to be decoded in parallel are determined by changing the decoding order of the blocks. Thereby, the decoding order of blocks can be changed so that the data transfer amount does not increase instantaneously. If the encoded image data is most effective in this method, the memory bandwidth of the external memory 110 can be reduced by up to almost half.
- a plurality of blocks to be decoded in parallel are determined so that the average value of the prediction data amounts of the plurality of blocks approaches the average value of the prediction data amounts of a predetermined number of blocks. Thereby, the prediction data amount of the block in which parallel decoding is performed becomes an average value.
- the stream parser unit 120 when decoding the encoded image data, when referring to a reference image in units of divided blocks obtained by dividing each macroblock of the encoded image data into smaller blocks, the stream parser unit 120 further sends block division pattern information indicating the size of the divided blocks included in the encoded image data to the decoding control unit 130.
- the data transfer amount prediction unit 131 further includes a probability that a reference image at an integer pixel position is referred to and a probability that a reference image at a decimal pixel position is referred to for each divided block having the size indicated by the block division pattern information. Is used to weight the data amount of the reference image at the integer pixel position and the data amount of the reference image at the decimal pixel position to calculate the predicted data amount.
- the block division pattern information includes a macro block division pattern that is a macro block division pattern and a sub macro block division pattern that is a sub macro block division pattern. That is, in the second embodiment, the stream parser unit 120 sends at least mb_type and sub_mb_type among the decoded parameters to the decoding control unit 130. Details will be described later.
- the process (S112 in FIG. 6) in which the data transfer amount prediction unit 131 shown in FIG. 6 calculates the predicted data amount is a process different from the first embodiment. Since this process is the same as that of the first embodiment, details of the process (S112 in FIG. 6) will be described below.
- FIG. 12 is a flowchart illustrating an example of processing in which the data transfer amount prediction unit 131 according to the second embodiment calculates the predicted data amount.
- the process of calculating the prediction data amount for one macroblock is shown, but the data transfer amount prediction unit 131 performs the process shown in the figure for all the macroblocks in the picture.
- the data transfer amount prediction unit 131 acquires the macroblock type of the macroblock to be decoded from the mb_type decoded by the stream parser unit 120 (S502). Details are the same as the processing (S202 in FIG. 7) for acquiring the macroblock type in FIG.
- the data transfer amount prediction unit 131 determines which macroblock type is the acquired macroblock type (S504).
- the data transfer amount prediction unit 131 calculates that the predicted data amount is 0 bytes (S506), and ends the processing. To do.
- the data transfer amount prediction unit 131 determines that the acquired macroblock type is the P macroblock type or the B macroblock type (“P or B” in S504)
- the macroblock of the macroblock to be decoded is determined from mb_type.
- a division pattern is acquired (S508).
- FIG. 13 is a diagram for explaining a macroblock division pattern.
- mb_type defines four types of macroblock division patterns of 16 pixels ⁇ 16 pixels, 16 pixels ⁇ 8 pixels, 8 pixels ⁇ 16 pixels, and 8 pixels ⁇ 8 pixels.
- each divided block into which the macroblock is divided is assigned a number called mbPartIdx (Macroblock Partition Index).
- mbPartIdx Macroblock Partition Index
- a macroblock division pattern can be acquired from the value of mb_type. That is, “Name of mb_type” shown in FIGS. 8 and 9 represents a macroblock division pattern. “NumMbPart (mb_type)” indicates the number of divided blocks of the macroblock, “MbPartWidth (mb_type)” indicates the width of the divided block of the macroblock, and “MbPartHeight (mb_type)” indicates the height of the divided block of the macroblock. It shows.
- the stream parser unit 120 decodes mb_type included in the encoded stream, so that the data transfer amount prediction unit 131 acquires the macroblock division pattern of the macroblock to be decoded from mb_type.
- the data transfer amount prediction unit 131 determines which macroblock division pattern is the acquired macroblock division pattern (S510).
- idx is an integer of 0 or more.
- the sub_mb_type is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent in advance from the stream parser unit 120 to the decoding control unit 130.
- FIG. 14 is a diagram for explaining a sub-macroblock division pattern.
- a sub-macroblock division pattern of 8 pixels ⁇ 4 pixels, 4 pixels ⁇ 8 pixels, 4 pixels ⁇ 4 pixels is defined.
- each divided block into which the sub macroblock is divided is assigned a number called subMbPartIdx (Sub-Macroblock Partition Index).
- subMbPartIdx Sub-Macroblock Partition Index
- FIG. 15 is a diagram showing a sub macroblock type and sub macroblock division pattern in a P macroblock.
- FIG. 16 is a diagram showing sub-macroblock types and sub-macroblock division patterns in B macroblocks.
- sub_mb_type is further determined for each sub-macroblock of 8 pixels ⁇ 8 pixels.
- segmentation pattern can be acquired from the value of sub_mb_type.
- “Name of sub_mb_type” shown in these drawings indicates a sub macroblock division pattern. “NumMbPart (sub_mb_type)” indicates the number of divided blocks of the sub macroblock, “MbPartWidth (sub_mb_type)” indicates the width of the divided block of the sub macroblock, and “MbPartHeight (sub_mb_sub block of sub_macro block)”. Indicates the height of the block.
- the stream parser unit 120 decodes sub_mb_type included in the encoded stream, so that the data transfer amount prediction unit 131 acquires the sub-macroblock division pattern of the macroblock to be decoded from the sub_mb_type.
- the data transfer amount prediction unit 131 determines which sub-macroblock division pattern is the acquired sub-macroblock division pattern (S516).
- the prediction data amount is 121 bytes. Calculate (S518).
- the prediction data amount is 49 bytes ⁇ 4 is calculated (S520).
- the data transfer amount prediction unit 131 determines that the sub-macroblock division pattern is a sub-macroblock division pattern of 8 pixels ⁇ 4 pixels or 4 pixels ⁇ 8 pixels (“8 ⁇ 4 or 4 ⁇ 8” in S516)
- the predicted data amount is calculated to be 77 bytes ⁇ 2 (S522).
- the data transfer amount prediction unit 131 adds 1 to idx (S524), and determines whether idx is greater than 3 (S526).
- the data transfer amount prediction unit 131 determines that idx is 3 or less (NO in S526), the data transfer amount prediction unit 131 repeats the process of calculating the predicted data amount (S514 to S524). That is, the data transfer amount prediction unit 131 calculates the predicted data amount for the divided blocks of all the sub macroblocks.
- the prediction data amount is 361 bytes. Calculate (S528).
- the data transfer amount prediction unit 131 determines that the macroblock division pattern is a macroblock division pattern of 16 pixels ⁇ 8 pixels or 8 pixels ⁇ 16 pixels (“16 ⁇ 8 or 8 ⁇ 16” in S510).
- the predicted data amount is calculated to be 209 bytes ⁇ 2 (S530).
- FIG. 17 shows H.264 in the second embodiment. It is a figure which shows the calculation method of the pixel value of a reference image of the decimal position pixel in H.264 motion compensation prediction.
- the pixel value of the half-position pixel located between the pixels is calculated by a 6-tap FIR (Finite Impulse Response) filter operation. Therefore, in order to calculate the pixel value of the 1/2 position pixel, 6 pixels at integer positions adjacent to the periphery are required.
- FIR Finite Impulse Response
- the pixel value of the 1/4 position pixel is calculated by taking the average of the pixel values of adjacent integer position pixels or 1/2 position pixels as shown in FIG. For this reason, in order to calculate the pixel value of the 1/4 position pixel, reference image data having the same data amount as that for calculating the pixel value of the 1/2 position pixel is required.
- FIG. 18 shows the H.264 in the second embodiment. It is a figure which shows the relationship between the unit block of H.264 motion compensation prediction, and prediction data amount.
- the “motion compensated prediction unit block” column shows the size of the motion compensated prediction unit block.
- the column “both horizontal and vertical positions is an integer pixel position” is the size of the reference image when a reference image in which both the horizontal position and the vertical position are integer pixel positions is required for motion compensation prediction. And the amount of data.
- the data amount of the reference image necessary for motion compensation prediction is the same as the data amount of the unit block for motion compensation prediction.
- the column “horizontal position is decimal pixel position” is a reference in the case where a reference image whose horizontal position is a decimal pixel position and a reference image whose vertical position is an integer pixel position is necessary for motion compensation prediction. The size of the image and the amount of data are shown.
- the column “Vertical position is decimal pixel position” is a reference image in the case where a reference image whose vertical position is a decimal pixel position and a reference image whose horizontal position is an integer pixel position is necessary for motion compensation prediction. And the amount of data.
- the column of “both horizontal and vertical positions is a decimal pixel position” indicates the size of the reference image when a reference image in which both the horizontal position and the vertical position are decimal pixel positions is required for motion compensation prediction. And the amount of data.
- the column of “predicted data amount” indicates a predicted value of the data amount of the reference image that is actually acquired from the external memory 110.
- the predicted value of the data amount of the reference image is calculated on the assumption that the position indicated by the motion vector is an integer position and the decimal position has an equal probability.
- pixels C, D, I, and L both horizontal and vertical positions are integer pixel positions”. Further, there are six pixels “a” to “f” whose “horizontal position is the decimal pixel position”. In addition, there are six pixels “g” to “l” whose “vertical position is the decimal pixel position”. In addition, there are nine pixels m to u at “both horizontal and vertical positions are decimal pixel positions”.
- the predicted data amount is calculated by weighting the data amount by 4: 6: 6: 9, respectively.
- the data transfer amount prediction unit 131 calculates the predicted data amount according to the following equation.
- the data transfer amount prediction unit 131 sets, for each divided block, the probability that the first reference image whose horizontal position and vertical position are both integer pixel positions are referred to as the first probability, and the horizontal position is the decimal pixel position.
- the probability that the second reference image whose vertical position is the integer pixel position is referred to as the second probability
- the probability that the third reference image whose horizontal position is the integer pixel position and whose vertical position is the decimal pixel position is referred to.
- Is the third probability, and the probability that the fourth reference image whose horizontal position and vertical position are both decimal pixel positions is referred to is the fourth probability, the first reference image, the second reference image, the third reference image, and The predicted data amount is calculated by multiplying the data amount of the fourth reference image by the first probability, the second probability, the third probability, and the fourth probability, respectively, and adding them.
- the data transfer amount prediction unit 131 determines which macroblock type is the macroblock type of the macroblock to be decoded (S532).
- the data transfer amount prediction unit 131 determines that the macroblock type is the P macroblock type (“P” in S532), the data transfer amount prediction unit 131 ends the process.
- the data transfer amount prediction unit 131 determines that the macroblock type is the B macroblock type (“B” in S532), the data transfer amount prediction unit 131 doubles the predicted data amount (S534), and ends the processing.
- the macroblock type and the macroblock division pattern are obtained from mb_type and sub_mb_type in the macroblock layer. Then, it is assumed that the total sum of the prediction data amounts corresponding to the respective divided blocks in the macro block is the data amount of the reference image acquired from the external memory 110.
- the macroblock type of the divided block is the B macroblock type, taking into account that two reference images are required, a value twice the predicted data amount in FIG. 18 is set as the predicted value. .
- the prediction data amount in FIG. 18 is used as a prediction value, and in the case of the I macroblock pattern, motion compensation prediction is not performed. Therefore, the predicted value is calculated as zero.
- MbPartWidth and MbPartHeight obtained from mb_type are the width and height of the divided block.
- MbPartWidth and MbPartHeight obtained from sub_mb_type are the width and height of the divided block.
- the predicted data amount is calculated using block division pattern information. Therefore, even when it is necessary to refer to the reference image in units of divided blocks, the predicted data amount can be calculated.
- the predicted data amount is calculated by further weighting the data amount of the reference image at the integer pixel position and the data amount of the reference image at the decimal pixel position.
- the predicted data amount is calculated using the probability that a reference image whose horizontal position or vertical position is an integer pixel position or decimal pixel position is referred to. As a result, the calculation is performed in consideration of whether the horizontal position or the vertical position is an integer pixel position or a fractional pixel position, so that the predicted data amount can be calculated more accurately.
- Embodiment 3 for each macroblock, the stream parser unit 120 further sends motion information indicating the amount of motion between the macroblock image to be decoded and the reference image to the decoding control unit 130 for data transfer.
- the amount prediction unit 131 further calculates the prediction data amount using the motion information for each macroblock.
- the stream parser unit 120 sends at least mb_type, sub_mb_type, and mvd to the decoding control unit 130 among the decoded parameters.
- the data transfer amount prediction unit 131 determines whether or not the position of the reference image indicated by the motion information is a decimal pixel position, and determines that the position of the reference image is a decimal pixel position.
- the data amount of the reference image at the pixel position is calculated as the predicted data amount.
- the process (S112 in FIG. 6) in which the data transfer amount prediction unit 131 shown in FIG. 6 calculates the predicted data amount is a process different from the first embodiment. Since this process is the same as that of the first embodiment, details of the process (S112 in FIG. 6) will be described below.
- FIG. 19 is a flowchart illustrating an example of processing in which the data transfer amount prediction unit 131 in the third embodiment calculates the predicted data amount.
- the process of calculating the prediction data amount for one macroblock is shown, but the data transfer amount prediction unit 131 performs the process shown in the figure for all the macroblocks in the picture.
- the data transfer amount prediction unit 131 acquires the macroblock type of the macroblock to be decoded from the mb_type decoded by the stream parser unit 120 (S602). Details are the same as the processing (S202 in FIG. 7) for acquiring the macroblock type in FIG.
- the data transfer amount prediction unit 131 determines which macroblock type is the acquired macroblock type (S604).
- the data transfer amount prediction unit 131 calculates that the predicted data amount is 0 bytes (S606), and ends the process. To do.
- the data transfer amount prediction unit 131 determines that the acquired macroblock type is the P macroblock type or the B macroblock type (“P or B” in S604)
- the macroblock of the macroblock to be decoded is determined from mb_type.
- a division pattern is acquired (S608). Details are the same as the processing (S508 in FIG. 12) for acquiring the macroblock division pattern in FIG.
- the data transfer amount prediction unit 131 determines which macroblock division pattern is the acquired macroblock division pattern (S612).
- the data transfer amount prediction unit 131 determines that the macroblock division pattern is a macroblock division pattern of 8 pixels ⁇ 8 pixels (“8 ⁇ 8” in S612), the data transfer amount prediction unit 131 uses the macroblock division pattern of 8 pixels ⁇ 8 pixels. In this case, the predicted data amount is calculated (S614). Processing for calculating the predicted data amount when the data transfer amount predicting unit 131 has a macroblock division pattern of 8 pixels ⁇ 8 pixels will be described later.
- the data transfer amount prediction unit 131 determines that the macroblock division pattern is a macroblock division pattern other than 8 pixels ⁇ 8 pixels (“other than 8 ⁇ 8” in S612)
- the predicted data amount is calculated (S616). Processing for calculating the predicted data amount when the data transfer amount prediction unit 131 is a macroblock division pattern other than 8 pixels ⁇ 8 pixels will be described later.
- the data transfer amount prediction unit 131 adds 1 to idx (S618), and determines whether or not idx is larger than “the number of macroblock divisions ⁇ 1” (S620).
- the data transfer amount prediction unit 131 determines that idx is equal to or less than “the number of divisions of the macroblock ⁇ 1” (NO in S620)
- the data transfer amount prediction unit 131 repeats the process of calculating the predicted data amount (S612 to S618). That is, the data transfer amount prediction unit 131 calculates the prediction data amount for the divided blocks of all macroblocks.
- FIG. 20 is a flowchart illustrating an example of a process for calculating the predicted data amount when the data transfer amount prediction unit 131 according to the third embodiment has a macroblock division pattern of 8 pixels ⁇ 8 pixels.
- the sub macro block division pattern of the macro block to be decoded is 8 pixels ⁇ 8 pixels
- the sub macro block division pattern exists in the sub macro block of 8 pixels ⁇ 8 pixels.
- the sub_mb_type is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent in advance from the stream parser unit 120 to the decoding control unit 130.
- subIdx is an integer of 0 or more.
- the data transfer amount prediction unit 131 uses “MbPartWidth (sub_mb_type)” that is the width of the divided block of the sub macroblock and the height of the divided block of the sub macroblock shown in FIG. 15 or FIG. A certain “MbPartHeight (sub_mb_type)” is acquired. Then, the data transfer amount prediction unit 131 substitutes MbPartWidth (sub_mb_type) for subW, and substitutes MbPartHeight (sub_mb_type) for subH.
- MbPartWidth sub_mb_type
- the data transfer amount prediction unit 131 determines whether the horizontal position indicated by the motion vector is a decimal pixel position (S710).
- the data transfer amount prediction unit 131 adds 5 to subW (S712). That is, the data transfer amount prediction unit 131 increases the width of the divided block of the sub macroblock by 5 pixels.
- the data transfer amount prediction unit 131 determines that the horizontal position pointed to by the motion vector is not a decimal pixel position (NO in S710), it proceeds to the next process (S714) without adding to subW.
- the data transfer amount prediction unit 131 determines whether or not the vertical position indicated by the motion vector is a decimal pixel position (S714).
- the data transfer amount prediction unit 131 adds 5 to subH (S716). That is, the data transfer amount prediction unit 131 widens the height of the divided block of the sub macroblock by 5 pixels.
- the data transfer amount prediction unit 131 determines that the vertical position indicated by the motion vector is not a decimal pixel position (NO in S714), the data transfer amount prediction unit 131 proceeds to the next process (S718) without adding to subH.
- the data transfer amount prediction unit 131 calculates a value obtained by multiplying subW by subH as a predicted data amount (S718).
- FIG. 21 is a flowchart illustrating an example of a process for calculating a predicted data amount when the data transfer amount prediction unit 131 according to the third embodiment has a macroblock division pattern other than 8 pixels ⁇ 8 pixels.
- the submacroblock division pattern of the macroblock to be decoded is other than 8 pixels ⁇ 8 pixels, the submacroblock division pattern does not exist in the submacroblock, and the submacroblock is the minimum unit of the decoding process.
- the data transfer amount prediction unit 131 acquires the size of the sub macroblock and substitutes it for w and h (S802).
- the data transfer amount prediction unit 131 indicates “MbPartWidth (mb_type)” which is the width of the divided block of the macroblock and the height of the divided block of the macroblock shown in FIG. MbPartHeight (mb_type) ”is acquired. Then, the data transfer amount prediction unit 131 substitutes MbPartWidth (mb_type) for w and substitutes MbPartHeight (mb_type) for h.
- the data transfer amount prediction unit 131 determines whether or not the horizontal position indicated by the motion vector is a decimal pixel position (S806).
- the data transfer amount prediction unit 131 adds 5 to w (S808). That is, the data transfer amount prediction unit 131 widens the width of the sub macroblock by 5 pixels.
- the data transfer amount prediction unit 131 determines that the horizontal position indicated by the motion vector is not a decimal pixel position (NO in S806), the data transfer amount prediction unit 131 proceeds to the next process (S810) without adding to w.
- the data transfer amount prediction unit 131 determines whether the vertical position indicated by the motion vector is a decimal pixel position (S810).
- the data transfer amount prediction unit 131 determines that the vertical position indicated by the motion vector is a decimal pixel position (YES in S810), it adds 5 to h (S812). That is, the data transfer amount prediction unit 131 widens the height of the sub macroblock by 5 pixels.
- the data transfer amount prediction unit 131 determines that the vertical position indicated by the motion vector is not a decimal pixel position (NO in S810), the data transfer amount prediction unit 131 proceeds to the next process (S814) without adding to h.
- the data transfer amount prediction unit 131 calculates a value obtained by multiplying w by h as a predicted data amount (S814).
- the predicted data amount is calculated using the motion information. Therefore, since the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected.
- the data amount of the reference image at the decimal pixel position is calculated as the predicted data amount. Therefore, since the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected.
- the data transfer amount prediction unit 131 determines whether the address of the reference image indicated by the motion information is an aligned address, and determines that the address of the reference image is not an aligned address. In this case, the predicted data amount is calculated by correcting the address of the reference image to the aligned address.
- the address of the reference image data read from the external memory 110 is an unaligned address, it must be read from the aligned address. Therefore, it is necessary to read out from the external memory 110 for that much.
- the address of the external memory 110 from which the reference image is read can also be calculated, so that the data amount can be predicted in consideration of the address alignment.
- the transfer data amount of the reference image can be completely predicted.
- the stream parser unit 120 sends to the decoding control unit 130 parameters necessary for calculating at least motion vectors such as mb_type, sub_mb_type, ref_idx, and mvd among the decoded parameters.
- the process (S614 and S616 in FIG. 19) in which the data transfer amount prediction unit 131 shown in FIG. 19 calculates the predicted data amount is a process different from the third embodiment. Since other processes are the same as those in the third embodiment, details of the processes (S614 and S616 in FIG. 19) will be described below.
- FIG. 22 is a flowchart illustrating an example of a process for calculating a predicted data amount when the data transfer amount prediction unit 131 according to the fourth embodiment has a macroblock division pattern of 8 pixels ⁇ 8 pixels.
- the sub_mb_type is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent in advance from the stream parser unit 120 to the decoding control unit 130.
- the address on the external memory 110 of the reference image necessary for motion compensation of the divided blocks is calculated (S908).
- ref_idx is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent from the stream parser unit 120 to the decoding control unit 130 in advance.
- the data transfer amount prediction unit 131 determines whether or not the calculated address of the reference image is an aligned position (S910).
- the data transfer amount prediction unit 131 determines that the calculated reference image address is not an aligned position (NO in S910), the data transfer amount prediction unit 131 corrects the reference image address to the aligned address (S912).
- FIG. 23 is a diagram illustrating that the data transfer amount prediction unit 131 according to the fourth embodiment corrects the reference image to the aligned address.
- the 13 ⁇ 13-byte reference image straddles the boundary of the memory alignment.
- the 13 ⁇ 13-byte reference image When transferring a reference image having such an address that crosses the boundary of memory alignment, it must be transferred from the aligned address.
- the data transfer amount prediction unit 131 corrects the address of the reference image that is not in the aligned position to the aligned address.
- the data transfer amount prediction unit 131 calculates the data transfer amount of the reference image from the address of the reference image (S914). For example, in the case shown in FIG. 23, the data transfer amount prediction unit 131 calculates 312 bytes as the data transfer amount of the reference image.
- the data transfer amount prediction unit 131 calculates the calculated data transfer amount of the reference image as the predicted data amount of the reference image (S916).
- FIG. 24 is a flowchart illustrating an example of a process for calculating the predicted data amount when the data transfer amount prediction unit 131 according to the fourth embodiment has a macroblock division pattern other than 8 pixels ⁇ 8 pixels.
- the address on the external memory 110 of the reference image necessary for motion compensation of the sub-macroblock is calculated (S1004).
- ref_idx is a parameter obtained when the stream parser unit 120 performs variable length decoding on the encoded stream, and is sent from the stream parser unit 120 to the decoding control unit 130 in advance.
- the data transfer amount prediction unit 131 determines whether or not the calculated address of the reference image is an aligned position (S1006).
- the data transfer amount prediction unit 131 determines that the calculated reference image address is not an aligned position (NO in S1006), the data transfer amount prediction unit 131 corrects the reference image address to the aligned address (S1008).
- the data transfer amount prediction unit 131 calculates the data transfer amount of the reference image from the address of the reference image (S1010). For example, in the case shown in FIG. 23, the data transfer amount prediction unit 131 calculates 312 bytes as the data transfer amount of the reference image.
- the data transfer amount prediction unit 131 calculates the calculated data transfer amount of the reference image as the predicted data amount of the reference image (S1012).
- the predicted data amount is calculated by correcting the address of the reference image to the aligned address. To do. Thereby, since the prediction data amount can be calculated more accurately, blocks to be decoded in parallel can be appropriately selected. As a result, an instantaneous increase in data transfer amount can be suppressed and parallel decoding of image data can be performed with a small memory bandwidth.
- the block determination unit 132 changes the number of macroblocks that are decoded in parallel using the predicted data amount so that the fluctuation of the data amount read from the external memory 110 is reduced. Thus, a plurality of macroblocks of encoded image data to be decoded in parallel are determined.
- the process (S114 in FIG. 6) in which the block determination unit 132 shown in FIG. 6 determines a macroblock to be decoded in parallel is a process different from that in the first embodiment. Since this process is the same as in the first embodiment, the details of the process (S114 in FIG. 6) will be described below.
- FIG. 25 is a flowchart showing an example of processing for determining macroblocks to be decoded in parallel by the block determination unit 132 according to the fifth embodiment.
- the block determination unit 132 calculates the average value of the predicted data amounts of a predetermined number of macroblocks (S1102).
- the predetermined number of macroblocks may be all macroblocks in the picture, or may be macroblocks for which the block determining unit 132 has already determined the decoding order.
- the block determination unit 132 performs the macro decoding in parallel so that the average value of the prediction data amounts of the plurality of macro blocks that are decoded in parallel approaches the average value of the prediction data amounts of the predetermined number of macro blocks.
- the number of blocks is determined (S1104).
- FIG. 26 is a diagram illustrating that the block determination unit 132 according to the fifth embodiment determines the number of macroblocks to be decoded in parallel.
- the decoding order of the macroblocks is performed in the order shown in the figure, and basically the decoding is performed in the order of the numbers given to the macroblocks in the figure. That is, the macroblock on the left side of the second column in the next lower row is decoded in parallel in units of three rows.
- the number of macroblocks that can be decoded in parallel may be larger than the number of macroblock decoding units.
- the decoding order shown in FIG. 26 is set so that the number of macroblocks to be decoded in parallel is three or less in consideration of the fact that there are only three macroblock decoding units.
- the macroblock to be decoded in parallel is a macroblock for which a lot of data must be acquired from the external memory 110, a lot of data is transferred at that moment. There must be.
- the sum of the predicted transfer data amounts of these decoding candidate macroblocks is obtained as macroblock candidates for decoding the macroblocks with the same number in parallel.
- the calculated predicted transfer data amount is larger than a predetermined transfer data amount, and if it is smaller, these three decoding candidate macroblocks are decoded. However, if it is larger, any one of the decoding candidate macroblocks is not decoded. Any macroblock that is not to be decoded may be selected. For example, the macroblock located in the lowermost row is not decoded.
- the amount of data transferred from the external memory 110 is suppressed by limiting the number of macroblocks to be decoded in parallel to two.
- a macroblock that has not been decoded is determined whether or not to decode again in addition to the decoding candidate macroblock at the decoding timing of the next macroblock.
- the three macro blocks with the number 6 in FIG. 26 are decoding candidate macro blocks.
- the sum of the predicted transfer data amounts of the sixth macro block is obtained. If the total transfer data amount is smaller than the predetermined transfer data amount, these three macro blocks are decoded. If the transfer data amount is larger than the predetermined transfer data amount, the sixth macroblock in the first and second rows from the top is removed except for the sixth macroblock in the third row from the top.
- the macroblock to be decoded is determined by using the macroblock No. 7 in the first row and the second row and the macroblock No. 6 in the third row that was not decoded earlier as decoding candidate macroblocks. Go.
- the image decoding device of the fifth embodiment occupies the memory bandwidth, and the other devices receive data from the external memory 110. It is possible to prevent a situation in which transfer is not possible.
- the number of macroblocks to be decoded in parallel is changed so that the fluctuation in the amount of data read from the external memory 110 is reduced.
- a plurality of macroblocks to be decoded in parallel are determined.
- the number of macroblocks can be changed so that the data transfer amount does not increase instantaneously. Accordingly, it is possible to perform parallel decoding of image data with a small memory bandwidth while suppressing an instantaneous increase in data transfer amount.
- the decoding order of the macroblocks is determined before performing the decoding process of the macroblocks, but only the data transfer amount of the reference image is predicted in advance, and the parallel decoding of the macroblocks is performed.
- the decoding order may be determined adaptively. For example, if another device other than the image decoding device 100 according to the first embodiment also accesses the external memory 110, when the other device accesses the external memory 110, the data transfer amount of the reference image is small. Select a macroblock and decode it. In this way, the image decoding apparatus 100 and other apparatuses can be operated simultaneously.
- the block determination unit 132 determines that the total value of the predicted data amounts of a plurality of macroblocks that are decoded in parallel from the maximum data amount that can be transferred from the external memory 110.
- a plurality of macroblocks to be decoded in parallel are determined so as to approach the difference data amount that is the data amount obtained by subtracting the data amount to which other devices perform data transfer.
- the block determination unit 132 performs a plurality of macroblocks that are decoded in parallel such that the total value of the prediction data amounts of the plurality of macroblocks that are decoded in parallel is large. To decide.
- the block determination unit 132 performs a plurality of macroblocks that are decoded in parallel so that the total value of the prediction data amounts of the plurality of macroblocks that are decoded in parallel is small. To decide.
- FIG. 27 is a block diagram illustrating a functional configuration when another device 200 according to the sixth embodiment accesses the external memory 110 of the image decoding device 100.
- the image decoding apparatus 100 has the same configuration as the image decoding apparatus 100 according to the first embodiment described with reference to FIG.
- another device 200 is a device different from the image decoding device 100 that accesses the external memory 110 of the image decoding device 100.
- the other device 200 may be a single device or a plurality of devices.
- the other device 200 is, for example, an image encoding block, an audio decoding block, an audio encoding block, a processor block, a graphic accelerator, or the like.
- the other device 200 may be any device as long as it shares the image decoding device 100 and the external memory 110.
- the external memory transfer amount control unit 300 receives the data transfer amount between the other device 200 and the external memory 110 from the other device 200. The external memory transfer amount control unit 300 then obtains the data transfer amount obtained by subtracting the data transfer amount of the other device 200 from the maximum transfer performance (transfer amount) of the external memory 110, and the decoding control unit 130 of the image decoding device 100. Notify
- the decoding control unit 130 selects a macroblock and performs a decoding process so that the predicted data amount approaches the notified data transfer amount.
- the process of determining the macroblock to be decoded in parallel by the block determination unit 132 shown in FIG. 6 is a process different from that of the first embodiment. Since this process is the same as in the first embodiment, the details of the process (S114 in FIG. 6) will be described below.
- FIG. 28 is a flowchart showing an example of processing for determining macroblocks to be decoded in parallel by the block determination unit 132 according to the sixth embodiment.
- the external memory transfer amount control unit 300 acquires the data transfer amount between the other device 200 and the external memory 110 from the other device 200 (S1202).
- the external memory transfer amount control unit 300 calculates a difference data amount obtained by subtracting the data transfer amount of the other device 200 from the maximum data transfer amount that can be transferred from the external memory 110 (S1204). 132.
- the block determination unit 132 determines a plurality of macroblocks to be decoded in parallel so that the total value of the prediction data amounts of the plurality of macroblocks to be decoded in parallel approaches the difference data amount (S1206). Specifically, the block determination unit 132 determines the plurality of macroblocks so that the total value is equal to or less than the difference data amount.
- decoding is performed in parallel so that the total value of the prediction data amounts of a plurality of blocks to be decoded in parallel approaches the difference data amount.
- Determine the blocks to be played That is, when the difference data amount is large, the total value of the prediction data amounts of a plurality of blocks to be decoded in parallel is increased, and when the difference data amount is small, the plurality of blocks to be decoded in parallel are decoded.
- a plurality of blocks to be decoded in parallel are determined so that the total value of the predicted data amount is small.
- control is performed so that the data transfer amount of the image decoding device 100 becomes small. Even if another device 200 is operated simultaneously with 100, the processing of the other device 200 can be operated without delay.
- the control is performed so that the data transfer amount of the image decoding device 100 is increased. Therefore, the reference image can be transferred at a high speed in the decoding process. It can speed itself up.
- the external memory transfer amount control unit 300 may not be provided, and the decoding control unit 130 and the other device 200 may directly communicate with each other. That is, the block determination unit 132 may acquire the data transfer amount of the other device 200 from the other device 200 and calculate the difference data amount.
- the image decoding apparatus 100 may mount all or part of the configuration requirements on one integrated circuit, or a plurality of integrated circuits mounted on one substrate. It may be an independent device connected via a network or a bus.
- FIG. 29 is a diagram illustrating an example of the integrated circuit 400 that controls the image decoding apparatus 100.
- the integrated circuit 400 has functions other than the external memory 110 of the image decoding apparatus 100 shown in FIG.
- each processing unit may be individually integrated into one chip, or may be integrated into one chip so as to include a part or all of the processing units.
- the integrated circuit 400 may not include the adjacent MB information memory 180 and the deblocking filter unit. That is, the integrated circuit 400 only needs to include the stream parser unit 120, the data transfer amount prediction unit 131, the block determination unit 132, and the macroblock decoding units 140 to 160, and the configuration achieves the object of the present invention. be able to.
- LSI is used, but depending on the degree of integration, it may be called IC, system LSI, super LSI, or ultra LSI.
- the method of circuit integration is not limited to LSI, and may be realized by a dedicated circuit or a general-purpose processor.
- An FPGA Field Programmable Gate Array
- a reconfigurable processor that can reconfigure the connection and setting of circuit cells inside the LSI may be used.
- the image decoding device has been described using the above embodiment, but the present invention is not limited to this.
- Patent Document 1 describes a method of decoding macroblocks in parallel using three or more macroblock decoding units. According to this method, decoding is performed even using three or more macroblock decoding units. can do. Also, when determining the decoding order of the macroblocks, the block determination unit 132 determines that the average value of the predicted transfer data amount of the reference image of the macroblocks decoded in parallel is the average value of the predicted transfer data amount of each macroblock. The macroblocks should be selected so that they are as close as possible. For this reason, decoding processing can be performed regardless of the number of macroblock decoding units.
- the stream parser unit 120 outputs a decoded stream that has been completely variable-length decoded to the external memory 110.
- the stream parser unit 120 only needs to be able to decode only the parameters necessary for predicting the data transfer amount of the reference image, and does not necessarily need to output a decoded stream that has been completely variable-length decoded.
- a method may be considered in which only the necessary parameters are decoded in the stream parser unit 120 and an intermediate stream obtained by decoding only the portions necessary for parallel decoding of macroblocks is output to the external memory 110. In this case, it is necessary to mount variable length decoding units in the macroblock decoding units 140 to 160 in order to decode the intermediate stream.
- the block determination unit 132 determines macroblocks to be decoded in parallel. did. However, each time the data transfer amount prediction unit 131 calculates the prediction data amount of some macroblocks, the block determination unit 132 may determine macroblocks to be decoded in parallel.
- the data transfer amount prediction unit 131 acquires the macroblock type of the macroblock to be decoded from mb_type.
- the data transfer amount prediction unit 131 may acquire the macroblock type of the macroblock to be decoded from the slice_type included in the slice header.
- the macroblocks of the macroblock to be decoded are assumed to be the macroblock types of the I slice, the P slice, and the B slice, respectively, the I macroblock type, the P macroblock type, and the B macroblock type You can get the type.
- the data transfer amount prediction unit 131 of the decoding control unit 130 calculates the prediction data amount.
- the stream parser unit 120 may calculate the prediction data amount. .
- the image decoding apparatus 100 includes the external memory 110, the stream parser unit 120, the decoding control unit 130, the macroblock decoding units 140 to 160, the deblocking filter unit 170, and the adjacent MB information memory.
- the decoding control unit 130 includes a data transfer amount prediction unit 131 and a block determination unit 132.
- the deblocking filter unit 170 and the adjacent MB information memory 180 are not essential components to achieve the object of the present invention. That is, the image decoding apparatus 100 only needs to include the external memory 110, the stream parser unit 120, the data transfer amount prediction unit 131, the block determination unit 132, and the macroblock decoding units 140 to 160. Can achieve the purpose.
- the image decoding apparatus has a feature capable of decoding moving image data at high speed. Therefore, it is useful as a digital television, a DVD, a Blu-ray Disc (registered trademark) recorder, etc. that handle compressed images such as MPEG. It can also be applied to the use of equipment that requires high-speed processing such as broadcasting stations.
- DESCRIPTION OF SYMBOLS 100 Image decoding apparatus 110 External memory 120 Stream parser part 130 Decoding control part 131 Data transfer amount prediction part 132 Block determination part 140,150,160 Macroblock decoding part 141 Inverse quantization part 142 Inverse orthogonal transformation part 143 In-screen prediction part 144 Motion compensation prediction unit 145 Adder circuit 170 Deblocking filter unit 180 Adjacent MB information memory 200 Other device 300 External memory transfer amount control unit 400 Integrated circuit 501 Start code 502 SPS header 503 PPS header 504 Slice header 505 Slice data
Landscapes
- Engineering & Computer Science (AREA)
- Multimedia (AREA)
- Signal Processing (AREA)
- Computing Systems (AREA)
- Theoretical Computer Science (AREA)
- Compression Or Coding Systems Of Tv Signals (AREA)
Abstract
Description
図3は、本発明の実施の形態1における画像復号装置100の機能構成を示すブロック図である。
本実施の形態2では、符号化画像データの復号が行われる際に、符号化画像データの各マクロブロックをさらに小さなブロックに分割した分割ブロックを単位とした参照画像を参照する場合、ストリームパーサ部120は、符号化画像データに含まれる、分割ブロックのサイズを示すブロック分割パターン情報を、さらに復号制御部130に送る。
+「水平位置が小数画素位置」の参照画像のデータ量×6
+「垂直位置が小数画素位置」の参照画像のデータ量×6
+「水平、垂直位置の両方が小数画素位置」の参照画像のデータ量×9)/25
本実施の形態3では、ストリームパーサ部120は、マクロブロックごとに、復号対象のマクロブロックの画像と参照画像との間の動き量を示す動き情報を、さらに復号制御部130に送り、データ転送量予測部131は、マクロブロックごとに、さらに動き情報を用いて、予測データ量を計算する。
本実施の形態4では、データ転送量予測部131は、動き情報が示す参照画像のアドレスが、アライメントされたアドレスか否かを判断し、参照画像のアドレスがアライメントされたアドレスではないと判断した場合、参照画像のアドレスをアライメントされたアドレスに補正して、予測データ量を計算する。
本実施の形態5では、ブロック決定部132は、外部メモリ110から読み出されるデータ量の変動が小さくなるように、予測データ量を用いて、並列に復号が行われるマクロブロックの数を変更することで、並列に復号が行われる符号化画像データの複数のマクロブロックを決定する。
上記実施の形態1では、マクロブロックの復号処理を行う前にマクロブロックの復号順序を決定したが、参照画像のデータ転送量の予測だけを予め行っておき、マクロブロックの並列復号を行いながら、復号順序を適応的に決定していっても良い。例えば、実施の形態1の画像復号装置100以外の他の装置も、外部メモリ110にアクセスするのであれば、当該他の装置が外部メモリ110にアクセスする時は、参照画像のデータ転送量が小さいマクロブロックを選んで復号する。こうすれば、画像復号装置100も他の装置も同時に動作させることができる。
110 外部メモリ
120 ストリームパーサ部
130 復号制御部
131 データ転送量予測部
132 ブロック決定部
140、150、160 マクロブロック復号部
141 逆量子化部
142 逆直交変換部
143 画面内予測部
144 動き補償予測部
145 加算回路
170 デブロッキングフィルタ部
180 隣接MB情報メモリ
200 他の装置
300 外部メモリ転送量制御部
400 集積回路
501 スタートコード
502 SPSヘッダ
503 PPSヘッダ
504 スライスヘッダ
505 スライスデータ
Claims (16)
- 所定の画素数のブロックごとに分割され符号化された符号化画像データの復号を、前記ブロックごとに行う画像復号装置であって、
前記符号化画像データの復号が行われる際に参照される参照画像のデータを格納している記憶部と、
前記ブロックごとに、前記符号化画像データの復号が行われる際に参照される前記参照画像の枚数を示す参照情報の復号を行うプリデコード部と、
前記ブロックごとに、前記参照情報を用いて、前記符号化画像データの復号が行われる際に前記記憶部から読み出される前記参照画像の予測データ量を計算するデータ転送量予測部と、
計算された前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定するブロック決定部と、
決定された前記符号化画像データの複数のブロックを並列に復号する複数のブロック復号部と
を備える画像復号装置。 - 前記プリデコード部は、前記符号化画像データに含まれる、前記ブロックであるマクロブロックのマクロブロックタイプ情報を前記参照情報として可変長復号し、
前記データ転送量予測部は、前記マクロブロックタイプ情報で示される前記参照画像の枚数に当該参照画像のデータ量を乗じて、前記予測データ量を計算する
請求項1に記載の画像復号装置。 - 前記ブロック復号部が前記符号化画像データの復号を行う際に、前記符号化画像データの各ブロックをさらに小さなブロックに分割した分割ブロックを単位とした前記参照画像を参照する場合、
前記プリデコード部は、さらに、前記符号化画像データに含まれる、前記分割ブロックのサイズを示すブロック分割パターン情報の復号を行い、
前記データ転送量予測部は、前記ブロック分割パターン情報で示されるサイズの前記分割ブロックごとに、さらに、整数画素位置の参照画像が参照される確率と小数画素位置の参照画像が参照される確率とを用いて、前記整数画素位置の参照画像のデータ量と前記小数画素位置の参照画像のデータ量とに重み付けを行うことで、前記予測データ量を計算する
請求項1又は2に記載の画像復号装置。 - 前記データ転送量予測部は、前記分割ブロックごとに、
水平位置及び垂直位置がともに整数画素位置である第1参照画像が参照される確率を第1確率とし、
水平位置が小数画素位置であり垂直位置が整数画素位置である第2参照画像が参照される確率を第2確率とし、
水平位置が整数画素位置であり垂直位置が小数画素位置である第3参照画像が参照される確率を第3確率とし、
水平位置及び垂直位置がともに小数画素位置である第4参照画像が参照される確率を第4確率とし、
前記第1参照画像、前記第2参照画像、前記第3参照画像及び前記第4参照画像のデータ量に、それぞれ前記第1確率、前記第2確率、前記第3確率及び前記第4確率を乗じて加算することで、前記予測データ量を計算する
請求項3に記載の画像復号装置。 - 前記プリデコード部は、前記ブロックごとに、さらに、復号対象の前記ブロックの画像と参照画像との間の動き量を示す動き情報の復号を行い、
前記データ転送量予測部は、前記ブロックごとに、さらに前記動き情報を用いて、前記予測データ量を計算する
請求項1~3のいずれか1項に記載の画像復号装置。 - 前記データ転送量予測部は、前記動き情報が示す参照画像の位置が小数画素位置であるか否かを判断し、前記参照画像の位置が小数画素位置であると判断した場合、小数画素位置の参照画像のデータ量を前記予測データ量として計算する
請求項5に記載の画像復号装置。 - 前記データ転送量予測部は、前記動き情報が示す参照画像のアドレスが、アライメントされたアドレスか否かを判断し、前記参照画像のアドレスがアライメントされたアドレスではないと判断した場合、前記参照画像のアドレスをアライメントされたアドレスに補正して前記予測データ量を計算する
請求項5又は6に記載の画像復号装置。 - 前記ブロック決定部は、前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、前記符号化画像データのブロックの復号順序を入れ替えることで、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項1~7のいずれか1項に記載の画像復号装置。 - 前記ブロック決定部は、前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、並列に復号が行われる前記符号化画像データのブロック数を変更することで、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項1~7のいずれか1項に記載の画像復号装置。 - 前記ブロック決定部は、並列に復号が行われる前記符号化画像データの複数のブロックの予測データ量の平均値が、所定の数のブロックの予測データ量の平均値に近付くように、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項8又は9に記載の画像復号装置。 - 前記ブロック決定部は、並列に復号が行われる前記符号化画像データの複数のブロックの予測データ量の合計値が、前記記憶部から読み出されるデータ転送可能な最大データ量から他の装置がデータ転送を行うデータ量を差し引いたデータ量である差分データ量に近付くように、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項8又は9に記載の画像復号装置。 - 前記ブロック決定部は、前記差分データ量が大きい場合は、並列に復号が行われる前記符号化画像データの複数のブロックの予測データ量の合計値が大きくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項11に記載の画像復号装置。 - 前記ブロック決定部は、前記差分データ量が小さい場合は、並列に復号が行われる前記符号化画像データの複数のブロックの予測データ量の合計値が小さくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定する
請求項11に記載の画像復号装置。 - 所定の画素数のブロックごとに分割され符号化された符号化画像データの復号を、前記ブロックごとに行う画像復号方法であって、
前記ブロックごとに、前記符号化画像データの復号が行われる際に参照される前記参照画像の枚数を示す参照情報の復号を行うプリデコードステップと、
前記ブロックごとに、前記参照情報を用いて、前記符号化画像データの復号が行われる際に、前記符号化画像データの復号が行われる際に参照される参照画像のデータを格納している記憶部から読み出される前記参照画像の予測データ量を計算するデータ転送量予測ステップと、
計算された前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定するブロック決定ステップと、
決定された前記符号化画像データの複数のブロックを並列に復号する複数のブロック復号ステップと
を含む画像復号方法。 - 所定の画素数のブロックごとに分割され符号化された符号化画像データの復号を、前記ブロックごとに行う画像復号装置を制御する集積回路であって、
前記ブロックごとに、前記符号化画像データの復号が行われる際に参照される前記参照画像の枚数を示す参照情報の復号を行うプリデコード部と、
前記ブロックごとに、前記参照情報を用いて、前記符号化画像データの復号が行われる際に、前記符号化画像データの復号が行われる際に参照される参照画像のデータを格納している記憶部から読み出される前記参照画像の予測データ量を計算するデータ転送量予測部と、
計算された前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定するブロック決定部と、
決定された前記符号化画像データの複数のブロックを並列に復号する複数のブロック復号部と
を備える集積回路。 - 所定の画素数のブロックごとに分割され符号化された符号化画像データの復号を、前記ブロックごとに行うためのプログラムであって、
前記ブロックごとに、前記符号化画像データの復号が行われる際に参照される前記参照画像の枚数を示す参照情報の復号を行うプリデコードステップと、
前記ブロックごとに、前記参照情報を用いて、前記符号化画像データの復号が行われる際に、前記符号化画像データの復号が行われる際に参照される参照画像のデータを格納している記憶部から読み出される前記参照画像の予測データ量を計算するデータ転送量予測ステップと、
計算された前記予測データ量を用いて、前記記憶部から読み出されるデータ量の変動が小さくなるように、並列に復号が行われる前記符号化画像データの複数のブロックを決定するブロック決定ステップと、
決定された前記符号化画像データの複数のブロックを並列に復号する複数のブロック復号ステップと
をコンピュータに実行させるプログラム。
Priority Applications (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2010522111A JP5340289B2 (ja) | 2008-11-10 | 2009-10-20 | 画像復号装置、画像復号方法、集積回路及びプログラム |
CN2009801399815A CN102177715A (zh) | 2008-11-10 | 2009-10-20 | 图像解码装置、图像解码方法、集成电路以及程序 |
US12/812,134 US8737476B2 (en) | 2008-11-10 | 2009-10-20 | Image decoding device, image decoding method, integrated circuit, and program for performing parallel decoding of coded image data |
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2008-287320 | 2008-11-10 | ||
JP2008287320 | 2008-11-10 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2010052837A1 true WO2010052837A1 (ja) | 2010-05-14 |
Family
ID=42152650
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/JP2009/005476 WO2010052837A1 (ja) | 2008-11-10 | 2009-10-20 | 画像復号装置、画像復号方法、集積回路及びプログラム |
Country Status (4)
Country | Link |
---|---|
US (1) | US8737476B2 (ja) |
JP (1) | JP5340289B2 (ja) |
CN (1) | CN102177715A (ja) |
WO (1) | WO2010052837A1 (ja) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2012046366A1 (ja) * | 2010-10-07 | 2012-04-12 | パナソニック株式会社 | 画像再生方法、画像再生装置、画像再生プログラム、撮像システム、および再生システム |
WO2019239931A1 (ja) * | 2018-06-14 | 2019-12-19 | ソニー株式会社 | 画像処理装置および方法 |
Families Citing this family (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102754437B (zh) * | 2009-10-29 | 2015-03-18 | 松下电器(美国)知识产权公司 | 图像编码方法、图像编码装置及集成电路 |
US9877033B2 (en) * | 2009-12-21 | 2018-01-23 | Qualcomm Incorporated | Temporal and spatial video block reordering in a decoder to improve cache hits |
GB2477527B (en) | 2010-02-04 | 2015-12-23 | Advanced Risc Mach Ltd | Parallel parsing in a video decoder |
GB2488159B (en) * | 2011-02-18 | 2017-08-16 | Advanced Risc Mach Ltd | Parallel video decoding |
CN110198450B (zh) | 2011-11-08 | 2021-12-31 | 韩国电子通信研究院 | 用于共享候选者列表的方法和装置 |
US20130188732A1 (en) * | 2012-01-20 | 2013-07-25 | Qualcomm Incorporated | Multi-Threaded Texture Decoding |
JP6080405B2 (ja) * | 2012-06-29 | 2017-02-15 | キヤノン株式会社 | 画像符号化装置、画像符号化方法及びプログラム、画像復号装置、画像復号方法及びプログラム |
US10585874B2 (en) * | 2016-04-25 | 2020-03-10 | International Business Machines Corporation | Locking concurrent commands in a database management system |
JP6775558B2 (ja) * | 2018-09-18 | 2020-10-28 | キヤノン株式会社 | 画像伸長装置及びその制御方法及びプログラム |
CN110930292B (zh) * | 2018-09-19 | 2024-01-26 | 珠海金山办公软件有限公司 | 一种图像处理的方法、装置、计算机存储介质及终端 |
US11487544B2 (en) * | 2020-01-15 | 2022-11-01 | Western Digital Technologies, Inc. | Method and device for simultaneously decoding data in parallel to improve quality of service |
Family Cites Families (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
AU5632394A (en) * | 1993-03-05 | 1994-09-08 | Sony Corporation | Apparatus and method for reproducing a prediction-encoded video signal |
US5532744A (en) * | 1994-08-22 | 1996-07-02 | Philips Electronics North America Corporation | Method and apparatus for decoding digital video using parallel processing |
JP4453518B2 (ja) * | 2004-10-29 | 2010-04-21 | ソニー株式会社 | 符号化及び復号装置並びに符号化及び復号方法 |
KR20080094005A (ko) * | 2006-01-10 | 2008-10-22 | 브라이트스케일, 인크. | 병렬 프로세싱 시스템에서 멀티미디어 데이터의 서브블록들을 프로세싱하기 위한 방법 및 장치 |
JP2007318517A (ja) | 2006-05-26 | 2007-12-06 | Sony Corp | 画像データの処理方法、画像データの処理方法のプログラム、画像データの処理方法のプログラムを記録した記録媒体及び画像データの処理装置 |
US8019002B2 (en) * | 2006-06-08 | 2011-09-13 | Qualcomm Incorporated | Parallel batch decoding of video blocks |
JP4254867B2 (ja) * | 2007-01-31 | 2009-04-15 | ソニー株式会社 | 情報処理装置および方法、プログラム、並びに記録媒体 |
RU2502213C2 (ru) * | 2008-06-27 | 2013-12-20 | Сони Корпорейшн | Устройство обработки изображений и способ обработки изображений |
JP5128389B2 (ja) * | 2008-07-01 | 2013-01-23 | 株式会社日立国際電気 | 動画像符号化装置及び動画像符号化方法 |
KR101673186B1 (ko) * | 2010-06-09 | 2016-11-07 | 삼성전자주식회사 | 매크로블록의 연관관계를 고려하여 영상 데이터의 부호화 및 복호화를 병렬 처리하는 장치 및 방법 |
KR101698797B1 (ko) * | 2010-07-27 | 2017-01-23 | 삼성전자주식회사 | 영상 데이터를 분할하여 부호화 및 복호화를 병렬 처리하는 장치 및 상기 장치의 동작 방법 |
-
2009
- 2009-10-20 US US12/812,134 patent/US8737476B2/en active Active
- 2009-10-20 CN CN2009801399815A patent/CN102177715A/zh active Pending
- 2009-10-20 JP JP2010522111A patent/JP5340289B2/ja not_active Expired - Fee Related
- 2009-10-20 WO PCT/JP2009/005476 patent/WO2010052837A1/ja active Application Filing
Non-Patent Citations (2)
Title |
---|
"Proc. of IEEE Int. Conf. on Multimedia and Expo, 2007.07.02", 2 July 2007, article CHONG, J. ET AL.: "Efficient Parallelization of H.264 Decoding with Macro Block Level Scheduling", pages: 1874 - 1877 * |
YASUHIRO WATANABE ET AL.: "Keitai Kiki Muke Tei Shohidenryoku MPEG-4 ASP CODEC Macro", ITE TECHNICAL REPORT, vol. 29, no. 21, 11 March 2005 (2005-03-11), pages 29 - 32 * |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2012046366A1 (ja) * | 2010-10-07 | 2012-04-12 | パナソニック株式会社 | 画像再生方法、画像再生装置、画像再生プログラム、撮像システム、および再生システム |
JP2012085001A (ja) * | 2010-10-07 | 2012-04-26 | Panasonic Corp | 画像再生方法、画像再生装置、画像再生プログラム、撮像システム、および再生システム |
WO2019239931A1 (ja) * | 2018-06-14 | 2019-12-19 | ソニー株式会社 | 画像処理装置および方法 |
Also Published As
Publication number | Publication date |
---|---|
JP5340289B2 (ja) | 2013-11-13 |
JPWO2010052837A1 (ja) | 2012-03-29 |
US20100284468A1 (en) | 2010-11-11 |
CN102177715A (zh) | 2011-09-07 |
US8737476B2 (en) | 2014-05-27 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5340289B2 (ja) | 画像復号装置、画像復号方法、集積回路及びプログラム | |
US11070802B2 (en) | Moving image coding device, moving image decoding device, moving image coding/decoding system, moving image coding method and moving image decoding method | |
US11647219B2 (en) | Image encoding and decoding method with merge flag and motion vectors | |
JP5368631B2 (ja) | 画像符号化方法、装置、及びプログラム | |
US20140105295A1 (en) | Moving image encoding method and apparatus, and moving image decoding method and apparatus | |
JPH09154137A (ja) | 動き依存予測を使用したビデオ情報の圧縮方法と装置 | |
US20070133689A1 (en) | Low-cost motion estimation apparatus and method thereof | |
JP5479648B1 (ja) | 画像符号化方法及び画像復号化方法 | |
JP5444497B2 (ja) | 画像符号化方法及び画像復号化方法 | |
KR101841352B1 (ko) | 참조 프레임 선택 방법 및 그 장치 | |
JP2008289105A (ja) | 画像処理装置およびそれを搭載した撮像装置 | |
US20130170565A1 (en) | Motion Estimation Complexity Reduction | |
US9838666B2 (en) | Video decoding device and image display device | |
JP6609004B2 (ja) | 画像符号化方法及び画像復号化方法 | |
JP6608904B2 (ja) | 動画像符号化装置及び方法 | |
JP6370977B2 (ja) | 画像符号化方法及び画像復号化方法 | |
JP6514307B2 (ja) | 動画像符号化装置及び方法 | |
CN105933709B (zh) | 运动图像编码方法、装置以及运动图像解码方法、装置 | |
JP2020025308A (ja) | 画像符号化方法及び画像復号化方法 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
WWE | Wipo information: entry into national phase |
Ref document number: 200980139981.5 Country of ref document: CN |
|
WWE | Wipo information: entry into national phase |
Ref document number: 2010522111 Country of ref document: JP |
|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 09824538 Country of ref document: EP Kind code of ref document: A1 |
|
WWE | Wipo information: entry into national phase |
Ref document number: 12812134 Country of ref document: US |
|
NENP | Non-entry into the national phase |
Ref country code: DE |
|
122 | Ep: pct application non-entry in european phase |
Ref document number: 09824538 Country of ref document: EP Kind code of ref document: A1 |