Image coding method and device based on intra-frame prediction using MPM list

By constructing an MPM list based on intra-frame prediction and optimizing image coding using candidate modes from neighboring blocks, the high-cost transmission and storage problems of high-resolution images and videos are solved, and compression efficiency and coding accuracy are improved.

CN117221531BActive Publication Date: 2026-11-10LG ELECTRONICS INC
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311247581.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2018-10-09
Filing Date
2019-10-08
Publication Date
2026-11-10
Estimated Expiration
2039-10-08

AI Technical Summary

Technical Problem

Existing technologies suffer from increased information content and high transmission and storage costs when transmitting and storing high-resolution, high-quality images and videos, especially when processing immersive media and images and videos with special image characteristics, where compression efficiency is insufficient.

Method used

By constructing an MPM list based on intra-frame prediction, the most probable mode list is generated by utilizing the candidate intra-frame prediction modes of the left and top adjacent blocks of the current block, and the intra-frame prediction mode is optimized by 64-modulus arithmetic operations, thereby improving image coding efficiency.

Benefits of technology

It improves the overall image and video compression efficiency, reduces computational complexity, and enhances the accuracy and coding efficiency of intra-frame prediction.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117221531B_ABST
    Figure CN117221531B_ABST
Patent Text Reader

Abstract

This disclosure relates to an image coding method and apparatus based on intra-frame prediction using an MPM list. The image decoding method according to this document includes the following steps: deriving a first intra-frame prediction mode candidate based on a first neighboring block to the left of the current block; deriving a second intra-frame prediction mode candidate based on a second neighboring block above the current block; configuring a most probable mode (MPM) list for the current block based on the first and second intra-frame prediction mode candidates; deriving an intra-frame prediction mode for the current block based on the MPM list; generating prediction samples by performing predictions on the current block based on the intra-frame prediction modes; and generating a reconstructed image of the current block based on the prediction samples.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of patent application No. 201980066112.8 (PCT / KR2019 / 013223), filed with the China Patent Office on April 7, 2021, with an international application date of October 8, 2019, entitled "Image Coding Method and Apparatus Based on Intra-Frame Prediction Using MPM List". Technical Field

[0002] This document relates to image coding techniques, and more specifically, to video coding methods and apparatus using intra-frame prediction based on MPM lists. Background Technology

[0003] There has been a growing demand for high-resolution, high-quality images and videos, such as Ultra High Definition (UHD) images and 4K or 8K or higher video, across various fields. As image and video data becomes higher resolution and higher quality, the amount of information or bits transmitted increases relatively compared to existing image and video data. Therefore, transmission and storage costs increase if media (such as existing wired or wireless broadband lines) are used to transmit image data or if existing storage media are used to store image and video data.

[0004] Furthermore, there has been a growing interest in and demand for immersive media, such as virtual reality (VR), artificial reality (AR) content, or holograms. Broadcasts of images and videos with image characteristics distinct from real images, such as game images, are also increasing.

[0005] Therefore, in order to effectively compress and transmit or store and play back information of high-resolution and high-quality images and videos with such various characteristics, efficient image and video compression technologies are needed. Summary of the Invention

[0006] Technical issues

[0007] This document provides methods and apparatus for improving image coding efficiency.

[0008] This document provides effective intra-frame prediction methods and apparatus.

[0009] This document provides a video coding method and apparatus for deriving a list of MPMs for effective intra-frame prediction.

[0010] This document provides intra-frame prediction methods and apparatus for configuring MPM candidates within a list of MPMs for effective intra-frame prediction.

[0011] Technical solution

[0012] On one hand, a video decoding method executed by a decoding device is provided. The method includes deriving a first candidate intra-prediction mode based on a first neighboring block located to the left of a current block; deriving a second candidate intra-prediction mode based on a second neighboring block located above the current block; constructing an MPM (Most Probable Mode) list for the current block based on the first and second candidate intra-prediction modes; deriving an intra-prediction mode for the current block based on the MPM list; generating prediction samples by performing predictions on the current block based on the intra-prediction modes; and generating a reconstructed image for the current block based on the prediction samples. The step of constructing the MPM list includes deriving MPM candidates including at least one of the first or second candidate intra-prediction modes, and at least one of the MPM candidates is derived by applying a modulo-64 arithmetic operation to the first or second candidate intra-prediction mode.

[0013] On the other hand, a video coding method performed by an encoding device is provided. The method includes: deriving a first candidate intra-prediction mode based on a first neighboring block located to the left of a current block; deriving a second candidate intra-prediction mode based on a second neighboring block located above the current block; constructing an MPM (Most Probable Mode) list for the current block based on the first candidate intra-prediction mode and the second candidate intra-prediction mode; determining an intra-prediction mode for the current block; generating prediction samples by performing predictions on the current block based on the intra-prediction modes; and encoding image information including intra-prediction mode information for the current block. The step of constructing the MPM list includes deriving MPM candidates including at least one of the first candidate intra-prediction mode or the second candidate intra-prediction mode, and at least one of the MPM candidates is derived by applying a modulo-64 arithmetic operation to the first candidate intra-prediction mode or the second candidate intra-prediction mode.

[0014] Beneficial effects

[0015] This document can be used to improve overall image and video compression efficiency.

[0016] According to this document, computational complexity can be reduced and overall coding efficiency can be improved through effective intra-frame prediction.

[0017] According to this document, the MPM list can be configured more effectively by considering an increase in the number of intra-prediction modes. Furthermore, the accuracy of the MPM list used to indicate the intra-prediction mode for the current block can be improved, thus enhancing overall coding efficiency.

[0018] According to this document, prediction performance can be improved and computational complexity reduced by configuring the MPM candidates in the MPM list by taking into account prediction performance, complexity, prediction directionality, etc. Attached Figure Description

[0019] Figure 1 An example of a video / image coding system to which embodiments of this document can be applied is illustrated schematically.

[0020] Figure 2 This is a diagram schematically illustrating the configuration of a video / image encoding apparatus to which embodiments of this document may be applied.

[0021] Figure 3 This is a diagram schematically illustrating the configuration of a video / image decoding apparatus to which embodiments of this document may be applied.

[0022] Figure 4 An example of an image encoding method performed by a video encoding device is shown.

[0023] Figure 5 An example of a video encoding method performed by a decoding device is shown.

[0024] Figure 6 Examples of image coding methods based on intra-frame prediction are shown. Figure 7 An intra-frame predictor within the coding apparatus is illustrated schematically.

[0025] Figure 8 An example of a video coding method based on intra-frame prediction is shown, and Figure 9 An intra-frame predictor within a decoding device is illustrated schematically.

[0026] Figure 10 Sixty-five directional intra-frame prediction modes are shown.

[0027] Figure 11 The adjacent blocks of the current block are shown.

[0028] Figure 12 and 13 This is a flowchart schematically illustrating a method for configuring the MPM list for the current block.

[0029] Figure 14 This is a flowchart illustrating an embodiment of a method for configuring an MPM list for the current block.

[0030] Figure 15 This is a flowchart illustrating another embodiment of a method for configuring an MPM list for the current block.

[0031] Figure 16 This is a flowchart schematically illustrating an encoding method that can be performed by an encoding device according to an embodiment of this document.

[0032] Figure 17 This is a flowchart schematically illustrating a decoding method that can be performed by a decoding device according to an embodiment of this document.

[0033] Figure 18 An example of a content streaming system to which the embodiments disclosed in this document can be applied is shown. Detailed Implementation

[0034] This document can be modified in various ways and can have various embodiments, and specific embodiments will be illustrated and described in detail in the accompanying drawings. However, this is not intended to limit this document to the specific embodiments. The terminology generally used in this specification is used to describe specific embodiments and is not intended to limit the technical spirit of this document. Unless otherwise expressly indicated in the context, singular expressions include plural expressions. Terms such as "comprising" or "having" in this specification should be understood to indicate the presence of the features, numbers, steps, operations, elements, components, or combinations thereof described in this specification, without excluding the possibility of the presence or addition of one or more other features, numbers, steps, operations, elements, components, or combinations thereof.

[0035] Furthermore, for ease of description in relation to different features and functions, the elements in the accompanying drawings described in this document are illustrated independently. This does not imply that the individual elements are implemented as separate hardware or separate software. For example, at least two elements may be combined to form a single element, or a single element may be divided into multiple elements. Embodiments of combining and / or separating elements are also included within the scope of this document, unless they depart from the spirit of this document.

[0036] In the following, preferred embodiments of this document are described in more detail with reference to the accompanying drawings. In the following drawings, the same reference numerals are used for the same elements, and redundant descriptions of the same elements may be omitted.

[0037] This document relates to video / image coding. For example, the methods / exercises disclosed in this document can be applied to methods disclosed in the Universal Video Coding (VVC) standard, the EVC (Essential Video Coding) standard, the AOMedia Video 1 (AV1) standard, the second-generation Audio Video Coding standard (AVS2), or the next-generation video / image coding standard (e.g., H.267 or H.268).

[0038] This document presents various embodiments of video / image coding, and unless otherwise stated, these embodiments may be combined with each other to perform the task.

[0039] In this document, video can refer to a series of images over time. Generally, an image is a unit representing an image within a specific time zone, and a tile is a unit that constitutes part of an image during encoding. A tile can include one or more Code Tree Units (CTUs). An image can consist of one or more tiles. An image can consist of one or more tile groups. A tile group can include one or more tiles. A brick can represent a rectangular area of ​​a CTU row within a tile in an image. A tile can be divided into multiple bricks, each brick consisting of one or more CTU rows within the tile. A tile that is not divided into multiple bricks can also be called a brick. Tile scanning is a specific order of CTUs that divide an image, where CTUs are sequentially ordered by CTU raster scan within a tile, tiles within a tile are sequentially ordered by the raster scan of the tile's bricks, and tiles in an image are sequentially ordered by the raster scan of the tile's tiles. A tile is a rectangular area of ​​CTUs within a specific tile column and a specific tile row in an image. A tile column is a rectangular area of ​​a CTU, the height of which is equal to the height of the image and the width is specified by the syntax element in the image parameter set. A tile row is a rectangular area of ​​a CTU, the height of which is specified by the syntax element in the image parameter set and the width of which is equal to the width of the image. A tile scan is a specific ordering of the CTUs that segment the image, where CTUs can be ordered consecutively by CTU raster scan within a tile, and tiles in an image can be ordered consecutively by the raster scan of the tiles in the image. A slice consists of an integer number of tiles of an image that can be exclusively contained within a single NAL unit. A slice can consist of multiple complete tiles or a consecutive sequence of complete tiles of a single tile. In this document, tile groups and slices are used interchangeably. For example, in this document, a tile group / tile group header can be referred to as a slice / slice header.

[0040] A pixel, or pel, can refer to the smallest unit that makes up a picture (or image). Additionally, the term "sample" can be used as the counterpart to a pixel. A sample can typically represent a pixel or pixel value, and can represent only the pixel / pixel value of the luminance component, or only the pixel / pixel value of the chrominance component.

[0041] A unit can represent the basic unit of image processing. A unit may include a specific region of an image and at least one of the information associated with that region. A unit may include a luminance block and two chrominance (e.g., cb, cr) blocks. In some cases, the terms unit and such as block or region may be used interchangeably. Typically, an M×N block may include a sample (or sample array) or a set (or array) of transform coefficients with M columns and N rows.

[0042] In this document, the terms " / " and "," should be interpreted as indicating "and / or." For example, the expression "A / B" can mean "A and / or B." Similarly, "A, B" can mean "A and / or B." Additionally, "A / B / C" can mean "at least one of A, B, and / or C."

[0043] Additionally, in this document, the term "or" should be interpreted as indicating "and / or". For example, the expression "A or B" could include 1) only A, 2) only B, and / or 3) both A and B. In other words, the term "or" in this document should be interpreted as indicating "additionally or alternatively".

[0044] Figure 1 An example of a video / image coding system to which embodiments of this document can be applied is illustrated schematically.

[0045] refer to Figure 1 A video / image encoding system may include a first device (source device) and a second device (receiving device). The source device may transmit encoded video / image information or data to the receiving device in the form of a file or stream via a digital storage medium or network.

[0046] The source device may include a video source, an encoding device, and a transmitter. The receiving device may include a receiver, a decoding device, and a renderer. The encoding device may be referred to as a video / image encoding device, and the decoding device may be referred to as a video / image decoding device. The transmitter may be included in the encoding device. The receiver may be included in the decoding device. The renderer may include a display, and the display may be configured as a separate device or an external component.

[0047] A video source can acquire video / images through processes of capturing, compositing, or generating video / images. A video source may include video / image capture devices and / or video / image generation devices. Video / image capture devices may include, for example, one or more cameras, video / image archives including previously captured video / images, etc. Video / image generation devices may include, for example, computers, tablets, and smartphones, and can generate video / images (electronically). For example, virtual video / images can be generated by a computer, etc. In this case, the video / image capture process can be replaced by a process of generating related data.

[0048] An encoding device can encode input video / images. The encoding device can perform a series of processes such as prediction, transformation, and quantization for compression and encoding efficiency. The encoded data (encoded video / image information) can be output as a bitstream.

[0049] A transmitter can transmit encoded video / image information or data, output in bitstream form, to a receiver of a receiving device in the form of a file or stream via digital storage media or a network. Digital storage media can include various storage media such as USB, SD, CD, DVD, Blu-ray, HDD, SSD, etc. The transmitter can include elements for generating media files according to a predetermined file format and may include elements for transmission over a broadcast / communication network. The receiver can receive / extract the bitstream and send the received bitstream to a decoding device.

[0050] Decoding devices can decode video / images by performing a series of processes, such as inverse quantization, inverse transform, and prediction, that correspond to the operations of encoding devices.

[0051] The renderer can render decoded video / images. The rendered video / images can be displayed on a monitor.

[0052] Figure 2 This is a schematic diagram illustrating the configuration of a video / image encoding apparatus to which embodiments of this document may be applied. In the following, the video encoding apparatus may include an image encoding apparatus.

[0053] refer to Figure 2 The encoding device 200 may include an image segmenter 210, a predictor 220, a residual processor 230, an entropy encoder 240, an adder 250, a filter 260, and a memory 270. The predictor 220 may include an inter-frame predictor 221 and an intra-frame predictor 222. The residual processor 230 may include a transform 232, a quantizer 233, an inverse quantizer 234, and an inverse transform 235. The residual processor 230 may further include a subtractor 231. The adder 250 may be referred to as a reconstructor or a reconstruction block generator. According to embodiments, the image segmenter 210, predictor 220, residual processor 230, entropy encoder 240, adder 250, and filter 260 may be configured by at least one hardware component (e.g., an encoder chipset or processor). Additionally, the memory 270 may include a decoded picture buffer (DPB) or may be configured by a digital storage medium. The hardware component may further include the memory 270 as an internal / external component.

[0054] Image segmenter 210 can segment an input image (or picture or frame) input to encoding device 200 into one or more processors. For example, a processor may be referred to as a coding unit (CU). In this case, coding units can be recursively segmented from coding tree units (CTUs) or maximum coding units (LCUs) according to a quadtree-binary-tritree (QTBTTT) structure. For example, a coding unit can be segmented into multiple deeper coding units based on a quadtree structure, a binary tree structure, and / or a ternary structure. In this case, for example, a quadtree structure can be applied first, followed by a binary tree structure and / or a ternary tree structure. Alternatively, a binary tree structure can be applied first. The encoding process according to this document can be performed based on the final coding unit that is no longer segmented. In this case, based on the image characteristics and encoding efficiency, the maximum coding unit can be used as the final coding unit, or if necessary, the coding unit can be recursively segmented into deeper coding units, and the coding unit with the optimal size can be used as the final coding unit. Here, the encoding process may include processes such as prediction, transformation, and reconstruction, which will be described later. As another example, the processor may further include a prediction unit (PU) or a transform unit (TU). In this case, the prediction unit and the transform unit can be partitioned or split from the final coding unit described above. 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 residual signals from the transform coefficients.

