Image decoding and encoding apparatus and apparatus for transmitting data for image
By limiting the maximum transformation size of the chroma component encoding block, the problem of low high-resolution and high-quality image encoding/decoding efficiency in the prior art is solved, and more efficient image encoding and decoding is achieved, reducing transmission and storage costs.
Patent Information
- Application Number
- CN202510461426.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2019-06-24
- Filing Date
- 2020-06-24
- Publication Date
- 2025-06-10
AI Technical Summary
The prior art is difficult to effectively improve the encoding/decoding efficiency of high resolution and high-quality images, resulting in increased transmission and storage costs.
The image encoding/decoding method and device are improved by limiting the maximum transformation size of the chroma component encoding block, thereby improving the encoding/decoding efficiency.
Improved encoding/decoding efficiency is achieved, reducing transmission and storage costs, while supporting sending and storing bitstreams generated by image encoding methods or devices.
Smart Images

Figure CN120128708A_ABST
Abstract
Description
[0001] This application is a divisional application of the invention patent application with the original application number 202080055789.4 (International Application No.: PCT / KR2020 / 008231, filing date: June 24, 2020, invention title: Image encoding / decoding method and apparatus and method for transmitting a bitstream using a maximum transform size limit of a chrominance component encoding block). Technical Field
[0002] The present disclosure relates to an image encoding / decoding method and apparatus, and more particularly, to a method and apparatus for encoding / decoding an image by limiting a maximum transform size of a chrominance component encoding block, and a method for transmitting a bitstream generated by the image encoding method / apparatus of the present disclosure. Background Art
[0003] Recently, the demand for high-resolution and high-quality images, such as high-definition (HD) images and ultra-high-definition (UHD) images, is increasing in various fields. As the resolution and quality of image data are improved, the amount of information or bits to be transmitted is relatively increased compared to existing image data. The increase in the amount of information or bits to be transmitted results in an increase in transmission costs and storage costs.
[0004] Therefore, there is a need for an efficient image compression technique to effectively transmit, store, and reproduce information on high-resolution and high-quality images. Summary of the Invention
[0005] Technical Problem
[0006] An object of the present disclosure is to provide an image encoding / decoding method and apparatus having improved encoding / decoding efficiency.
[0007] An object of the present disclosure is to provide an image encoding / decoding method and apparatus capable of improving encoding / decoding efficiency by limiting a maximum transform size of a chrominance component encoding block.
[0008] Another object of the present disclosure is to provide a method for transmitting a bitstream generated by an image encoding method or apparatus according to the present disclosure.
[0009] Another object of the present disclosure is to provide a recording medium storing a bitstream generated by an image encoding method or apparatus according to the present disclosure.
[0010] Another object of the present disclosure is to provide a recording medium storing a bitstream received, decoded, and used for reconstructing an image by an image decoding apparatus according to the present disclosure.
[0011] The technical problems solved by the present disclosure are not limited to the above technical problems, and other technical problems not described herein will be apparent to those skilled in the art from the following description.
[0012] Technical solution
[0013] An image decoding method performed by an image decoding device according to an aspect of the present disclosure may include the following steps: determining a prediction mode of a current block; generating a prediction block of the current block based on the prediction mode of the current block being an Intra Block Copy (IBC) prediction mode and based on IBC prediction mode information; determining a size of a transform block of the current block based on a color component of the current block; generating a residual block of the current block based on the size of the transform block; and reconstructing the current block based on the prediction block and the residual block of the current block.
[0014] In addition, an image decoding device according to an aspect of the present disclosure may include a memory and at least one processor. The at least one processor may determine a prediction mode of a current block, generate a prediction block of the current block based on the prediction mode of the current block being an Intra Block Copy (IBC) prediction mode and based on IBC prediction mode information, determine a size of a transform block of the current block based on a color component of the current block, and generate a residual block of the current block based on the size of the transform block. In this case, the decoding device may reconstruct the current block based on the prediction block and the residual block of the current block.
[0015] In addition, an image encoding method performed by an image encoding device according to an aspect of the present disclosure may include the following steps: determining a current block by dividing an image; generating a prediction block of the current block by performing Intra Block Copy (IBC) prediction on the current block; generating a residual block of the current block based on the prediction block; and encoding prediction mode information of the current block. In this case, the residual block may be encoded based on the size of a transform block of the current block, and the size of the transform block may be determined based on a color component of the current block.
[0016] Furthermore, a transmission method according to another aspect of the present disclosure may transmit a bitstream generated by the image encoding device or the image encoding method of the present disclosure.
[0017] Furthermore, a computer-readable recording medium according to another aspect of the present disclosure may store a bitstream generated by the image encoding device or the image encoding method of the present disclosure.
[0018] The features of the above brief overview of the present disclosure are merely exemplary aspects of the following detailed description of the present disclosure and do not limit the scope of the present disclosure.
[0019] Beneficial effects
[0020] According to the present disclosure, it is possible to provide an image encoding / decoding method and device with improved encoding / decoding efficiency.
[0021] According to the present disclosure, there can be provided an image encoding / decoding method and apparatus capable of improving encoding / decoding efficiency by restricting a maximum transform size of a chrominance component encoding block.
[0022] In addition, according to the present disclosure, there can be provided a method of transmitting a bitstream generated by an image encoding method or apparatus according to the present disclosure.
[0023] In addition, according to the present disclosure, there can be provided a recording medium storing a bitstream generated by an image encoding method or apparatus according to the present disclosure.
[0024] In addition, according to the present disclosure, there can be provided a recording medium storing a bitstream received, decoded, and used for reconstructing an image by an image decoding apparatus according to the present disclosure.
[0025] Those skilled in the art will understand that the effects achievable through the present disclosure are not limited to those specifically described above, and other advantages of the present disclosure will be more clearly understood from the detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] Figure 1 is a view schematically showing a video coding system to which an embodiment of the present disclosure is applicable.
[0027] Figure 2 is a view schematically showing an image encoding apparatus to which an embodiment of the present disclosure is applicable.
[0028] Figure 3 is a view schematically showing an image decoding apparatus to which an embodiment of the present disclosure is applicable.
[0029] Figure 4 is a view showing a segmentation structure of an image according to an embodiment.
[0030] Figure 5 is a view showing an embodiment of a segmentation type of a block according to a multi-type tree structure.
[0031] Figure 6 is a view showing a signaling mechanism of block partition information in a quadtree having a nested multi-type tree structure according to the present disclosure.
[0032] Figure 7 is a view showing an embodiment of dividing a CTU into a plurality of CUs.
[0033] Figure 8 is a view illustrating an embodiment of a redundancy division pattern.
[0034] Figure 9 is a flowchart illustrating a video / image encoding method based on inter prediction.
[0035] Figure 10 is a view illustrating the configuration of the inter prediction unit 180 according to the present disclosure.
[0036] Figure 11 is a flowchart illustrating a video / image decoding method based on inter prediction.
[0037] Figure 12 is a view illustrating the configuration of the inter prediction unit 260 according to the present disclosure.
[0038] Figure 13 is a view illustrating neighboring blocks that can be used as spatial merge candidates according to an embodiment.
[0039] Figure 14 is a view schematically illustrating a method for constructing a merge candidate list according to an embodiment.
[0040] Figure 15 is a view schematically illustrating a method for constructing a motion vector predictor candidate list according to an embodiment.
[0041] Figure 16 is a view illustrating the syntax structure for sending an MVD from an image encoding device to an image decoding device according to an embodiment.
[0042] Figure 17 is a flowchart illustrating an IBC-based video / image encoding method according to an embodiment.
[0043] Figure 18 is a view illustrating the configuration of a prediction unit for performing an IBC-based video / image encoding method according to an embodiment.
[0044] Figure 19 is a flowchart illustrating an IBC-based video / image decoding method according to an embodiment.
[0045] Figure 20 is a view illustrating the configuration of a prediction unit for performing an IBC-based video / image decoding method according to an embodiment.
[0046] Figure 21 is a view illustrating the syntax of chroma format signaling according to an embodiment.
[0047] Figure 22 is a view illustrating a chroma format classification table according to an embodiment.
[0048] Figure 23 is a view illustrating an example of the division limit of a CU for virtual pipeline processing.
[0049] Figures 24 to 26 is a view illustrating an example of the division of a CU and a TU according to an embodiment.
[0050] Figure 27 and Figure 28 is a flowchart exemplifying IBC prediction and intra prediction applying the maximum transform size according to an embodiment.
[0051] Figure 29 is a flowchart exemplifying a method for encoding an image by an encoding device according to an embodiment.
[0052] Figure 30 is a flowchart exemplifying a method for decoding an image by a decoding device according to an embodiment.
[0053] Figure 31 is a view showing a content stream system to which an embodiment of the present disclosure is applicable. Detailed Embodiments
[0054] Hereinafter, embodiments of the present disclosure will be described in detail with reference to the accompanying drawings to facilitate implementation by those skilled in the art. However, the present disclosure can be implemented in various different forms and is not limited to the embodiments described herein.
[0055] When describing the present disclosure, if it is determined that a detailed description of related known functions or configurations makes the scope of the present disclosure unnecessarily ambiguous, the detailed description thereof will be omitted. In the drawings, parts irrelevant to the description of the present disclosure are omitted, and similar reference numerals are assigned to similar parts.
[0056] In the present disclosure, when a component is "connected", "coupled" or "linked" to another component, it may include not only a direct connection relationship but also an indirect connection relationship in which an intermediate component exists. Additionally, when a component "includes" or "has" other components, unless otherwise specified, it means that other components may also be included, rather than excluding other components.
[0057] In the present disclosure, terms such as first and second are only used for the purpose of distinguishing one component from other components and do not limit the order or importance of the components, unless otherwise specified. Accordingly, within the scope of the present disclosure, the first component in one embodiment may be referred to as the second component in another embodiment, and similarly, the second component in one embodiment may be referred to as the first component in another embodiment.
[0058] In the present disclosure, mutually distinguishable components are intended to clearly describe each feature and do not mean that the components must be separate. That is, multiple components may be integrated and implemented in one hardware or software unit, or one component may be distributed and implemented in multiple hardware or software units. Therefore, even without specific description, these integrated or distributed embodiments of the components are included within the scope of the present disclosure.
[0059] In the present disclosure, the components described in each embodiment are not necessarily essential components, and some components may be optional components. Therefore, an embodiment composed of a subset of the components described in the embodiment is also included within the scope of the present disclosure. In addition, an embodiment including other components in addition to the components described in various embodiments is included within the scope of the present disclosure.
[0060] The present disclosure relates to the encoding and decoding of images. Unless otherwise redefined in the present disclosure, the terms used in the present disclosure may have the general meanings commonly used in the technical field to which the present disclosure pertains.
[0061] In the present disclosure, a "picture" generally refers to a unit representing an image within a specific time period, while a slice / tile is an encoding unit that forms part of a picture, and a picture may be composed of one or more slices / tiles. In addition, a slice / tile may include one or more coding tree units (CTUs).
[0062] In the present disclosure, a "pixel" or "pel" may mean the smallest unit that constitutes a picture (or image). In addition, "sample" may be used as a term corresponding to a pixel. A sample generally may represent a pixel or the value of a pixel, or may represent only the pixel / pixel value of the luminance component or only the pixel / pixel value of the chrominance component.
[0063] In the present disclosure, a "unit" may represent a basic unit of image processing. The unit may include at least one of a specific area of a picture and information related to the area. In some cases, the unit may be used interchangeably with terms such as "sample array", "block", or "area". Generally, an M×N block may include a set (or array) of samples (or sample arrays) or transform coefficients having M columns and N rows.
[0064] In the present disclosure, a "current block" may mean one of a "current encoding block", "current encoding unit", "encoding target block", "decoding target block", or "processing target block". When performing prediction, a "current block" may mean a "current prediction block" or a "prediction target block". When performing transform (inverse transform) / quantization (dequantization), a "current block" may mean a "current transform block" or a "transform target block". When performing filtering, a "current block" may mean a "filtering target block".
[0065] In addition, in the present disclosure, unless explicitly stated as a chrominance block, a "current block" may mean the luminance block of the "current block". The chrominance block of the "current block" may be expressed by including an explicit description of a chrominance block such as a "chrominance block" or a "current chrominance block".
[0066] In the present disclosure, the slashes " / " or "," may be interpreted as indicating "and / or". For example, "A / B" and "A,B" may mean "A and / or B". Further, "A / B / C" and "A,B,C" may mean "at least one of A, B, and / or C".
[0067] In the present disclosure, the term "or" shall be interpreted to indicate "and / or". For example, the expression "A or B" may include 1) only "A", 2) only "B", or 3) both "A and B". In other words, in the present disclosure, "or" shall be interpreted to indicate "additionally or alternatively".
[0068] Overview of Video Coding System
[0069] Figure 1 is a view schematically showing a video coding system according to the present disclosure.
[0070] The video coding system according to an embodiment may include an encoding device 10 and a decoding device 20. The encoding device 10 may deliver encoded video and / or image information or data in the form of a file or a stream to the decoding device 20 via a digital storage medium or a network.
[0071] The encoding device 10 according to an embodiment may include a video source generator 11, an encoding unit 12, and a transmitter 13. The decoding device 20 according to an embodiment may include a receiver 21, a decoding unit 22, and a renderer 23. The encoding unit 12 may be referred to as a video / image encoding unit, and the decoding unit 22 may be referred to as a video / image decoding unit. The transmitter 13 may be included in the encoding unit 12. The receiver 21 may be included in the decoding unit 22. The renderer 23 may include a display, and the display may be configured as a separate device or an external component.
[0072] The video source generator 11 may acquire video / images through a process of capturing, synthesizing, or generating video / images. The video source generator 11 may include a video / image capturing device and / or a video / image generating device. The video / image capturing device may include, for example, one or more cameras, a video / image archive including previously captured video / images, etc. The video / image generating device may include, for example, a computer, a tablet computer, and a smart phone, and may generate (electronically) video / images. For example, virtual video / images may be generated by a computer or the like. In this case, the video / image capturing process may be replaced by a process of generating relevant data.
[0073] The encoding unit 12 may encode the input video / images. For compression and encoding efficiency, the encoding unit 12 may perform a series of processes such as prediction, transformation, and quantization. The encoding unit 12 may output encoded data (encoded video / image information) in the form of a bitstream.
[0074] The transmitter 13 can transmit the encoded video / image information or data output in the form of a bitstream to the receiver 21 of the decoding device 20 in the form of a file or a stream via a digital storage medium or a network. The digital storage medium can include various storage media, such as USB, SD, CD, DVD, Blu-ray, HDD, SSD, etc. The transmitter 13 can include components for generating a media file in a predetermined file format and can include components for transmitting via a broadcast / communication network. The receiver 21 can extract / receive the bitstream from the storage medium or the network and transmit the bitstream to the decoding unit 22.
[0075] The decoding unit 22 can decode the video / image by performing a series of processes corresponding to the operations of the encoding unit 12, such as dequantization, inverse transformation, and prediction.
[0076] The renderer 23 can render the decoded video / image. The rendered video / image can be displayed via a display.
[0077] Overview of the Image Encoding Device
[0078] Figure 2 is a view schematically showing an image encoding device to which embodiments of the present disclosure can be applied.
[0079] As Figure 2 shown, the image encoding device 100 can include an image splitter 110, a subtractor 115, a transformer 120, a quantizer 130, a dequantizer 140, an inverse transformer 150, an adder 155, a filter 160, a memory 170, an inter-frame prediction unit 180, an intra-frame prediction unit 185, and an entropy encoder 190. The inter-frame prediction unit 180 and the intra-frame prediction unit 185 can be collectively referred to as a "prediction unit". The transformer 120, the quantizer 130, the dequantizer 140, and the inverse transformer 150 can be included in a residual processor. The residual processor can also include the subtractor 115.
[0080] In some embodiments, all or at least some of the multiple components configuring the image encoding device 100 can be configured by one hardware component (e.g., an encoder or a processor). In addition, the memory 170 can include a decoded picture buffer (DPB) and can be configured by a digital storage medium.
[0081] The image splitter 110 may split an input image (or picture or frame) input to the image encoding device 100 into one or more processing units. For example, the processing unit may be referred to as a coding unit (CU). Coding units may be obtained by recursively splitting a coding tree unit (CTU) or a largest coding unit (LCU) according to a quadtree binary tree ternary tree (QT / BT / TT) structure. For example, a coding unit may be split into multiple coding units of a deeper depth based on a quadtree structure, a binary tree structure, and / or a ternary tree structure. For the splitting of a coding unit, a quadtree structure may be applied first, and then a binary tree structure and / or a ternary tree structure may be applied. The encoding process according to the present disclosure may be performed based on the final coding units that are no longer splittable. The largest coding unit may be used as the final coding unit, or the coding units of a deeper depth obtained by splitting the largest coding unit may be used as the final coding units. Here, the encoding process may include processes of prediction, transformation, and reconstruction to be described later. As another example, the processing unit of the encoding process may be a prediction unit (PU) or a transform unit (TU). The prediction unit and the transform unit may be divided or split from the final coding unit. The prediction unit may be a sample prediction unit, and the transform unit may be a unit for deriving transform coefficients and / or a unit for deriving a residual signal from the transform coefficients.
[0082] The prediction unit (inter-frame prediction unit 180 or intra-frame prediction unit 185) may perform prediction on a block to be processed (current block) and generate a prediction block including prediction samples of the current block. The prediction unit may determine whether to apply intra-frame prediction or inter-frame prediction based on the current block or CU. The prediction unit may generate various information related to the prediction of the current block and transmit the generated information to the entropy encoder 190. The information about the prediction may be encoded in the entropy encoder 190 and output in the form of a bitstream.
[0083] The intra-frame prediction unit 185 may predict the current block by referring to samples in the current picture. According to the intra-frame prediction mode and / or intra-frame prediction technique, the reference samples may be located in the neighbors of the current block or may be placed separately. The intra-frame prediction mode may include multiple non-directional modes and multiple directional modes. The non-directional modes may include, for example, the DC mode and the planar mode. According to the detail level of the prediction direction, the directional modes may include, for example, 33 directional prediction modes or 65 directional prediction modes. However, this is merely an example, and more or fewer directional prediction modes may be used according to settings. The intra-frame prediction unit 185 may determine the prediction mode applied to the current block by using the prediction mode applied to neighboring blocks.
[0084] The inter-frame prediction unit 180 may derive a prediction block of a current block based on a reference block (reference sample array) specified by a motion vector on a reference picture. In this case, in order to reduce the amount of motion information transmitted in the inter-frame prediction mode, the motion information may be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between neighboring blocks and the current block. The motion information may include a motion vector and a reference picture index. The motion information may further include inter-frame prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.) information. In the case of inter-frame prediction, the neighboring blocks may include spatial neighboring blocks present in the current picture and temporal neighboring blocks present in the reference picture. The reference picture including the reference block and the reference picture including the temporal neighboring blocks may be the same or different. The temporal neighboring blocks may be referred to as co-located reference blocks, co-located CUs (colCUs), etc. The reference picture including the temporal neighboring blocks may be referred to as a co-located picture (colPic). For example, the inter-frame prediction unit 180 may configure a motion information candidate list based on neighboring blocks and generate information specifying which candidate to use to derive the motion vector and / or reference picture index of the current block. The inter-frame prediction may be performed based on various prediction modes. For example, in the case of the skip mode and the merge mode, the inter-frame prediction unit 180 may use the motion information of neighboring blocks as the motion information of the current block. In the case of the skip mode, different from the merge mode, the residual signal may not be transmitted. In the case of the motion vector prediction (MVP) mode, the motion vector of a neighboring block may be used as a motion vector predictor, and the motion vector of the current block may be signaled by encoding the motion vector difference and an indicator of the motion vector predictor. The motion vector difference may mean the difference between the motion vector of the current block and the motion vector predictor.
[0085] The prediction unit may generate a prediction signal based on various prediction methods and prediction techniques described below. For example, the prediction unit may not only apply intra-frame prediction or inter-frame prediction, but also apply intra-frame prediction and inter-frame prediction simultaneously to predict the current block. The prediction method of applying both intra-frame prediction and inter-frame prediction simultaneously to predict the current block may be referred to as combined intra and inter-frame prediction (CIIP). In addition, the prediction unit may perform intra-block copy (IBC) to predict the current block. Intra-block copy may be used for content image / video coding such as games, for example, screen content coding (SCC). IBC is a method of predicting the current picture using a previously reconstructed reference block in the current picture at a position separated from the current block by a predetermined distance. When IBC is applied, the position of the reference block in the current picture may be encoded as a vector (block vector) corresponding to the predetermined distance. IBC basically performs prediction in the current picture, but may be performed similarly to inter-frame prediction because the reference block is derived within the current picture. That is, IBC may use at least one of the inter-frame prediction techniques described in the present disclosure.
[0086] The prediction signal generated by the prediction unit can be used to generate a reconstructed signal or a residual signal. The subtractor 115 can generate a residual signal (residual block or residual sample array) by subtracting the prediction signal (prediction block or prediction sample array) output from the prediction unit from the input image signal (original block or original sample array). The generated residual signal can be transmitted to the transformer 120.
[0087] The transformer 120 can generate transform coefficients by applying a transform technique to the residual signal. For example, the transform technique can include at least one of a discrete cosine transform (DCT), a discrete sine transform (DST), a karhunen-loève transform (KLT), a graph-based transform (GBT), or a conditional non-linear transform (CNT). Here, the GBT refers to a transform obtained from a graph when the relationship information between pixels is represented by a graph. The CNT refers to a transform obtained based on a prediction signal generated using all previously reconstructed pixels. In addition, the transform processing can be applied to a square pixel block of the same size or can be applied to a block having a variable size rather than a square.
[0088] The quantizer 130 can quantize the transform coefficients and transmit them to the entropy encoder 190. The entropy encoder 190 can encode the quantized signal (information about the quantized transform coefficients) and output a bitstream. The information about the quantized transform coefficients can be referred to as residual information. The quantizer 130 can rearrange the quantized transform coefficients in block form into a one-dimensional vector form based on the coefficient scan order and generate information about the quantized transform coefficients based on the quantized transform coefficients in one-dimensional vector form.
[0089] The entropy encoder 190 can perform various coding methods, such as exponential Golomb, context-adaptive variable length coding (CAVLC), context-adaptive binary arithmetic coding (CABAC), etc. The entropy encoder 190 can encode information required for video / image reconstruction other than the quantized transform coefficients (e.g., values of syntax elements, etc.) together or individually. The encoded information (e.g., encoded video / image information) can be transmitted or stored in the form of a bitstream in units of a network abstraction layer (NAL). The video / image information can also include information about various parameter sets, such as an adaptive parameter set (APS), a picture parameter set (PPS), a sequence parameter set (SPS), or a video parameter set (VPS). In addition, the video / image information can also include general constraint information. The information signaled, transmitted, and / or syntax elements described in the present disclosure can be encoded through the above coding process and included in the bitstream.
[0090] The bitstream can be transmitted over a network or stored in a digital storage medium. The network can include a broadcast network and / or a communication network, and the digital storage medium can include various storage media such as USB, SD, CD, DVD, Blu-ray, HDD, SSD, etc. A transmitter (not shown) that transmits the signal output from the entropy encoder 190 and / or a storage unit (not shown) that stores the signal can be included as internal / external elements of the image encoding device 100. Alternatively, a transmitter can be provided as a component of the entropy encoder 190.
[0091] The quantized transform coefficients output from the quantizer 130 can be used to generate a residual signal. For example, the residual signal (residual block or residual sample) can be reconstructed by applying dequantization and inverse transformation to the quantized transform coefficients through the dequantizer 140 and the inverse transformer 150.
[0092] The adder 155 adds the reconstructed residual signal to the prediction signal output from the inter-frame prediction unit 180 or the intra-frame prediction unit 185 to generate a reconstructed signal (reconstructed picture, reconstructed block, reconstructed sample array). If the block to be processed has no residual, for example, in the case of applying the skip mode, the predicted block can be used as the reconstructed block. The adder 155 can be referred to as a reconstructor or a reconstructed block generator. The generated reconstructed signal can be used for intra-frame prediction of the next block to be processed in the current picture and can be used for inter-frame prediction of the next picture through filtering as described below.
[0093] The filter 160 can improve the subjective / objective image quality by applying filtering to the reconstructed signal. For example, the filter 160 can generate a modified reconstructed picture by applying various filtering methods to the reconstructed picture and store the modified reconstructed picture in the memory 170, specifically, in the DPB of the memory 170. Various filtering methods can include, for example, deblocking filtering, sample adaptive offset, adaptive loop filtering, bilateral filtering, etc. The filter 160 can generate various information related to the filtering and transmit the generated information to the entropy encoder 190, as described later in the description of each filtering method. The information related to the filtering can be encoded by the entropy encoder 190 and output in the form of a bitstream.
[0094] The modified reconstructed picture transmitted to the memory 170 can be used as a reference picture in the inter-frame prediction unit 180. When inter-frame prediction is applied by the image encoding device 100, prediction mismatch between the image encoding device 100 and the image decoding device can be avoided and the encoding efficiency can be improved.
[0095] The DPB of the memory 170 may store the modified reconstructed picture to be used as a reference picture in the inter prediction unit 180. The memory 170 may store the motion information of the blocks from which the motion information in the current picture is derived (or encoded) and / or the motion information of the blocks that have been reconstructed in the picture. The stored motion information may be transmitted to the inter prediction unit 180 and used as the motion information of spatially adjacent blocks or temporally adjacent blocks. The memory 170 may store the reconstructed samples of the reconstructed blocks in the current picture and may transmit the reconstructed samples to the intra prediction unit 185.
[0096] Overview of the Image Decoding Device
[0097] Figure 3 is a view schematically showing an image decoding device to which an embodiment of the present disclosure is applicable.
[0098] As Figure 3 shown, the image decoding device 200 may include an entropy decoder 210, a dequantizer 220, an inverse transformer 230, an adder 235, a filter 240, a memory 250, an inter prediction unit 260, and an intra prediction unit 265. The inter prediction unit 260 and the intra prediction unit 265 may be collectively referred to as "prediction units". The dequantizer 220 and the inverse transformer 230 may be included in the residual processor.
[0099] According to an embodiment, all or at least some of the plurality of components configuring the image decoding device 200 may be configured by hardware components (e.g., a decoder or a processor). In addition, the memory 250 may include a decoded picture buffer (DPB) or may be configured by a digital storage medium.
[0100] The image decoding device 200 that has received a bitstream including video / image information may reconstruct an image by performing processing corresponding to the processing performed by the Figure 2 image encoding device 100. For example, the image decoding device 200 may perform decoding using the processing units applied in the image encoding device. Therefore, the decoding processing unit may be, for example, an encoding unit. The encoding unit may be obtained by dividing a coding tree unit or a maximum coding unit. The reconstructed image signal decoded and output by the image decoding device 200 may be reproduced by a reproduction device (not shown).
[0101] The image decoding device 200 may receive, in the form of a bitstream, from Figure 2The signal output by the image encoding device. The received signal can be decoded by the entropy decoder 210. For example, the entropy decoder 210 can parse the bitstream to derive the information (e.g., video / image information) required for image reconstruction (or picture reconstruction). The video / image information can also include information about various parameter sets, such as the Adaptive Parameter Set (APS), Picture Parameter Set (PPS), Sequence Parameter Set (SPS), or Video Parameter Set (VPS). In addition, the video / image information can also include general constraint information. The image decoding device can also decode the picture based on the information about the parameter set and / or the general constraint information. The information and / or syntax elements signaled / received described in this disclosure can be decoded through the decoding process and obtained from the bitstream. For example, the entropy decoder 210 decodes the information in the bitstream based on an encoding method such as Exponential Golomb coding, CAVLC, or CABAC, and outputs the values of the syntax elements required for image reconstruction and the quantization values of the transformed coefficients of the residuals. More specifically, the CABAC entropy decoding method can receive the bins corresponding to each syntax element in the bitstream, use the decoding target syntax element information, the neighboring blocks, and the decoding information of the decoding target block or the information of the symbols / bins decoded in the previous stage to determine the context model, perform arithmetic decoding on the bins by predicting the occurrence probability of the bins according to the determined context model, and generate symbols corresponding to the values of each syntax element. In this case, after determining the context model, the CABAC entropy decoding method can update the context model by using the information of the decoded symbols / bins for the context model of the next symbol / bin. The information related to prediction in the information decoded by the entropy decoder 210 can be provided to the prediction units (inter-frame prediction unit 260 and intra-frame prediction unit 265), and the residual values for which entropy decoding is performed in the entropy decoder 210, that is, the quantized transform coefficients and the related parameter information, can be input to the dequantizer 220. Additionally, the information about filtering among the information decoded by the entropy decoder 210 can be provided to the filter 240. Furthermore, the receiver (not shown) for receiving the signal output by the image encoding device can be further configured as an internal / external component of the image decoding device 200, or the receiver can be a component of the entropy decoder 210.
[0102] In addition, the image decoding device according to the present disclosure can be referred to as a video / image / picture decoding device. The image decoding device can be divided into an information decoder (video / image / picture information decoder) and a sample decoder (video / image / picture sample decoder). The information decoder can include the entropy decoder 210. The sample decoder can include at least one of the dequantizer 220, the inverse transformer 230, the adder 235, the filter 240, the memory 250, the inter-frame prediction unit 180, or the intra-frame prediction unit 265.
[0103] The dequantizer 220 may dequantize the quantized transform coefficients and output the transform coefficients. The dequantizer 220 may rearrange the quantized transform coefficients in the form of two-dimensional blocks. In this case, the rearrangement may be performed based on the coefficient scan order executed in the image coding device. The dequantizer 220 may dequantize the quantized transform coefficients by using quantization parameters (e.g., quantization step information) and obtain the transform coefficients.
[0104] The inverse transformer 230 may perform an inverse transform on the transform coefficients to obtain a residual signal (residual block, residual sample array).
[0105] The prediction unit may perform prediction on the current block and generate a prediction block including the prediction samples of the current block. The prediction unit may determine whether to apply intra prediction or inter prediction to the current block based on the information about prediction output from the entropy decoder 210, and may determine a specific intra / inter prediction mode (prediction technique).
[0106] Similar to that described in the prediction unit of the image coding device 100, the prediction unit may generate a prediction signal based on various prediction methods (techniques) described later.
[0107] The intra prediction unit 265 may predict the current block by referring to the samples in the current picture. The description of the intra prediction unit 185 is equally applicable to the intra prediction unit 265.
[0108] The inter prediction unit 260 may derive a prediction block of the current block based on a reference block (reference sample array) specified by a motion vector on a reference picture. In this case, in order to reduce the amount of motion information transmitted in the inter prediction mode, the motion information may be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between neighboring blocks and the current block. The motion information may include a motion vector and a reference picture index. The motion information may also include information about the inter prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.). In the case of inter prediction, the neighboring blocks may include spatial neighboring blocks present in the current picture and temporal neighboring blocks present in the reference picture. For example, the inter prediction unit 260 may configure a motion information candidate list based on neighboring blocks, and derive the motion vector and / or reference picture index of the current block based on the received candidate selection information. The inter prediction may be performed based on various prediction modes, and the information about prediction may include information specifying the inter prediction mode of the current block.
[0109] The adder 235 can generate a reconstructed signal (reconstructed picture, reconstructed block, reconstructed sample array) by adding the obtained residual signal to the predicted signal (predicted block, predicted sample array) output from the prediction unit (including the inter-frame prediction unit 260 and / or the intra-frame prediction unit 265). If the block to be processed has no residual, for example, when the skip mode is applied, the predicted block can be used as the reconstructed block. The description of the adder 155 equally applies to the adder 235. The adder 235 can be referred to as a reconstructor or a reconstructed block generator. The generated reconstructed signal can be used for intra-frame prediction of the next block to be processed in the current picture and can be used for inter-frame prediction of the next picture through filtering as described below.
[0110] The filter 240 can improve the subjective / objective image quality by applying filtering to the reconstructed signal. For example, the filter 240 can generate a modified reconstructed picture by applying various filtering methods to the reconstructed picture and store the modified reconstructed picture in the memory 250, specifically, in the DPB of the memory 250. The various filtering methods can include, for example, deblocking filtering, sample adaptive offset, adaptive loop filtering, bilateral filtering, etc.
[0111] The (modified) reconstructed picture stored in the DPB of the memory 250 can be used as a reference picture in the inter-frame prediction unit 260. The memory 250 can store the motion information of the blocks from which the motion information in the current picture is derived (or decoded) and / or the motion information of the blocks that have been reconstructed in the picture. The stored motion information can be transmitted to the inter-frame prediction unit 260 to be used as the motion information of spatially adjacent blocks or temporally adjacent blocks. The memory 250 can store the reconstructed samples of the reconstructed blocks in the current picture and transmit the reconstructed samples to the intra-frame prediction unit 265.
[0112] In the present disclosure, the embodiments described in the filter 160, the inter-frame prediction unit 180, and the intra-frame prediction unit 185 of the image encoding device 100 can be equally or correspondingly applied to the filter 240, the inter-frame prediction unit 260, and the intra-frame prediction unit 265 of the image decoding device 200.
[0113] Overview of Image Segmentation
[0114] The video / image encoding method according to the present disclosure can be performed based on an image segmentation structure as follows. Specifically, processes such as prediction, residual processing ((inverse) transformation, (de) quantization, etc.), syntax element encoding, and filtering, which will be described later, can be performed based on CTUs, CUs (and / or TUs, PUs) derived according to the image segmentation structure. The image can be segmented in block units, and the block segmentation process can be performed in the image segmenter 110 of the encoding device. The segmentation-related information can be encoded by the entropy encoder 190 and sent to the decoding device in the form of a bitstream. The entropy decoder 210 of the decoding device can derive the block segmentation structure of the current picture based on the segmentation-related information obtained from the bitstream, and based on this, a series of processes (such as prediction, residual processing, block / picture reconstruction, in-loop filtering, etc.) can be performed for image decoding.
[0115] A picture can be segmented into a sequence of coding tree units (CTUs). Figure 4 An example of a picture segmented into CTUs is shown. A CTU can correspond to a coding tree block (CTB). Alternatively, a CTU can include a coding tree block of luminance samples and two coding tree blocks of corresponding chrominance samples. For example, for a picture containing three sample arrays, a CTU can include one N×N block of luminance samples and two corresponding blocks of chrominance samples.
[0116] Overview of CTU Segmentation
[0117] As described above, coding units can be obtained by recursively segmenting coding tree units (CTUs) or largest coding units (LCUs) according to a quadtree / binary tree / trinary tree (QT / BT / TT) structure. For example, a CTU can be first segmented into a quadtree structure. Thereafter, the leaf nodes of the quadtree structure can be further segmented by a multi-type tree structure.
[0118] Segmentation according to the quadtree means that the current CU (or CTU) is equally divided into four. By segmentation according to the quadtree, the current CU can be divided into four CUs with the same width and the same height. When the current CU is no longer segmented into a quadtree structure, the current CU corresponds to the leaf node of the quadtree structure. The CU corresponding to the leaf node of the quadtree structure can no longer be segmented and can be used as the final coding unit described above. Alternatively, the CU corresponding to the leaf node of the quadtree structure can be further segmented by a multi-type tree structure.
[0119] Figure 5 It is a view showing an embodiment of the segmentation type of a block according to a multi-type tree structure. Segmentation according to the multi-type tree structure can include two types of divisions according to the binary tree structure and two types of divisions according to the trinary tree structure.
[0120] The two types of divisions according to the binary tree structure may include a vertical binary division (SPLIT_BT_VER) and a horizontal binary division (SPLIT_BT_HOR). The vertical binary division (SPLIT_BT_VER) means that the current CU is equally divided into two in the vertical direction. As Figure 4 shown, through the vertical binary division, two CUs with the same height as the current CU and a width that is half of the width of the current CU can be generated. The horizontal binary division (SPLIT_BT_HOR) means that the current CU is equally divided into two in the horizontal direction. As Figure 5 shown, through the horizontal binary division, two CUs with a height that is half of the height of the current CU and the same width as the current CU can be generated.
[0121] The two types of divisions according to the ternary tree structure may include a vertical ternary division (SPLIT_TT_VER) and a horizontal ternary division (SPLIT_TT_HOR). In the vertical ternary division (SPLIT_TT_VER), the current CU is divided in the vertical direction at a ratio of 1:2:1. As Figure 5 shown, through the vertical ternary division, two CUs with the same height as the current CU and a width that is 1 / 4 of the width of the current CU and one CU with the same height as the current CU and a width that is half of the width of the current CU can be generated. In the horizontal ternary division (SPLIT_TT_HOR), the current CU is divided in the horizontal direction at a ratio of 1:2:1. As Figure 5 shown, through the horizontal ternary division, two CUs with a height that is 1 / 4 of the height of the current CU and the same width as the current CU and one CU with a height that is half of the height of the current CU and the same width as the current CU can be generated.
[0122] Figure 6 is a view showing a signaling mechanism of block division information in a quadtree having a nested multi-type tree structure according to the present disclosure.
[0123] Here, the CTU is regarded as the root node of a quadtree and is first partitioned into a quadtree structure. Information (e.g., qt_split_flag) is signaled to specify whether to perform quadtree partitioning on the current CU (the CTU of the quadtree or a node (QT_node) of the quadtree). For example, when the qt_split_flag has a first value (e.g., "1"), the current CU can be quadtreesplit. Additionally, when the qt_split_flag has a second value (e.g., "0"), the current CU is not quadtreesplit but becomes a leaf node (QT_leaf_node) of the quadtree. Then each quadtree leaf node can be further partitioned into a multi-type tree structure. That is, the leaf node of the quadtree can become a node (MTT_node) of the multi-type tree. In the multi-type tree structure, a first flag (e.g., Mtt_split_cu_flag) is signaled to specify whether the current node is additionally partitioned. If the corresponding node is additionally partitioned (e.g., if the first flag is 1), then a second flag (e.g., Mtt_split_cu_vertical_flag) can be signaled to specify the partitioning direction. For example, the partitioning direction can be the vertical direction when the second flag is 1 and the horizontal direction when the second flag is 0. Then, a third flag (e.g., Mtt_split_cu_binary_flag) can be signaled to specify whether the partitioning type is a binary partitioning type or a ternary partitioning type. For example, the partitioning type can be a binary partitioning type when the third flag is 1 and a ternary partitioning type when the third flag is 0. The nodes of the multi-type tree obtained by binary or ternary partitioning can be further partitioned into a multi-type tree structure. However, the nodes of the multi-type tree may not be partitioned into a quadtree structure. If the first flag is 0, the corresponding node of the multi-type tree is no longer partitioned but becomes a leaf node (MTT_leaf_node) of the multi-type tree. The CU corresponding to the leaf node of the multi-type tree can be used as the above-mentioned final coding unit.
[0124] Based on mtt_split_cu_vertical_flag and mtt_split_cu_binary_flag, the multi-type tree partitioning mode (MttSplitMode) of the CU can be derived as shown in Table 1 below. In the following description, the multi-type tree partitioning mode may be referred to as the multi-tree partitioning type or the partitioning type.
[0125] [Table 1]
[0126]
[0127]
[0128] Figure 7It is a view showing an example of dividing a CTU into multiple CUs by applying a multi-type tree after applying a quadtree. In Figure 7 In it, the bold block edges 710 represent quadtree division, and the remaining edges 720 represent multi-type tree division. A CU may correspond to a coding block (CB). In an embodiment, a CU may include one coding block of luminance samples and two coding blocks of chrominance samples corresponding to the luminance samples. The chrominance component (sample) CB or TB size may be derived based on the component ratio according to the color format (chrominance format, e.g., 4:4:4, 4:2:2, 4:2:0, etc.) of the picture / image based on the luminance component (sample) CB or TB size. In the case of the 4:4:4 color format, the chrominance component CB / TB size may be set to be equal to the luminance component CB / TB size. In the case of the 4:2:2 color format, the width of the chrominance component CB / TB may be set to half of the width of the luminance component CB / TB and the height of the chrominance component CB / TB may be set to the height of the luminance component CB / TB. In the case of the 4:2:0 color format, the width of the chrominance component CB / TB may be set to half of the width of the luminance component CB / TB and the height of the chrominance component CB / TB may be set to half of the height of the luminance component CB / TB.
[0129] In an embodiment, when the size of the CTU is 128 based on luminance sample units, the size of the CU may have a size ranging from 128×128 to 4×4, which is the same size as the CTU. In one embodiment, in the case of the 4:2:0 color format (or chrominance format), the chrominance CB size may have a size ranging from 64×64 to 2×2.
[0130] In addition, in an embodiment, the CU size and the TU size may be the same. Alternatively, there may be multiple TUs in the CU region. The TU size generally represents the luminance component (sample) transform block (TB) size.
[0131] The TU size may be derived based on the maximum allowable TB size maxTbSize which is a predetermined value. For example, when the CU size is greater than maxTbSize, multiple TUs (TBs) with maxTbSize may be derived from the CU, and the transform / inverse transform may be performed in units of TUs (TBs). For example, the maximum allowable luminance TB size may be 64×64 and the maximum allowable chrominance TB size may be 32×32. If the width or height of the CB divided according to the tree structure is greater than the maximum transform width or height, the CB may be automatically (or implicitly) divided until the TB size limits in the horizontal and vertical directions are satisfied.
[0132] In addition, for example, when intra prediction is applied, the intra prediction mode / type may be derived on a CU (or CB) basis, and the neighboring reference sample derivation and predicted sample generation processes may be performed on a TU (or TB) basis. In this case, there may be one or more TUs (or TBs) in a CU (or CB) region, and in this case, multiple TUs or (TBs) may share the same intra prediction mode / type.
[0133] Furthermore, for a quadtree coding tree scheme with a nested multi-type tree, the following parameters may be signaled from an encoding device to a decoding device as SPS syntax elements. For example, at least one of the CTU size as a parameter representing the root node size of the quadtree, the MinQTSize as a parameter representing the minimum allowable quadtree leaf node size, the MaxBtSize as a parameter representing the maximum allowable binary tree root node size, the MaxTtSize as a parameter representing the maximum allowable ternary tree root node size, the MaxMttDepth as a parameter representing the maximum allowable hierarchical depth of multi-type tree partitioning starting from quadtree leaf nodes, the MinBtSize as a parameter representing the minimum allowable binary tree leaf node size, or the MinTtSize as a parameter representing the minimum allowable ternary tree leaf node size.
[0134] As an implementation using the 4:2:0 chroma format, the CTU size can be set to 128×128 luma blocks and two 64×64 chroma blocks corresponding to these luma blocks. In this case, MinOTSize can be set to 16×16, MaxBtSize can be set to 128×128, MaxTtSzie can be set to 64×64, MinBtSize and MinTtSize can be set to 4×4, and MaxMttDepth can be set to 4. Quadtree segmentation can be applied to the CTU to generate quadtree leaf nodes. The quadtree leaf nodes can be referred to as leaf QT nodes. The size of the quadtree leaf nodes can range from 16×16 size (e.g., MinOTSize) to 128×128 size (e.g., CTU size). If the leaf QT node is 128×128, it may not be additionally split into a binary tree / trinary tree. This is because, in this case, even if split, it exceeds MaxBtsize and MaxTtszie (e.g., 64×64). In other cases, the leaf QT node can be further split into multi-type trees. Therefore, the leaf QT node is the root node of the multi-type tree, and the leaf QT node can have a multi-type tree depth (mttDepth) value of 0. If the multi-type tree depth reaches MaxMttdepth (e.g., 4), further splitting may not be considered. If the width of the multi-type tree node is equal to MinBtSize and less than or equal to 2xMinTtSize, further horizontal splitting may not be considered. If the height of the multi-type tree node is equal to MinBtSize and less than or equal to 2xMinTtSize, further vertical splitting may not be considered. When splitting is not considered, the encoding device can skip signaling of the splitting information. In this case, the decoding device can derive the splitting information with a predetermined value.
[0135] In addition, a CTU may include an encoded block of luma samples (hereinafter referred to as “luma block”) and two encoded blocks of chroma samples corresponding thereto (hereinafter referred to as “chroma blocks”). The above-described coding tree scheme may be equally or separately applied to the luma block and the chroma block of the current CU. Specifically, the luma block and the chroma block in a CTU may be divided into the same block tree structure, and in this case, the tree structure is represented as SINGLE_TREE. Alternatively, the luma block and the chroma block in a CTU may be divided into separate block tree structures, and in this case, the tree structure may be represented as DUAL_TREE. That is, when a CTU is divided into a dual tree, the block tree structure for the luma block and the block tree structure for the chroma block may exist separately. In this case, the block tree structure for the luma block may be referred to as DUAL_TREE_LUMA, and the block tree structure for the chroma component may be referred to as DUAL_TREE_CHROMA. For P and B slices / tile groups, the luma block and the chroma block in a CTU may be restricted to having the same coding tree structure. However, for I slices / tile groups, the luma block and the chroma block may have separate block tree structures from each other. If a separate block tree structure is applied, the luma CTB may be divided into CUs based on a specific coding tree structure, and the chroma CTB may be divided into chroma CUs based on another coding tree structure. That is, this means that a CU in an I slice / tile group to which a separate block tree structure is applied may include an encoded block of a luma component or encoded blocks of two chroma components, and a CU of a P or B slice / tile group may include blocks of three color components (one luma component and two chroma components).
[0136] Although the quadtree coding tree structure having a nested multi-type tree has been described, the structure for dividing a CU is not limited thereto. For example, the BT structure and the TT structure may be interpreted as concepts included in a multi-partition tree (MPT) structure, and a CU may be interpreted as being divided by a QT structure and an MPT structure. In an example of dividing a CU by a QT structure and an MPT structure, a syntax element (e.g., MPT_split_type) including information on how many blocks a leaf node of the QT structure is divided into and a syntax element (e.g., MPT_split_mode) including information on which of the vertical direction and the horizontal direction the leaf node of the QT structure is divided into may be signaled to determine the division structure.
[0137] In another example, the CU can be split in a way different from the QT structure, BT structure, or TT structure. That is, different from splitting a lower-depth CU into 1 / 4 of a higher-depth CU according to the QT structure, splitting a lower-depth CU into 1 / 2 of a higher-depth CU according to the BT structure, or splitting a lower-depth CU into 1 / 4 or 1 / 2 of a higher-depth CU according to the TT structure, in some cases, a lower-depth CU can be split into 1 / 5, 1 / 3, 3 / 8, 3 / 5, 2 / 3, or 5 / 8 of a higher-depth CU, and the method of splitting the CU is not limited to this.
[0138] The quadtree coding block structure with multi-type trees can provide a very flexible block splitting structure. Due to the splitting types supported in the multi-type trees, in some cases, different splitting patterns can potentially result in the same coding block structure. In the encoding device and the decoding device, by restricting the occurrence of such redundant splitting patterns, the amount of data for the splitting information can be reduced.
[0139] For example, Figure 8 shows the redundant partitioning patterns that may occur in binary tree partitioning and ternary tree partitioning. As Figure 8 shown, the consecutive binary partitions 810 and 820 in one direction at two levels have the same coding block structure as the binary partition for the central split after the ternary partition. In this case, the binary tree partitioning for the central blocks 830 and 840 of the ternary tree partitioning can be prohibited. This prohibition applies to the CUs of all pictures. When this specific partitioning is prohibited, the signaling of the corresponding syntax element can be modified by reflecting this prohibited situation, thereby reducing the number of bits signaled for the partitioning. For example, as Figure 8 shown in the example shown, when the binary tree partitioning for the central block of the CU is prohibited, the syntax element mtt_split_cu_binary_flag that specifies whether the partitioning is a binary partition or a ternary partition is not signaled and its value can be deduced by the decoding device as 0.
[0140] Overview of Inter-Frame Prediction
[0141] Hereinafter, the inter-frame prediction according to the present disclosure will be described.
[0142] The prediction unit of the image encoding device / image decoding device according to the present disclosure may perform inter-frame prediction in units of blocks to derive prediction samples. Inter-frame prediction may represent prediction derived in a manner that depends on data elements (e.g., sample values, motion information, etc.) of pictures other than the current picture. When inter-frame prediction is applied to a current block, a prediction block (prediction block or prediction sample array) of the current block may be derived based on a reference block (reference sample array) specified by a motion vector on a reference picture indicated by a reference picture index. In this case, in order to reduce the amount of motion information transmitted in the inter-frame prediction mode, the motion information of the current block may be predicted in units of blocks, sub-blocks, or samples based on the correlation of the motion information between neighboring blocks and the current block. The motion information may include a motion vector and a reference picture index. The motion information may further include inter-frame prediction type (L0 prediction, L1 prediction, Bi prediction, etc.) information. When inter-frame prediction is applied, neighboring blocks may include spatial neighboring blocks present in the current picture and temporal neighboring blocks present in the reference picture. The reference picture including the reference block and the reference picture including the temporal neighboring block may be the same or different. The temporal neighboring block may be referred to as a collocated reference block, a collocated CU (ColCU), or a colBlock, and the reference picture including the temporal neighboring block may be referred to as a collocated picture (colPic) or a colPicture. For example, a motion information candidate list may be constructed based on neighboring blocks of the current block, and flag or index information specifying which candidate is selected (used) may be signaled in order to derive the motion vector and / or reference picture index of the current block.
[0143] Inter-frame prediction may be performed based on various prediction modes. For example, in the case of the skip mode and the merge mode, the motion information of the current block may be equal to the motion information of the selected neighboring block. In the case of the skip mode, different from the merge mode, a residual signal may not be transmitted. In the case of the motion vector prediction (MVP) mode, the motion vector of the selected neighboring block may be used as a motion vector predictor and a motion vector difference may be signaled. In this case, the sum of the motion vector predictor and the motion vector difference may be used to derive the motion vector of the current block. In the present disclosure, the MVP mode may have the same meaning as the advanced motion vector prediction (AMVP).
[0144] Depending on the inter - frame prediction type (L0 prediction, L1 prediction, Bi - prediction, etc.), the motion information may include L0 motion information and / or L1 motion information. The motion vector in the L0 direction may be referred to as the L0 motion vector or MVL0, and the motion vector in the L1 direction may be referred to as the L1 motion vector or MVL1. The prediction based on the L0 motion vector may be referred to as L0 prediction, the prediction based on the L1 motion vector may be referred to as L1 prediction, and the prediction based on both the L0 motion vector and the L1 motion vector may be referred to as Bi - prediction. Here, the L0 motion vector may specify the motion vector associated with the reference picture list L0 (L0), and the L1 motion vector may specify the motion vector associated with the reference picture list L1 (L1). The reference picture list L0 may include pictures before the current picture in the output order as reference pictures, and the reference picture list L1 may include pictures after the current picture in the output order. The previous picture may be referred to as a forward (reference) picture, and the subsequent picture may be referred to as a backward (reference) picture. The reference picture list L0 may also include pictures after the current picture in the output order as reference pictures. In this case, within the reference picture list L0, the previous pictures may be indexed first, and then the subsequent pictures may be indexed. The reference picture list L1 may also include pictures before the current picture in the output order as reference pictures. In this case, within the reference picture list L1, the subsequent pictures may be indexed first, and then the previous pictures may be indexed. Here, the output order may correspond to the picture order count (POC) order.
[0145] Figure 9 is a flowchart illustrating a video / image encoding method based on inter - frame prediction.
[0146] Figure 10 is a view illustrating the configuration of the inter - frame prediction unit 180 according to the present disclosure.
[0147] Figure 9 The encoding method can be performed by Figure 2 an image encoding device. Specifically, step S610 can be performed by the inter - frame prediction unit 180, and step S620 can be performed by the residual processor. Specifically, step S620 can be performed by the subtractor 115. Step S630 can be performed by the entropy encoder 190. The prediction information of step S630 can be derived by the inter - frame prediction unit 180, and the residual information of step S630 can be derived by the residual processor. The residual information is information about the residual samples. The residual information may include information about the quantization transform coefficients for the residual samples. As described above, the residual samples can be derived as transform coefficients by the transformer 120 of the image encoding device, and the transform coefficients can be derived as quantization transform coefficients by the quantizer 130. The information about the quantization transform coefficients can be encoded by the entropy encoder 190 through the residual encoding process.
[0148] An image encoding device may perform inter prediction on a current block (S610). The image encoding device may derive an inter prediction mode and motion information of the current block and generate prediction samples of the current block. Here, the inter prediction mode determination, motion information derivation, and prediction sample generation processes may be performed simultaneously or any one of them may be performed before other processes. For example, as Figure 10 shown, the inter prediction unit 180 of the image encoding device may include a prediction mode determination unit 181, a motion information derivation unit 182, and a prediction sample derivation unit 183. The prediction mode determination unit 181 may determine the prediction mode of the current block, the motion information derivation unit 182 may derive the motion information of the current block, and the prediction sample derivation unit 183 may derive the prediction samples of the current block. For example, the inter prediction unit 180 of the image encoding device may search for a block similar to the current block within a predetermined area (search area) of a reference picture through motion estimation, and derive a reference block whose difference from the current block is equal to or less than a predetermined criterion or minimum value. Based on this, a reference picture index of the reference picture in which the reference block is located may be derived, and a motion vector may be derived based on the position difference between the reference block and the current block. The image encoding device may determine a mode to be applied to the current block among various prediction modes. The image encoding device may compare rate-distortion (RD) costs for various prediction modes and determine the best prediction mode of the current block. However, the method for the image encoding device to determine the prediction mode of the current block is not limited to the above example, and various methods may be used.
[0149] For example, when the skip mode or the merge mode is applied to the current block, the image encoding device may derive merge candidates from neighboring blocks of the current block and use the derived merge candidates to construct a merge candidate list. In addition, the image encoding device may derive a reference block whose difference from the current block is equal to or less than a predetermined criterion or minimum value among the reference blocks specified by the merge candidates included in the merge candidate list. In this case, a merge candidate associated with the derived reference block may be selected, and merge index information specifying the selected merge candidate may be generated and signaled to the image decoding device. The motion information of the selected merge candidate may be used to derive the motion information of the current block.
[0150] As another example, when the MVP mode is applied to the current block, the image coding device may derive motion vector predictor (MVP) candidates from neighboring blocks of the current block and use the derived MVP candidates to construct an MVP candidate list. Additionally, the image coding device may use the motion vector of the MVP candidate selected from among the MVP candidates included in the MVP candidate list as the MVP of the current block. In this case, for example, the motion vector indicating the reference block derived by the above-described motion estimation may be used as the motion vector of the current block, and the MVP candidate having the smallest difference from the motion vector of the current block among the MVP candidates may be the selected MVP candidate. A motion vector difference (MVD) that is the difference obtained by subtracting the MVP from the motion vector of the current block may be derived. In this case, the index information specifying the selected MVP candidate and the information about the MVD may be signaled to the image decoding device. Additionally, when the MVP mode is applied, the value of the reference picture index may be constructed as reference picture index information and signaled separately to the image decoding device.
[0151] The image coding device may derive a residual sample based on a prediction sample (S620). The image coding device may derive the residual sample by comparing the original sample of the current block with the prediction sample. For example, the residual sample may be derived by subtracting the corresponding prediction sample from the original sample.
[0152] An image encoding device may encode image information including prediction information and residual information (S630). The image encoding device may output the encoded image information in the form of a bitstream. The prediction information may include prediction mode information (e.g., a skip flag, a merge flag, or a mode index, etc.) and information about motion information as information related to the prediction process. Among the prediction mode information, the skip flag specifies whether the skip mode is applied to the current block, and the merge flag specifies whether the merge mode is applied to the current block. Alternatively, the prediction mode information may specify one of a plurality of prediction modes, such as a mode index. When the skip flag and the merge flag are 0, it may be determined that the MVP mode is applied to the current block. The information about motion information may include candidate selection information (e.g., a merge index, an mvp flag, or an mvp index) as information for deriving a motion vector. Among the candidate selection information, the merge index may be signaled when the merge mode is applied to the current block, and may be information for selecting one of the merge candidates included in the merge candidate list. Among the candidate selection information, the mvp flag or the mvp index may be signaled when the MVP mode is applied to the current block, and may be information for selecting one of the mvp candidates in the mvp candidate list. Additionally, the information about motion information may include information about the above-mentioned MVD and / or reference picture index information. Additionally, the information about motion information may include information specifying whether L0 prediction, L1 prediction, or Bi prediction is applied. The residual information is information about residual samples. The residual information may include information about quantization transform coefficients for the residual samples.
[0153] The output bitstream may be stored in a (digital) storage medium and sent to the image decoding device or may be sent to the image decoding device via a network.
[0154] As described above, the image encoding device may generate a reconstructed picture (a picture including reconstructed samples and reconstructed blocks) based on reference samples and residual samples. This is for the image encoding device to derive the same prediction result as the prediction result performed by the image decoding device, thereby improving the encoding efficiency. Therefore, the image encoding device may store the reconstructed picture (or reconstructed samples and reconstructed blocks) in a memory and use it as a reference picture for inter prediction. As described above, the in-loop filtering process also applies to the reconstructed picture.
[0155] Figure 11 is a flowchart illustrating a video / image decoding method based on inter prediction.
[0156] Figure 12 is a view illustrating the configuration of the inter prediction unit 260 according to the present disclosure.
[0157] The image decoding device may perform operations corresponding to those performed by the image encoding device. The image decoding device may perform prediction on a current block and derive prediction samples based on the received prediction information.
[0158] Figure 11 The decoding method of Figure 3 may be performed by the image decoding device of . Steps S810 to S830 may be performed by the inter prediction unit 260, and the prediction information in step S810 and the residual information in step S840 may be obtained by the entropy decoder 210 from the bitstream. The residual processor of the image decoding device may derive the residual samples of the current block based on the residual information (S840). Specifically, the dequantizer 220 of the residual processor may perform dequantization based on the dequantized transform coefficients derived according to the residual information to derive the transform coefficients, and the inverse transformer 230 of the residual processor may perform inverse transformation on the transform coefficients to derive the residual samples of the current block. Step S850 may be performed by the adder 235 or the reconstructor.
[0159] Specifically, the image decoding device may determine the prediction mode of the current block based on the received prediction information (S810). The image decoding device may determine which inter prediction mode is applied to the current block based on the prediction mode information in the prediction information.
[0160] For example, it may be determined whether the skip mode is applied to the current block based on the skip flag. Additionally, it may be determined whether the merge mode or the MVP mode is applied to the current block based on the merge flag. Alternatively, one of various inter prediction mode candidates may be selected based on the mode index. The inter prediction mode candidates may include the skip mode, the merge mode, and / or the MVP mode or may include various inter prediction modes to be described below.
[0161] The image decoding device may derive the motion information of the current block based on the determined inter prediction mode (S820). For example, when the skip mode or the merge mode is applied to the current block, the image decoding device may construct a merge candidate list to be described below and select one of the merge candidates included in the merge candidate list. The selection may be performed based on the above-mentioned candidate selection information (merge index). The motion information of the selected merge candidate may be used to derive the motion information of the current block. For example, the motion information of the selected merge candidate may be used as the motion information of the current block.
[0162] As another example, when the MVP mode is applied to the current block, the image decoding device may construct an mvp candidate list and use the motion vector of the mvp candidate selected from among the mvps included in the mvp candidate list as the mvp of the current block. The selection may be performed based on the above-mentioned candidate selection information (mvp flag or mvp index). In this case, the MVD of the current block may be derived based on the information about the MVD, and the motion vector of the current block may be derived based on the mvp and MVD of the current block. Additionally, the reference picture index of the current block may be derived based on the reference picture index information. The picture indicated by the reference picture index in the reference picture list of the current block may be derived as the reference picture to be referred to for the inter-frame prediction of the current block.
[0163] The image decoding device may generate a prediction sample for the current block based on the motion information of the current block (S830). In this case, the reference picture may be derived based on the reference picture index of the current block, and the prediction sample of the current block may be derived using the samples of the reference block indicated by the motion vector of the current block on the reference picture. In some cases, a prediction sample filtering process may also be performed on all or some of the prediction samples of the current block.
[0164] For example, as Figure 12 shown, the inter-frame prediction unit 260 of the image decoding device may include a prediction mode determination unit 261, a motion information derivation unit 262, and a prediction sample derivation unit 263. In the inter-frame prediction unit 260 of the image decoding device, the prediction mode determination unit 261 may determine the prediction mode of the current block based on the received prediction mode information, the motion information derivation unit 262 may derive the motion information (motion vector and / or reference picture index, etc.) of the current block based on the received motion information, and the prediction sample derivation unit 263 may derive the prediction sample of the current block.
[0165] The image decoding device may generate a residual sample for the current block based on the received residual information (S840). The image decoding device may generate a reconstructed sample for the current block based on the prediction sample and the residual sample and generate a reconstructed picture based on this (S850). Thereafter, an in-loop filtering process is applied to the reconstructed picture as described above.
[0166] As described above, the inter-frame prediction process may include the steps of determining an inter-frame prediction mode, deriving motion information according to the determined prediction mode, and performing prediction (generating a prediction sample) based on the derived motion information. As described above, the inter-frame prediction process may be performed by an image encoding device and an image decoding device.
[0167] Hereinafter, the step of deriving motion information according to the prediction mode will be described in more detail.
[0168] As described above, motion information of a current block can be used to perform inter prediction. An image encoding device can derive optimal motion information of the current block through a motion estimation process. For example, the image encoding device can use an original block in an original picture of the current block in fractional pixel units to search for a similar reference block with high correlation in a reference picture within a predetermined search range, and use it to derive motion information. The similarity of blocks can be calculated based on the sum of absolute differences (SAD) between the current block and the reference block. In this case, motion information can be derived based on the reference block with the minimum SAD in the search area. The derived motion information can be signaled to an image decoding device according to various methods based on an inter prediction mode.
[0169] When the merge mode is applied to a current block, the motion information of the current block is not directly sent, and the motion information of neighboring blocks is used to derive the motion information of the current block. Therefore, the motion information of the current prediction block can be indicated by sending flag information specifying that the merge mode is used and candidate selection information (e.g., a merge index) specifying which neighboring block is used as a merge candidate. In the present disclosure, since the current block is a prediction execution unit, the current block can be used with the same meaning as the current prediction block, and the neighboring block can be used with the same meaning as the neighboring prediction block.
[0170] An image encoding device can search for merge candidate blocks for deriving the motion information of a current block to perform the merge mode. For example, up to five merge candidate blocks can be used, but it is not limited thereto. The maximum number of merge candidate blocks can be sent in a slice header or a tile group header, but it is not limited thereto. After finding the merge candidate blocks, the image encoding device can generate a merge candidate list and select the merge candidate block with the minimum RD cost as the final merge candidate block.
[0171] The present disclosure provides various embodiments for merge candidate blocks configuring a merge candidate list. The merge candidate list can use, for example, five merge candidate blocks. For example, four spatial merge candidates and one temporal merge candidate can be used.
[0172] Figure 13 is a view exemplifying neighboring blocks that can be used as spatial merge candidates.
[0173] Figure 14 is a view schematically exemplifying a method for constructing a merge candidate list according to an example of the present disclosure.
[0174] An image encoding / decoding device can insert spatial merge candidates derived by searching spatial neighboring blocks of a current block into a merge candidate list (S1110). For example, as Figure 13 shown, the spatial neighboring blocks can include the bottom left neighboring block A of the current block 0 , the left neighboring block A1 , the upper - right neighboring block B 0 , the upper neighboring block B 1 and the upper - left neighboring block B 2 . However, this is an example, and in addition to the above spatial neighboring blocks, additional neighboring blocks such as the right neighboring block, the lower neighboring block, and the lower - right neighboring block can be further used as spatial neighboring blocks. The image encoding / decoding device can detect available blocks by searching for spatial neighboring blocks based on priority and derive the motion information of the detected blocks as spatial merge candidates. For example, the image encoding / decoding device can search for the five blocks shown in 1 A 1 B 0 B 0 A 2 and B Figure 13 in order and index the available candidates sequentially to construct a merge candidate list.
[0175] The image encoding / decoding device can insert the temporal merge candidates derived by searching for the temporal neighboring blocks of the current block into the merge candidate list (S1120). The temporal neighboring blocks can be located on a reference picture different from the current picture in which the current block is located. The reference picture in which the temporal neighboring blocks are located can be referred to as a collocated picture or col picture. The temporal neighboring blocks can be searched in the order of the lower - right neighboring block and the lower - right center block of the collocated block of the current block on the col picture. In addition, when motion data compression is applied to reduce the memory load, specific motion information can be stored as the representative motion information of each predetermined storage unit of the col picture. In this case, it is not necessary to store the motion information of all blocks in the predetermined storage unit, thus obtaining a motion data compression effect. In this case, the predetermined storage unit can be predetermined as, for example, a 16×16 sample unit or an 8×8 sample unit, or the size information of the predetermined storage unit can be signaled from the image encoding device to the image decoding device. When motion data compression is applied, the motion information of the temporal neighboring blocks can be replaced with the representative motion information of the predetermined storage unit in which the temporal neighboring blocks are located. That is, in this case, from the perspective of implementation, the temporal merge candidates can be derived based on the motion information of the prediction block (instead of the prediction block located at the coordinates of the temporal neighboring block) that covers the arithmetically left - shifted position after arithmetically right - shifting the coordinates (upper - left sample position) of the temporal neighboring block by a predetermined value. For example, when the predetermined storage unit is 2 n ×2 nWhen the coordinates of the sample unit and the temporally neighboring block are (xTnb, yTnb), the motion information of the prediction block located at the modified position ((xTnb >> n) << n), (yTnb >> n) << n)) can be used for temporal merge candidates. Specifically, for example, when the predetermined storage unit is a 16×16 sample unit and the coordinates of the temporally neighboring block are (xTnb, yTnb), the motion information of the prediction block located at the modified position ((xTnb >> 4) << 4), (yTnb >> 4) << 4)) can be used for temporal merge candidates. Alternatively, for example, when the predetermined storage unit is an 8×8 sample unit and the coordinates of the temporally neighboring block are (xTnb, yTnb), the motion information of the prediction block located at the modified position ((xTnb >> 3) << 3), (yTnb >> 3) << 3)) can be used for temporal merge candidates.
[0176] Referring again to Figure 14 , the image encoding / decoding device may check whether the number of current merge candidates is less than the maximum number of merge candidates (S1130). The maximum number of merge candidates may be predefined or signaled from the image encoding device to the image decoding device. For example, the image encoding device may generate and encode information about the maximum number of merge candidates and send the encoded information to the image decoding device in the form of a bitstream. When the maximum number of merge candidates is satisfied, the subsequent candidate addition process S1140 may not be performed.
[0177] When, as a result of the check in step S1130, the number of current merge candidates is less than the maximum number of merge candidates, the image encoding / decoding device may derive additional merge candidates according to a predetermined method and then insert the additional merge candidates into the merge candidate list (S1140).
[0178] When, as a result of the check in step S1130, the number of current merge candidates is not less than the maximum number of merge candidates, the image encoding / decoding device may end the construction of the merge candidate list. In this case, the image encoding device may select the best merge candidate from among the merge candidates configuring the merge candidate list and signal candidate selection information (e.g., merge index) specifying the selected merge candidate to the image decoding device. The image decoding device may select the best merge candidate based on the merge candidate list and the candidate selection information.
[0179] As described above, the motion information of the selected merge candidate can be used as the motion information of the current block, and the predicted sample of the current block can be derived based on the motion information of the current block. The image encoding device can derive the residual sample of the current block based on the predicted sample and signal the residual information of the residual sample to the image decoding device. As described above, the image decoding device can generate a reconstructed sample based on the residual sample derived from the residual information and the predicted sample and generate a reconstructed picture based thereon.
[0180] When the skip mode is applied to the current block, the same method as in the case of applying the merge mode can be used to derive the motion information of the current block. However, when the skip mode is applied, the residual signal of the corresponding block is omitted, and thus the predicted sample can be directly used as the reconstructed sample.
[0181] When the MVP mode is applied to the current block, the motion vector of the reconstructed spatial neighboring block (e.g., Figure 13 the neighboring block shown) and / or the motion vector corresponding to the temporal neighboring block (or Col block) can be used to generate a motion vector predictor (mvp) candidate list. That is, the motion vector of the reconstructed spatial neighboring block and the motion vector corresponding to the temporal neighboring block can be used as the motion vector predictor candidate of the current block. When bi-prediction is applied, the mvp candidate list for L0 motion information derivation and the mvp candidate list for L1 motion information derivation are generated and used separately. The prediction information (or information about prediction) of the current block can include candidate selection information (e.g., MVP flag or MVP index) specifying the best motion vector predictor candidate selected from among the motion vector predictor candidates included in the mvp candidate list. In this case, the prediction unit can use the candidate selection information to select the motion vector predictor of the current block from among the motion vector predictor candidates included in the mvp candidate list. The prediction unit of the image encoding device can obtain and encode the motion vector difference (MVD) between the motion vector of the current block and the motion vector predictor and output the encoded MVD in the form of a bitstream. That is, the MVD can be obtained by subtracting the motion vector predictor from the motion vector of the current block. The prediction unit of the image decoding device can obtain the motion vector difference included in the information about prediction and derive the motion vector of the current block by adding the motion vector difference and the motion vector predictor. The prediction unit of the image encoding device can obtain or derive the reference picture index specifying the reference picture from the information about prediction.
[0182] Figure 15 is a view schematically illustrating a method for constructing a motion vector predictor candidate list according to an example of the present disclosure.
[0183] First, spatial candidate blocks of the current block can be searched and available candidate blocks can be inserted into the MVP candidate list (S1210). Thereafter, it is determined whether the number of MVP candidates included in the MVP candidate list is less than 2 (S1220), and when the number of MVP candidates is 2, the construction of the MVP candidate list can be completed.
[0184] In step S1220, when the number of available spatial candidate blocks is less than 2, temporal candidate blocks of the current block can be searched and available candidate blocks can be inserted into the MVP candidate list (S1230). When the temporal candidate blocks are not available, a zero motion vector can be inserted into the MVP candidate list, thereby completing the construction of the MVP candidate list.
[0185] In addition, when the MVP mode is applied, the reference picture index can be signaled explicitly. In this case, the reference picture index refidxL0 for L0 prediction and the reference picture index refidxL1 for L1 prediction can be signaled differently. For example, when the MVP mode is applied and Bi prediction is applied, information about refidxL0 and information about refidxL1 can be signaled.
[0186] As described above, when the MVP mode is applied, information about the MVP derived by the image coding device can be signaled to the image decoding device. For example, the information about the MVD can include information specifying the x and y components of the absolute value of the MVD (MVD absolute value) and the sign of the MVD. In this case, when the MVD absolute value is greater than 0, it can be signaled step by step whether the MVD absolute value is greater than 1 and information specifying the MVD remainder. For example, the information specifying whether the MVD absolute value is greater than 1 can be signaled only when the value of the flag information specifying whether the MVD absolute value is greater than 0 is 1.
[0187] Figure 16 is a view illustrating a syntax structure for sending an MVD from an image coding device to an image decoding device according to an embodiment of the present disclosure.
[0188] In Figure 16 abs_mvd_greater0_flag[0] specifies whether the absolute value of the x component of the MVD is greater than 0, while abs_mvd_greater0_flag[1] specifies whether the absolute value of the y component of the MVD is greater than 0. Similarly, abs_mvd_greater1_flag[0] specifies whether the absolute value of the x component of the MVD is greater than 1, and abs_mvd_greater1_flag[1] specifies whether the absolute value of the y component of the MVD is greater than 1. As Figure 16As shown, abs_mvd_greater1_flag can be sent only when abs_mvd_greater0_flag is 1. In Figure 16 , abs_mvd_minus2 can specify a value obtained by subtracting 2 from the absolute value of MVD, and mvd_sign_flag specifies whether the sign of MVD is positive or negative. Using the Figure 16 syntax structure shown, MVD can be derived as shown in Equation 1 below.
[0189] [Equation 1]
[0190] MVD[compIdx] = abs_mvd_greater0_flag[compIdx] * (abs_mvd_minus2[compIdx] + 2)
[0191] * (1 - 2 * mvd_sign_flag[compIdx])
[0192] In addition, the MVD for L0 prediction (MVDL0) and the MVD for L1 prediction (MVDL1) can be signaled differentially, and the information about MVD can include the information about MVDL0 and / or the information about MVDL1. For example, when the MVP mode is applied to the current block and BI prediction is applied, the information about MVDL0 and the information about MVDL1 can be signaled.
[0193] Overview of Intra Block Copy (IBC) Prediction
[0194] Hereinafter, the IBC prediction according to the present disclosure will be described.
[0195] IBC prediction can be performed by a prediction unit of an image encoding / decoding device. IBC prediction can be abbreviated as IBC. IBC can be used for content image / motion image encoding such as Screen Content Coding (SCC). IBC prediction can be basically performed in the current picture, but can be performed similar to inter prediction because a reference block is derived within the current picture. That is, IBC can use at least one of the inter prediction techniques described in the present disclosure. For example, IBC can use at least one of the above-described motion information (motion vector) derivation methods. It can be considered that IBC prediction partially modifies and uses at least one of the inter prediction techniques. IBC can refer to the current picture and thus can be called Current Picture Reference (CPR).
[0196] For IBC, an image encoding device may perform block matching (BM) and derive an optimal block vector (or motion vector) for a current block (e.g., a CU). A method similar to the signaling of motion information (motion vectors) in the inter prediction described above may be used to signal the derived block vector (or motion vector) to an image decoding device via a bitstream. The image decoding device may derive a reference block for a current block in a current picture based on the signaled block vector (motion vector) and thereby derive a prediction signal (predicted block or predicted samples) for the current block. Here, the block vector (or motion vector) may specify a displacement from the current block to a reference block located in a reconstructed region in the current picture. Thus, the block vector (or motion vector) may be referred to as a displacement vector. Hereinafter, in IBC, the motion vector may correspond to the block vector or the displacement vector. The motion vector of a current block may include a motion vector for a luminance component (luminance motion vector) or a motion vector for a chrominance component (chrominance motion vector). For example, the luminance motion vector of a CU encoded by IBC may be in integer sample units (i.e., integer precision). The chrominance motion vector may be trimmed in integer sample units. As described above, IBC may use at least one of the inter prediction techniques, and for example, may use the merge mode or the MVP mode described above to encode / decode the luminance motion vector.
[0197] When applying the merge mode to a luminance IBC block, a merge candidate list for the luminance IBC block may be constructed similar to the merge candidate list in the inter frame mode described with reference to Figure 14 However, in the case of a luminance IBC block, temporally neighboring blocks may not be used as merge candidates.
[0198] When applying the MVP mode to a luminance IBC block, an mvp candidate list for the luminance IBC block may be constructed similar to the mvp candidate list in the inter frame mode described with reference to Figure 15 However, in the case of a luminance IBC block, temporally candidate blocks may not be used as mvp candidates.
[0199] In IBC, the reference block is derived from a reconstructed region in the current picture. In this case, in order to reduce the memory consumption and complexity of the image decoding device, only a predefined region among the reconstructed regions in the current picture may be referred to. The predefined region may include the current CTU in which the current block is included. By restricting the referenceable reconstructed region to the predefined region, the IBC mode may be implemented in hardware using local on-chip memory.
[0200] An image encoding device for performing IBC may search the predefined region to determine a reference block having the minimum RD cost and derive a motion vector (block vector) based on the positions of the reference block and the current block.
[0201] Whether to apply IBC to the current block can be signaled as IBC execution information at the CU level. Information on the signaling method (IBC MVP mode or IBC skip / merge mode) of the motion vector for the current block can be signaled. The IBC execution information can be used to determine the prediction mode of the current block. Thus, the IBC execution information can be included in the information on the prediction mode of the current block.
[0202] In the case of the IBC skip / merge mode, a merge candidate index can be signaled to specify the block vector among the block vectors included in the merge candidate list that is to be used for the prediction of the current luma block. In this case, the merge candidate list can include IBC-encoded neighboring blocks. The merge candidate list can be configured to include spatial merge candidates and not include temporal merge candidates. Additionally, the merge candidate list can further include history-based motion vector predictor (HMVP) candidates and / or paired candidates.
[0203] In the case of the IBC MVP mode, the block vector difference can be encoded using the same method as the motion vector difference in the above inter-frame mode. The block vector prediction method can be constructed similar to the MVP mode in the inter-frame mode and use an mvp candidate list that includes two candidates as predictors. One of the two candidates can be derived from the left neighboring block, and the other candidate can be derived from the upper neighboring block. In this case, a candidate can be derived from the corresponding neighboring block only when the left or upper neighboring block is IBC-encoded. If the left or upper neighboring block is not available, e.g., not IBC-encoded, a default block vector can be included in the mvp candidate list as a predictor. Additionally, information (e.g., a flag) specifying one of the two block vector predictors is signaled similar to the MVP mode in the inter-frame mode and used as candidate selection information. The mvp candidate list can include HMVP candidates and / or a zero motion vector as the default block vector.
[0204] The HMVP candidate can be referred to as a history-based MVP candidate, and the MVP candidate, merge candidate, or block vector candidate used before the encoding / decoding of the current block can be stored in the HMVP list as an HMVP candidate. Thereafter, when the merge candidate list or mvp candidate list of the current block does not include the maximum number of candidates, the candidate stored in the HMVP list can be added to the merge candidate list or mvp candidate list of the current block as an HMVP candidate.
[0205] The paired candidate means a candidate derived by selecting two candidates from among the candidates already included in the merge candidate list of the current block according to a predetermined order and calculating the average of the two selected candidates.
[0206] Figure 17 is a flowchart illustrating an IBC-based video / image encoding method.
[0207] Figure 18 It is a view illustrating the configuration of a prediction unit for performing an IBC-based video / image encoding method according to the present disclosure.
[0208] Figure 17 The encoding method can be performed by Figure 2 an image encoding device. Specifically, step S1410 can be performed by a prediction unit and step S1420 can be performed by a residual processor. Specifically, step S1420 can be performed by subtracter 115. Step S1430 can be performed by entropy encoder 190. The prediction information of step S1430 can be derived by the prediction unit and the residual information of step S1430 can be derived by the residual processor. The residual information is information about residual samples. The residual information can include information about quantization transform coefficients for the residual samples. As described above, the residual samples can be derived through transform coefficients by transformer 120 of the image encoding device, and the transform coefficients can be derived through the quantization transform coefficients quantized via quantizer 130. The information about the quantization transform coefficients can be encoded by entropy encoder 190 through a residual encoding process.
[0209] The image encoding device can perform IBC prediction (IBC-based prediction) for the current block (S1410). The image encoding device can derive the prediction mode and motion vector (block vector) of the current block and generate a prediction sample of the current block. The prediction mode can include at least one of the above-mentioned inter prediction modes. Here, the prediction mode determination, motion vector derivation, and prediction sample generation processes can be performed simultaneously, or any one of the processes can be performed before other processes. For example, as Figure 18 shown, the prediction unit of an image encoding device for performing an IBC-based video / image encoding method can include a prediction mode determination unit, a motion vector derivation unit, and a prediction sample derivation unit. The prediction mode determination unit can determine the prediction mode of the current block, the motion vector derivation unit can derive the motion vector of the current block, and the prediction sample derivation unit can derive the prediction sample of the current block. For example, the prediction unit of the image encoding device can search for a block similar to the current block in the reconstructed region (or a certain region (search region) of the reconstructed region) of the current picture and derive a reference block whose difference from the current block is equal to or less than a specific criterion or minimum value. The image encoding device can derive the motion vector based on the displacement difference between the reference block and the current block. The image encoding device can determine the mode applied to the current block among various prediction modes. The image encoding device can compare the RD costs for various prediction modes and determine the best prediction mode for the current block. However, the method for the image encoding device to determine the prediction mode of the current block is not limited to the above example and various methods can be used.
[0210] For example, when applying a skip mode or a merge mode to a current block, an image coding device may derive merge candidates from neighboring blocks of the current block and use the derived merge candidates to construct a merge candidate list. Additionally, the image coding device may derive, among reference blocks indicated by the merge candidates included in the merge candidate list, a reference block whose difference from the current block is equal to or less than a specific criterion or a minimum value. In such a case, a merge candidate associated with the derived reference block may be selected, and merge index information specifying the selected merge candidate may be generated and signaled to an image decoding device. Using the motion vector of the selected merge candidate, the motion vector of the current block may be derived.
[0211] As another example, when applying an MVP mode to a current block, an image coding device may derive motion vector predictor (mvp) candidates from neighboring blocks of the current block and use the derived mvp candidates to construct an mvp candidate list. Additionally, the image coding device may use the motion vector of an mvp candidate selected from among the mvp candidates included in the mvp candidate list as the mvp of the current block. In such a case, for example, the motion vector indicating the reference block derived by the above-described motion estimation may be used as the motion vector of the current block, and the mvp candidate having the smallest difference from the motion vector of the current block among the mvp candidates may become the selected mvp candidate. A motion vector difference (MVD) obtained by subtracting the mvp from the motion vector of the current block may be derived. In such a case, index information specifying the selected mvp candidate and information about the MVD may be signaled to an image decoding device.
[0212] An image coding device may derive a residual sample based on a prediction sample (S1420). The image coding device may derive the residual sample by comparing the original sample of the current block with the prediction sample. For example, the residual sample may be derived by subtracting the corresponding prediction sample from the original sample.
[0213] An image encoding device may encode image information including prediction information and residual information (S1430). The image encoding device may output the encoded image information in the form of a bitstream. The prediction information may include prediction mode information (e.g., a skip flag, a merge flag, or a mode index) and information about a motion vector as information related to a prediction process. Among the prediction mode information, the skip flag specifies whether to apply the skip mode to a current block, and the merge flag specifies whether to apply the merge mode to the current block. Alternatively, the prediction mode information may specify one of a plurality of prediction modes, such as a mode index. When the skip flag and the merge flag are 0, it may be determined that the MVP mode is applied to the current block. The information about the motion vector may include candidate selection information (e.g., a merge index, an mvp flag, or an mvp index) as information for deriving the motion vector. Among the candidate selection information, the merge index may be signaled when the merge mode is applied to the current block and may be information for selecting one of the merge candidates included in a merge candidate list. Among the candidate selection information, the mvp flag or the mvp index may be signaled when the MVP mode is applied to the current block and may be information for selecting one of the mvp candidates included in an mvp candidate list. In addition, the information about the motion vector may include information about the above-mentioned MVD. In addition, the information about the motion vector may include information specifying whether to apply L0 prediction, L1 prediction, or bi prediction. The residual information is information about residual samples. The residual information may include information about quantization transform coefficients for the residual samples.
[0214] The output bitstream may be stored in a (digital) storage medium and sent to an image decoding device or may be sent to the image decoding device through a network.
[0215] In addition, as described above, the image encoding device may generate a reconstructed picture (a picture including reconstructed samples and reconstructed blocks) based on reference samples and residual samples. This is for the image encoding device to derive the same prediction result as the prediction result executed by the image decoding device, thereby improving the encoding efficiency. Therefore, the image encoding device may store the reconstructed picture (or reconstructed samples and reconstructed blocks) in a memory and use it as a reference picture for inter prediction. As described above, the in-loop filtering process also applies to the reconstructed picture.
[0216] Figure 19 is a flowchart illustrating a video / image decoding method based on IBC.
[0217] Figure 20 is a view illustrating a configuration of a prediction unit for performing a video / image decoding method based on IBC according to the present disclosure.
[0218] The image decoding device may perform operations corresponding to those performed by the image encoding device. The image decoding device may perform IBC prediction on a current block based on received prediction information to derive prediction samples.
[0219] Figure 19 The decoding method of Figure 3 may be performed by the image decoding device of . Steps S1610 to S1630 may be performed by the prediction unit, and the prediction information in step S1610 and the residual information in step S1640 may be obtained by the entropy decoder 210 from the bitstream. The residual processor of the image decoding device may derive the residual samples of the current block based on the residual information (S1640). Specifically, the dequantizer 220 of the residual processor may perform dequantization based on the quantization transform coefficients derived according to the residual information to derive the transform coefficients, and the inverse transformer 230 of the residual processor may perform inverse transformation on the transform coefficients to derive the residual samples of the current block. Step S1650 may be performed by the adder 235 or the reconstructor.
[0220] Specifically, the image decoding device may determine the prediction mode of the current block based on the received prediction information (S1610). The image decoding device may determine which prediction mode is applied to the current block based on the prediction mode information in the prediction information.
[0221] For example, it may be determined whether the skip mode is applied to the current block based on the skip flag. Additionally, it may be determined whether the merge node or MVP mode is applied to the current block based on the merge flag. Alternatively, one of various prediction mode candidates may be selected based on the mode index. The prediction mode candidates may include the skip mode, the merge mode, and / or the MVP mode or may include the above various inter-frame prediction modes.
[0222] The image encoding device may derive the motion vector of the current block based on the determined prediction mode (S1620). For example, when the skip mode or the merge mode is applied to the current block, the image decoding device may construct the above merge candidate list and select one of the merge modes included in the merge candidate list. The selection may be performed based on the above candidate selection information (merge index). The motion vector of the current block may be derived using the motion vector of the selected merge candidate. For example, the motion vector of the selected merge candidate may be used as the motion vector of the current block.
[0223] As another example, when applying the MVP mode to the current block, the image decoding device may construct an mvp candidate list and use the motion vector of the mvp candidate selected from among the mvp candidates included in the mvp candidate list as the mvp of the current block. The selection may be performed based on the above-mentioned candidate selection information (mvp flag or mvp index). In this case, the MVD of the current block may be derived based on the information about the MVD, and the motion vector of the current block may be derived based on the mvp and MVD of the current block.
[0224] The image decoding device may generate a prediction sample for the current block based on the motion vector of the current block (S1630). The prediction sample for the current block may be derived using the samples of the reference block indicated by the motion vector of the current block on the current picture. In some cases, a prediction sample filtering process may be further performed on all or some of the prediction samples for the current block.
[0225] For example, as Figure 20 shown, the prediction unit of the image decoding device for performing an IBC-based video / image decoding method may include a prediction mode determination unit, a motion vector derivation unit, and a prediction sample derivation unit. The prediction unit of the image decoding device may determine the prediction mode of the current block based on the received prediction mode information in the prediction mode determination unit, derive the motion vector of the current block based on the received information about the motion vector in the motion vector derivation unit, and derive the prediction sample of the current block in the prediction sample derivation unit.
[0226] The image decoding device may generate a residual sample for the current block based on the received residual information (S1640). The image decoding device may generate a reconstructed sample for the current block based on the prediction sample and the residual sample, and generate a reconstructed picture based on this (S1650). Thereafter, as described above, the in-loop filtering process also applies to the reconstructed picture.
[0227] As described above, a unit (e.g., coding unit (CU)) may include a luminance block (luminance coding block (CB)) and a chrominance block (chrominance CB). In this case, the luminance block and its corresponding chrominance block may have the same motion information (e.g., motion vector) or different motion information. For example, the motion information of the chrominance block may be derived based on the motion information of the luminance block so that the luminance block and its corresponding chrominance block have the same motion information.
[0228] Overview of chrominance formats
[0229] Hereinafter, the chroma format will be described. An image may be encoded as encoded data including an array of luminance components (e.g., Y) and two arrays of chrominance components (e.g., Cb and Cr). For example, one pixel of the encoded image may include a luminance sample and a chrominance sample. The chroma format may be used to represent the configuration format of the luminance samples and the chrominance samples, and the chroma format may be referred to as a color format.
[0230] In an embodiment, an image may be encoded in various chroma formats such as monochrome, 4:2:0, 4:2:2, or 4:4:4. In monochrome sampling, there may be one sample array and the sample array may be a luminance array. In 4:2:0 sampling, there may be one luminance sample array and two chrominance sample arrays, and each of the two chrominance arrays may have a height equal to half of the luminance array and a width equal to half of the luminance array. In 4:2:2 sampling, there may be one luminance sample array and two chrominance sample arrays, and each of the two chrominance arrays may have a height equal to the luminance array and a width equal to half of the luminance array. In 4:4:4 sampling, there may be one luminance sample array and two chrominance sample arrays, and each of the two chrominance arrays may have a height and width equal to the luminance array.
[0231] For example, in 4:2:0 sampling, the chrominance samples may be located below their corresponding luminance samples. In 4:2:2 sampling, the chrominance samples may be positioned to overlap their corresponding luminance samples. In 4:4:4 sampling, both the luminance samples and the chrominance samples may be located at overlapping positions.
[0232] The chroma format used in the encoding device and the decoding device may be predetermined. Alternatively, the chroma format may be signaled from the encoding device to the decoding device for adaptive use in the encoding device and the decoding device. In an embodiment, the chroma format may be signaled based on at least one of chroma_format_idc or separate_colour_plane_flag. At least one of chroma_format_idc or separate_colour_plane_flag may be signaled by an advanced syntax such as DPS, VPS, SPS, or PPS. For example, chroma_format_idc and separate_colour_plane_flag may be included in the Figure 21 shown SPS syntax.
[0233] Furthermore, Figure 22An embodiment of chroma format classification using the signaling of chroma_format_idc and separate_colour_plane_flag is shown. chroma_format_idc may be information specifying the chroma format applied to the encoded image. separate_colour_plane_flag may specify whether to process the color arrays separately in a specific chroma format. For example, a first value of chroma_format_idc (e.g., 0) may specify monochrome sampling. A second value of chroma_format_idc (e.g., 1) may specify 4:2:0 sampling. A third value of chroma_format_idc (e.g., 2) may specify 4:2:2 sampling. A fourth value of chroma_format_idc (e.g., 3) may specify 4:4:4 sampling.
[0234] In 4:4:4, depending on the value of separate_colour_plane_flag, the following may apply. If the value of separate_colour_plane_flag is a first value (e.g., 0), each of the two chroma arrays may have the same height and width as the luma array. In this case, the value of ChromaArrayType, which specifies the type of the chroma sample array, may be set equal to chroma_format_idc. If the value of separate_colour_plane_flag is a second value (e.g., 1), the luma sample array, the Cb sample array, and the Cr sample array may be processed separately and together with the monochrome sampling picture. In this case, ChromaArrayType may be set to 0.
[0235] Intra prediction of chroma blocks
[0236] When performing intra prediction on the current block, prediction of the luma component block (luma block) and prediction of the chroma component block (chroma block) of the current block may be performed. In this case, the intra prediction mode of the chroma block may be set separately from the intra prediction mode of the luma block.
[0237] For example, the intra prediction mode of a chroma block can be specified based on intra chroma prediction mode information, and the intra chroma prediction mode information can be signaled in the form of the intra_chroma_pred_mode syntax element. For example, the intra chroma prediction mode information can represent one of a planar mode, a DC mode, a vertical mode, a horizontal mode, a derivation mode (DM), and a cross-component linear model (CCLM) mode. Here, the planar mode can specify intra prediction mode #0, the DC mode can specify intra prediction mode #1, the vertical mode can specify intra prediction mode #26, and the horizontal mode can specify intra prediction mode #10. DM can also be referred to as the direct mode. CCLM can also be referred to as the linear model (LM).
[0238] In addition, DM and CCLM are relevant intra prediction modes for predicting chroma blocks using information about luma blocks. DM can represent a mode that applies the same intra prediction mode as that of the luma component as the intra prediction mode of the chroma component. Additionally, CCLM can represent an intra prediction mode that uses samples derived by downsampling the reconstructed samples of a luma block and then applying CCLM parameters α and β to the downsampled samples during the process of generating the prediction block of the chroma block as the prediction samples of the chroma block.
[0239] [Equation 2]
[0240] pred c (i,j) = α·rec L ′(i,j) + β
[0241] where pred c (i,j) can represent the prediction sample at the (i,j) coordinates of the current chroma block in the current CU. rec L ’(i,j) can represent the reconstructed sample at the (i,j) coordinates of the current luma block in the CU. For example, rec L ’(i,j) can represent the downsampled reconstructed sample of the current luma block. The linear model coefficients α and β can be signaled or derived from neighboring samples.
[0242] Virtual pipeline data unit
[0243] A virtual pipeline data unit (VPDU) can be defined for pipeline processing within a picture. The VPDU can be defined as a non - overlapping unit within a picture. In a hardware decoding device, consecutive VPDUs can be processed simultaneously by multiple pipeline stages. In most pipeline stages, the VPDU size can be approximately proportional to the buffer size. Therefore, it is important to keep the VPDU size small when considering the buffer size from a hardware perspective. In most hardware decoding devices, the VPDU size can be set to be equal to the maximum transform block (TB) size. For example, the VPDU size can be 64×64 (64×64 luma samples) size. Alternatively, in VVC, the above - mentioned ternary tree (TT) and / or binary tree (BT) partitioning can be considered to change (increase or decrease) the VPDU size.
[0244] In addition, in order to keep the VPDU size at 64×64 luma samples, the Figure 23 partitioning of the CUs shown can be restricted. More specifically, at least one of the following restrictions can be applied.
[0245] Restriction 1: For a CU with a width or height of 128 or both width and height of 128, ternary tree (TT) partitioning is not allowed.
[0246] Restriction 2: For a CU with 128×N (where N is an integer equal to or less than 64 and greater than 0), horizontal binary tree (BT) partitioning is not allowed (e.g., for a CU with a width of 128 and a height less than 128, horizontal binary tree partitioning is not allowed).
[0247] Restriction 3: For a CU with N×128 (where N is an integer equal to or less than 64 and greater than 0), vertical binary tree (BT) partitioning is not allowed (e.g., for a CU with a height of 128 and a width less than 128, vertical binary tree partitioning is not allowed).
[0248] The problem of the maximum size limit of chroma blocks for pipeline processing
[0249] As described above regarding the partitioning structure and transform processing, a CU can be partitioned to generate multiple TUs. When the size of a CU is larger than the maximum TU size, the CU can be partitioned into multiple TUs. Therefore, transform and / or inverse transform can be performed on each TU. Generally, the maximum TU size of a luma block can be set to the maximum available transform size, which can be performed by an encoding device and / or a decoding device. An example of partitioning CUs and TUs according to an embodiment is shown in Figures 24 to 26 in.
[0250] Figure 24Shows an example of a TU generated by dividing a luminance CU and a chrominance CU according to an embodiment. In the embodiment, the maximum size of the luminance CU may be 64×64, the maximum available transform size may be 32×32, and non-square TUs may not be allowed. Therefore, the maximum size of the luminance component transform block may be 32×32. In this embodiment, the maximum TU size may be set as shown in the following equation.
[0251] [Equation 3]
[0252] maxTbSize = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / max(SubWidthC, SubHeightC)
[0253] In the above equation, maxTbSize may be the maximum size of the transform block (TB), and cIdx may be the color component of the corresponding block. cIdx 0 may represent the luminance component, 1 may represent the Cb chrominance component, and 2 may represent the Cr chrominance component. MaxTbSizeY may represent the maximum size of the luminance component transform block, SubWidthC may represent the ratio of the width of the luminance block to the width of the chrominance block, SubHeightC may represent the ratio of the height of the luminance block to the height of the chrominance block, and max(A, B) may represent a function that returns the larger value of A and B as the result value.
[0254] According to the above equation, in the above embodiment, in the case of the luminance block, the maximum size of the transform block may be set to the maximum size of the luminance component transform block. Here, the maximum size of the luminance component transform block is a value set during encoding and may be signaled from the encoding device to the decoding device through the bitstream.
[0255] In addition, in the above embodiment, the maximum size of the transform block of the chrominance block may be set to a value obtained by dividing the maximum size of the luminance component transform block by the larger value of SubWidthC and SubHeightC. Here, SubWidthC and SubHeightC may be determined based on chroma_format_idc and separate_colour_plane_flag signaled from the encoding device to the decoding device through the bitstream, as Figure 23 shown.
[0256] According to the above equation, in the above embodiment, the maximum size of the transform block may be determined as either the minimum width or the minimum height of the transform block. Therefore, the TU partitioning of the luminance block and the chrominance block in the above embodiment may be performed as Figure 24 shown. For example, as Figure 24As shown, in the case of a chrominance block having a 4:2:2 format, when the maximum size of a transform block is determined to be 16, the chrominance CU can be divided into a plurality of transform blocks in a form different from the form in which the luminance CU is divided into transform blocks.
[0257] Figure 25 An example of a TU generated by dividing a luminance CU and a chrominance CU according to another embodiment is shown. In the embodiment, the maximum size of the luminance CU may be 128×128, the maximum available transform size may be 64×64, and non-square TUs may not be allowed. Therefore, the maximum size of the luminance component transform block may be 64×64. In this embodiment, the maximum size of the transform block may be set as shown in the following formula. In the following formula, min(A,B) may be a function that returns the smaller value of A and B.
[0258] [Equation 4]
[0259] maxTbSize = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / min(SubWidthC, SubHeightC)
[0260] In addition, according to the above formula, when the larger value of the width and height of the corresponding block is applied as the maximum size of the transform block, the luminance CU and the chrominance CU can be divided into a plurality of TUs as in the Figure 25 example.
[0261] In the Figure 24 and Figure 25 example, when dividing a chrominance CU having a 4:2:2 format into TUs, it is divided in a form different from the form in which the corresponding luminance CU is divided into TUs. However, when encoding / decoding a chrominance block by referring to a luminance block as in the DM mode or the CCLM mode for prediction of a chrominance block described above, in order to reduce the delay in pipeline processing and save memory, it is efficient to perform encoding (or decoding) of the corresponding chrominance block immediately after encoding (or decoding) of the luminance block corresponding to the chrominance block.
[0262] However, in the Figure 24 example, encoding of two chrominance blocks 2421 and 2423 should be performed after encoding of one luminance transform block 2411, which requires separate processing related to different color formats (4:4:4 or 4:2:0). In addition, in the Figure 25 example, encoding of one chrominance transform block 2521 should be performed after encoding of two luminance transform blocks 2511 and 2512. Thus, in the above TU division method, when using a 4:2:2 format, since the luminance block and the corresponding chrominance block do not match, separate processing may be added to perform pipeline processing, or pipeline processing may not be performed.
[0263] Maximum size limit of chrominance transform blocks for pipeline processing
[0264] Hereinafter, a method of setting the size of the maximum transform block of a chrominance CU to satisfy the conditions for performing the above VPDU will be described.
[0265] Figure 26 An example of a TU generated by dividing a luminance CU and a chrominance CU according to another embodiment is shown. In the embodiment, the maximum size of the luminance CU may be 128×128, the maximum available transform size may be 64×64, and division into non-square TUs may be allowed. Therefore, the maximum size of the luminance component transform block may be 64×64.
[0266] As Figure 26 shown, in order to divide into non-square TUs, the maximum size of the transform block may be defined for the width and height. For example, the maximum width (maxTbWidth) and the maximum height (maxTbHeight) of the transform block may be defined as shown in the following equations, thereby defining the maximum size of the transform block.
[0267] [Equation 5]
[0268] maxTbWidth = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubWidthC
[0269] [Equation 6]
[0270] maxTbHeight = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubHeightC
[0271] As in the above embodiment, by defining the maximum size of the transform block as the width and height, as Figure 26 shown in the example, even in the case of a chrominance CU having a 4:2:2 format, the chrominance CU can be divided into TUs in the form of dividing the corresponding luminance CU into TUs. Therefore, by dividing the chrominance CU into TUs corresponding to the TUs of the luminance CU, encoding (or decoding) of the corresponding chrominance block can be immediately performed after encoding (or decoding) of the luminance block, thereby reducing the delay in pipeline processing.
[0272] Maximum size limit of chrominance transform blocks in IBC prediction mode and inter prediction mode
[0273] Hereinafter, the execution of the intra block copy (IBC) prediction mode and the inter prediction mode that apply the maximum size limit of the chrominance transform block for the above chrominance pipeline processing will be described. The encoding device and the decoding device can perform IBC prediction and inter prediction by limiting the maximum size of the chrominance transform block according to the following description, and their operations can correspond to each other. In addition, the following description of IBC prediction can be variably applied to the inter prediction mode. Therefore, hereinafter, the IBC prediction operation of the decoding device according to the embodiment will be described.
[0274] The decoding device according to the embodiment can generate a luminance prediction block predSamplesL of size (cbWidth)×(cbHeight) and chrominance prediction blocks predSamplesCb and predSamplesCr of size (cbWidth / SubWidthC)×(cbHeight / SubHeightC) by performing IBC prediction. Here, cbWidth can be the width of the current CU, and cbHeight can be the height of the current CU.
[0275] In addition, the decoding device can generate a luminance residual block resSamplesL of size (cbWidth)×(cbHeight) and chrominance residual blocks resSamplesCr and resSamplesCb of size (cbWidth / SubWidthC)×(cbHeight / SubHeightC). Finally, the decoding device can use the prediction block and the residual block to generate a reconstructed block.
[0276] Hereinafter, a method for limiting the maximum size of the chrominance transform block to generate a residual block of a CU encoded in the IBC prediction mode according to the embodiment will be described. The decoding device can use the residual block generated in this step to generate a reconstructed block.
[0277] The decoding device according to the embodiment can directly obtain the following information from the bitstream or derive the following information from other information obtained from the bitstream to generate a residual block of size (nTbW)×(nTbH) of a CU encoded in the IBC prediction mode. Here, nTbW and nTbH can be set to the width cbWidth and the height cbHeight of the current CU.
[0278] - The sample position (xTb0, yTb0) specifies the position of the top-left sample of the current transform block relative to the position of the top-left sample of the current picture
[0279] - The parameter nTbW specifies the width of the current transform block
[0280] - The parameter nTbH specifies the height of the current transform block
[0281] - The parameter cIdx specifies the color component of the current CU.
[0282] The decoding device can derive the maximum width maxTbWidth of the transform block and the maximum height maxTbHeight of the transform block from the received information as follows.
[0283] [Equation 7]
[0284] maxTbWidth = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubWidthC
[0285] [Equation 8]
[0286] maxTbHeight = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubHeightC
[0287] In addition, the decoding device can derive the top - left sample position (xTbY, yTbY) of the current transform block based on whether the current CU is a luminance component or a chrominance component as follows.
[0288] [Equation 9]
[0289] (xTbY, yTbY) = (cIdx == 0)? (xTb0, yTb0) : (xTb0 * SubWidthC, yTb0 * SubHeightC)
[0290] In the above equations, when the current transform block is a chrominance block, in order to reflect the size of the chrominance block determined according to the chrominance format of the current transform block, the maximum width and height of the transform block and the top - left sample position of the current transform block can be determined based on the chrominance format.
[0291] Hereinafter, the decoding device can generate a residual block by performing the following process. This will be described with reference to Figure 27 First, the decoding device can determine whether the current transform block is partitioned (S2710). For example, the decoding device can determine whether the current transform block is partitioned based on whether the width and height of the current transform block are greater than the width and height of the maximum transform block. For example, when nTbW is greater than maxTbWidth or nTbH is greater than maxTbHeight, the decoding device can determine to generate lower - layer transform blocks by partitioning the current transform block.
[0292] When the current transform block is partitioned into lower - layer transform blocks, as described above, the decoding device can derive the width newTbW of the lower - layer transform block and the height newTbH of the lower - layer transform block as shown in the following equation (S2720).
[0293] [Equation 10]
[0294] newTbW = (nTbW > maxTbWidth)? (nTbW / 2) : nTbW
[0295] [Equation 11]
[0296] newTbH = (nTbH > maxTbHeight)? (nTbH / 2) : nTbH
[0297] Next, the decoding device may generate a residual block using the lower-layer transform blocks divided from the current transform block (S2730). In an embodiment, as Figure 26 shown, the current transform block may be a transform block having the width and height of a chrominance CU in 4:2:2 format, and the lower-layer transform blocks may be the first lower-layer transform block 2621 to the fourth lower-layer transform block 2624 obtained by dividing the current transform block into four in a non-square form.
[0298] First, the decoding device may generate a residual block for the first lower-layer transform block. Referring to Figure 26 , the first lower-layer transform block 2621 may be specified by the sample positions (xTb0, yTb0), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. The decoding device may use the color component cIdx of the current CU to generate a residual block for the first lower-layer transform block 2621. Based on this, the decoding device may generate a modified reconstructed picture. Thereafter, in-loop filtering may be performed on the modified reconstructed picture.
[0299] Next, when nTbW is greater than maxTbWidth, the decoding device may generate a residual block for the second lower-layer transform block. The second lower-layer transform block 2622 may be specified by the sample positions (xTb0 + newTbW, yTb0), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. The decoding device may use the color component cIdx of the current CU to generate a residual block for the second lower-layer transform block 2622. Based on this, the decoding device may generate a modified reconstructed picture. Thereafter, in-loop filtering may be performed on the modified reconstructed picture.
[0300] Next, when nTbH is greater than maxTbHeight, the decoding device may generate a residual block for the third lower-layer transform block. The third lower-layer transform block 2623 may be specified by the sample positions (xTb0, yTb0 + newTbH), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. Similar to the above description, the decoding device may use the color component cIdx of the current CU to generate a residual block.
[0301] Next, when nTbW is greater than maxTbWidth and nTbH is greater than maxTbHeight, the decoding device may generate a residual block of the fourth lower-layer transform block. The fourth lower-layer transform block 2624 may be specified by the sample position (xTb0 + newTbW, yTb0 + newTbH), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. Similar to the above description, the decoding device may use the color component cIdx of the current CU to generate the residual block.
[0302] In addition, when the partitioning of the current transform block is not performed, the decoding device may perform IBC prediction as follows. For example, when nTbW is less than maxTbWidth and nTbH is less than maxTbHeight, the current transform block may not be partitioned. In this case, the decoding device may generate a residual block for the IBC prediction mode by performing scaling and transform processing using the sample position (xTbY, xTbY), the color component cIdx of the current CU, the transform block width nTbW, and the transform block height nTbH as inputs. Based on this, the decoding device may generate a modified reconstructed picture. Thereafter, in-loop filtering may be performed on the modified reconstructed picture.
[0303] Maximum size limit of chrominance transform blocks in intra prediction mode
[0304] Hereinafter, the execution of the intra prediction mode to which the maximum size limit of the chrominance transform block for the above chrominance pipeline processing is applied will be described. The encoding device and the decoding device may perform intra prediction by limiting the maximum size of the chrominance transform block according to the following description, and their operations may correspond to each other. Therefore, hereinafter, the operation of the decoding device will be described.
[0305] The decoding device according to an embodiment may generate a reconstructed picture by performing intra prediction. In-loop filtering may be performed on the reconstructed picture. The decoding device according to an embodiment may directly obtain the following information from the bitstream or derive the following information from other information obtained from the bitstream to perform intra prediction.
[0306] - The sample position (xTb0, yTb0) specifies the position of the top-left sample of the current transform block relative to the top-left sample of the current picture
[0307] - The parameter nTbW specifies the width of the current transform block
[0308] - The parameter nTbH specifies the height of the current transform block
[0309] - The parameter predModeIntra specifies the intra prediction mode of the current CU
[0310] - The parameter cIdx specifies the color component of the current CU
[0311] The decoding device can derive the maximum width maxTbWidth of the transform block and the maximum height maxTbHeight of the transform block from the received information as follows.
[0312] [Equation 12]
[0313] maxTbWidth = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubWidthC
[0314] [Equation 13]
[0315] maxTbHeight = (cIdx == 0)? MaxTbSizeY : MaxTbSizeY / SubHeightC
[0316] In addition, the decoding device can derive the top - left sample position (xTbY, yTbY) of the current transform block based on whether the current CU is a luminance component or a chrominance component as follows.
[0317] [Equation 14]
[0318] (xTbY, yTbY) = (cIdx == 0)? (xTb0, yTb0) : (xTb0 * SubWidthC, yTb0 * SubHeightC)
[0319] Hereinafter, the decoding device can perform intra - prediction by executing the following process. This will be described with reference to Figure 28 First, the decoding device can determine whether the current transform block is partitioned (S2810). For example, the decoding device can determine whether the current transform block is partitioned based on whether the width and height of the current transform block are greater than the width and height of the maximum transform block. In addition, the decoding device can determine whether to perform partitioning by further considering whether intra - sub - partitioning (ISP) is applied to the current CU. For example, when nTbW is greater than maxTbWidth or nTbH is greater than maxTbHeight, the decoding device can determine to perform intra - prediction by partitioning the current transform block. In addition, even in this case, only when ISP is not applied to the current CU (for example, the value of IntraSubpartitonSplitType is NO_ISP_SPLIT, that is, ISP is not applied to the current CU), the decoding device can determine to perform intra - prediction by partitioning the current transform block.
[0320] When the current transform block is partitioned into lower - layer transform blocks, the decoding device can derive the width newTbW and height newTbH of the lower - layer transform blocks as shown in the following equation (S2820).
[0321] [Equation 15]
[0322] newTbW = (nTbW > maxTbWidth)? (nTbW / 2) : nTbW
[0323] [Equation 16]
[0324] newTbH = (nTbH > maxTbHeight)? (nTbH / 2) : nTbH
[0325] It will be described with reference to Figure 26 In an embodiment, the width nTbW of the current transform block may be the width of the chrominance CU, and the height nTbH of the current transform block may be the height of the chrominance CU. In this embodiment, the width newTbW of the lower-layer transform block and the height newTbH of the lower-layer transform block may be determined as the width and height of the transform block 2621 divided from the chrominance CU. That is, in this embodiment, the current transform block may be a transform block having the width and height of the chrominance CU in a 4:2:2 format, and the lower-layer transform blocks may be the first lower-layer transform block 2621 to the fourth lower-layer transform block 2624 obtained by dividing the current transform block into four in a non-square form.
[0326] Next, the decoding device may perform intra prediction (S2830) using the lower-layer transform blocks divided from the current transform block. First, the decoding device may perform intra prediction on the first lower-layer transform block. With reference to Figure 26 , the first lower-layer transform block 2621 may be specified by the sample position (xTb0, yTb0), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. The decoding device may perform intra prediction on the first lower-layer transform block 2621 using the intra prediction mode predModeIntra of the current CU and the color component cIdx of the CU. Thus, a modified reconstructed picture of the first lower-layer transform block 2621 may be generated.
[0327] For example, the decoding device may generate a prediction sample matrix predSamples of size (newTbW) × (newTbH) by performing an intra-sample prediction process. For example, the decoding device may perform an intra-sample prediction process using the sample position (xTb0, yTb0), the intra prediction mode predModeIntra, the transform block width (nTbW) newTbW, the transform block height (nTbH) newTbH, the coding block width (nCbW) nTbW, the coding block height (nCbH) nTbH, and the value of the parameter cIdx.
[0328] In addition, the decoding device may generate a residual sample matrix reSamples of size (newTbW)×(newTbH) by performing scaling and transformation processing. For example, the decoding device may perform scaling and transformation processing based on the sample position (xTb0, yTb0), the value of the parameter cIdx, the transform block width (nTbW) newTbW, and the transform block height (nTbH) newTbH.
[0329] In addition, the decoding device may generate a reconstructed picture by performing picture reconstruction processing on the color components. For example, the decoding device may set the transform block position to (xTb0, yTb0), set the transform block width (nTbW) to newTbW, set the transform block height (nTbH) to newTbH, use the value of the parameter cIdx, use a prediction sample matrix predSamples of size (newTbW)×(newTbH), and use a residual sample matrix reSamples of size (newTbW)×(newTbH), thereby performing picture reconstruction processing on the color components.
[0330] Next, when nTbW is greater than maxTbWidth, the decoding device may perform intra prediction on a second lower-layer transform block. The second lower-layer transform block 2622 may be specified by the sample position (xTb0 + newTbW, yTb0), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. The decoding device may perform intra prediction on the second lower-layer transform block 2622 using the intra prediction mode predModeIntra of the current CU and the color component cIdx of the current CU. Intra prediction of the second lower-layer transform block 2622 may be performed on its sample position similar to the intra prediction of the first lower-layer transform block 2621. Therefore, a modified reconstructed picture of the second lower-layer transform block 2622 may be generated.
[0331] Next, when nTbH is greater than maxTbHeight, the decoding device may perform intra prediction on a third lower-layer transform block. The third lower-layer transform block 2623 may be specified by the sample position (xTb0, yTb0 + newTbH), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. Similar to the above description, the decoding device may perform intra prediction using the intra prediction mode predModeIntra of the current CU and the color component cIdx of the current CU.
[0332] Next, when nTbW is greater than maxTbWidth and nTbH is greater than maxTbHeight, the decoding device may perform intra prediction on the fourth lower-layer transform block. The fourth lower-layer transform block 2624 may be specified by the sample position (xTb0 + newTbW, yTb0 + newTbH), the width newTbW of the lower-layer transform block, and the height newTbH of the lower-layer transform block. Similar to the above description, the decoding device may perform intra prediction using the intra prediction mode predModeIntra of the current CU and the color component cIdx of the current CU.
[0333] In addition, when the current transform block is not partitioned, the decoding device may perform intra prediction as follows. For example, when nTbW is less than maxTbWidth and nTbH is less than maxTbHeight or ISP is applied to the current CU (e.g., the value of IntraSubpartitonSplitType is not NO_ISP_SPLIT), the current transform block may not be partitioned.
[0334] First, the decoding device may derive the parameters nW, nH, numPartsX, and numPartsY as shown in the following formula.
[0335] [Equation 17]
[0336] nW = IntraSubPartitionsSplitType == ISP_VER_SPLIT? nTbW / NumIntraSubPartitions : nTbW
[0337] nH = IntraSubPartitionsSplitType == ISP_HOR_SPLIT? nTbH / NumIntraSubPartitions : nTbH
[0338] numPartsX = IntraSubPartitionsSplitType == ISP_VER_SPLIT? NumIntraSubPartitions : 1
[0339] numPartsY = IntraSubPartitionsSplitType == ISP_HOR_SPLIT? NumIntraSubPartitions : 1
[0340] In the above formula, IntraSubPartitionsSplitType specifies the ISP partitioning type of the current CU, ISP_VER_SPLIT specifies vertical ISP partitioning, and ISP_HOR_SPLIT specifies horizontal ISP partitioning. NumIntraSubPartitions specifies the number of ISP sub-partitions.
[0341] Next, the decoding device can generate a prediction sample matrix predSamples of size (nTbW)×(nTbH) by performing intra-sample prediction processing. For example, the decoding device can perform intra-sample prediction processing using the sample position (xTb0 + nW*xPartIdx, yTb0 + nH*yPartIdx), the intra-prediction mode predModeIntra, the transform block width (nTbW)nW, the transform block height (nTbH)nH, the coding block width (nCbW)nTbW, the coding block height (nCbH)nTbH, and the value of the parameter cIdx. Here, the value of the split index xPartIdx can have values from 0 to numPartX - 1, and yPartIdx can have values from 0 to numPartsY - 1.
[0342] Next, the decoding device can generate a residual sample matrix reSamples of size (nTbW)×(nTbH) by performing scaling and transformation processing. For example, the decoding device can perform scaling and transformation processing based on the sample position (xTbY + nW*xPartIdx, yTbY + nH*yPartIdx), the value of the parameter cIdx, the transform block width (nTbW)nW, and the transform block height (nTbH)nH.
[0343] Next, the decoding device can generate a reconstructed picture by performing picture reconstruction processing on the color components. For example, the decoding device can set the transform block position to (xTb0 + nW*xPartIdx, yTb0 + nH*yPartIdx), set the transform block width (nTbW) to nW, set the transform block height (nTbH) to nH, use the preset value of cIdx, and use the prediction sample matrix predSamples of size (nTbW)×(nTbH) and the residual sample matrix reSamples of size (nTbW)×(nTbH) to perform picture reconstruction processing on the color components.
[0344] Coding method
[0345] Hereinafter, with reference to Figure 29Describe a method for an encoding device according to an embodiment to perform encoding using the above method. The encoding device according to an embodiment may include a memory and at least one processor, and the at least one processor may perform the following encoding method.
[0346] First, the encoding device may determine a current block by partitioning an image (S2910). Next, the encoding device may generate a prediction block for the current block by performing IBC prediction on the current block (S2920). Next, the encoding device may generate a residual block for the current block based on the prediction block (S2930). Next, the encoding device may encode the prediction mode information of the current block (S2940). In this case, the residual block may be encoded based on the size of the transform block of the current block, and the size of the transform block may be determined based on the color component of the current block.
[0347] More specifically, when the color component of the current block is a chrominance component, the size of the transform block may be determined based on the color format. Additionally, the width of the transform block may be determined based on the maximum width of the transform block, and the maximum width of the transform block may be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format.
[0348] Additionally, the height of the transform block may be determined based on the maximum height of the transform block, and the maximum height of the transform block may be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format.
[0349] Additionally, when the color format of the current block is a format that specifies that the width and height of the chrominance block are half the width of the corresponding luminance block, the maximum width of the transform block may be determined to be half the maximum width of the transform block of the luminance block corresponding to the current block, and the maximum height of the transform block may be determined to be half the maximum height of the transform block of the luminance block corresponding to the current block.
[0350] Additionally, when the current block is a chrominance block, the position of the top-left sample of the transform block may be determined based on the position of the top-left sample of the luminance block corresponding to the current block and the color format.
[0351] Additionally, when the current block is a chrominance block and the transform block is partitioned into multiple lower-level transform blocks, the top-left position of the lower-level transform blocks may be determined based on the maximum width and the maximum height of the transform block. In this case, the maximum width of the transform block may be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format, and the maximum height of the transform block may be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format.
[0352] In addition, when the current block is a chrominance block and the width of the transform block is greater than the maximum width of the transform block, multiple lower-layer transform blocks can be generated by vertically dividing the current block. The maximum width of the transform block can be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format. In this case, the multiple lower-layer transform blocks can include a first lower-layer transform block and a second lower-layer transform block, and the width of the first lower-layer transform block and the width of the second lower-layer transform block can be determined as the maximum width of the transform block.
[0353] In addition, when the current block is a chrominance block and the height of the transform block is greater than the maximum height of the transform block, multiple lower-layer transform blocks can be generated by horizontally dividing the current block, and the maximum height of the transform block can be determined based on the maximum height of the transform block of the luminance block corresponding to the current block and the color format. In this case, the multiple lower-layer transform blocks can include a third lower-layer transform block and a fourth lower-layer transform block, and the height of the third lower-layer transform block and the height of the fourth lower-layer transform block can be determined as the maximum height of the transform block.
[0354] Decoding method
[0355] Hereinafter, reference will be made to Figure 30 a method for a decoding device according to an embodiment to perform decoding using the above method. The decoding device according to an embodiment may include a memory and at least one processor, and the at least one processor may perform the following decoding method.
[0356] First, the decoding device may determine the prediction mode of the current block (S3010). Next, when the prediction mode of the current block is the intra block copy (IBC) prediction mode, the decoding device may generate a prediction block of the current block based on the IBC prediction mode information (S3020). Next, the decoding device may determine the size of the transform block of the current block based on the color component of the current block (S3030). Next, the decoding device may generate a residual block of the current block based on the size of the transform block (S3040). Next, the decoding device may reconstruct the current block based on the prediction block and the residual block of the current block (S3050).
[0357] More specifically, when the color component of the current block is a chrominance component, the size of the transform block can be determined based on the color format. In addition, the width of the transform block can be determined based on the maximum width of the transform block, and the maximum width of the transform block can be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format.
[0358] In addition, the height of the transform block can be determined based on the maximum height of the transform block, and the maximum height of the transform block can be determined based on the maximum size of the transform block of the luminance block corresponding to the current block and the color format.
[0359] In addition, when the color format of the current block is a format in which the width and height of the chrominance block are half of the width of the corresponding luminance block, the maximum width of the transform block can be determined to be half of the maximum width of the transform block of the luminance block corresponding to the current block, and the maximum height of the transform block can be determined to be half of the maximum height of the transform block of the luminance block corresponding to the current block.
[0360] In addition, when the current block is a chrominance block, the position of the top-left sample of the transform block can be determined based on the position and color format of the top-left sample of the luminance block corresponding to the current block.
[0361] In addition, when the current block is a chrominance block and the transform block is divided into multiple lower-level transform blocks, the top-left position of the lower-level transform blocks can be determined based on the maximum width and maximum height of the transform block. In this case, the maximum width of the transform block can be determined based on the maximum size and color format of the transform block of the luminance block corresponding to the current block, and the maximum height of the transform block can be determined based on the maximum size and color format of the transform block of the luminance block corresponding to the current block.
[0362] In addition, when the current block is a chrominance block and the width of the transform block is greater than the maximum width of the transform block, multiple lower-level transform blocks can be generated by vertically dividing the current block. The maximum width of the transform block can be determined based on the maximum size and color format of the transform block of the luminance block corresponding to the current block. In this case, the multiple lower-level transform blocks can include a first lower-level transform block and a second lower-level transform block, and the width of the first lower-level transform block and the width of the second lower-level transform block can be determined to be the maximum width of the transform block.
[0363] In addition, when the current block is a chrominance block and the height of the transform block is greater than the maximum height of the transform block, multiple lower-level transform blocks can be generated by horizontally dividing the current block, and the maximum height of the transform block can be determined based on the maximum height and color format of the transform block of the luminance block corresponding to the current block. In this case, the multiple lower-level transform blocks can include a third lower-level transform block and a fourth lower-level transform block, and the height of the third lower-level transform block and the height of the fourth lower-level transform block can be determined to be the maximum height of the transform block.
[0364] Application Embodiment
[0365] Although, for the sake of clarity of description, the above-described exemplary method of the present disclosure is represented as a series of operations, it is not intended to limit the order of execution of the steps, and these steps can be performed simultaneously or in a different order when necessary. To implement the method according to the present invention, the described steps may further include other steps, may include the remaining steps except for some steps, or may include other additional steps except for some steps.
[0366] In the present disclosure, an image encoding device or an image decoding device that performs a predetermined operation (step) may perform an operation (step) of confirming the execution conditions or circumstances of the corresponding operation (step). For example, if it is described that a predetermined operation is performed when a predetermined condition is satisfied, the image encoding device or the image decoding device may perform the predetermined operation after determining whether the predetermined condition is satisfied.
[0367] The various embodiments of the present disclosure are not a list of all possible combinations and are intended to describe representative aspects of the present disclosure, and the matters described in the various embodiments may be applied independently or in combinations of two or more.
[0368] The various embodiments of the present disclosure may be implemented in hardware, firmware, software, or a combination thereof. In the case where the present disclosure is implemented by hardware, the present disclosure may be implemented by an application specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a general-purpose processor, a controller, a microcontroller, a microprocessor, etc.
[0369] In addition, an image decoding device and an image encoding device to which the embodiments of the present disclosure are applied may be included in a multimedia broadcast transmission and reception device, a mobile communication terminal, a home theater video device, a digital cinema video device, a surveillance camera, a video chat device, a real-time communication device such as video communication, a mobile streaming device, a storage medium, a camera, a video on demand (VoD) service providing device, an over the top video (OTT video) device, an Internet streaming service providing device, a three-dimensional (3D) video device, a video phone video device, a medical video device, etc., and may be used to process video signals or data signals. For example, an OTT video device may include a game console, a Blu-ray player, an Internet access TV, a home theater system, a smart phone, a tablet PC, a digital video recorder (DVR), etc.
[0370] Figure 31 is a view showing a content stream system to which the embodiments of the present disclosure can be applied.
[0371] As Figure 31 shown, a content stream system to which the embodiments of the present disclosure are applied may mainly include an encoding server, a streaming server, a network server, a media storage device, a user device, and a multimedia input device.
[0372] The encoding server compresses the content input from a multimedia input device such as a smart phone, a camera, a video camera, etc. into digital data to generate a bitstream and sends the bitstream to the streaming server. As another example, when a multimedia input device such as a smart phone, a camera, a video camera, etc. directly generates a bitstream, the encoding server may be omitted.
[0373] A bitstream may be generated by an image encoding method or an image encoding device applying embodiments of the present disclosure, and a streaming server may temporarily store the bitstream during the process of transmitting or receiving the bitstream.
[0374] The streaming server transmits multimedia data to a user device based on a request from the user via a web server, and the web server serves as a medium for informing the user of the service. When the user requests a desired service from the web server, the web server may deliver it to the streaming server, and the streaming server may send the multimedia data to the user. In this case, the content streaming system may include a separate control server. In this case, the control server is used to control commands / responses between devices in the content streaming system.
[0375] The streaming server may receive content from a media storage device and / or an encoding server. For example, when receiving content from the encoding server, the content may be received in real time. In this case, in order to provide a smooth streaming service, the streaming server may store the bitstream for a predetermined time.
[0376] Examples of the user device may include a mobile phone, a smartphone, a laptop computer, a digital broadcast terminal, a personal digital assistant (PDA), a portable multimedia player (PMP), a navigation device, a tablet computer, a tablet PC, a superbook, a wearable device (e.g., a smartwatch, smart glasses, a head-mounted display), a digital TV, a desktop computer, a digital signage, etc.
[0377] Each server in the content streaming system may operate as a distributed server, and in this case, data received from each server may be distributed.
[0378] The scope of the present disclosure includes software or machine-executable commands (e.g., an operating system, an application, firmware, a program, etc.) for enabling the operation of a method according to various embodiments to be executed on a device or a computer, and a non-transitory computer-readable medium having such software or commands stored thereon and executable on the device or the computer.
[0379] Industrial Applicability
[0380] Embodiments of the present disclosure may be used to encode or decode an image.
Claims
1. An image decoding device (200) for image decoding, the image decoding device comprises: a memory; and at least one processor, the at least one processor being connected to the memory and configured to: (a) determine a prediction mode of a current block; (b) generate a prediction block of the current block based on the prediction mode of the current block being an Intra Block Copy (IBC) prediction mode and based on IBC prediction mode information; (c) determine a size of a transform block of the current block based on a color component of the current block; (d) generate a residual block of the current block based on the size of the transform block; and (e) reconstruct the current block based on the residual block and the prediction block of the current block, wherein: based on the color component of the current block being a chrominance component, determine the size of the transform block based on a color format of the current block, the current block is a chrominance block, and determine a position of a top - left sample of the transform block based on a position of a top - left sample of a luminance transform block corresponding to the current block and the color format of the current block.
2. An image encoding device (100) for image encoding, the image encoding device comprises: a memory; and at least one processor, the at least one processor being connected to the memory and configured to: (a) determine a current block by dividing an image; (b) generate a prediction block of the current block by performing Intra Block Copy (IBC) prediction on the current block; (c) generate a residual block of the current block based on the prediction block; and (d) encode prediction mode information of the current block, wherein: encode the residual block based on a size of a transform block of the current block, determine the size of the transform block based on a color component of the current block, based on the color component of the current block being a chrominance component, determine the size of the transform block based on a color format of the current block, the current block is a chrominance block, and determine a position of a top - left sample of the transform block based on a position of a top - left sample of a luminance transform block corresponding to the current block and the color format of the current block.
3. A device for transmitting data for an image, the device comprises: at least one processor configured to obtain a bitstream generated by an image encoding method; and a transmitter configured to transmit the bitstream, wherein the image encoding method comprises: (a) determine a current block by dividing an image; (b) generate a prediction block of the current block by performing Intra Block Copy (IBC) prediction on the current block; (c) generate a residual block of the current block based on the prediction block; and (d) encode prediction mode information of the current block, wherein: encode the residual block based on a size of a transform block of the current block, determine the size of the transform block based on a color component of the current block, Based on the color component of the current block being a chrominance component, determine the size of the transform block based on the color format of the current block, the current block is a chrominance block, and determine the position of the upper-left sample of the transform block based on the position of the upper-left sample of the luminance transform block corresponding to the current block and the color format of the current block.