[0055] In some cases, units and terms such as blocks or regions can be used interchangeably. Typically, an M×N block can represent a set of samples or transform coefficients consisting of M columns and N rows. Samples can typically represent pixels or pixel values, and can represent pixel / pixel values ​​of only the luminance component, or pixel / pixel values ​​of only the chrominance component. Samples can be used as a term corresponding to a picture (or image) for a pixel or image unit.

[0056] In the encoding apparatus 200, a residual signal (residual block, residual sample array) is generated by subtracting the prediction signal (predicted block, prediction sample array) output from the inter-frame predictor 221 or the intra-frame predictor 222 from the input image signal (original block, original sample array), and the generated residual signal is transmitted to the converter 232. In this case, as shown, the unit in the encoder 200 for subtracting the prediction signal (predicted block, prediction sample array) from the input image signal (original block, original sample array) can be referred to as subtractor 231. The predictor can perform prediction on the block to be processed (hereinafter referred to as the current block) and can generate a predicted block including prediction samples for the current block. The predictor can determine whether to apply intra-frame prediction or inter-frame prediction based on the current block or CU. As described later in the description of each prediction mode, the predictor can generate various information related to the prediction (such as prediction mode information) and transmit the generated information to the entropy encoder 240. The information about the prediction can be encoded in the entropy encoder 240 and output in the form of a bitstream.

[0057] Intra-predictor 222 can predict the current block by referencing samples in the current image. Depending on the prediction mode, the reference samples may be located near the current block or at a separate location. In intra-prediction, the prediction modes can include multiple non-directional modes and multiple directional modes. Non-directional modes can include, for example, DC mode and planar mode. Depending on the level of detail in the prediction direction, the directional modes can include, for example, 33 or 65 directional prediction modes. However, this is just an example, and more or fewer directional prediction modes may be used depending on the settings. Intra-predictor 222 can determine the prediction mode to be applied to the current block by using the prediction modes applied to neighboring blocks.

[0058] Inter-frame predictor 221 can derive blocks for prediction of the current block based on reference blocks (reference sample arrays) specified by motion vectors on a reference image. Here, to reduce the amount of motion information transmitted in inter-frame prediction mode, motion information can be predicted on a block, sub-block, or sample basis based on the correlation between motion information between neighboring blocks and the current block. Motion information may include motion vectors and reference image indices. Motion information may further include inter-frame prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.) information. In the case of inter-frame prediction, neighboring blocks may include spatially adjacent blocks existing in the current image and temporally adjacent blocks existing in the reference image. The reference image including the reference blocks and the reference image including the temporally adjacent blocks may be the same or different. Temporally adjacent blocks may be referred to as co-located reference blocks, co-located CUs (colCUs), etc., and the reference image including the temporally adjacent blocks may be referred to as a co-located image (colPic). For example, inter-frame predictor 221 can configure a motion information candidate list based on neighboring blocks and generate information indicating which candidate is used to derive the motion vector and / or reference image index of the current block. Inter-frame prediction can be performed based on various prediction modes. For example, in skip mode and merge mode, the inter-frame predictor 221 can use the motion information of neighboring blocks as the motion information of the current block. In skip mode, unlike merge mode, residual signals may not be transmitted. In motion vector prediction (MVP) mode, the motion vectors of neighboring blocks can be used as motion vector predictors, and the motion vector of the current block can be indicated by signaling the motion vector difference.

[0059] Predictor 220 can generate prediction signals based on various prediction methods described below. For example, the predictor can not only apply intra-frame prediction or inter-frame prediction to predict a block, but can also apply both intra-frame prediction and inter-frame prediction simultaneously. This can be referred to as combined intra-frame and inter-frame prediction (CIIP). Alternatively, the predictor can predict blocks based on intra-frame block copy (IBC) prediction mode or palette mode. IBC prediction mode or palette mode can be used for content image / video encoding in games, such as screen content encoding (SCC). IBC essentially performs prediction within the current image, but in terms of deriving reference blocks within the current image, it can be performed similarly to inter-frame prediction. That is, IBC can use at least one of the inter-frame prediction techniques described in this document. Palette mode can be considered an example of intra-frame coding or intra-frame prediction. When applying palette mode, the sample values ​​within the image can be signaled based on information about the palette table and palette index.

[0060] The predicted signal generated by the predictor (including inter-frame predictor 221 and / or intra-frame predictor 222) can be used to generate the reconstructed signal or the residual signal. Transformer 232 can generate transform coefficients by applying a transform technique to the residual signal. For example, the transform technique can include at least one of Discrete Cosine Transform (DCT), Discrete Sine Transform (DST), Karhunen-Loève Transform (KLT), Graph-Based Transform (GBT), or Conditional Nonlinear Transform (CNT). Here, GBT refers to a transform obtained from a graph when representing the relationship information between pixels using a graph. CNT refers to a transform generated based on the predicted signal generated using all previously reconstructed pixels. Furthermore, the transform process can be applied to square pixel blocks of the same size, or it can be applied to blocks of variable size that are not square.

[0061] Quantizer 233 can quantize the transform coefficients and transmit them to entropy encoder 240, which 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. Quantizer 233 can rearrange the block-type quantized transform coefficients into a one-dimensional vector based on the coefficient scan order, and generate information about the quantized transform coefficients based on the one-dimensional vector form. Entropy encoder 240 can perform various encoding methods, such as (e.g.) exponential Golomb, context-adaptive variable-length coding (CAVLC), context-adaptive binary arithmetic coding (CABAC), etc. Entropy encoder 240 can encode information required for video / image reconstruction, either together or separately, in addition to the quantized transform coefficients (e.g., values ​​of syntax elements, etc.). The encoded information (e.g., encoded video / image information) can be transmitted or stored in units of NAL (Network Abstraction Layer) in the form of a bitstream. The video / image information may further include information about various parameter sets (such as Adaptive Parameter Set (APS), Picture Parameter Set (PPS), Sequence Parameter Set (SPS), or Video Parameter Set (VPS)). Additionally, the video / image information may further include general constraint information. In this document, information and / or syntax elements transmitted from the encoding device to / signaled to the decoding device may be included in the video / image information. The video / image information may be encoded by the encoding process described above and included in the bitstream. The bitstream may be transmitted over a network or stored in a digital storage medium. The network may include broadcast networks and / or communication networks, and the digital storage medium may 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 240 or a storage unit (not shown) that stores the signal may be included as an internal / external element of the encoding device 200, and alternatively, the transmitter may be included within the entropy encoder 240.

[0062] The quantized transform coefficients output from quantizer 233 can be used to generate a prediction signal. For example, the residual signal (residual block or residual sample) can be reconstructed by applying inverse quantization and inverse transform to the quantized transform coefficients using inverse quantizer 234 and inverse transform 235. Adder 155 adds the reconstructed residual signal to the prediction signal output from inter-frame predictor 221 or intra-frame predictor 222 to generate a reconstructed signal (reconstructed image, reconstructed block, reconstructed sample array). If there is no residual for the block to be processed, such as when a skip mode is applied, the predicted block can be used as the reconstructed block. Adder 250 can be referred to as a reconstructor or reconstructed block generator. The generated reconstructed signal can be used for intra-frame prediction of the next block to be processed in the current image, and, as described below, can be filtered for inter-frame prediction of the next image.

[0063] Simultaneously, during image encoding and / or reconstruction, luminance mapping with chroma scaling (LMCS) can be applied.

[0064] Filter 260 can improve subjective / objective image quality by applying filtering to the reconstructed signal. For example, filter 260 can generate a modified reconstructed image by applying various filtering methods to the reconstructed image, and the modified reconstructed image can be stored in memory 270 (specifically, the DPB of memory 270). Various filtering methods can include, for example, deblocking filtering, sample adaptive offset, adaptive loop filtering, bilateral filtering, etc. As described later in the description of each filtering method, filter 260 can generate various filtering-related information and transmit the generated information to entropy encoder 240. The filtering information can be encoded by entropy encoder 240 and output as a bitstream.

[0065] The modified reconstructed image transmitted to memory 270 can be used as a reference image in inter-frame predictor 221. When inter-frame prediction is applied through the encoding device, prediction mismatch between the encoding device 200 and the decoding device can be avoided, and encoding efficiency can also be improved.

[0066] Memory 270 DPB can store modified reconstructed images for use as reference images in inter-frame predictor 221. Memory 270 can store motion information of blocks from which motion information in the current image is derived (or encoded) and / or motion information of blocks in reconstructed images. The stored motion information can be transmitted to inter-frame predictor 221 and used as motion information for spatially adjacent blocks or temporally adjacent blocks. Memory 270 can store reconstructed samples of reconstructed blocks in the current image and can transmit these reconstructed samples to intra-frame predictor 222.

[0067] Figure 3This is a schematic diagram illustrating the configuration of a video / image decoding apparatus to which embodiments of this document can be applied.

[0068] refer to Figure 3 The decoding device 300 may include an entropy decoder 310, a residual processor 320, a predictor 330, an adder 340, a filter 350, and a memory 360. The predictor 330 may include an inter-frame predictor 332 and an intra-frame predictor 331. The residual processor 320 may include an inverse quantizer 321 and an inverse transformer 322. According to embodiments, the entropy decoder 310, residual processor 320, predictor 330, adder 340, and filter 350 may be configured by hardware components (e.g., a decoder chipset or processor). Additionally, the memory 360 may include a decoded picture buffer (DPB) and may be configured by a digital storage medium. The hardware components may further include the memory 360 as an internal / external component.

[0069] When the input includes a bitstream containing video / image information, the decoding device 300 can reconstruct the data from the input bitstream. Figure 2 The decoding device 300 can derive units / blocks based on block segmentation information obtained from the bitstream. The decoding device 300 can perform decoding using a processor applied in the encoding device. Therefore, the processor for decoding can be, for example, an encoding unit, and the encoding unit can be segmented from encoding tree units or maximum encoding units according to a quadtree structure, binary tree structure, and / or ternary tree structure. One or more transform units can be derived from the encoding unit. The reconstructed image signal decoded and output by the decoding device 300 can be reproduced by a reproduction device.

[0070] Decoding device 300 can receive data from a source in the form of a bitstream. Figure 2The signal output by the encoding device and the received signal can be decoded by the entropy decoder 310. For example, the entropy decoder 310 can parse the bitstream to derive the information (e.g., video / image information) required for image reconstruction (or picture reconstruction). The video / image information may further include information about various parameter sets (such as adaptive parameter sets (APS), picture parameter sets (PPS), sequence parameter sets (SPS), or video parameter sets (VPS)). In addition, the video / image information may further include general constraint information. The decoding device can further decode the picture based on the information about the parameter sets and / or general constraint information. In this document, the signaling / receiving information and / or syntax elements described later can be decoded by the decoding process and obtained from the bitstream. For example, the entropy decoder 310 can decode the information in the bitstream based on an encoding method (such as exponential Golomb coding, CAVLC, or CABAC) and can output the syntax elements required for image reconstruction and the quantized values ​​of the transform coefficients for the residuals. More specifically, the CABAC entropy decoding method can receive bins corresponding to each syntax element in the bitstream, determine a context model using information about the target syntax element, decoding information about the target block, or information about symbols / bins decoded in a previous stage, and perform arithmetic decoding on the bins based on the determined context model by predicting the occurrence probability of the bins, generating symbols corresponding to each syntax element value. In this case, the CABAC entropy decoding method can update the context model after determining the context model by using information from the decoded symbols / bins for the context model of the next symbol / bin. Prediction-related information from the information decoded by the entropy decoder 310 can be provided to the predictors (inter-frame predictor 332 and intra-frame predictor 331), and the residual values ​​(i.e., quantized transform coefficients and associated parameter information) that have undergone entropy decoding in the entropy decoder 310 can be input to the residual processor 320. The residual processor 320 can derive residual signals (residual blocks, residual samples, residual sample arrays). Additionally, filtering-related information from the information decoded in the entropy decoder 310 can be provided to the filter 350. Meanwhile, the receiver (not shown) for receiving the signal output from the encoding device can be further configured as an internal / external element of the decoding device 300, or the receiver can be a component of the entropy decoder 310. Furthermore, the decoding device according to this document can be referred to as a video / image / picture decoding device, and the 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 may include the entropy decoder 310, and the sample decoder may include at least one of a dequantizer 321, an inverse transformer 322, an adder 340, a filter 350, a memory 360, an inter-frame predictor 332, and an intra-frame predictor 331.

[0071] The dequantizer 321 can dequantize the quantized transform coefficients and output the transform coefficients. The dequantizer 321 can rearrange the quantized transform coefficients in the form of two-dimensional blocks. In this case, the rearrangement can be performed based on the coefficient scan order performed in the encoding device. The dequantizer 321 can perform dequantization on the quantized transform coefficients using quantization parameters (e.g., quantization step size information) and obtain the transform coefficients.

[0072] The inverse converter 322 obtains the residual signal (residual block, residual sample array) by performing an inverse transformation on the transformation coefficients.

[0073] The predictor can perform predictions on the current block and generate a block of predictions that includes the prediction samples used for the current block. The predictor can determine whether to apply intra-frame prediction or inter-frame prediction to the current block based on information about the predictions output from the entropy decoder 310, and can determine a specific intra-frame / inter-frame prediction mode.

[0074] Predictor 330 can generate prediction signals based on various prediction methods described below. For example, the predictor can not only apply intra-frame prediction or inter-frame prediction to predict a block, but can also apply intra-frame prediction and inter-frame prediction simultaneously. This can be referred to as combined intra-frame and inter-frame prediction (CIIP). Alternatively, the predictor can use an intra-block copy (IBC) prediction mode or a palette mode for predicting blocks. The IBC prediction mode or palette mode can be used for content image / video encoding in games, such as Screen Content Coding (SCC). IBC essentially performs prediction within the current image, but in terms of deriving reference blocks within the current image, it can be performed similarly to inter-frame prediction. That is, IBC can use at least one of the inter-frame prediction techniques described in this document. The palette mode can be considered an example of intra-frame coding or inter-frame prediction. When applying a palette mode, sample values ​​within the image can be signaled based on information about the palette table and palette index.

[0075] Intra-predictor 331 can predict the current block by referencing samples in the current image. Depending on the prediction mode, the reference samples may be located near the current block or at a separate location. In intra-prediction, the prediction mode can include multiple non-directional modes and multiple directional modes. Intra-predictor 331 can determine the prediction mode applied to the current block by using the prediction modes applied to neighboring blocks.

[0076] Inter-frame predictor 332 can derive the block for prediction of the current block based on a reference block (reference sample array) specified by motion vectors on a reference image. In this case, to reduce the amount of motion information transmitted in inter-frame prediction mode, motion information can be predicted on a block, sub-block, or sample basis based on the correlation of motion information between neighboring blocks and the current block. Motion information may include motion vectors and reference image indices. Motion information may further include inter-frame prediction direction (L0 prediction, L1 prediction, Bi prediction, etc.) information. In the case of inter-frame prediction, neighboring blocks may include spatially adjacent blocks existing in the current image and temporally adjacent blocks existing in the reference image. For example, inter-frame predictor 332 can configure a motion information candidate list based on neighboring blocks and derive the motion vector and / or reference image index of the current block based on the received candidate selection information. Inter-frame prediction can be performed based on various prediction modes, and the information about the prediction may include information indicating the mode of inter-frame prediction used for the current block.

[0077] Adder 340 can generate a reconstruction signal (reconstructed image, reconstructed block, reconstructed sample array) by adding the obtained residual signal to the prediction signal (predicted block, prediction sample array) output from the predictor (including inter-frame predictor 332 and / or intra-frame predictor 331). If there is no residual for the block to be processed, such as when a skip mode is applied, the predicted block can be used as the reconstruction block.

[0078] Adder 340 can be referred to as a reconstructor or reconstruction block generator. The generated reconstructed signal can be used for intra-frame prediction of the next block to be processed in the current image, can be filtered and output as described below, or can be used for inter-frame prediction of the next image.

[0079] Simultaneously, luminance mapping with chroma scaling (LMCS) can be applied during image decoding.

[0080] Filter 350 can improve subjective / objective image quality by applying filtering to the reconstructed signal. For example, filter 350 can generate a modified reconstructed image by applying various filtering methods to the reconstructed image and storing the modified reconstructed image in memory 360 (specifically, the DPB of memory 360). Various filtering methods may include, for example, deblocking filtering, adaptive sample shifting, adaptive loop filtering, bilateral filtering, etc.

[0081] The (modified) reconstructed image stored in the DPB of memory 360 can be used as a reference image in inter-frame predictor 332. Memory 360 can store motion information of blocks in the current image from which motion information is derived (or decoded) and / or motion information of blocks in reconstructed images. The stored motion information can be transmitted to inter-frame predictor 332 to be used as motion information for spatially adjacent blocks or temporally adjacent blocks. Memory 360 can store reconstructed samples of reconstructed blocks in the current image and transmit the reconstructed samples to intra-frame predictor 331.

[0082] In this disclosure, the embodiments described in the filter 260, inter-frame predictor 221 and intra-frame predictor 222 of the encoding device 200 may be the same as or respectively applied to the filter 350, inter-frame predictor 332 and intra-frame predictor 331 of the decoding device 300 to correspond to the filter 350, inter-frame predictor 332 and intra-frame predictor 331 of the decoding device 300.

[0083] As described above, during video encoding, prediction is performed to improve compression efficiency. A predicted block, including predicted samples for the current block used as the target coding block, can be generated through prediction. In this case, the predicted block includes predicted samples in the spatial domain (or pixel domain). The predicted block is similarly derived in both the encoding and decoding devices. The encoding device can improve image coding efficiency by signaling information (residual information) about the residual between the original block (the original sample values ​​of the non-original block) and the predicted block. The decoding device can derive a residual block including residual samples based on the residual information, generate a reconstructed block including reconstructed samples by adding the residual block to the predicted block, and generate a reconstructed image including the reconstructed block.

[0084] Residual information can be generated through transformation and quantization processes. For example, the encoding device can derive a residual block between the initial block and the predicted block, derive transform coefficients by performing a transform process on the residual samples (residual sample array) included in the residual block, derive quantized transform coefficients by performing a quantization process on the transform coefficients, and signal the relevant residual information to the decoding device (via a bitstream). In this case, the residual information may include information such as value information, position information, transform scheme, transform kernel, and quantization parameters of the quantized transform coefficients. The decoding device can perform inverse quantization / inverse transform processes based on the residual information and derive residual samples (or residual blocks). The decoding device can generate a reconstructed image based on the predicted block and the residual block. Furthermore, the encoding device can derive residual blocks by performing inverse quantization / inverse transform on the quantized transform coefficients for inter-frame prediction reference of subsequent images and can generate a reconstructed image.

[0085] Figure 4An example of an image encoding method performed by a video encoding device is illustrated.

[0086] refer to Figure 4 Image coding methods can include block segmentation, intra / inter-frame prediction, transform, quantization, and entropy coding processes. For example, the current image can be segmented into multiple blocks. A prediction block for the current block can be generated through intra / inter-frame prediction. A residual block for the current block can be generated by subtracting the input block from the prediction block. Subsequently, a coefficient block, i.e., the transform coefficients of the current block, can be generated by transforming the residual block. The transform coefficients can be quantized and entropy-coded and stored in a bitstream.

[0087] Figure 5 The illustration shows an example of a video encoding method performed by a decoding device.

[0088] refer to Figure 5 Image coding methods can include entropy decoding, inverse quantization, inverse transform, and intra / inter-frame prediction processes. For example, a decoding device can perform the reverse of the coding methods mentioned above. Specifically, quantized transform coefficients can be obtained by entropy decoding of the bitstream. The coefficient block of the current block, i.e., the transform coefficients, can be obtained by inverse quantization of the quantized transform coefficients. The residual block of the current block can be derived by inverse transforming the transform coefficients. The reconstructed block of the current block can be derived by adding the predicted block of the current block derived through intra / inter-frame prediction to the residual block.

[0089] Furthermore, if intra-frame prediction is performed, the correlation between samples can be used, and the difference between the original block and the predicted block, i.e., the residual, can be obtained. The transformations and quantizations mentioned above can be applied to the residual. Therefore, spatial redundancy can be reduced. The coding and decoding methods using intra-frame prediction are described in detail below.

[0090] Intra-frame prediction refers to generating prediction samples for the current block based on reference samples outside the current block within the image including the current block (hereinafter, the current image). In this case, the reference samples outside the current block can refer to samples located around the current block. If intra-frame prediction is applied to the current block, neighboring reference samples that will be used for intra-frame prediction of the current block can be derived.

[0091] For example, when the size (width × height) of the current block is nW × nH, the adjacent reference samples of the current block can include samples adjacent to the left boundary and a total of 2 × nH samples adjacent to the bottom left of the current block, samples adjacent to the top boundary and a total of 2 × nW samples adjacent to the top right of the current block, and one sample adjacent to the top left of the current block. Alternatively, the adjacent reference samples of the current block can also include multiple column-adjacent samples and multiple row-adjacent samples. In addition, the adjacent reference samples of the current block can also include a total of nH samples adjacent to the right boundary of the current block of size nW × nH, a total of nW samples adjacent to the bottom boundary of the current block, and one sample adjacent to the bottom right of the current block.

[0092] In this scenario, some neighboring reference samples of the current block may not have been decoded or may be unavailable. In this case, the decoding device can configure the neighboring reference samples to be used for prediction by replacing unavailable samples with available ones. Alternatively, the neighboring reference samples to be used for prediction can be constructed by interpolating the available samples.

[0093] If deriving neighboring reference samples, then (i) the predicted sample can be derived based on the average or interpolation of the neighboring reference samples of the current block, and (ii) the predicted sample can be derived based on the reference samples present in a specific (prediction) direction relative to the predicted sample among the neighboring reference samples of the current block. (i) can be applied when the intra-frame prediction mode is non-directional or non-angular. (ii) can be applied when the intra-frame prediction mode is directional or angular.

[0094] Furthermore, prediction samples can be generated based on the prediction samples of the current block among neighboring reference samples by interpolation between a first neighboring sample located in the prediction direction of the intra-prediction mode of the current block and a second neighboring sample corresponding to the first neighboring sample. The second neighboring sample can be a sample located in the opposite direction to the prediction direction of the intra-prediction mode of the current block. This case can be referred to as Linear Interpolation Intra-Prediction (LIP). Additionally, temporal prediction samples of the current block can be derived based on filtered neighboring reference samples. Prediction samples of the current block can be derived by weighted summing of at least one reference sample derived based on the intra-prediction mode and the temporal prediction samples (i.e., unfiltered neighboring reference samples) among existing neighboring reference samples. This case can be referred to as Position-Related Intra-Prediction (PDCP). Simultaneously, post-filtering of the derived prediction samples can be performed if necessary.

[0095] Specifically, the intra-frame prediction process may include an intra-frame prediction mode determination step, a neighboring reference sample derivation step, and a prediction sample derivation step based on the intra-frame prediction mode. Furthermore, if necessary, a post-filtering step may be performed on the derived prediction samples.

[0096] Figure 6 An example of an image coding method based on intra-frame prediction is illustrated, and Figure 7 An intra-frame predictor within a coding device is schematically illustrated. Figure 7 The intra-frame predictor within the coding device can be applied equivalently or in a corresponding manner. Figure 2 The intra-frame predictor 222 of the coding device 200.

[0097] refer to Figure 6 and 7 S600 can be executed by the intra-predictor 222 of the encoding apparatus. S610 can be executed by the residual processor 230 of the encoding apparatus. Specifically, S610 can be executed by the subtractor 231 of the encoding apparatus. In S620, the intra-predictor 222 can derive prediction information, and the entropy encoder 240 can encode the prediction information. In S620, the residual processor 230 can derive residual information, and the entropy encoder 240 can encode the residual information. The residual information is information related to the residual samples. The residual information may include information related to the transform coefficients quantized for the residual samples. As described above, the residual samples can be derived into transform coefficients by the transformer 232 of the encoding apparatus. The transform coefficients can be derived into quantized transform coefficients by the quantizer 233. The entropy encoder 240 can encode the information related to the quantized transform coefficients through the residual coding process.

[0098] The coding device can perform intra-prediction for the current block (S600). The coding device can derive the intra-prediction mode for the current block, derive neighboring reference samples for the current block, and generate prediction samples within the current block based on the intra-prediction mode and neighboring reference samples. In this case, the intra-prediction mode determination, neighboring reference sample derivation, and prediction sample generation processes can be performed, or any one of these processes can be performed before the other.

[0099] In one embodiment, the intra-predictor 222 of the encoding apparatus may include a prediction mode determiner 223, a reference sample deriver 224, and a prediction sample deriver 225. The prediction mode determiner 223 determines the intra-prediction mode for the current block. The reference sample deriver 224 derives neighboring reference samples for the current block. The prediction sample deriver 225 derives prediction samples for the current block. Additionally, although not shown, the intra-predictor 222 may further include a prediction sample filtering unit (not shown) if the prediction sample filtering process, described subsequently, is performed. The encoding apparatus may determine the mode applicable to the current block from among a plurality of intra-prediction modes. The encoding apparatus may compare the RD costs used for the intra-prediction modes and determine the optimal intra-prediction mode for the current block.

[0100] As described above, the encoding device can perform a prediction sample filtering process. Prediction sample filtering can be referred to as post-filtering. Some or all prediction samples can be filtered through the prediction sample filtering process. The prediction sample filtering process can be omitted depending on the situation.

[0101] The encoding device can generate residual samples for the current block based on the (filtered) prediction samples (S610). The encoding device can encode image information including prediction mode information indicating the intra-frame prediction mode and residual information related to the residual samples (S620). The encoded image information can be output in the form of a bitstream. The output bitstream can be transmitted to the decoding device via a network through a storage medium.

[0102] As described above, the encoding device can generate a reconstructed image (including reconstructed samples and reconstructed blocks) based on the predicted samples and residual samples. This is to derive the same prediction result by the encoding device as the prediction result performed in the decoding device. The reason for this is to improve encoding efficiency. Furthermore, as mentioned above, the in-loop filtering process can be further applied to the reconstructed image.

[0103] Figure 8 An example of a video coding method based on intra-frame prediction is illustrated, and Figure 9 An intra-frame predictor within a decoding device is schematically shown. Figure 9 The intra-frame predictor within the decoding device can be applied equivalently or in a corresponding manner. Figure 3 The intra-frame predictor 331 of the decoding device 300.

[0104] refer to Figure 8 and 9 The decoding device can perform operations corresponding to those performed in the encoding device. The decoding device can perform predictions for the current block and derive prediction samples based on the received prediction information.

[0105] S800 to S820 can be executed by the intra-frame predictor 331 of the decoding device. In S830, residual information can be obtained from the bitstream by the entropy decoder 310 of the decoding device. The residual processor 320 of the decoding device can derive residual samples for the current block based on the residual information. Specifically, the inverse quantizer 321 of the residual processor can derive transform coefficients by performing inverse quantization based on the quantized transform coefficients derived from the residual information. The inverse transformer 322 of the residual processor 320 can derive residual samples for the current block by performing inverse transform on the transform coefficients. S840 can be executed by the adder 340 or the reconstructor of the decoding device.

[0106] The decoding device can derive the intra-prediction mode for the current block based on the received prediction mode information (S800). The decoding device can derive neighboring reference samples for the current block (S810). The decoding device can generate prediction samples within the current block based on the intra-prediction mode and neighboring reference samples (S820). In this case, the decoding device can perform a prediction sample filtering process. Prediction sample filtering can be referred to as post-filtering. Some or all prediction samples can be filtered through the prediction sample filtering process. The prediction sample filtering process can be omitted depending on the situation.

[0107] The decoding device can generate residual samples for the current block based on the received residual information (S830). The decoding device can generate reconstruction samples for the current block based on the (filtered) prediction samples and residual samples, and can generate a reconstruction image based on the reconstruction samples (S840).

[0108] In one embodiment, the intra-predictor 331 of the decoding apparatus may include a prediction mode determiner 333, a reference sample deriver 334, and a prediction sample deriver 335. The prediction mode determiner 333 may determine the intra-prediction mode for the current block based on prediction mode information received from the prediction mode determiner 223 of the encoding apparatus. The reference sample deriver 334 may derive neighboring reference samples for the current block. The prediction sample deriver 335 may derive prediction samples for the current block. Additionally, although not shown, if a prediction sample filtering process is performed, the intra-predictor 331 may further include a prediction sample filtering unit (not shown).

[0109] Simultaneously, during intra-frame prediction, prediction mode information can be determined based on whether the most probable mode (MPM) is applied to the current block. For example, prediction mode information may include flag information (e.g., `prev_intra_luma_pred_flag`) indicating whether the most probable mode (MPM) or a remaining mode is applied to the current block. If the MPM is applied to the current block, the prediction mode information may further include index information (e.g., `mpm_idx`) indicating one of the intra-frame prediction mode candidates (MPM candidates). In this case, the intra-frame prediction mode candidates (MPM candidates) can be configured as an MPM candidate list or an MPM list. Furthermore, if the MPM is not applied to the current block, the prediction mode information may further include remaining mode information (e.g., `rem_intra_luma_pred_mode`) indicating one of the remaining intra-frame prediction modes besides the intra-frame prediction mode candidates (MPM candidates). The decoding device can determine the intra-frame prediction mode of the current block based on the prediction mode information. In this case, the prediction mode information can be encoded / decoded using the encoding method described later. For example, prediction pattern information can be encoded / decoded based on truncated (Rice) binary code using entropy coding (e.g., CABAC, CAVLC).

[0110] Furthermore, if intra-prediction is applied, the intra-prediction modes of adjacent blocks can be used to determine the intra-prediction mode applied to the current block when determining the prediction mode information. For example, the decoding device can derive the most probable mode (MPM) candidates based on the intra-prediction modes of the left block and the previous block, and can select one of the MPM candidates based on the MPM index (e.g., mpm_idx). Alternatively, the decoding device can select one of the remaining intra-prediction modes not included in the MPM candidates based on the remaining intra-prediction mode information (e.g., rem_intra_luma_pred_mode). The MPM index can be signaled in the form of the mpm_idx syntax element. The remaining intra-prediction mode information can be signaled in the form of the rem_intra_luma_pred_mode syntax element. For example, the remaining intra-prediction mode information can indicate one of the remaining intra-prediction modes that is not included in the MPM candidates and is indexed in order of prediction mode number among all intra-prediction modes.

[0111] Intra-prediction modes can include non-directional (or non-angular) intra-prediction modes and directional (or angular) intra-prediction modes. For example, the HEVC standard uses intra-prediction modes that include 2 non-directional prediction modes and 33 directional prediction modes. Non-directional prediction modes can include planar intra-prediction modes (i.e., mode 0) and DC intra-prediction modes (i.e., mode 1). Directional prediction modes can include intra-prediction modes 2 through 34. Planar intra-prediction modes can be referred to as planar modes, and DC intra-prediction modes can be referred to as DC modes.

[0112] Alternatively, in order to obtain a given edge orientation proposed in a natural video, such as Figure 10 Similar to the previous example, directional intra-prediction modes can be extended from the existing 33 modes to 65 modes. In this case, the intra-prediction modes can include 2 non-directional intra-prediction modes and 65 directional intra-prediction modes. Non-directional intra-prediction modes can include planar intra-prediction modes (i.e., mode 0) and DC intra-prediction modes (i.e., mode 1). Directional intra-prediction modes can include intra-prediction modes 2 through 66. The extended directional intra-prediction modes can be applied to blocks of all sizes and can be applied to both the luma and chroma components. However, this is an example, and the embodiments in this document can be applied to cases with different numbers of intra-prediction modes. Intra-prediction mode 67 can be further used, depending on the situation. Intra-prediction mode 67 can indicate a linear model (LM) mode.

[0113] Figure 10 The diagram illustrates 65 directional intra-frame prediction modes.

[0114] refer to Figure 10 Based on intra-prediction mode 34, which has a left-top diagonal prediction direction, the mode can be divided into intra-prediction modes with horizontal direction and intra-prediction modes with vertical direction. Figure 10 In the diagram, H and V represent horizontal and vertical orientations, respectively. Each of the numbers -32 to 32 indicates a displacement of 1 / 32 unit at the sample grid position. Intra-prediction modes 2 to 33 are horizontally oriented, and intra-prediction modes 34 to 66 are vertically oriented. Intra-prediction modes 18 and 50 indicate horizontal and vertical intra-prediction modes, respectively. Intra-prediction mode 2 can be referred to as the lower-left diagonal intra-prediction mode, mode 34 as the upper-left diagonal intra-prediction mode, and mode 66 as the upper-right diagonal intra-prediction mode.

[0115] As mentioned above, typically, if block segmentation of an image is performed, the current block to be encoded and its neighboring blocks have similar image characteristics. Therefore, it is highly likely that the current block and its neighboring blocks will have the same or similar intra-prediction modes. Based on these image characteristics, the intra-prediction mode of the current block can be derived using the intra-prediction modes of the neighboring blocks. This can be called the most probable mode (MPM). That is, MPM can refer to the mode used to improve coding efficiency by considering the similarity between the current block and its neighboring blocks when performing intra-prediction mode coding.

[0116] For example, the encoding / decoding device can be configured with a list of most probable modes (MPMs) for the current block. The MPM list can be designated as an MPM candidate list. In this case, the MPM list including a given MPM candidate can be configured by considering the complexity of generating the MPM list. For example, the MPM list can include 3, 5, or 6 MPM candidates. In one embodiment, the MPM list can include MPM candidates derived based on the intra-prediction modes of neighboring blocks, derived intra-prediction modes, and / or a default intra-prediction mode. In this case, when deriving MPM candidates from neighboring blocks, the encoding / decoding device can derive the intra-prediction modes of neighboring blocks by searching the neighboring blocks of the current block in a specific order, and can use the intra-prediction modes of neighboring blocks as MPM candidates based on the derived order. For example, neighboring blocks can include at least one of the left neighboring block, top neighboring block, bottom-left neighboring block, top-right neighboring block, and top-left neighboring block of the current block. If the intra-prediction mode of the current block is not included among the MPM candidates in the MPM list, the remaining modes can be used. In this scenario, the remaining mode is the mode that uses all remaining intra-prediction modes except for the MPM candidate, and the remaining intra-prediction mode information can be encoded and signaled. The remaining intra-prediction mode information can be information indicating the intra-prediction mode applied to the current block from the remaining intra-prediction modes excluding the MPM candidate. For example, if 67 intra-prediction modes are used, the remaining intra-prediction mode information can include 6-bit syntax elements (e.g., the `rem_intra_luma_pred_mode` syntax element).

[0117] As mentioned above, the HEVC standard uses 35 intra-prediction modes when performing intra-prediction. In this case, the configuration includes an MPM list of 3 MPM candidates. In this scenario, the 3 MPM candidates can be derived based on the intra-prediction modes of neighboring blocks F and G. The neighboring blocks of the current block, including neighboring blocks F and G, can be the same as the aforementioned neighboring blocks.

[0118] Figure 11 The diagram shows the adjacent blocks of the current block.

[0119] refer to Figure 11 The adjacent blocks of the current block can include adjacent block A, adjacent block B, adjacent block C, adjacent block D, adjacent block E, adjacent block F and / or adjacent block G.

[0120] In this scenario, adjacent block A can indicate the adjacent block to the upper left of the current block's upper-left sample position. Adjacent block B can indicate the adjacent block above the current block's upper-right sample position. Adjacent block C can indicate the adjacent block to the upper right of the current block's upper-right sample position. Adjacent block D can indicate the adjacent block to the left of the current block's lower-left sample position. Adjacent block E can indicate the adjacent block to the lower left of the current block's lower-left sample position. Adjacent block G can indicate the adjacent block above the current block's upper-left sample position. Adjacent block F can indicate the adjacent block to the left of the current block's upper-left sample position.

[0121] For example, if the size of the current block is W×H, and the x and y components of the top-left sample position of the current block are 0, then the adjacent block A can be a block that includes the sample at coordinates (-1, -1), the adjacent block B can be a block that includes the sample at coordinates (W-1, -1), the adjacent block C can be a block that includes the sample at coordinates (W, -1), the adjacent block D can be a block that includes the sample at coordinates (-1, H-1), the adjacent block E can be a block that includes the sample at coordinates (-1, H), the adjacent block F can be a block that includes the sample at coordinates (-1, 0), and the adjacent block G can be a block that includes the sample at coordinates (0, -1).

[0122] According to the HEVC standard, three MPM candidates can be derived based on the intra prediction modes of neighboring block F and neighboring block G. For example, the intra prediction modes of neighboring block F and neighboring block G can be derived. Furthermore, in the following cases, the intra prediction modes of neighboring block F or neighboring block G can be derived as DC intra prediction modes.

[0123] 1) If adjacent block F or adjacent block G is unavailable

[0124] 2) If neighboring block F or neighboring block G is not encoded by intra-predictive mode (i.e., if neighboring block F or neighboring block G is not an intra-coded block)

[0125] 3) If neighboring block F or neighboring block G is outside the current coding tree unit (CTU)

[0126] If, as described above, the intra-prediction mode of adjacent block F or the intra-prediction mode of adjacent block G is determined, then three MPM candidates can be derived as shown in Table 1.

[0127] [Table 1]

[0128] Table 1 illustrates a schematic algorithm (i.e., pseudocode) for configuring the MPM list. Referring to Table 1, it can be determined whether the intra-prediction mode of adjacent block F is the same as that of adjacent block G.

[0129] If the intra-prediction mode of neighboring block F is the same as that of neighboring block G, and the mode number of the intra-prediction mode of neighboring block F is less than 2, then the MPM list of the current block can be exported as MPM list 1. That is, if the intra-prediction mode of neighboring block F is the same as that of neighboring block G, and the intra-prediction mode of neighboring block F is either an intra-prediction mode with mode number 0 or an intra-prediction mode with mode number 1, then the MPM list of the current block can be exported as MPM list 1. In this case, MPM list 1 can indicate an MPM list configured with MPM candidates {F, F-1, F+1}. F can indicate the intra-prediction mode of neighboring block F. F-1 can indicate an intra-prediction mode whose value is the mode number obtained by subtracting 1 from the mode number of the intra-prediction mode of neighboring block F. F+1 can indicate an intra-prediction mode whose value is the mode number obtained by adding 1 to the mode number of the intra-prediction mode of neighboring block F. For example, if the intra prediction mode of the adjacent block F is the intra prediction mode with mode number N, then MPM list 1 can be configured with an MPM list that includes the intra prediction mode with mode number N, the intra prediction mode with mode number N-1, and the intra prediction mode with mode number N+1 as MPM candidates.

[0130] Furthermore, if the intra-prediction mode of adjacent block F is the same as that of adjacent block G, and the mode number of the intra-prediction mode of adjacent block F is not less than 2, then the MPM list of the current block can be exported as MPM list 2 (MPMlist2).

[0131] Furthermore, if the intra-prediction mode of adjacent block F is different from that of adjacent block G, and the intra-prediction modes of adjacent block F and adjacent block G are not planar intra-prediction modes, then the MPM list of the current block can be exported as MPM list 3.

[0132] Furthermore, if the intra-prediction mode of adjacent block F is different from that of adjacent block G, and the sum of the mode number of the intra-prediction mode of adjacent block F and the mode number of the intra-prediction mode of adjacent block G is less than 2, then the MPM list of the current block can be exported as MPM list 4.

[0133] Furthermore, if the intra-prediction mode of adjacent block F is different from that of adjacent block G, and at least one of the intra-prediction modes of adjacent block F and adjacent block G is a planar intra-prediction mode, and the sum of the mode number of the intra-prediction mode of adjacent block F and the mode number of the intra-prediction mode of adjacent block G is not less than 2, then the MPM list of the current block can be exported as MPM list 5.

[0134] Simultaneously, as the number of intra-prediction modes increases, the number of MPM candidates needs to increase. Therefore, the number of MPM candidates can vary depending on the number of intra-prediction modes. Generally, the number of MPM candidates can increase as the number of intra-prediction modes increases. However, the number of MPM candidates does not always increase with the number of intra-prediction modes. For example, if there are 35 intra-prediction modes or 67 intra-prediction modes, various numbers of MPM candidates (such as 3, 4, 5, and 6) can exist depending on the design.

[0135] For example, a 6-MPM list configuration can be performed. That is, an MPM list including 6 MPM candidates can be configured. For example, in a 6-MPM list configuration, a process of searching for the positions of various neighboring blocks and a continuous pruning check process for excluding the same intra-frame prediction mode can be performed. For example, the order of the 6 MPM candidates can be configured as follows: Neighboring block D, neighboring block B, planar intra-prediction mode, DC intra-prediction mode, neighboring block E, neighboring block C, and neighboring block A.

[0136] That is, adjacent blocks can be exported as MPM candidates in the following order: intra-prediction mode of adjacent block D, intra-prediction mode of adjacent block B, planar intra-prediction mode, DC intra-prediction mode, intra-prediction mode of adjacent block E, intra-prediction mode of adjacent block C, and intra-prediction mode of adjacent block A. If the prediction mode is the same as the already exported intra-prediction mode, it does not need to be exported as an MPM candidate.

[0137] Furthermore, if the MPM list does not include MPM candidates with the maximum number of candidates (i.e., when the number of derived MPM candidates is less than the maximum number), the directional intra-prediction modes adjacent to the derived MPM candidates and the predefined default intra-prediction mode can be considered as MPM candidates, and a pruning check process can be performed. In this case, the directional intra-prediction modes adjacent to the MPM candidates can indicate the intra-prediction mode with the mode number adjacent to the MPM candidates. Neighbor block search and continuous pruning checks have advantages in reducing bit transfer rate, but increase the number of hardware operation cycles for MPM list configuration per block. In the worst case, a 3840×2160 4K image can be divided into 4×4 blocks for intra-prediction. In this case, the increased hardware operation cycles for each of the 4×4 blocks can be considered significantly in terms of throughput. Meanwhile, if the intra-prediction mode of a neighboring block is known through inter-frame prediction coding, the intra-prediction mode of that neighboring block can be used for MPM list configuration.

[0138] As described above, when configuring the MPM list, the encoding device can determine the optimal intra-prediction mode by simultaneously optimizing bit rate and distortion, and can encode the determined optimal intra-prediction mode into a bitstream. The decoding device can parse (decode) the intra-prediction modes included in the bitstream and can perform intra-prediction based on the parsed intra-prediction modes. However, efficient intra-prediction mode encoding is necessary to minimize the signaling overhead caused by the increase in the number of intra-prediction modes. Both the encoding and decoding devices use adjacent intra-prediction modes of the coded blocks to configure the MPM list. In this case, when the optimal intra-prediction mode is one of the candidates in the MPM list, the overhead can be minimized by signaling the MPM index. Depending on the algorithm, the length of the MPM list and the method of configuring the MPM list may differ.

[0139] In this scenario, if 67 intra-prediction modes are used for intra-prediction, an MPM list including the existing three MPM candidates may be insufficient to represent the diversity of multiple intra-prediction modes. Furthermore, a 6-MPM list configuration scheme, which includes neighbor block search and pruning checks, may impact throughput due to its complexity. Therefore, the embodiments in this document propose an efficient MPM list configuration method that strikes a proper balance between complexity and coding efficiency.

[0140] Figure 12 and 13 This is a flowchart illustrating a method for configuring the MPM list for the current block.

[0141] refer to Figure 12 and 13This allows configuring a list of k MPM candidates for the current block. In this case, k can indicate the length of the MPM list, i.e., the number of MPM candidates included in the list. According to... Figure 12 and 13 The disclosed embodiments allow configuring five valid MPM lists (MPM list 1 to MPM list 5) based on five conditions. That is, one of the five MPM lists can be derived as the MPM list for the current block based on five conditions. The MPM list can be as follows: Figure 12 The independent list shown, and can be as follows Figure 13 The list shown has partially shared parts. If using, as... Figure 13 By sharing a partial list, repetitive processes can be avoided. Five conditions can be modeled so that the sum of the probabilities of all conditions becomes 1.

[0142] Figure 14 This is a flowchart illustrating an embodiment of a method for configuring an MPM list for the current block.

[0143] Figure 14 The diagram illustrates a method for efficiently configuring a list of k MPM candidates for the current block based on its neighboring blocks. For example, k can be 6, and five conditions can be used to configure the MPM list for the current block from five valid lists. Figure 14 In the middle, L can indicate Figure 11 The intra-prediction mode of adjacent block B is shown in the diagram, while A can indicate... Figure 11 The intra-prediction mode of adjacent block D is shown. Alternatively, instead, L can indicate... Figure 11 The intra-prediction mode of adjacent block D is shown in the diagram, while A can indicate... Figure 11 The intra-frame prediction mode of adjacent block B is shown. Figure 14 In English, the symbol "!" is a negative logical operator and can refer to the "NOT" operator, which converts a non-true value to a true value and a true value to a non-true value. For example, !7 can indicate the value 0, while !0 can indicate the value 1.

[0144] refer to Figure 14 The encoding / decoding device can check condition 1 (S1400) used to determine whether L and A are the same. That is, the encoding / decoding device can determine whether L and A are the same intra-frame prediction modes. Condition 1 can be a condition used to determine whether "L == A" is true.

[0145] If L and A are the same intra-prediction mode (i.e., when condition 1 is met), the encoding / decoding device can check condition 2 (S1405) used to determine whether L (or A) is a directional intra-prediction mode. That is, the encoding / decoding device can determine whether L and A are the same and whether the mode number of L (or A) is greater than the mode number of the DC mode. Condition 2 can be a condition used to determine whether "L>DC_idx".

[0146] When condition 2 is met, the encoding / decoding device can export MPM list 1 as an MPM list for the current block (S1410). When condition 2 is not met, the encoding / decoding device can export MPM list 2 as an MPM list for the current block (S1415).

[0147] In this case, MPM list 1 can be configured as in Table 2, and MPM list 2 can be configured as in Table 3.

[0148] [Table 2]

[0149] [Table 3]

[0150] Referring to Tables 2 and 3, as in Table 2, MPM list 1 may include the first MPM candidate (mpm[0]) to the sixth MPM candidate (mpm[5]). As in Table 3, MPM list 2 may include the first MPM candidate (mpm[0]) to the sixth MPM candidate (mpm[5]). In this case, the first MPM candidate to the sixth MPM candidate may indicate the intra-prediction mode (i.e., mode number) indicated by the corresponding MPM index values ​​0 to 5. For example, the first MPM candidate indicates the intra-prediction mode assigned to mpm[0] and may be indicated by the MPM index value 0.

[0151] If L and A are not the same intra-prediction mode (i.e., when condition 1 is not met), the encoder / decoder can derive a partially shared MPM list 1 (S1420).

[0152] In this case, the partially shared MPM list 1 can be configured as shown in Table 4.

[0153] [Table 4]

[0154] Referring to Table 4, the partially shared MPM list 1 may include a first MPM candidate (mpm[0]) indicating L and a second MPM candidate (mpm[1]) indicating A. That is, if L and A are not the same, the encoding / decoding device may add L and A to the MPM list first. Therefore, as in Table 4, MPM lists 3, 4 and 5, which will be described later, may be configured to partially include the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]). In this case, when deriving the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]), the MPM index order can be determined by comparing the size of the mode numbers of L and A. For example, referring to Table 4, when L has a mode number greater than A, the max_idx value indicating L may be set to 0 and the min_idx value indicating A may be set to 1. When L has a mode number less than A, the max_idx value and the min_idx value may be set in reverse.

[0155] Next, the encoding / decoding device can check condition 3 (S1425) used to determine whether both L and A are directional intra-prediction modes. That is, the encoding / decoding device can determine whether L and A are different and whether the mode number of each of L and A is greater than the DC mode number. Condition 3 can be a condition used to determine whether "L>DC_idx and A>DC_idx".

[0156] If each of L and A has a mode number larger than the DC mode (i.e., when condition 3 is satisfied), the encoder / decoder can derive a partially shared MPM list 2 (S1440).

[0157] In this case, the partially shared MPM list 2 can be configured as shown in Table 5.

[0158] [Table 5]

[0159] Referring to Table 5, the partially shared MPM list 2 may include a third MPM candidate (mpm[2]) indicating a planar mode and a fourth MPM candidate (mpm[3]) indicating a DC mode. That is, if condition 3 is satisfied, this means that both L and A are directional intra-prediction modes. Therefore, the encoding / decoding device may add the planar mode and the DC mode (i.e., non-directional intra-prediction modes) to the MPM list as the third MPM candidate (mpm[2]) and the fourth MPM candidate (mpm[3]) after the first MPM candidate (mpm[0] = L) and the second MPM candidate (mpm[1] = A) included in the partially shared MPM list 1 described in Table 4. Therefore, the MPM lists 4 and 5, which will be described subsequently, may be configured to partially include the third MPM candidate (mpm[2]) and the fourth MPM candidate (mpm[3]) in Table 5 and the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]) in Table 4.

[0160] Next, the encoding / decoding device can check whether the difference between the mode number of L and the mode number of A is not 64 and not 1, according to condition 4 (S1445). Condition 4 can be a condition used to determine whether "diff != 64 and diff != 1".

[0161] For example, the difference (diff) between the pattern number of L and the pattern number of A can be calculated as shown in the equations in Table 5. In this case, the diff can be obtained by subtracting the smaller value from the larger value of the pattern number of L and the pattern number of A.

[0162] In this case, when condition 4 is met, the encoding / decoding device can export MPM list 5 as the MPM list for the current block (S1455). When condition 4 is not met, the encoding / decoding device can export MPM list 4 as the MPM list for the current block (S1450).

[0163] In this case, MPM list 4 can be configured as in Table 6, and MPM list 5 can be configured as in Table 7.

[0164] [Table 6]

[0165] [Table 7]

[0166] Each of the MPM lists 4 in Table 6 and MPM lists 5 in Table 7 can be configured to include the fifth MPM candidate (mpm[4]) and the sixth MPM candidate (mpm[5]) as well as the first to fourth MPM candidates (mpm[0] to mpm[3]) as described in Tables 4 and 5.

[0167] Simultaneously, if at least one of L and A is a non-directional intra-prediction mode in step S1425 (i.e., when condition 3 is not satisfied), the encoding / decoding device can check condition 5 (S1430) used to determine whether only one of L and A is a non-directional intra-prediction mode. That is, the encoding / decoding device can determine whether at least one of L and A has a DC mode number or smaller and whether the sum of the mode number of L and the mode number of A is 2 or greater. Condition 5 can be a condition used to determine whether "L+A>=2".

[0168] When the sum of the mode number of L and the mode number of A is 2 or greater (i.e., when condition 5 is met), the encoding / decoding device can export MPM list 3 as an MPM list for the current block (S1435).

[0169] In this case, MPM list 3 can be configured as shown in Table 8.

[0170] [Table 8]

[0171] Referring to Table 8, MPM list 3 can be configured to include the third to sixth MPM candidates (mpm[2] to mpm[5]) and the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]) as described in Table 4. In this case, satisfying condition 5 can mean that either L or A is a directional prediction mode and the other is a non-directional prediction mode. Therefore, MPM list 3 can include a non-directional prediction mode as the third MPM candidate (mpm[2]) after the first and second MPM candidates. For example, if one of L and A with a non-directional mode is a planar mode, the third MPM candidate (mpm[2]) can be derived as a DC mode. Alternatively, if one of L and A with a non-directional mode is a DC mode, the third MPM candidate (mpm[2]) can be derived as a planar mode.

[0172] When the sum of the mode number of L and the mode number of A is not 2 or greater (i.e., when condition 5 is not met), the encoder / decoder can derive MPM list 2 as the MPM list for the current block (S1415). In this case, both L and A can be non-directional prediction modes.

[0173] In this case, MPM list 2 can be the same as Table 3. Referring to Table 3, since both L and A are non-directional prediction modes, in MPM list 2, the planar mode and DC mode can be derived as the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]), respectively. As shown in Table 3, the remaining third MPM candidates to the sixth MPM candidates (mpm[2] to mpm[5]) can be derived.

[0174] In Tables 2 through 8, values ​​can be arithmetically added or subtracted in (Directional Intra-Prediction Mode + 1), (Directional Intra-Prediction Mode - 1), (Directional Intra-Prediction Mode + 2), (Directional Intra-Prediction Mode - 2), etc. However, in some cases, simple arithmetic calculations are not possible. For example, in non-directional intra-prediction modes, the consistency of adjacent intra-prediction modes cannot be maintained by subtracting or adding directional intra-prediction modes, or it may exceed the maximum available intra-prediction mode index. For example, the value obtained by subtracting 1 from a directional intra-prediction mode may be derived as intra-mode 1 (DC mode) indicating the DC index. By adding 1 to directional intra-prediction mode 66, 67 is obtained, thus exceeding the maximum available intra-prediction mode index 66. Therefore, modulo arithmetic (indicated by %) can be used to restrict the addition or subtraction of modes as follows. That is, it can prevent the derivation of values ​​for non-directional intra-prediction modes that indicate inconsistencies or values ​​exceeding the maximum available intra-prediction mode index. For example, the addition or subtraction of modes using modulo arithmetic can be derived as shown in Table 9.

[0175] [Table 9]

[0176] Figure 15 This is a flowchart illustrating another embodiment of a method for configuring an MPM list for the current block.

[0177] Figure 15 This paper illustrates a method for efficiently configuring a list of k MPM candidates for the current block based on its neighbors. For example, k can be 6, and five conditions can be used to configure a list of five valid MPM candidates for the current block. Figure 15 In the middle, L can indicate in Figure 11 The intra-prediction mode of adjacent block B is shown in the figure, while A can indicate the intra-prediction mode of adjacent block B. Figure 11 The intra-prediction mode of adjacent block D is shown in the figure. Alternatively, L can indicate the intra-prediction mode of adjacent block D. Figure 11 The intra-prediction mode of adjacent block D is shown in the diagram, while A can indicate... Figure 11 The intra-frame prediction mode of adjacent block B is shown. Figure 15In English, the symbol "!" is a negation logical operator that can be used to represent the "NOT" operator, which converts a non-true value to a true value and a true value to a non-true value. For example, !7 can indicate the value 0, while !0 can indicate the value 1.

[0178] In addition, according to Figure 15 The MPM list configuration method of the embodiment and Figure 14 The configuration methods are similar, but the conditions used to configure the MPM list differ. Therefore, in Figure 15 In the embodiments, the related Figure 14 The repeated detailed descriptions only describe the different configurations.

[0179] The encoding / decoding device checks condition 1 (S1500) to determine whether L and A are the same. If L and A are the same intra-prediction mode, the encoding / decoding device may check condition 2 (S1510) to determine whether L (or A) is a directional intra-prediction mode. Condition 1 may be a condition for determining whether "L == A", while condition 2 may be a condition for determining whether "L > DC_idx".

[0180] When conditions 1 and 2 are met, the encoding / decoding device can configure MPM list 1 by deriving the first MPM candidate (mpm[0]) to the sixth MPM candidate (mpm[5]) as shown in Table 2 (S1510).

[0181] Alternatively, when condition 1 is met but condition 2 is not met, the encoding / decoding device can configure MPM list 2 by deriving the first MPM candidate (mpm[0]) to the sixth MPM candidate (mpm[5]) as shown in Table 3 (S1515).

[0182] In the determination step S1500 of condition 1, if it is determined that L and A are different intra-prediction modes, the encoding / decoding device can configure the partially shared MPM list 1 by deriving the first MPM candidate (mpm[0]) indicating L and the second MPM candidate (mpm[1]) indicating A as shown in Table 4 (S1520). In addition, the encoding / decoding device can check condition 3 used to determine whether both L and A are directional intra-prediction modes (S1525), and can derive the remaining MPM candidates (mpm[2] to mpm[5]) based on whether condition 3 is satisfied. Condition 3 can be a condition used to determine whether "L > DC_idx and A > DC_idx".

[0183] In this case, when condition 3 is met, the encoder / decoder can, as shown in Table 5, derive the third MPM candidate (mpm[2]) indicating the plane mode and the fourth MPM candidate (mpm[3]) indicating the DC mode, and can configure a partially shared MPM list 2 (S1540). Furthermore, if both L and A are directional intra-prediction modes, the encoder / decoder can check condition 4 (S1545) to see if the difference (diff) between the mode numbers used to determine L and A is less than 63 and not equal to 1. Condition 4 can be a condition used to determine whether "diff < 63 and diff != 1".

[0184] When condition 4 is met, the encoding / decoding device can configure MPM list 5 (S1555) by deriving the fifth MPM candidate (mpm[4]) and the sixth MPM candidate (mpm[5]) as shown in Table 7.

[0185] Alternatively, when condition 4 is not met, the encoding / decoding device can configure MPM list 4 by deriving the fifth MPM candidate (mpm[4]) and the sixth MPM candidate (mpm[5]) as shown in Table 6 (S1550).

[0186] In this case, MPM list 4 and MPM list 5 can be configured to include the fifth MPM candidate (mpm[4]) and the sixth MPM candidate (mpm[5]) as well as the first to fourth MPM candidates (mpm[0] to mpm[3]) as described in Tables 4 and 5.

[0187] Simultaneously, in the determination step S1525 of condition 3, if it is determined that at least one of L and A is a non-directional intra-prediction mode, the encoding / decoding device can check condition 5 (S1530) used to determine whether only one of L and A is a non-directional intra-prediction mode. That is, the encoding / decoding device can determine whether at least one of L and A is a DC mode number or smaller, and whether the sum of the mode number of L and the mode number of A is 2 or greater. Condition 5 can be a condition used to determine whether "L+A>=2".

[0188] When the sum of the mode number of L and the mode number of A is 2 or greater (i.e., when condition 5 is met), the encoder / decoder can configure MPM list 3 (S1535) by deriving the third MPM candidate (mpm[2]) and the sixth MPM candidate (mpm[5]) as shown in Table 8.

[0189] In this case, MPM list 3 can be configured to include the remaining MPM candidates (mpm[2] to mpm[5]) and the first MPM candidate (mpm[0]) and the second MPM candidate (mpm[1]) as described in Table 4.

[0190] When the sum of the mode number of L and the mode number of A is not 2 or greater (i.e., when condition 5 is not met), the encoding / decoding device can configure MPM list 2 (S1515) by deriving MPM candidates (mpm[0] to mpm[5]) as shown in Table 3.

[0191] The method for configuring the MPM list as described in the embodiments mentioned above can be executed in the encoding / decoding apparatus. In this case, when configuring the MPM list, the encoding apparatus can derive the optimal intra-prediction mode to be applied to the current block and determine whether the derived optimal intra-prediction mode belongs to an MPM list that includes MPM candidates configured using a method such as the method described in the embodiments mentioned above. If the intra-prediction mode of the current block belongs to an MPM list that includes MPM candidates, the encoding apparatus can encode the MPM flag and the MPM index. In this case, the MPM flag can indicate whether the intra-prediction mode of the current block belongs to the MPM list (i.e., an MPM candidate). The MPM index can indicate which MPM mode among the MPM candidates included in the MPM list is applied as the intra-prediction mode of the current block. Conversely, if the intra-prediction mode of the current block does not belong to an MPM list that includes MPM candidates, the encoding apparatus can encode the intra-prediction mode of the current block.

[0192] The decoding device can configure the MPM list by applying the same method as the encoding device in the embodiments mentioned above. Furthermore, the decoding device can receive an MPM flag from the encoding device and can use the MPM flag to identify whether the intra-prediction mode applied to the current block is included in the MPM list (i.e., MPM candidates). If the intra-prediction mode applied to the current block is included in the MPM list (i.e., MPM candidates), the decoding device can use the MPM index received from the encoding device to derive the intra-prediction mode applied to the current block. Conversely, if the intra-prediction mode applied to the current block is not included in the MPM list (i.e., MPM candidates), the decoding device can use the prediction mode index (or remaining prediction mode index; remaining mode information) indicating a specific prediction mode among the remaining prediction modes other than the MPM candidates to derive the intra-prediction mode applied to the current block.

[0193] The following describes a method for configuring an extended MPM list with similar complexity by comparing it with an MPM list containing three MPM candidates. An extended MPM list refers to an MPM list containing three or more MPM candidates, such as three, four, five, or six. In the proposed method described below, an embodiment is described using two adjacent intra-prediction modes (left adjacent intra-prediction mode and top adjacent intra-prediction mode) to generate an MPM list containing six MPM candidates. In this case, the left adjacent intra-prediction mode (LEFT) can indicate... Figure 11 The intra-prediction mode of adjacent block D in the frame, while the upper adjacent intra-prediction mode (ABOVE) can indicate Figure 11 Intra-prediction mode of adjacent block B in the frame.

[0194] The reason for using three MPM candidates when configuring an extended MPM list is the advantages in terms of simplicity and throughput. However, existing methods using six MPM candidates increase complexity because they involve searching for the positions of neighboring blocks, continuous pruning, steps for generating the MPM list, line buffer requirements, and resolution dependencies. Therefore, a method that achieves advantages in both complexity and throughput is proposed, as in the method using three MPM candidates.

[0195] In one embodiment, the MPM list can be configured based on an algorithm (i.e., pseudocode) such as Table 10.

[0196] Table 10

[0197] Referring to Table 10, the MPM list for the current block can be generated based on LEFT and ABOVE (i.e., adjacent intra-prediction modes). In this case, LEFT can indicate... Figure 11 The intra-prediction mode of adjacent block D in the frame, and ABOVE can indicate Figure 11 The intra-prediction mode of neighboring block B in the current block. Furthermore, neighboring block D can indicate the bottommost left neighboring block among the left neighboring blocks adjacent to the left of the current block. Neighboring block B can indicate the rightmost upper neighboring block among the upper neighboring blocks adjacent to the current block.

[0198] Specifically, the intra-prediction modes for LEFT and ABOVE can be derived. Furthermore, based on the intra-prediction modes for LEFT and ABOVE, the MPM list (i.e., MPM candidates) for the current block can be set to MPM_ordering_0. In this case, if LEFT and ABOVE are the same and the mode number of LEFT is greater than or equal to the DC mode, the MPM list (i.e., MPM candidates) for the current block can be set to MPM_ordering_1. Alternatively, if LEFT and ABOVE are not the same and the mode number of LEFT is greater than the mode number of the DC mode and the mode number of ABOVE is greater than the mode number of the DC mode, the MPM list (i.e., MPM candidates) for the current block can be set to MPM_ordering_2. Alternatively, if LEFT and ABOVE are not the same, at least one of the mode numbers of LEFT and ABOVE is not greater than the mode number of DC mode, and the sum of the mode numbers of LEFT and ABOVE is greater than the mode number of DC mode, then the MPM list (i.e., MPM candidates) of the current block can be set to MPM_ordering_3.

[0199] In this case, MPM_ordering_0, MPM_ordering_1, MPM_ordering_2, or MPM_ordering_3 may have been configured as follows: Figures 12 to 15 The MPM candidates are included in a predetermined order as described in the document.

[0200] Furthermore, if one of the remaining intra-prediction modes besides the derived MPM candidates is an intra-prediction mode applied to the current block as described above, then MPM coding for the current block can be performed based on the remaining mode information. This remaining mode information can be encoded / decoded by applying truncated binary (TB) coding. If TB coding is applied, the remaining mode information can be used to variably generate bits from 1 to 5 bits and can undergo binarization. Therefore, by performing TB binarization when deriving the remaining mode information, the number of bits can be reduced, and coding efficiency can be improved.

[0201] In another embodiment, the MPM list can be configured based on an algorithm such as Table 11 (i.e., spec).

[0202] [Table 11]

[0203] Referring to Table 11, candidate intra-prediction modes can be derived based on neighboring blocks of the current block. A list of MPMs for the current block can be configured based on these candidate intra-prediction modes. Candidate intra-prediction modes can include candidate intra-prediction mode A and candidate intra-prediction mode B.

[0204] For example, candidate intra-prediction mode A can be set to planar intra-prediction mode when at least one of the conditions subsequently described is true (i.e., when at least one of the conditions subsequently described is satisfied).

[0205] - Adjacent block A is unavailable

[0206] - Intra-frame prediction was not applied to adjacent block A

[0207] In this case, adjacent block A can be the left adjacent block of the current block. The left adjacent block can be the bottommost left adjacent block among the left adjacent blocks adjacent to the current block. For example, if the size of the current block is cbWidth × cbHeight and the x and y components at the top-left sample position of the current block are xCb and yCb, then adjacent block A can be a block that includes the sample at coordinates (xCb-1, yCb + cbHeight-1). Simultaneously, adjacent block A can indicate... Figure 11 The adjacent block D.

[0208] When all conditions are false (i.e., when all conditions are not met), candidate intra-prediction mode A can be set as the intra-prediction mode of neighboring block A.

[0209] Furthermore, for example, candidate intra-prediction mode B can be set to planar intra-prediction mode when at least one of the conditions subsequently described is true (i.e., when at least one of the conditions subsequently described is satisfied).

[0210] - Adjacent block B is unavailable

[0211] - Intra-frame prediction was not applied to adjacent block B

[0212] -yCb-1 is less than ((yCb>>CtbLog2SizeY)< <CtbLog2SizeY)

[0213] In this case, the adjacent block B may be an upper adjacent block of the current block. The upper adjacent block may be the rightmost upper adjacent block among the upper adjacent blocks adjacent to the current block. For example, if the size of the current block is cbWidth×cbHeight and the x component and y component at the top-left sample position of the current block are xCb and yCb, the adjacent block B may be a block including a sample at the coordinate (xCb+cbWidth-1, yCb-1). Meanwhile, CtbLog2SizeY may indicate the size of the current CTU, and ((yCb>>CtbLog2SizeY)<<CtbLog2SizeY) may indicate the coordinate at the upper boundary of the current CTU. That is, the case where yCb-1 is less than ((yCb>>CtbLog2SizeY)<<CtbLog2SizeY) may indicate a case where the adjacent block B is out of the range of the current CTU. That is, the above-mentioned condition may indicate a case where the adjacent block B is out of the range of the current CTU.

[0214] When none of the conditions are true (that is, when all the conditions are not satisfied), the candidate intra prediction mode B may be set to the intra prediction mode of the adjacent block B.

[0215] If the candidate intra prediction modes have been derived, the MPM list of the current block may be configured in the same manner as the first MPM list. The first MPM list may be configured with a first MPM candidate indicating the candidate intra prediction mode A, a second MPM candidate indicating an intra prediction mode of a value obtained by performing an operation on the candidate intra prediction mode A using a negation logical operator, a third MPM candidate indicating intra prediction mode No. 50, a fourth MPM candidate indicating intra prediction mode No. 18, a fifth MPM candidate indicating intra prediction mode No. 46, and a sixth MPM candidate indicating intra prediction mode No. 54.

[0216] Thereafter, it may be determined whether the candidate intra prediction mode B and the candidate intra prediction mode A are the same.

[0217] In this case, if candidate intra-prediction mode B and candidate intra-prediction mode A are the same, it can be determined whether candidate intra-prediction mode A is greater than 1. When candidate intra-prediction mode A is greater than 1, the MPM list of the current block can be configured in the same way as the second MPM list. The second MPM list can be configured with a first MPM candidate indicating candidate intra-prediction mode A, a second MPM candidate indicating a plane intra-prediction mode, a third MPM candidate indicating a DC intra-prediction mode, a fourth MPM candidate indicating an intra-prediction mode derived as 2 + ((candIntraPredModeA + 62) % 65), a fifth MPM candidate indicating an intra-prediction mode derived as 2 + ((candIntraPredModeA - 1) % 65), and a sixth MPM candidate indicating an intra-prediction mode derived as 2 + ((candIntraPredModeA + 61) % 65).

[0218] Otherwise, if candidate intra-prediction mode B is different from candidate intra-prediction mode A, the first and second MPM candidates for the current block can be derived first. The first MPM candidate can be derived as candidate intra-prediction mode A, and the second MPM candidate can be derived as candidate intra-prediction mode B. Furthermore, biggerIdx can be set. When the first MPM candidate is greater than the second MPM candidate, biggerIdx can be derived as 0. When the first MPM candidate is not greater than the second MPM candidate, biggerIdx can be derived as 1.

[0219] Next, it can be determined whether candidate intra-prediction mode A and candidate intra-prediction mode B are greater than 1 (i.e., it can be determined whether the mode number of candidate intra-prediction mode A and the mode number of candidate intra-prediction mode B are greater than 1). In this case, when candidate intra-prediction mode A and candidate intra-prediction mode B are greater than 1, the third MPM candidate and the fourth MPM candidate of the current block can be derived. The third MPM candidate can be derived as a planar intra-prediction mode, and the fourth MPM candidate can be derived as a DC intra-prediction mode.

[0220] Next, it can be determined whether the difference (diff) between the MPM candidate indicated by the MPM index with the value of biggerIdx and the MPM candidate indicated by the MPM index with the value obtained by performing an operation on biggerIdx using the negation logical operator (i.e., !biggerIdx) is neither 64 nor 1.

[0221] When the difference is neither 64 nor 1, the fifth and sixth MPM candidates for the current block can be derived. The fifth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] + 62) % 65). The sixth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] – 1) % 65).

[0222] Otherwise, if the difference is 64 or 1, the fifth and sixth MPM candidates for the current block can be derived. The fifth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] + 61) % 65). The sixth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx]) % 65).

[0223] Simultaneously, when the sum of candidate intra-prediction mode A and candidate intra-prediction mode B is greater than or equal to 2, the third, fourth, fifth, and sixth MPM candidates for the current block can be derived. The third MPM candidate can be derived using a negation logical operator as an intra-prediction mode whose value is obtained by performing an operation on the MPM candidate indicated by the MPM index having a value obtained by performing an operation on biggerIdx using the negation logical operator (i.e., !biggerIdx). The fourth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] + 62) % 65). The fifth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] - 1) % 65). The sixth MPM candidate can be derived as an intra-prediction mode of 2 + ((candModeList[biggerIdx] + 61) % 65).

[0224] In another embodiment, the MPM list can be configured using a method different from the algorithm presented in Table 11. An algorithm such as the one in Table 12 (i.e., the spec) can be used to configure the MPM list.

[0225] [Table 12]

[0226] Referring to Table 12, the conditions used to derive the MPM list differ from those in Table 11, and the MPM candidates derived based on each condition also differ from those in Table 11. In this case, detailed descriptions of content that overlaps with that in Table 11 are omitted.

[0227] Referring to Table 12, candidate intra-prediction modes A and B can be derived based on the neighboring blocks A and B of the current block. In this case, the MPM list can be configured differently based on whether predetermined conditions are met, using candidate intra-prediction mode A and candidate intra-prediction mode B.

[0228] In one embodiment, it can be determined whether candidate intra-prediction mode A and candidate intra-prediction mode B are the same. It can also be determined whether candidate intra-prediction mode A or candidate intra-prediction mode B has a mode number larger than the DC mode (i.e., No. 1). When candidate intra-prediction mode A and candidate intra-prediction mode B are not the same, it can be determined whether both candidate intra-prediction mode A and candidate intra-prediction mode B have a mode number larger than the DC mode, or whether either of them has a mode number larger than the DC mode. In this case, when both candidate intra-prediction mode A and candidate intra-prediction mode B have mode numbers larger than the DC mode, it can be determined based on the difference in mode numbers between candidate intra-prediction mode A and candidate intra-prediction mode B (e.g., whether the difference in mode numbers between the two candidates is greater than 1 and less than 63). As shown in Table 12, MPM candidates derived in the MPM list can be determined differently depending on whether such conditions are met.

[0229] Furthermore, referring to Tables 11 and 12, modulo arithmetic is used in candidate intra-prediction mode A and candidate intra-prediction mode B to derive the remaining MPM candidates. A modulo arithmetic of 65 is used in the embodiment of Table 11, while a modulo arithmetic of 64 is used in the embodiment of Table 12. Modulo arithmetic can be applied differently depending on the algorithm, taking into account prediction performance and complexity. For example, if modulo arithmetic is used, modes with similar orientation can be derived as MPM candidates by considering the orientation of candidate intra-prediction mode A and / or candidate intra-prediction mode B, or modes whose consistency is not maintained (e.g., non-directional modes) can be derived as MPM candidates based on the modes of candidate intra-prediction mode A and / or candidate intra-prediction mode B. Therefore, because modulo arithmetic can be used to derive MPM candidates with meaningful angles (i.e., orientations), the performance of intra-prediction can be improved and efficiency can be increased.

[0230] For example, the 64-modulus arithmetic can be used to perform addition and subtraction operations on intra-prediction modes, as shown in Table 13. For example, if the 64-modulus arithmetic is applied to (intra-prediction mode + 1), (intra-prediction mode - 1), (intra-prediction mode + 2), and (intra-prediction mode - 2) described in Tables 2 to 8, the results can be calculated as shown in Table 13.

[0231] [Table 13]

[0232] As described above, an intra-prediction mode for the current block can be derived based on an MPM list including the derived MPM candidates. Prediction samples can be generated by performing predictions on the current block based on the derived intra-prediction mode.

[0233] In this scenario, when exporting the intra-prediction mode for the current block, if the MPM flag (e.g., intra_luma_mpm_flag in Tables 11 and 12) is 1, as described above, the MPM candidate indicated by the MPM index (e.g., intra_luma_mpm_idx in Tables 11 and 12) among the exported MPM candidates can be exported as the intra-prediction mode for the current block. Alternatively, if the MPM flag (e.g., intra_luma_mpm_flag in Tables 11 and 12) is 0, as described above, the residual mode (e.g., intra_luma_mpm_remainder in Tables 11 and 12) indicating one of the remaining intra-prediction modes besides the exported MPM candidates can be exported as the intra-prediction mode for the current block.

[0234] As described above, the intra-prediction mode information for the current block can be encoded and signaled as the value of the syntax element. In this case, the intra-prediction mode information is the information required for intra-prediction of the current block and may include the MPM flag, MPM index, residual mode, etc., mentioned above. When encoding the intra-prediction mode information, various binarization processes can be applied based on each syntax element.

[0235] In this context, binarization can refer to a set of bin strings used for all possible values ​​of a grammar element. Furthermore, the binarization process can refer to the process of uniquely mapping all possible values ​​of a grammar element to a set of bin strings. A bin can refer to a single-bit binary value. For example, "0" or "1" can be referred to as a single bin. A bin string can refer to a binary sequence configured with bins, and can be consecutive binary values ​​such as "01".

[0236] In one embodiment, the syntax elements and corresponding binarization of intra-frame prediction mode information can be the same as those in Table 14.

[0237] [Table 14]

[0238] Referring to Table 14, the “intra_luma_mpm_flag” syntax element representing the MPM flag can be encoded / decoded by applying a fixed-length (FL) binarization process to the “intra_luma_mpm_flag” syntax element. The “intra_luma_mpm_idx” syntax element representing the MPM index can be encoded / decoded by applying a truncated Rice (TR) binarization process to the “intra_luma_mpm_idx” syntax element. The “intra_luma_mpm_remainder” syntax element representing the residual pattern can be encoded / decoded by applying a truncated binary (TB) binarization process to the “intra_luma_mpm_remainder” syntax element.

[0239] According to the embodiments in this document, as described above, the existing 35 intra-prediction modes can be extended, thus allowing the use of 67 intra-prediction modes. In this case, the syntax elements representing the remaining modes may require 6 bits when encoding the intra-prediction mode information. However, the number of bits for representing the remaining modes can be reduced depending on the encoding method (i.e., the binarization method). That is, as shown in Table 12, when encoding the syntax elements representing the remaining modes, the number of bits can be reduced and encoding efficiency can be improved by performing truncated binary (TB) binarization.

[0240] In one embodiment, a truncated binary (TB) binarization process, such as that in Table 15, can be performed on the syntax elements representing the remaining pattern.

[0241] [Table 15]

[0242] Referring to Table 15, when the input is a syntax element (intra_luma_mpm_remainder) representing the remainder pattern, the TB binarized value of the syntax element (intra_luma_mpm_remainder) can be output based on truncated binary (TB) encoding. First, the range of possible values ​​for the syntax element (intra_luma_mpm_remainder) can be determined. The range of the syntax element (intra_luma_mpm_remainder) can be between 0 and cMax. cMax indicates the maximum value of the syntax element (intra_luma_mpm_remainder) and can have a value greater than or equal to 1. The TB binarized value (TB bin string) of the syntax element (intra_luma_mpm_remainder) can be derived based on the algorithm in Table 15. For example, in Table 14, in the case of the syntax element (intra_luma_mpm_remainder) representing the remainder pattern, cMax is 60. Therefore, 6 bits can be used to represent the syntax element (intra_luma_mpm_remainder). However, if binarization encoding is performed on the value of the syntax element (intra_luma_mpm_remainder) representing the residual pattern based on TB encoding such as the algorithm in Table 15, binarization encoding can be performed using fewer than 6 bits based on the value of the syntax element (intra_luma_mpm_remainder). For example, the syntax element (intra_luma_mpm_remainder) representing the residual pattern can be used to variably generate bits from 1 to 5 bits based on the value of the syntax element, and can be encoded using TB encoding.

[0243] Figure 16 This is a schematic diagram of a flowchart illustrating an encoding method that can be performed by an encoding device according to an embodiment of this document.

[0244] It can be done Figure 2 The coding device 200 disclosed in the article performs... Figure 16 The method disclosed in the document. Specifically, it can be... Figure 2 The predictor 220 and intra-frame predictor 222 disclosed in the document are used to perform this function. Figure 16 Steps S1600 to S1640 in the above steps can be performed by... Figure 2 The entropy encoder 240 disclosed in the document is used to perform this operation. Figure 16 Step S1650 in the process. Furthermore, Figure 16 The methods disclosed herein may include the embodiments disclosed herein. Therefore, in Figure 16 In this document, detailed descriptions of content that overlaps with the embodiments mentioned above are omitted, or are only briefly described.

[0245] refer to Figure 16 The encoding device can derive a first candidate intra-prediction mode based on the first adjacent block located to the left of the current block (S1600).

[0246] In this case, adjacent blocks adjacent to the current block can include Figure 11 The adjacent blocks shown are A, B, C, D, E, F, and / or G. In this case, for example, the first adjacent block is the block to the left of the current block, and may be... Figure 11 The adjacent block D is shown. That is, the adjacent block D can indicate the bottommost left adjacent block among the adjacent blocks that are adjacent to the left boundary of the current block.

[0247] In one embodiment, if the first neighboring block is available and intra-prediction has been applied to the first neighboring block, the coding device can derive the intra-prediction mode of the first neighboring block as a first candidate intra-prediction mode. Alternatively, if the first neighboring block is unavailable or intra-prediction has not been applied to the first neighboring block, the coding device can derive the planar intra-prediction mode as a first candidate intra-prediction mode.

[0248] The coding device can derive a second candidate intra-frame prediction mode based on a second adjacent block located above the current block (S1610).

[0249] In this case, for example, the second adjacent block is the block above the current block, and can be... Figure 11 The adjacent block B shown is an example. That is, adjacent block B can indicate the rightmost upper adjacent block among the adjacent blocks adjacent to the upper boundary of the current block. For example, if the size of the current block is W×H, and the x and y components at the upper left sample position of the current block are xN and yN, then the first adjacent block can be the block containing the sample at coordinates (xN-1, H+yN-1), and the second adjacent block can be the block containing the sample at coordinates (W+xN-1, yN-1).

[0250] In one embodiment, if the second neighboring block is available, intra-prediction is applied to the second neighboring block, and the second neighboring block is included in the current CTU, the coding device can derive the intra-prediction mode of the second neighboring block as a second candidate intra-prediction mode. Alternatively, if the second neighboring block is unavailable, or intra-prediction is not applied to the second neighboring block, or the second neighboring block is not included in the current CTU, the coding device can derive the planar intra-prediction mode as a second candidate intra-prediction mode.

[0251] The coding device can configure a list of most probable modes (MPMs) for the current block based on a first candidate intra-prediction mode and a second candidate intra-prediction mode (S1620).

[0252] That is, the encoding device can derive MPM candidates including at least one of a first candidate intra-prediction mode and a second candidate intra-prediction mode, and can configure the MPM list based on the MPM candidates. In this case, the various embodiments mentioned above can be applied to the process of deriving MPM candidates and configuring the MPM list. Reference has been made above. Figures 12 to 15 The process is described in Tables 1 to 13. According to the embodiments mentioned above, MPM candidates can be derived to configure the MPM list based on a first candidate intra-prediction mode derived from a first neighboring block and a second candidate intra-prediction mode derived from a second neighboring block, depending on whether predetermined conditions are met.

[0253] In this scenario, at least one of the MPM candidates included in the MPM list can be derived by applying modular arithmetic operations to either the first or second candidate intra-prediction mode. In this implementation of the MPM list, an algorithm can be implemented such that MPM candidates with meaningful angles (i.e., directions) can be configured by considering the total number of intra-prediction modes, the direction of intra-prediction, prediction performance, complexity, etc. According to an embodiment, as shown in Table 9 or Table 13, MPM candidates can be derived by applying 64 or 65 modular arithmetic operations to either the first or second candidate intra-prediction mode.

[0254] In one embodiment, one of the MPM candidates' intra-prediction modes can be derived based on the result of calculating a first value by adding 61, 60, 0, or -1 to the larger of the mode index (mode number) of the first candidate intra-prediction mode and the mode index (mode number) of the second candidate intra-prediction mode, calculating a second value by applying a modulo-64 arithmetic operation to the first value, and adding 2 to the second value.

[0255] For example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are the same intra-prediction mode, the coding device can derive MPM candidates by determining whether the mode index of the first candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, if the first candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidates can include: intra-prediction modes derived based on the result calculated by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode + 61) and adding 2; intra-prediction modes derived based on the result calculated by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode - 1) and adding 2; and intra-prediction modes derived based on the result obtained by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode + 60) and adding 2.

[0256] Alternatively, for example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, the coding device can derive MPM candidates by determining whether either the first candidate intra-prediction mode or the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, when either the first candidate intra-prediction mode or the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidate may include: an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 61) and adding 2; an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode - 1) and adding 2; and an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 60) and adding 2.

[0257] Alternatively, for example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, the coding device can derive the MPM candidates by determining whether each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, when each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidates can be based on the difference between the mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode, including: an intra-prediction mode derived by applying a modulo-64 arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 61) and adding 2, or an intra-prediction mode derived by applying a modulo-64 arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode - 1) and adding 2.

[0258] For example, if each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode and the difference between the first mode index and the second mode index is 62, then the MPM candidate may include an intra-prediction mode derived based on the result obtained by applying a modulo 64 arithmetic operation to (first mode index + 61) and adding 2.

[0259] For another example, if each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a mode index larger than the DC intra-prediction mode and the difference between the first mode index and the second mode index is 2, then the MPM candidate may include an intra-prediction mode derived based on the result obtained by applying a 64-modulus arithmetic operation to (first mode index - 1) and adding 2.

[0260] In this scenario, the first mode index can indicate the larger mode index between the first candidate intra-prediction mode and the second candidate intra-prediction mode. The second mode index can indicate the smaller mode index between the first candidate intra-prediction mode and the second candidate intra-prediction mode.

[0261] The encoding device can include MPM candidates derived as described above in the MPM list. In this case, each MPM candidate can be sequentially indexed within the list and can be indicated by an index value in the MPM list. That is, the encoding device can indicate any one of the MPM candidates in the MPM list by signaling the index value.

[0262] The coding device can determine the intra-prediction mode of the current block (S1630).

[0263] In one embodiment, the coding device can derive an intra-prediction mode with optimal rate distortion (RD) cost by performing various intra-prediction modes on the current block, and can determine this intra-prediction mode as the intra-prediction mode for the current block. In this case, the coding device can derive the optimal intra-prediction mode for the current block based on an intra-prediction mode comprising 2 non-directional intra-prediction modes and 65 directional intra-prediction modes. (67 intra-prediction modes are referenced above.) Figure 10 The described intra-frame prediction modes are the same.

[0264] In addition, the coding device can generate information related to the intra-prediction mode of the current block. This information, which indicates the intra-prediction mode of the current block, may include MPM flag information, MPM index information, remaining mode information, etc.

[0265] In one embodiment, the encoding device can determine whether the determined intra-prediction mode of the current block is included in the MPM candidates in the MPM list, and can generate MPM flag information based on the determination result. For example, if the intra-prediction mode of the current block is included in the MPM candidates in the MPM list, the encoding device can set the MPM flag information to 1. Alternatively, if the intra-prediction mode of the current block is not included in the MPM candidates in the MPM list, the encoding device can set the MPM flag information to 0.

[0266] Furthermore, if the intra-prediction mode of the current block is included in the MPM candidates within the MPM list, the coding device can generate MPM index information to indicate the intra-prediction mode of the current block among the MPM candidates. For example, if the MPM list is configured with k (e.g., 6) MPM candidates, the MPM index information can indicate the index value from 0 to k-1 (e.g., 0 to 5) that corresponds to the intra-prediction mode of the current block.

[0267] If the intra-prediction mode of the current block is not included in the MPM candidates in the MPM list, the encoding device can generate residual mode information to indicate the intra-prediction mode of the current block among the remaining intra-prediction modes other than the MPM candidates. For example, as described above, if 67 intra-prediction modes are used and the MPM list is configured to include k (e.g., 6) MPM candidates, the remaining intra-prediction modes can include 67-k (e.g., 61) modes obtained by subtracting the number of MPM candidates from the total number of intra-prediction modes. Therefore, the residual mode information can indicate the index value from 0 to 67-k-1 (e.g., 0 to 60) that corresponds to the intra-prediction mode of the current block.

[0268] The coding device can generate prediction samples for the current block by performing intra-prediction based on the determined intra-prediction mode of the current block (S1640).

[0269] In one embodiment, the encoding device can derive at least one of the neighboring samples of the current block based on an intra-frame prediction mode, and can generate prediction samples based on the neighboring samples. In this case, the neighboring samples can include the top-left neighboring sample, the top neighboring sample, and the left neighboring sample of the current block. For example, if the size of the current block is W×H and the x and y components at the top-left sample position of the current block are xN and yN, then the left neighboring sample can be p[xN-1][yN] to p[xN-1][2H+yN-1], the top-left neighboring sample can be p[xN-1][yN-1], and the top neighboring sample can be p[xN][yN-1] to p[2W+xN-1][yN-1].

[0270] The encoding device can encode image information including information related to the intra-prediction mode of the current block (S1650).

[0271] That is, the coding device can generate information related to the intra-prediction mode (including at least one of the MPM flag information, MPM index information and residual mode information mentioned above), and can encode the information related to the intra-prediction mode.

[0272] Furthermore, although not shown, the encoding device can derive residual samples for the current block based on the original samples and predicted samples used for the current block, and can generate residual-related information for the current block based on the residual samples. Additionally, the encoding device can encode image information including residual-related information and can output the image information as a bitstream.

[0273] Bitstreams can be transmitted to the decoding device via a network or via (digital) storage media. In this case, the network can include broadcast networks and / or communication networks. Digital storage media can include various storage media such as USB, SD, CD, DVD, Blu-ray, HDD, and SSD.

[0274] It can be done Figure 2 The subtractor 231 of the disclosed encoding device 200 performs the process of deriving residual samples for the current block. This can be achieved through... Figure 2 The encoder 200 disclosed herein uses a converter 232 to perform the process of generating information related to the residual. This can be achieved through... Figure 2 The entropy encoder 240 of the disclosed encoding device 200 performs the process of encoding image information, including information related to residuals.

[0275] Figure 17 This is a schematic illustration of a flowchart of a decoding method that can be performed by a decoding device according to an embodiment of this document.

[0276] It can be by Figure 3 The publicly disclosed decoding device 300 performs Figure 17 The method disclosed in the document. Specifically, it can be... Figure 3 The predictor 330 and intra-frame predictor 331 disclosed herein perform [the following actions]. Figure 17 Steps S1700 to S1740 in the process. This can be achieved by... Figure 3 The adder 340 disclosed in the article performs... Figure 17 Step S1750 in the process. Furthermore, in Figure 17 In the middle, it can be made by Figure 3 The entropy decoder 310 disclosed in the document executes step S1730. Furthermore, Figure 17 The methods disclosed herein may include the embodiments described herein. Therefore, in Figure 17 In this document, detailed descriptions of content that overlaps with the embodiments mentioned above are omitted, or are only briefly described.

[0277] refer to Figure 17 The decoding device can derive a first candidate intra-frame prediction mode based on the first adjacent block located to the left of the current block (S1700).

[0278] In this case, adjacent blocks placed next to the current block can include Figure 11 The adjacent blocks shown are A, B, C, D, E, F, and / or G. In this case, for example, the first adjacent block is the block to the left of the current block, and may be... Figure 11 The adjacent block D is shown. That is, the adjacent block D can indicate the bottom left adjacent block among the left adjacent blocks that are adjacent to the left boundary of the current block.

[0279] In one embodiment, if the first neighboring block is available and intra-prediction has been applied to the first neighboring block, the decoding device can derive the intra-prediction mode of the first neighboring block as a first candidate intra-prediction mode. Alternatively, if the first neighboring block is unavailable or intra-prediction has not been applied to the first neighboring block, the decoding device can derive the planar intra-prediction mode as a first candidate intra-prediction mode.

[0280] The decoding device can derive a second candidate intra-prediction mode based on the second adjacent block located above the current block (S1710).

[0281] In this case, for example, the second adjacent block is the block above the current block, and can be... Figure 11The adjacent block B is shown. That is, the adjacent block B can indicate the rightmost upper adjacent block among the adjacent blocks adjacent to the upper boundary of the current block. For example, if the size of the current block is W×H, and the x and y components at the upper left sample position of the current block are xN and yN, then the first adjacent block can be the block containing the sample at the coordinates (xN-1, H+yN-1), and the second adjacent block can be the block containing the sample at the coordinates (W+xN-1, yN-1).

[0282] In one embodiment, if the second neighboring block is available, intra-prediction is applied to the second neighboring block, and the second neighboring block is included in the current CTU, the decoding device can derive the intra-prediction mode of the second neighboring block as a second candidate intra-prediction mode. Alternatively, if the second neighboring block is unavailable, or intra-prediction is not applied to the second neighboring block, or the second neighboring block is not included in the current CTU, the decoding device can derive the planar intra-prediction mode as a second candidate intra-prediction mode.

[0283] The decoding device can configure a list of most probable modes (MPMs) for the current block based on the first candidate intra-prediction mode and the second candidate intra-prediction mode (S1720).

[0284] That is, the decoding device can derive MPM candidates including at least one of a first candidate intra-frame prediction mode and a second candidate intra-frame prediction mode, and can configure the MPM list based on the MPM candidates. In this case, the various embodiments mentioned above can be applied to the process of configuring the MPM list by deriving MPM candidates. Reference has been made above. Figures 12 to 15 Tables 1 to 13 describe this. According to the embodiments mentioned above, the MPM list can be configured by deriving MPM candidates based on whether predetermined conditions are met by deriving a first candidate intra-prediction mode derived from a first neighboring block and a second candidate intra-prediction mode derived from a second neighboring block.

[0285] In this scenario, at least one of the MPM candidates included in the MPM list can be derived by applying modular arithmetic operations to either the first or second candidate intra-prediction mode. In this implementation of the MPM list, an algorithm can be implemented such that MPM candidates with meaningful angles (i.e., directions) are configured by considering the total number of intra-prediction modes, the direction of intra-prediction, prediction performance, complexity, etc. In some embodiments, such as those shown in Table 9 or Table 13, MPM candidates can be derived by applying 64 or 65 modular arithmetic operations to either the first or second candidate intra-prediction mode.

[0286] In one embodiment, one of the MPM candidates' intra-prediction modes can be derived based on the result of calculating a first value by adding 61, 60, 0, or -1 to the larger of the mode index (mode number) of the first candidate intra-prediction mode and the mode index (mode number) of the second candidate intra-prediction mode, calculating a second value by applying a modulo-64 arithmetic operation to the first value, and adding 2 to the second value.

[0287] For example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are the same intra-prediction mode, the decoding device can derive MPM candidates by determining whether the mode index of the first candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, if the first candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidates can include: intra-prediction modes derived based on the result calculated by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode + 61) and adding 2; intra-prediction modes derived based on the result calculated by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode - 1) and adding 2; and intra-prediction modes derived based on the result obtained by applying a modulo-64 arithmetic operation to (the mode index of the first candidate intra-prediction mode + 60) and adding 2.

[0288] Alternatively, for example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, the decoding device can derive MPM candidates by determining whether either the first candidate intra-prediction mode or the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, when either the first candidate intra-prediction mode or the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidate may include: an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 61) and adding 2; an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode - 1) and adding 2; and an intra-prediction mode derived by applying a 64-modulus arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 60) and adding 2.

[0289] Alternatively, for example, when deriving MPM candidates, if the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, the decoding device can derive the MPM candidates by determining whether each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode. In this case, when each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode, the MPM candidates can be based on the difference between the mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode, including: an intra-prediction mode derived by applying a modulo-64 arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode + 61) and adding 2, or an intra-prediction mode derived by applying a modulo-64 arithmetic operation to (the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode - 1) and adding 2.

[0290] For example, if each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a larger mode index than the DC intra-prediction mode and the difference between the first mode index and the second mode index is 62, then the MPM candidate may include an intra-prediction mode derived based on the result obtained by applying a modulo 64 arithmetic operation to (first mode index + 61) and adding 2.

[0291] For another example, if each of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a mode index larger than the DC intra-prediction mode and the difference between the first mode index and the second mode index is 2, then the MPM candidate may include an intra-prediction mode derived based on the result obtained by applying a 64-modulus arithmetic operation to (first mode index - 1) and adding 2.

[0292] In this scenario, the first mode index can indicate the larger mode index between the first candidate intra-prediction mode and the second candidate intra-prediction mode. The second mode index can indicate the smaller mode index between the first candidate intra-prediction mode and the second candidate intra-prediction mode.

[0293] The decoding device can include the MPM candidates derived as described above in the MPM list. In this case, each MPM candidate can be sequentially indexed within the list and can be indicated by an index value in the MPM list. That is, the decoding device can determine which MPM candidate in the MPM list is indicated based on the index value signaled by the encoding device.

[0294] The decoding device can derive the intra-prediction mode of the current block based on the MPM list (S1730).

[0295] In one embodiment, the decoding device can obtain information related to the intra-prediction mode of the current block from the bitstream. The information related to the intra-prediction mode is information used to indicate the intra-prediction mode of the current block, and may include MPM flag information, MPM index information, remaining mode information, etc.

[0296] First, the decoding device can obtain MPM flag information indicating whether the intra-prediction mode of the current block is included in the MPM candidate list. Furthermore, the decoding device can obtain MPM index information or remaining mode information based on the MPM flag information.

[0297] For example, when the MPM flag information indicates 1, the decoding device can determine that the intra-prediction mode of the current block is included in the MPM candidates within the MPM list. In this case, the decoding device can obtain MPM index information indicating the intra-prediction mode of the current block among the MPM candidates. The decoding device can then derive the intra-prediction mode of the current block from the MPM candidates indicated by the MPM index information within the MPM list.

[0298] When the MPM flag information indicates 0, the decoding device can determine that the intra-prediction mode of the current block is not included in the MPM candidates in the MPM list. In this case, the decoding device can obtain residual mode information indicating the intra-prediction mode of the current block among the remaining intra-prediction modes besides the MPM candidates. The decoding device can derive the intra-prediction mode indicated by the residual mode information as the intra-prediction mode of the current block.

[0299] The decoding device can generate prediction samples for the current block by performing intra-prediction on the current block based on the derived intra-prediction mode (S1740).

[0300] In one embodiment, the decoding device can derive at least one of the neighboring samples of the current block based on an intra-frame prediction mode, and can generate prediction samples based on the neighboring samples. In this case, the neighboring samples can include the top-left neighboring sample, the top neighboring sample, and the left neighboring sample of the current block. For example, if the size of the current block is W×H and the x and y components at the top-left sample position of the current block are xN and yN, then the left neighboring sample can be p[xN-1][yN] to p[xN-1][2H+yN-1], the top-left neighboring sample can be p[xN-1][yN-1], and the top neighboring sample can be p[xN][yN-1] to p[2W+xN-1][yN-1].

[0301] The decoding device can generate a reconstructed image for the current block based on the predicted samples (S1750).

[0302] In one embodiment, the decoding device may use the predicted samples directly as reconstructed samples based on the prediction pattern, or it may generate reconstructed samples by adding the residual samples to the predicted samples.

[0303] If residual samples exist for the current block, the decoding device can receive information related to the residuals used for the current block. This residual-related information may include transform coefficients associated with the residual samples. The decoding device can derive residual samples (or an array of residual samples) for the current block based on the residual information. The decoding device can generate reconstructed samples based on the predicted samples and residual samples, and can derive a reconstructed block or reconstructed image based on the reconstructed samples. Subsequently, as described above, the decoding device can apply in-loop filtering processes such as deblocking filtering and / or SAO processes to the reconstructed image to improve subjective / objective image quality.

[0304] In the embodiments mentioned above, although these methods have been described based on flowcharts in the form of a series of steps or units, the embodiments of this document are not limited to the order of these steps, and some of these steps may be performed in a different order than the others or may be performed simultaneously with other steps. Furthermore, those skilled in the art will understand that the steps shown in the flowcharts are not exclusive, and without affecting the scope of the claims of this document, these steps may include other steps or one or more steps in the flowcharts may be deleted.

[0305] The methods mentioned above in this document can be implemented in software, and the encoding and / or decoding devices according to this document can be included in a device for performing image processing (e.g., TV, computer, smartphone, set-top box, or display device).

[0306] In this document, when the embodiments are implemented in software form, the methods mentioned above can be implemented as modules (procedures, functions, etc.) for performing the functions mentioned above. Modules can be stored in memory and executed by a processor. Memory can be arranged internally or externally to the processor and connected to the processor by various known means. The processor may include application-specific integrated circuits (ASICs), other chipsets, logic circuits, and / or data processing devices. Memory may include read-only memory (ROM), random access memory (RAM), flash memory, memory cards, storage media, and / or other storage devices. That is, the embodiments described in this document can be implemented and executed on a processor, microprocessor, controller, or chip. For example, the functional units shown in the figures can be implemented and executed on a computer, processor, microprocessor, controller, or chip. In this case, information (e.g., information about instructions) or algorithms used in these implementations can be stored in a digital storage medium.

[0307] Furthermore, the decoding and encoding devices using this document can be included in multimedia broadcasting transmitters and receivers, mobile communication terminals, home theater video equipment, digital cinema video equipment, surveillance cameras, video chat devices, real-time communication devices such as video communication, mobile streaming devices, storage media, cameras, video-on-demand (VoD) service providers, over-the-top (OTT) video devices, internet streaming service providers, three-dimensional (3D) video devices, virtual reality (VR) devices, augmented reality (AR) devices, video telephony devices, transportation terminals (e.g., vehicle (including autonomous vehicle) terminals, aircraft terminals, and ship terminals), and medical video equipment, and can be used to process video signals or data signals. For example, over-the-top (OTT) video devices can include game consoles, Blu-ray players, internet access TVs, home theater systems, smartphones, tablet PCs, and digital video recorders (DVRs).

[0308] Furthermore, the processing methods described in this document can be generated in the form of a computer-executable program and can be stored in a computer-readable recording medium. Multimedia data with data structures according to this document can also be stored in a computer-readable recording medium. Computer-readable recording media include all types of storage devices storing computer-readable data. Computer-readable recording media can include, for example, Blu-ray discs (BD), Universal Serial Bus (USB), ROM, PROM, EPROM, EEPROM, RAM, CD-ROM, magnetic tape, floppy disks, and optical data storage devices. Furthermore, computer-readable recording media include media implemented in the form of a carrier wave (e.g., transmitted via the Internet). Additionally, bitstreams generated using encoding methods can be stored in computer-readable recording media or transmitted via wired and wireless communication networks.

[0309] Furthermore, the embodiments of this document can be implemented as a computer program product using program code. The program code can be executed by a computer according to the embodiments of this document. The program code can be stored on a carrier wave that can be read by a computer.

[0310] Figure 18 An example of a content streaming system to which the embodiments disclosed in this document can be applied is illustrated.

[0311] refer to Figure 18 The content streaming system using the embodiments of this document may mainly include an encoding server, a streaming server, a web server, a media storage device, a user device, and a multimedia input device.

[0312] An encoding server compresses content input from multimedia input devices such as smartphones, cameras, and camcorders into digital data to generate a bitstream, and then transmits this bitstream to a streaming server. As another example, when multimedia input devices such as smartphones, cameras, and camcorders directly generate bitstreams, the encoding server can be omitted.

[0313] A bitstream can be generated using the encoding method or bitstream generation method described in the embodiments of this document, and the streaming server can temporarily store the bitstream during transmission or reception.

[0314] A streaming server, based on a user's request, transmits multimedia data to the user's device via a web server, with the web server acting as the medium for informing the user of the service. When a user requests a desired service from the web server, the web server forwards it to the streaming server, and the streaming server delivers the multimedia data to the user. In this scenario, the content streaming system may include a separate control server. In this case, the control server is used to manage the commands / responses between devices within the content streaming system.

[0315] A streaming server can receive content from media storage devices and / or encoding servers. For example, when receiving content from an encoding server, the content can be received in real time. In this case, to provide a smooth streaming service, the streaming server can store the bitstream for a predetermined period of time.

[0316] Examples of user equipment may include mobile phones, smartphones, laptops, digital broadcast terminals, personal digital assistants (PDAs), portable multimedia players (PMPs), navigators, board PCs, tablet PCs, ultrabooks, wearable devices (e.g., smartwatches, smart glasses, head-mounted displays), digital TVs, desktop computers, digital signage, etc.

[0317] In a content streaming system, each server can be operated as a distributed server, in which case the data received from each server can be distributed.

Claims

1. A video decoding method performed by a decoding device, the method comprising: Based on the first neighboring block located at the bottommost position among the neighboring blocks adjacent to the left boundary of the current block, derive the first candidate intra-frame prediction mode. Based on the rightmost second neighboring block among the neighboring blocks adjacent to the upper boundary of the current block, a second candidate intra-frame prediction mode is derived. Based on the first candidate intra-frame prediction mode and the second candidate intra-frame prediction mode, a candidate mode list for the current block is constructed. Based on the candidate mode list, derive the intra-prediction mode for the current block; A prediction sample is generated by performing a prediction on the current block based on the intra-frame prediction mode; as well as Based on the predicted samples, a reconstructed image for the current block is generated. The step of constructing the candidate mode list includes: deriving candidate modes that include at least one of the first candidate intra-frame prediction mode or the second candidate intra-frame prediction mode. The step of constructing the candidate mode list includes: based on the fact that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, deriving the candidate modes by determining whether one of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a mode index greater than that of the DC intra-prediction mode. Specifically, based on a mode index greater than the DC intra-prediction mode of either the first candidate intra-prediction mode or the second candidate intra-prediction mode, and provided that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, at least one candidate of the candidate mode is derived by applying a 64-modulus arithmetic operation to either the first candidate intra-prediction mode or the second candidate intra-prediction mode. Wherein, based on a mode index greater than the DC intra-prediction mode, either the first candidate intra-prediction mode or the second candidate intra-prediction mode, the candidate modes include: The intra-prediction mode is derived by obtaining a first value (the larger of the mode indices of the first candidate intra-prediction mode and the second candidate intra-prediction mode, plus 61), a second value (obtained by applying the 64-modulus arithmetic operation to the first value), and a result value (the second value plus 2). The intra-prediction mode is derived by obtaining a third value obtained by subtracting 1 from the larger mode index of the first candidate intra-prediction mode and the second candidate intra-prediction mode, obtaining a fourth value obtained by applying the 64-modulus arithmetic operation to the third value, and obtaining the result of adding 2 to the fourth value. The intra-prediction mode is derived by obtaining a fifth value obtained by adding 60 to the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode, obtaining a sixth value obtained by applying the 64-modulus arithmetic operation to the fifth value, and obtaining the result value obtained by adding 2 to the sixth value.

2. A video encoding method performed by an encoding device, the method comprising: Based on the first neighboring block located at the bottommost position among the neighboring blocks adjacent to the left boundary of the current block, derive the first candidate intra-frame prediction mode. Based on the rightmost second neighboring block among the neighboring blocks adjacent to the upper boundary of the current block, a second candidate intra-frame prediction mode is derived. Based on the first candidate intra-frame prediction mode and the second candidate intra-frame prediction mode, a candidate mode list for the current block is constructed. Determine the intra-prediction mode for the current block; Based on the intra-frame prediction mode, prediction samples are generated by performing prediction on the current block; as well as The encoding includes image information used for intra-frame prediction mode information of the current block. The step of constructing the candidate mode list includes: deriving candidate modes that include at least one of the first candidate intra-frame prediction mode or the second candidate intra-frame prediction mode. The step of constructing the candidate mode list includes: based on the fact that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, deriving the candidate modes by determining whether one of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a mode index greater than that of the DC intra-prediction mode. Specifically, based on a mode index greater than the DC intra-prediction mode of either the first candidate intra-prediction mode or the second candidate intra-prediction mode, and provided that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, at least one candidate of the candidate mode is derived by applying a 64-modulus arithmetic operation to either the first candidate intra-prediction mode or the second candidate intra-prediction mode. Wherein, based on a mode index greater than the DC intra-prediction mode, either the first candidate intra-prediction mode or the second candidate intra-prediction mode, the candidate modes include: The intra-prediction mode is derived by obtaining a first value (the larger of the mode indices of the first candidate intra-prediction mode and the second candidate intra-prediction mode, plus 61), a second value (obtained by applying the 64-modulus arithmetic operation to the first value), and a result value (the second value plus 2). The intra-prediction mode is derived by obtaining a third value obtained by subtracting 1 from the larger mode index of the first candidate intra-prediction mode and the second candidate intra-prediction mode, obtaining a fourth value obtained by applying the 64-modulus arithmetic operation to the third value, and obtaining the result of adding 2 to the fourth value. The intra-prediction mode is derived by obtaining a fifth value obtained by adding 60 to the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode, obtaining a sixth value obtained by applying the 64-modulus arithmetic operation to the fifth value, and obtaining the result value obtained by adding 2 to the sixth value.

3. A non-transitory computer-readable storage medium storing instructions and a bit stream, wherein the instructions are executed by a processor to implement the encoding method of claim 2 to generate the bit stream.

4. A method for transmitting data for an image, the method comprising: A bitstream is obtained, wherein the bitstream is generated by: deriving a first candidate intra-prediction mode based on the bottommost first neighboring block among the neighboring blocks adjacent to the left boundary of the current block; deriving a second candidate intra-prediction mode based on the rightmost second neighboring block among the neighboring blocks adjacent to the upper boundary of the current block; constructing a candidate mode list for the current block based on the first candidate intra-prediction mode and the second candidate intra-prediction mode; determining an intra-prediction mode for the current block; generating prediction samples by performing prediction on the current block based on the intra-prediction mode; and encoding image information including intra-prediction mode information for the current block to generate the bitstream. as well as Send the data including the bit stream. The step of constructing the candidate mode list includes: deriving candidate modes that include at least one of the first candidate intra-frame prediction mode or the second candidate intra-frame prediction mode. The step of constructing the candidate mode list includes: based on the fact that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, deriving the candidate modes by determining whether one of the first candidate intra-prediction mode and the second candidate intra-prediction mode has a mode index greater than that of the DC intra-prediction mode. Specifically, based on a mode index greater than the DC intra-prediction mode of either the first candidate intra-prediction mode or the second candidate intra-prediction mode, and provided that the first candidate intra-prediction mode and the second candidate intra-prediction mode are not the same intra-prediction mode, at least one candidate of the candidate mode is derived by applying a 64-modulus arithmetic operation to either the first candidate intra-prediction mode or the second candidate intra-prediction mode. Wherein, based on a mode index greater than the DC intra-prediction mode, either the first candidate intra-prediction mode or the second candidate intra-prediction mode, the candidate modes include: The intra-prediction mode is derived by obtaining a first value (the larger of the mode indices of the first candidate intra-prediction mode and the second candidate intra-prediction mode, plus 61), a second value (obtained by applying the 64-modulus arithmetic operation to the first value), and a result value (the second value plus 2). The intra-prediction mode is derived by obtaining a third value obtained by subtracting 1 from the larger mode index of the first candidate intra-prediction mode and the second candidate intra-prediction mode, obtaining a fourth value obtained by applying the 64-modulus arithmetic operation to the third value, and obtaining the result of adding 2 to the fourth value. The intra-prediction mode is derived by obtaining a fifth value obtained by adding 60 to the larger mode index of the first candidate intra-prediction mode and the mode index of the second candidate intra-prediction mode, obtaining a sixth value obtained by applying the 64-modulus arithmetic operation to the fifth value, and obtaining the result value obtained by adding 2 to the sixth value.

Citation Information

Patent Citations

  • Intra prediction mode encoding / decoding method and apparatus for same

    CN103380622A

  • Method and device for intra prediction

    CN103891283A