Video signal processing method and apparatus using block DPCM prediction method

By adopting BDPCM technology in video signal processing, the encoding process of the video signal is optimized, the problem of low encoding efficiency in the existing technology is solved, and more efficient video signal encoding is achieved.

CN113966610BActive Publication Date: 2025-09-12WILUS INSTITUTE OF STANDARDS & TECHNOLOGY INC
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202080043005.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2019-06-11
Filing Date
2020-06-10
Publication Date
2025-09-12
Estimated Expiration
2040-06-10

AI Technical Summary

Technical Problem

Existing video signal processing methods are inefficient in the compression encoding process and cannot fully utilize the spatial, temporal and random correlations of video signals.

Method used

Block-based delta pulse code modulation (BDPCM) technology is used to optimize the encoding process of the video signal by parsing BDPCM enable information, intra-frame BDPCM direction information and transform skip information, especially processing the luminance component to reduce unnecessary transform operations.

Benefits of technology

The coding efficiency of the video signal is improved, and the efficiency and quality of the coding process are enhanced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113966610B_ABST
    Figure CN113966610B_ABST
Patent Text Reader

Abstract

The present disclosure relates to a method and apparatus for processing a video signal, and more specifically, includes the following steps: parsing block-based delta pulse code modulation (BDPCM) enable information indicating whether BDPCM has been enabled from a bitstream; when the BDPCM enable information indicates that BDPCM has been enabled, the width of a current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether BDPCM is applied to the current block from the bitstream; when the intra-frame BDPCM information indicates that BDPCM is applied to the current block, parsing intra-frame BDPCM direction information about the current block from the bitstream; and reconstructing the current block based on the intra-frame BDPCM direction information.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to a method and apparatus for processing a video signal, and more particularly, to a method and apparatus for processing a video signal to encode or decode the video signal. Background Art

[0002] Compression coding refers to a series of signal processing techniques used to transmit digitized information over communication lines or store information in a form suitable for storage media. Compression coding targets include objects such as voice, video, and text, and in particular, techniques for performing compression coding on images are referred to as video compression. Compression coding of video signals is performed by removing excess information, taking into account spatial, temporal, and random correlations. However, with the recent development of various media and data transmission media, more efficient video signal processing methods and devices are needed. Summary of the Invention

[0003] Technical issues

[0004] The purpose of the present disclosure is to improve the coding efficiency of video signals.

[0005] Technical Solution

[0006] According to an embodiment of the present disclosure, a method for processing a video signal includes the following steps: parsing BDPCM enable information indicating whether block-based incremental pulse code modulation (BDPCM) is enabled from a bitstream; when the BDPCM enable information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; when the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, parsing intra-frame BDPCM direction information related to the current block; and reconstructing the current block based on the intra-frame BDPCM direction information.

[0007] In the method for processing a video signal according to an embodiment of the present disclosure, the first value and the second value are each a maximum block size allowing transform skipping.

[0008] In the method for processing a video signal according to an embodiment of the present disclosure, the intra-frame BDPCM information and the intra-frame BDPCM direction information are parsed for the luma component independently of the chroma component.

[0009] In the method for processing a video signal according to an embodiment of the present disclosure, the BDPCM enable information is signaled as a sequence.

[0010] In a method for processing a video signal according to an embodiment of the present disclosure, when the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, transform skip information of a transform block corresponding to the current block is not parsed from the bitstream, and when a value of the transform skip information is a first inferred value, the transform skip information indicates that a transform is not applied to a block corresponding to the transform skip information.

[0011] The method for processing a video signal according to an embodiment of the present disclosure further includes the following steps: when the transform skip information does not exist and the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, inferring the transform skip information as the first inferred value; and when the transform skip information does not exist and the intra-frame BDPCM information indicates that the BDPCM is not applied to the current block, inferring the transform skip information as a second inferred value.

[0012] In the method for processing a video signal according to an embodiment of the present disclosure, the intra-frame BDPCM direction information indicates one of a horizontal direction or a vertical direction.

[0013] According to an embodiment of the present disclosure, the method for processing a video signal further includes the following steps: when the intra-frame BDPCM direction information is 0, selecting the intra-frame prediction mode corresponding to the horizontal direction from multiple intra-frame modes as the intra-frame prediction mode of the current block; and when the intra-frame BDPCM direction information is 1, selecting the intra-frame prediction mode corresponding to the vertical direction from the multiple intra-frame modes as the intra-frame prediction mode of the current block.

[0014] In the method for processing a video signal according to an embodiment of the present disclosure, the intra prediction mode of the current block is used to determine the intra prediction mode of a neighboring block to be reconstructed after the current block.

[0015] According to an embodiment of the present disclosure, an apparatus for processing a video signal includes a processor and a memory, wherein the processor parses BDPCM enable information indicating whether block-based incremental pulse code modulation (BDPCM) is enabled from a bitstream based on instructions stored in the memory; when the BDPCM enable information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parses intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; when the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, parses intra-frame BDPCM direction information related to the current block from the bitstream; and reconstructs the current block based on the intra-frame BDPCM direction information.

[0016] In the apparatus for processing a video signal according to an embodiment of the present disclosure, the first value and the second value are each a maximum block size allowing transform skipping.

[0017] In the apparatus for processing a video signal according to an embodiment of the present disclosure, the intra BDPCM information and the intra BDPCM direction information are parsed for the luma component independently of the chroma component.

[0018] In the apparatus for processing a video signal according to an embodiment of the present disclosure, the BDPCM enable information may be signaled as a sequence.

[0019] In the apparatus for processing a video signal according to an embodiment of the present disclosure, when the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, transform skip information of a transform block corresponding to the current block is not parsed from the bitstream, and when a value of the transform skip information is a first inferred value, the transform skip information indicates that a transform is not applied to a block corresponding to the transform skip information.

[0020] In the device for processing a video signal according to an embodiment of the present disclosure, the processor, based on instructions stored in the memory, infers the transform skip information as the first inferred value when the transform skip information does not exist and the intra-frame BDPCM information indicates that the BDPCM is applied to the current block; and infers the transform skip information as the second inferred value when the transform skip information does not exist and the intra-frame BDPCM information indicates that the BDPCM is not applied to the current block.

[0021] In the apparatus for processing a video signal according to an embodiment of the present disclosure, the intra-frame BDPCM direction information indicates one of a horizontal direction or a vertical direction.

[0022] In the device for processing a video signal according to an embodiment of the present disclosure, the processor selects, based on instructions stored in the memory, the intra-frame prediction mode corresponding to the horizontal direction from multiple intra-frame modes as the intra-frame prediction mode of the current block when the intra-frame BDPCM direction information is 0; and the processor selects, based on instructions stored in the memory, the intra-frame prediction mode corresponding to the vertical direction from the multiple intra-frame modes as the intra-frame prediction mode of the current block when the intra-frame BDPCM direction information is 1.

[0023] In the apparatus for processing a video signal according to an embodiment of the present disclosure, the intra prediction mode of the current block is used to determine the intra prediction mode of a neighboring block to be reconstructed after the current block.

[0024] According to an embodiment of the present disclosure, a method for processing a video signal includes the following steps: generating BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled; when the BDPCM enable information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, generating intra-frame BDPCM information indicating whether the BDPCM is applied to the current block; when the intra-frame BDPCM information indicates that the BDPCM is applied to the current block, generating intra-frame BDPCM direction information related to the current block; and generating a bitstream based on the BDPCM enable information, the intra-frame BDPCM information, and the intra-frame BDPCM direction information.

[0025] In the method for processing a video signal according to an embodiment of the present disclosure, when the intra BDPCM information indicates that BDPCM is applied to the current block, transform skip information of a transform block corresponding to the current block is not generated.

[0026] According to an embodiment of the present disclosure, an apparatus for processing a video signal includes a processor and a memory, wherein the processor generates BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled based on instructions stored in the memory; generates intra-frame BDPCM information indicating whether the BDPCM is applied to the current block when the BDPCM enable information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value; generates intra-frame BDPCM direction information related to the current block when the intra-frame BDPCM information indicates that the BDPCM is to be applied to the current block; and generates a bitstream based on the BDPCM enable information, the intra-frame BDPCM information, and the intra-frame BDPCM direction information.

[0027] In the apparatus for processing a video signal according to an embodiment of the present disclosure, when the intra BDPCM information indicates that the BDPCM is applied to the current block, transform skip information of a transform block corresponding to the current block is not generated.

[0028] According to an embodiment of the present disclosure, a computer-readable recording medium having an encoded video signal recorded therein includes the steps of: generating block-based delta pulse code modulation (BDPCM) enable information indicating whether BDPCM is enabled; generating intra-frame BDPCM information indicating whether BDPCM is applied to the current block when the BDPCM enable information indicates that BDPCM is enabled, the width of a current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value; generating intra-frame BDPCM direction information related to the current block when the intra-frame BDPCM information indicates that BDPCM is applied to the current block; and generating a bitstream based on the BDPCM enable information, the intra-frame BDPCM information, and the intra-frame BDPCM direction information.

[0029] Beneficial effects

[0030] According to the embodiments of the present disclosure, the coding efficiency of a video signal can be improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0031] Figure 1 is a schematic block diagram of a video signal encoding apparatus according to an embodiment of the present invention.

[0032] Figure 2 is a schematic block diagram of a video signal decoding apparatus according to an embodiment of the present invention.

[0033] Figure 3 An embodiment in which a coding tree unit is divided into coding units in a picture is shown.

[0034] Figure 4 Embodiments of methods for signaling partitioning of quadtrees and multi-type trees are shown.

[0035] Figure 5 An embodiment of reference samples used for prediction of a current block in intra prediction mode is illustrated.

[0036] Figure 6 An embodiment of a prediction mode for intra prediction is illustrated.

[0037] Figure 7 is a flowchart illustrating the operation of an apparatus for processing a video signal according to an embodiment of the present disclosure.

[0038] Figure 8 is a diagram illustrating a prediction mode and a quantized residual signal of block DPCM (BDPCM).

[0039] Figure 9 This is a diagram illustrating BDPCM flags defined in a sequence parameter set.

[0040] Figure 10is a diagram illustrating a portion of the syntax structure of a compilation unit.

[0041] Figure 11 is a diagram illustrating a portion of the syntax of a coding unit, and includes a size variable of a block to which BDPCM is applied.

[0042] Figure 12 is a diagram illustrating a portion of the transform unit syntax.

[0043] Figure 13 is a diagram illustrating the signaling / parsing conditions of a transform skip flag within a portion of a transform unit syntax.

[0044] Figure 14 is a diagram illustrating the relationship between a block to which BDPCM is applied and an intra prediction mode variable. DETAILED DESCRIPTION

[0045] The terms used in this specification may be general terms that are currently widely used, taking into account the functions in the present disclosure, but may be changed according to the intentions of those skilled in the art, customs, or the emergence of new technologies. In addition, in some cases, there may be terms arbitrarily selected by the applicant, and in such cases, their meanings are described in the corresponding description sections of the present disclosure. Therefore, the terms used in this specification should be interpreted based on the substantive meaning of the terms and content throughout the specification.

[0046] In this specification, some terms may be interpreted as follows. In some cases, coding may be interpreted as encoding or decoding. In this specification, a device that generates a video signal bitstream by performing coding (coding) of a video signal is referred to as a coding device or encoder, and a device that performs decoding (decoding) of a video signal bitstream to reconstruct a video signal is referred to as a decoding device or decoder. In addition, in this specification, a video signal processing device is used as a term that includes the concepts of both encoders and decoders. Information is a term that includes all values, parameters, coefficients, elements, etc. In some cases, the meaning is interpreted differently, and thus the present disclosure is not limited thereto. "Unit" is used to represent the basic unit of image processing or a specific location of a picture, and refers to an image area that includes both luminance and chrominance components. In addition, "block" refers to an image area that includes specific components of luminance and chrominance components (i.e., Cb and Cr). However, depending on the embodiment, terms such as "unit", "block", "partition", and "area" may be used interchangeably. In addition, in this specification, a unit or block may be used as a concept that includes both a coding unit (or coding block), a prediction unit (or prediction block), and a transform unit (or transform block). A picture indicates a field or a frame, and these terms may be used interchangeably depending on the embodiment.

[0047] Figure 11 is a schematic block diagram of a video signal encoding apparatus according to an embodiment of the present invention. Figure 1 The encoding apparatus 100 of the present invention includes a transform unit 110 , a quantization unit 115 , an inverse quantization unit 120 , an inverse transform unit 125 , a filtering unit 130 , a prediction unit 150 , and an entropy coding unit 160 .

[0048] The transform unit 110 obtains the value of the transform coefficient by transforming the residual signal, which is the difference between the input video signal and the prediction signal generated by the prediction unit 150. For example, a discrete cosine transform (DCT), a discrete sine transform (DST), or a wavelet transform can be used. DCT and DST perform a transform by dividing the input picture signal into a plurality of blocks. During the transform, the coding efficiency may vary depending on the distribution and characteristics of the values ​​in the transform area. The quantization unit 115 quantizes the value of the transform coefficient value output from the transform unit 110.

[0049] In order to improve coding efficiency, instead of coding the picture signal as is, a method is used that uses the area that has been encoded by the prediction unit 150 to predict the picture, and obtains a reconstructed picture by adding the residual value between the original picture and the predicted picture to the predicted picture. In order to prevent mismatches between the encoder and the decoder, when performing prediction in the encoder, information that can be used in the decoder should be used. To this end, the encoder performs the process of reconstructing the encoded current block again. The inverse quantization unit 120 inverse quantizes the value of the transform coefficient, and the inverse transform unit 125 reconstructs the residual value using the inverse quantized transform coefficient value. At the same time, the filtering unit 130 performs a filtering operation to improve the quality of the reconstructed picture and improve coding efficiency. For example, it may include a deblocking filter, sample adaptive offset (SAO), and an adaptive loop filter. The filtered picture is output or stored in the decoded picture buffer (DPB) 156 to be used as a reference picture.

[0050] The prediction unit 150 includes an intra-prediction unit 152 and an inter-prediction unit 154. The intra-prediction unit 152 performs intra-prediction within the current picture, and the inter-prediction unit 154 performs inter-prediction to predict the current picture using a reference picture stored in the DBP 156. The intra-prediction unit 152 performs intra-prediction based on reconstructed samples in the current picture and transmits intra-encoding information to the entropy coding unit 160. The intra-encoding information may include at least one of an intra-prediction mode, a most probable mode (MPM) flag, and an MPM index. The inter-prediction unit 154 may include a motion estimation unit 154a and a motion compensation unit 154b. The motion estimation unit 154a obtains a motion vector value for a specific region of the current region by referring to a reconstructed reference picture. The motion estimation unit 154a transmits a motion information set (reference picture index, motion vector information, etc.) for the reference region to the entropy coding unit 160. The motion compensation unit 154b performs motion compensation using the motion vector value transmitted from the motion estimation unit 154a. The inter prediction unit 154 transfers the inter encoding information including the motion information about the reference region to the entropy coding unit 160 .

[0051] When performing the above-described picture prediction, the transform unit 110 transforms the residual value between the original picture and the predicted picture to obtain a transform coefficient value. In this case, the transform can be performed in units of specific blocks within the picture, and the size of the specific block can be changed within a preset range. The quantization unit 115 quantizes the transform coefficient value generated in the transform unit 110 and sends it to the entropy coding unit 160.

[0052] The entropy coding unit 160 performs entropy coding on the quantized transform coefficients, inter-frame coding information, intra-frame coding information, etc. to generate a video signal bit stream. In the entropy coding unit 160, a variable length coding (VLC) scheme, an arithmetic coding scheme, etc. can be used. The variable length coding (VLC) scheme includes converting the input symbols into continuous code words, and the length of the code words can be variable. For example, frequently occurring symbols are represented by short code words, while rarely occurring symbols are represented by long code words. A context-based adaptive variable length coding (CAVLC) scheme can be used as a variable length coding scheme. Arithmetic coding can convert continuous data symbols into a single prime number, wherein arithmetic coding can obtain the optimal bits required to represent each symbol. Context-based adaptive binary arithmetic coding (CABAC) can be used as arithmetic coding.

[0053] The generated bitstream is encapsulated using the Network Abstraction Layer (NAL) unit as the basic unit. The NAL unit includes an integer number of coded coding tree units. In order to decode the bitstream in the video decoder, first, the bitstream must be separated into NAL units, and then each separated NAL unit must be decoded. At the same time, the information required to decode the video signal bitstream can be sent through the raw byte sequence payload (RBSP) of the high-level set such as the picture parameter set (PPS), sequence parameter set (SPS), video parameter set (VPS), etc.

[0054] at the same time, Figure 1 The block diagram shows an encoding device 100 according to an embodiment of the present invention, and the blocks shown separately logically distinguish and illustrate the elements of the encoding device 100. Therefore, depending on the design of the device, the elements of the encoding device 100 described above may be installed as one chip or multiple chips. According to an embodiment, the operation of each element of the encoding device 100 described above may be performed by a processor (not shown).

[0055] Figure 2 FIG is a schematic block diagram of a video signal decoding apparatus 200 according to an embodiment of the present invention. Figure 2 The decoding device 200 of the present invention includes an entropy decoding unit 210, an inverse quantization unit 220, an inverse transform unit 225, a filtering unit 230 and a prediction unit 250.

[0056] The entropy decoding unit 210 entropy decodes the video signal bitstream to extract the transform coefficients, intra-frame coding information, inter-frame coding information, etc. for each region. The inverse quantization unit 220 inversely quantizes the entropy-decoded transform coefficients, and the inverse transform unit 225 restores the residual value by using the inversely quantized transform coefficients. The video signal processing device 200 restores the original pixel value by adding the residual value obtained by the inverse transform unit 225 to the predicted value obtained by the prediction unit 250.

[0057] At the same time, the filtering unit 230 performs filtering on the picture to improve image quality. This may include a deblocking filter for reducing block distortion and / or an adaptive loop filter for removing distortion from the entire picture. The filtered picture is output or stored in the DPB 256 to be used as a reference picture for the next picture.

[0058] The prediction unit 250 includes an intra-frame prediction unit 252 and an inter-frame prediction unit 254. The prediction unit 250 generates a predicted picture by using the encoding type, transform coefficients for each region, and intra-frame / inter-frame encoding information decoded by the entropy decoding unit 210. To reconstruct the current block in which decoding is performed, the current picture or a decoded region of another picture including the current block can be used. A picture (or tile / slice) in which only the current picture is used for reconstruction (i.e., only intra-frame prediction is performed for reconstruction) is called an intra-frame picture or I-frame (or tile / slice), and a picture (or tile / slice) in which both intra-frame prediction and inter-frame prediction can be performed for reconstruction is called an inter-frame picture (or tile / slice). To predict the sample values ​​of each block in an inter-frame picture (or tile / slice), a picture (or tile / slice) that uses up to one motion vector and a reference picture index is called a predicted picture or P-picture (or tile / slice), and a picture (or tile / slice) that uses up to two motion vectors and a reference picture index is called a bidirectionally predicted picture or B-picture (or tile / slice). In other words, a P-picture (or tile / slice) uses up to one motion information set to predict each block, and a B-picture (or tile / slice) uses up to two motion information sets to predict each block. Here, a motion information set includes one or more motion vectors and a reference picture index.

[0059] The intra-frame prediction unit 252 uses the intra-frame coding information and the reconstructed samples in the current picture to generate a prediction block. As described above, the intra-frame coding information may include at least one of the intra-frame prediction mode, the most probable mode (MPM) flag, and the MPM index. The intra-frame prediction unit 252 predicts the pixel values ​​of the current block by using the reconstructed pixels located to the left and / or above the current block as reference pixels. According to an embodiment, the reference pixels may be pixels adjacent to the left boundary of the current block and / or pixels adjacent to the top boundary of the current block. According to another embodiment, the reference pixels may be pixels of the neighboring blocks of the current block that are adjacent to the left boundary of the current block and / or adjacent to the top boundary of the current block within a preset distance. In this case, the neighboring blocks of the current block may include at least one of the left L block, the upper A block, the lower left BL block, the upper right AR block, or the upper left AL block adjacent to the current block.

[0060] The inter-frame prediction unit 254 uses the reference pictures and inter-frame coding information stored in the DPB 256 to generate a prediction block. The inter-frame coding information may include motion information (reference picture index, motion vector information, etc.) for the current block of the reference block. Inter-frame prediction may include L0 prediction, L1 prediction, and bidirectional prediction. L0 prediction means prediction using one reference picture included in the L0 picture list, while L1 prediction means prediction using one reference picture included in the L1 picture list. To achieve this, a motion information set (e.g., motion vector and reference picture index) may be required. In bidirectional prediction methods, up to two reference regions can be used, and the two reference regions can exist in the same reference picture or in different pictures. That is, in bidirectional prediction methods, up to two motion information sets (e.g., motion vector and reference picture index) can be used, and the two motion vectors can correspond to the same reference picture index or different reference picture indexes. In this case, the reference pictures can be displayed (or output) before and after the current picture in terms of time.

[0061] The inter-frame prediction unit 254 can obtain a reference block for the current block by using a motion vector and a reference picture index. The reference block exists in a reference picture corresponding to the reference picture index. In addition, the pixel value of the block specified by the motion vector or its interpolated value can be used as a predictor for the current block. For motion prediction with pixel accuracy in sub-pel units, for example, an 8-tap interpolation filter can be used for a luminance signal, and a 4-tap interpolation filter can be used for a chrominance signal. However, the interpolation filter used for motion prediction in sub-pel units is not limited thereto. As described above, the inter-frame prediction unit 254 performs motion compensation to predict the texture of the current unit from a previously reconstructed picture using motion information.

[0062] A reconstructed video picture is generated by adding the prediction value output from the intra prediction unit 252 or the inter prediction unit 254 to the residual value output from the inverse transform unit 225. That is, the video signal decoding apparatus 200 reconstructs the current block using the prediction block generated by the prediction unit 250 and the residual obtained from the inverse transform unit 225.

[0063] at the same time, Figure 2 The block diagram shows a decoding device 200 according to an embodiment of the present invention, and the blocks shown separately logically distinguish and illustrate the elements of the decoding device 200. Therefore, depending on the design of the device, the elements of the decoding device 200 described above can be installed as one chip or multiple chips. According to an embodiment, the operation of each element of the decoding device 200 described above can be performed by a processor (not shown).

[0064] Figure 3The diagram illustrates an embodiment in which a coding tree unit (CTU) in a picture is partitioned into coding units (CUs). During the encoding process of a video signal, a picture may be partitioned into a series of coding tree units (CTUs). A coding tree unit consists of an NxN block of luma samples and two blocks of chroma samples corresponding thereto. A coding tree unit may be partitioned into multiple coding units. A coding unit refers to a basic unit used to process a picture in the above-mentioned video signal processing process, i.e., intra / inter prediction, transform, quantization, and / or entropy coding. The size and shape of a coding unit in a picture may not be constant. A coding unit may have a square or rectangular shape. A rectangular coding unit (or rectangular block) includes a vertical coding unit (or vertical block) and a horizontal coding unit (or horizontal block). In this specification, a vertical block is a block whose height is greater than its width, and a horizontal block is a block whose width is greater than its height. In addition, in this specification, a non-square block may refer to a rectangular block, but the present disclosure is not limited thereto. The encoding device 100 and the decoding device 200 have been described above. The apparatus for processing a video signal described below may include at least one of the encoding apparatus 100 and the decoding apparatus 200 .

[0065] refer to Figure 3 First, the coding tree unit is split into a quadtree (QT) structure. That is, a node with a size of 2N×2N in the quadtree structure can be split into four nodes with a size of N×N. In this specification, a quadtree may also be referred to as a quadtree. Quadtree splitting can be performed recursively, and not all nodes need to be split at the same depth.

[0066] At the same time, the leaf nodes of the above-mentioned quadtree can be further divided into a multi-type tree (MTT) structure. According to an embodiment of the present invention, in the multi-type tree structure, a node can be divided into a binary or ternary tree structure divided horizontally or vertically. That is, in the multi-type tree structure, there are four segmentation structures, such as vertical binary segmentation, horizontal binary segmentation, vertical ternary segmentation and horizontal ternary segmentation. According to an embodiment of the present invention, in each tree structure, the width and height of the node can have a power of 2. For example, in a binary tree (BT) structure, a node of 2N×2N size can be split into two NX2N nodes by vertical binary segmentation, and split into two 2N×N nodes by horizontal binary segmentation. In addition, in a ternary tree (TT) structure, a node of 2N×2N size can be split into (N / 2)×2N, NX2N and (N / 2)×2N nodes by vertical ternary segmentation, and split into 2N×(N / 2), 2N×N and 2N×(N / 2) nodes by horizontal ternary segmentation. This multi-type tree splitting can be performed recursively.

[0067] The leaf nodes of the multi-type tree can be coding units. If the coding unit is not too large for the maximum transform length, the corresponding coding unit is used as a unit of prediction and transform without further division. At the same time, in the quadtree and multi-type tree described above, at least one of the following parameters can be predefined or transmitted through the RBSP of a higher-level set such as PPS, SPS or VPS. 1) CTU size: the root node size of the quadtree, 2) Minimum QT size MinQtSize: the minimum QT leaf node size allowed, 3) Maximum BT size MaxBtSize: the maximum BT root node size allowed, 4) Maximum TT size MaxTtSize: the maximum TT root node size allowed, 5) Maximum MTT depth MaxMttDepth: the maximum allowed depth of the MTT split from the leaf node of the QT, 6) Minimum BT size MinBtSize: the minimum BT leaf node size allowed, 7) Minimum TT size MinTtSize: the minimum TT leaf node size allowed.

[0068] Figure 4 An embodiment of a method for signaling the partitioning of quadtrees and multi-type trees is shown. Preset flags can be used to signal the partitioning of quadtrees and multi-type trees. Figure 4 , at least one of the flag "qt_split_flag" indicating whether to split a quadtree node, the flag "mtt_split_flag" indicating whether to split a multi-type tree node, the flag "mtt_split_vertical_flag" indicating the split direction of the multi-type tree node, or the flag "mtt_split_binary_flag" indicating the split type of the multi-type tree node may be used.

[0069] According to an embodiment of the present invention, a coding tree unit is the root node of a quadtree and can be first split into a quadtree structure. In the quadtree structure, a "qt_split_flag" signal is sent for each node "QT_node". If the value of "qt_split_flag" is 1, the node is split into 4 square nodes. If the value of "qt_split_flag" is 0, the corresponding node becomes a leaf node "QT_leaf_node" of the quadtree.

[0070] Each quad leaf node "QT_leaf_node" can be further split into a multi-type tree structure. In the multi-type tree structure, "mtt_split_flag" is signaled for each node "MTT_node". When the value of "mtt_split_flag" is 1, the corresponding node is split into multiple rectangular nodes, and when the value of "mtt_split_flag" is 0, the corresponding node is a leaf node "MTT_leaf_node" of the multi-type tree. When the multi-type tree node "MTT_node" is split into multiple rectangular nodes (that is, when the value of "mtt_split_flag" is 1), the "mtt_split_vertical_flag" and "mtt_split_binary_flag" of the node "MTT_node" can be additionally signaled. When the value of "mtt_split_vertical_flag" is 1, it indicates vertical splitting of the node "MTT_node", and when the value of "mtt_split_vertical_flag" is 0, it indicates horizontal splitting of the node "MTT_node". In addition, when the value of "mtt_split_binary_flag" is 1, the node "MTT_node" is split into 2 rectangular nodes, and when the value of "mtt_split_binary_flag" is 0, the node "MTT_node" is split into 3 rectangular nodes.

[0071] Figure 5 and Figure 6 The intra prediction method according to an embodiment of the present disclosure is shown in more detail. As described above, the intra prediction unit predicts pixel values ​​of a current block by using reconstructed pixels located to the left and / or above the current block as reference pixels.

[0072] first, Figure 5 An embodiment of a reference sample for prediction of a current block in an intra prediction mode is shown. According to an embodiment, the reference pixel may be a pixel adjacent to the left boundary of the current block and / or a pixel adjacent to the upper boundary of the current block. Figure 5As shown, when the size of the current block is W×H and the pixels of a single reference line adjacent to the current block are used for intra prediction, up to (2W+2H+1) adjacent pixels located to the left and / or above the current block can be used to set the reference pixels. At the same time, according to additional embodiments of the present disclosure, pixels of multiple reference lines can be used for intra prediction of the current block. The multiple reference lines can be composed of N lines located within a preset range from the current block. According to an embodiment, when the pixels of multiple reference lines are used for intra prediction, separate index information indicating the lines to be set as reference pixels can be signaled. When at least some of the adjacent pixels to be used as reference pixels have not been reconstructed, the intra prediction unit can obtain the reference pixels by performing a reference sample filling process according to a preset rule. In addition, the intra prediction unit can perform a reference sample filtering process to reduce the intra prediction error. That is, the reference pixels can be obtained by performing filtering on the adjacent pixels and / or the pixels obtained by the reference sample filling process. The intra prediction unit uses the reference pixels obtained in this way to predict the pixels of the current block.

[0073] Next, Figure 6 An embodiment of a prediction mode for intra-frame prediction is shown. For intra-frame prediction, intra-frame prediction mode information indicating an intra-frame prediction direction can be signaled. The intra-frame prediction mode information indicates one of multiple intra-frame prediction modes included in an intra-frame prediction mode set. When a current block is an intra-frame prediction block, the decoder receives the intra-frame prediction mode information for the current block from the bitstream. The intra-frame prediction unit of the decoder performs intra-frame prediction on the current block based on the extracted intra-frame prediction mode information.

[0074] According to an embodiment of the present invention, the intra-frame prediction mode set may include all intra-frame prediction modes used in intra-frame prediction (for example, a total of 67 intra-frame prediction modes). More specifically, the intra-frame prediction mode set may include a planar mode, a DC mode, and a plurality of (for example, 65) angular modes (i.e., directional modes). Each intra-frame prediction mode may be indicated by a preset index (i.e., an intra-frame prediction mode index). For example, Figure 6As shown, intra-frame prediction mode index 0 indicates planar mode, and intra-frame prediction mode index 1 indicates DC mode. In addition, intra-frame prediction mode indexes 2 to 66 can respectively indicate different angle modes. The angle modes respectively indicate angles that are different from each other within a preset angle range. For example, the angle mode may indicate an angle within an angle range (i.e., a first angle range) between 45 degrees and -135 degrees in a clockwise direction. The angle mode can be defined based on the 12 o'clock direction. In this case, intra-frame prediction mode index 2 indicates a horizontal diagonal (HDIA) mode, intra-frame prediction mode index 18 indicates a horizontal (horizontal, HOR) mode, intra-frame prediction mode index 34 indicates a diagonal (DIA) mode, intra-frame prediction mode index 50 indicates a vertical (VER) mode, and intra-frame prediction mode index 66 indicates a vertical diagonal (VDIA) mode.

[0075] At the same time, the preset angle range can be set differently according to the shape of the current block. For example, if the current block is a rectangular block, a wide-angle mode indicating an angle greater than 45 degrees or less than -135 degrees in the clockwise direction can be additionally used. When the current block is a horizontal block, the angle mode can indicate an angle within an angle range between (45+offset1) degrees and (-135+offset1) degrees in the clockwise direction (i.e., a second angle range). In this case, angle modes 67 to 76 outside the first angle range can be additionally used. In addition, if the current block is a vertical block, the angle mode can indicate an angle within an angle range between (45-offset2) degrees and (-135-offset2) degrees in the clockwise direction (i.e., a third angle range). In this case, angle modes -10 to -1 outside the first angle range can be additionally used. According to an embodiment of the present disclosure, the values ​​of offset1 and offset2 can be determined differently depending on the ratio between the width and height of the rectangular block. In addition, offset1 and offset2 can be positive numbers.

[0076] According to another embodiment of the present invention, the plurality of angle modes configuring the intra prediction mode set may include a basic angle mode and an extended angle mode. In this case, the extended angle mode may be determined based on the basic angle mode.

[0077] According to an embodiment, the basic angle mode is a mode corresponding to the angle used in the intra-frame prediction of the existing high-efficiency video coding (HEVC) standard, and the extended angle mode may be a mode corresponding to the angle newly added in the intra-frame prediction of the next-generation video codec standard. More specifically, the basic angle mode may be an angle mode corresponding to any one of the intra-frame prediction modes {2, 4, 6, ..., 66}, and the extended angle mode may be an angle mode corresponding to any one of the intra-frame prediction modes {3, 5, 7, ..., 65}. That is, the extended angle mode may be an angle mode between the basic angle modes within the first angle range. Therefore, the angle indicated by the extended angle mode can be determined based on the angle indicated by the basic angle mode.

[0078] According to another embodiment, the basic angle mode may be a mode corresponding to an angle within a preset first angle range, while the extended angle mode may be a wide-angle mode outside the first angle range. That is, the basic angle mode may be an angle mode corresponding to any one of the intra-prediction modes {2, 3, 4, ..., 66}, while the extended angle mode may be an angle mode corresponding to any one of the intra-prediction modes {-10, -9, ..., -1} and {67, 68, ..., 76}. The angle indicated by the extended angle mode may be determined as an angle on the opposite side of the angle indicated by the corresponding basic angle mode. Therefore, the angle indicated by the extended angle mode may be determined based on the angle indicated by the basic angle mode. The number of extended angle modes is not limited to this, and additional extended angles may be defined based on the size and / or shape of the current block. For example, the extended angle mode may be defined as an angle mode corresponding to any one of the intra-prediction modes {14, -13, ..., -1} and {67, 68, ..., 80}. The total number of intra-prediction modes included in the intra-prediction mode set may vary depending on the configuration of the basic angle mode and the extended angle mode.

[0079] In the above embodiment, the intervals between the extended angle modes can be set based on the intervals between the corresponding basic angle modes. For example, the intervals between the extended angle modes {3, 5, 7, ..., 65} can be determined based on the intervals between the corresponding basic angle modes {2, 4, 6, ..., 66}. In addition, the intervals between the extended angle modes {-10, -9, ..., -1} can be determined based on the intervals between the corresponding basic angle modes {56, 57, ..., 65} on the opposite sides, and the intervals between the extended angle modes {67, 68, ..., 76} can be determined based on the intervals between the corresponding basic angle modes {3, 4, ..., 12} on the opposite sides. The angular intervals between the extended angle modes can be set to be the same as the angular intervals between the corresponding basic angle modes. In addition, the number of extended angle modes in the intra-frame prediction mode set can be set to be less than or equal to the number of basic angle modes.

[0080] According to an embodiment of the present disclosure, an extended angle mode can be signaled based on a basic angle mode. For example, a wide-angle mode (i.e., an extended angle mode) can replace at least one angle mode (i.e., a basic angle mode) within a first angle range. The basic angle mode to be replaced can be a corresponding angle mode on the side opposite to the wide-angle mode. That is, the basic angle mode to be replaced is an angle mode corresponding to an angle in the opposite direction to the angle indicated by the wide-angle mode or an angle mode that differs from the angle in the opposite direction by a preset offset index. According to an embodiment of the present disclosure, the preset offset index is 1. The intra-frame prediction mode index corresponding to the basic angle mode to be replaced can be remapped to the wide-angle mode to signal the corresponding wide-angle mode. For example, wide-angle modes {-10, -9, ..., -1} can be signaled respectively by intra-frame prediction mode indices {57, 58, ..., 66}, and wide-angle modes {67, 68, ..., 76} can be signaled respectively by intra-frame prediction mode indices {2, 3, ..., 11}. In this way, the intra-frame prediction mode index used for the basic angular mode signals the extended angular mode. Therefore, even if the configuration of the angular mode used for intra-frame prediction of each block is different from each other, the same set of intra-frame prediction mode indexes can be used to signal the intra-frame prediction mode. Therefore, the signaling overhead caused by the change of the intra-frame prediction mode configuration can be minimized.

[0081] At the same time, whether to use the extended angle mode can be determined based on at least one of the shape and size of the current block. According to an embodiment, if the size of the current block is larger than a preset size, the extended angle mode can be used for intra-frame prediction of the current block, otherwise, only the basic angle mode can be used for intra-frame prediction of the current block. According to another embodiment, if the current block is a block other than a square block, the extended angle mode can be used for intra-frame prediction of the current block, and if the current block is a square block, only the basic angle mode can be used for intra-frame prediction of the current block.

[0082] The intra prediction unit determines the reference pixels and / or interpolated reference pixels to be used for intra prediction of the current block based on the intra prediction mode information of the current block. When the intra prediction mode index indicates a specific angle mode, the reference pixels or interpolated reference pixels corresponding to the specific angle from the current pixel of the current block are used for prediction of the current pixel. Therefore, depending on the intra prediction mode, different sets of reference pixels and / or interpolated reference pixels can be used for intra prediction. After performing intra prediction of the current block using the reference pixels and the intra prediction mode information, the decoder reconstructs the pixel values ​​of the current block by adding the residual signal of the current block obtained from the inverse transform unit to the intra predictor of the current block.

[0083] Figure 7 is a flowchart illustrating the operation of an apparatus for processing a video signal according to an embodiment of the present disclosure.

[0084] Will combine Figures 9 to 13 Describe in detail Figure 7 Each step.

[0085] Figure 8 is a diagram illustrating a prediction mode of block DPCM (BDPCM) and a quantized residual signal according to an embodiment of the present disclosure.

[0086] Block-based delta pulse code modulation (BDPCM) can be one of the intra prediction methods. BDPCM can use two intra prediction modes. Among the general intra prediction modes, vertical prediction mode and horizontal prediction mode can be used. When a total of 67 intra prediction modes are used, the index of the vertical prediction mode can be number 50, and the index of the horizontal prediction mode can be number 18. When BDPCM is used, one of the two modes can be signaled. When BDPCM is applied to the current coding block, unfiltered samples can be used as reference samples. When the vertical prediction mode is applied to BDPCM, samples corresponding to the width of the current coding block can be used, and each sample can be predicted using the same value in the corresponding column. When the horizontal prediction mode is applied to BDPCM, samples corresponding to the height of the current coding block can be used, and each sample can be predicted using the same value for all samples in the corresponding row. The block to which BDPCM is applied can be notified to the decoder by omitting the transform process and performing residual signal coding. Figure 8 The "BDPCM prediction mode" in is a method for coding the residual signal.

[0087] The size of the coding block can be M (rows) × N (columns), and r i,j , 0≤i≤M-1, 0≤j≤N-1 may be a prediction residual signal. The prediction residual signal may indicate the difference between the original sample value and the predicted value predicted using the reference sample. Q(r i,j ), 0≤i≤M-1, 0≤j≤N-1 can be a quantized prediction residual signal.

[0088] When vertical BDPCM is applied, the final value may be generated as follows.

[0089]

[0090] When horizontal-direction BDPCM is applied, the final value may be generated as follows.

[0091]

[0092] The decoder may perform calculations in the reverse manner of the encoder to generate a quantized residual signal, and add the quantized residual signal to the prediction value to produce a reconstructed signal.

[0093] Figure 9 This is a diagram showing BDPCM flags defined in a sequence parameter set.

[0094] At a higher level, a BDPCM flag can be defined and the corresponding function can be turned on / off. If the levels are listed in the order of the higher levels, the levels can be divided into video parameter sets, sequence parameter sets, parameter sets, etc. In the present disclosure, the flag is defined in the sequence parameter set (SPS). However, the present invention is not limited to this. BDPCM enable information sps_bdpcm_enabled_flag indicates whether BDPCM is enabled. The device for processing a video signal can perform step 710 of parsing BDPCM enable information sps_bdpcm_enabled_flag from the bitstream. If the BDPCM enable information sps_bdpcm_enabled_flag is equal to 1, it indicates that BDPCM is enabled. If the value of the BDPCM enable information sps_bdpcm_enabled_flag is equal to 0, it indicates that BDPCM is not enabled. The value indicating whether BDPCM is enabled or disabled can be defined in reverse, and the enabling or disabling of BDPCM can be indicated in any form.

[0095] As mentioned above, in Figure 9 In the

[0014] , the BDPCM enable information sps_bdpcm_enabled_flag is defined in sequence units, but is not limited thereto. The BDPCM enable information sps_bdpcm_enabled_flag may be signaled in at least one of a coding tree unit (CTU), a slice, a tile, a tile group, a picture, a sub-picture, a sequence, or a video. When the BDPCM enable information sps_bdpcm_enabled_flag is signaled in coding tree units (CTUs), slices, tiles, tile groups, pictures, sub-pictures, sequences, or videos, the name of the BDPCM enable information sps_bdpcm_enabled_flag may be changed. However, its function may remain the same.

[0096] Reference Figure 9, the BDPCM enabling information sps_bdpcm_enabled_flag can be parsed from the bitstream without special conditions. However, the present invention is not limited to this. The apparatus for processing a video signal can parse the transform skip enabling information sps_transform_skip_enabled_flag indicating whether the transform skip information transform_skip_flag exists in the transform unit from the bitstream. The transform unit is a unit for transforming pixels included in a coding block and can be included in the coding block. In addition, the current transform unit can be included in the current block. The transform skip enabling information sps_transform_skip_enabled_flag can be information indicating whether transform skip is to be used. The transform skip enabling information sps_transform_skip_enabled_flag can be signaled in sequence units. When the transform skip enabling information sps_transform_skip_enabled_flag is 1, it indicates that the transform skip information transform_skip_flag exists, and the apparatus for processing a video signal can parse the transform skip information transform_skip_flag from the bitstream later. When the transform skip enable information sps_transform_skip_enabled_flag is 0, it can indicate that the transform skip information transform_skip_flag does not exist, and the device for processing the video signal may not parse the transform skip information transform_skip_flag from the bitstream later. The fact that the decoder of the device for processing the video signal does not parse the transform skip information can indicate that the encoder of the device for processing the video signal does not generate the transform skip information. According to the present disclosure, when the transform skip enable information sps_transform_skip_enabled_flag is 1, the device for processing the video signal can parse the BDPCM enable information sps_bdpcm_enabled_flag from the bitstream.

[0097] Figure 10 is a diagram showing a portion of the syntax structure of a compilation unit.

[0098] Figure 10The structure of the required information in units of coding blocks to be predicted is shown, and the encoder can signal according to the corresponding conditions, and the decoder can also parse and obtain information from the bitstream according to the corresponding conditions. If the pcm_flag[x0][y0] at the upper left coordinate (x0, y0) of the corresponding coding block is equal to the value 0 indicating that the PCM mode is not applied, it can be checked whether the treeType is SINGLE_TREE or DUAL_TREE_LUMA. When the treeType is SINGLE_TREE or DUAL_TREE_LUMA, the device for processing the video signal can parse the intra-frame BDPCM information intra_bdpcm_flag from the bitstream. The intra-frame BDPCM information intra_bdpcm_flag can indicate whether BDPCM is applied to the current block. When the intra-frame BDPCM information intra_bdpcm_flag is 1, it can mean that BDPCM is applied to the current block. In addition, when the intra-frame BDPCM information intra_bdpcm_flag is 0, it can mean that BDPCM is not applied to the current block. However, the present invention is not limited to this. When the intra BDPCM information intra_bdpcm_flag is 0, it may mean that BDPCM is applied to the current block, and when the intra BDPCM information intra_bdpcm_flag is 1, it may mean that BDPCM is not applied to the current block.

[0099] The intra-frame BDPCM information intra_bdpcm_flag may be represented in a format such as intra_bdpcm_flag[x0][y0]. Here, x0 and y0 may be the coordinates of the current block. More specifically, x0 and y0 may be the coordinates of the upper left pixel of the current block.

[0100] In order to parse the intra-frame BDPCM information intra_bdpcm_flag, the conditions of the width and height of the corresponding coding unit and the enable / disable condition of the BDPCM enable information sps_bdpcm_enabled_flag may have to be satisfied. For example, the width and height are both less than or equal to 32, and the BDPCM enable information sps_bdpcm_enabled_flag may have to be equal to 1, indicating that the BDPCM enable information sps_bdpcm_enabled_flag is enabled. If the BDPCM enable information sps_bdpcm_enabled_flag is equal to 1, indicating that the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is used, the intra-frame BDPCM direction information intra_bdpcm_dir_flag[x0][y0] may be signaled / parsed. The corresponding flag may indicate the prediction mode applied to the BDPCM. The prediction mode may be one of the horizontal direction prediction mode number 18 and the vertical direction prediction mode number 50. If the intra BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 0, it may indicate intra prediction mode number 18, and if the intra BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 1, it may indicate intra prediction mode number 50. Whether the BDPCM function is used in a coding block may be determined by the value of sps_bdpcm_enabled_flag defined at a higher level.

[0101] Figure 11 is a diagram showing a portion of the syntax of a coding unit, and includes a size variable of a block to which BDPCM is applied.

[0102] The size of the block to which BDPCM is applied may also be variably changed by a preset variable, or the size of the block to which BDPCM is applied may be applied in combination with other preset variables. When the BDPCM enabling information sps_bdpcm_enabled_flag indicates that BDPCM is enabled, the width of the current block is less than or equal to the first value Value1, and the height of the current block is less than or equal to the second value Value2, the apparatus for processing a video signal may perform step 720 of parsing intra-frame BDPCM information intra_bdpcm_flag indicating whether BDPCM is to be applied to the current block from a bitstream.

[0103] More specifically, the condition for signaling / parsing intra-frame BDPCM information intra_bdpcm_flag[x0][y0] may be a case where the coding block width cbWidth is equal to or less than a first value Value1, or the coding block height cbHeight is equal to or less than a second value Value2. Value1 and Value2 may be the same or different values. For example, the first value Value1 and the second value Value2 may be the maximum block size MaxTsSize to which transform skipping is applied. The maximum block size MaxTsSize to which transform skipping is applied may be the maximum block size for which transform skipping is permitted. The maximum block size MaxTsSize to which transform skipping is permitted may be a value between 4 and 32. The maximum block size MaxTsSize to which transform skipping is permitted may be defined as follows. The syntax variable log2_transform_skip_max_size_minus2 indicates the maximum block size for which transform skipping is applied, and its value may be between 0 and 3. If the corresponding variable log2_transform_skip_max_size_minus2 does not exist, the value may be inferred to be 0. Using the corresponding variable log2_transform_skip_max_size_minus, the maximum block size MaxTsSize, which is a variable allowing transform skipping, is set to 1<<(log2_transform_skip_max_size_minus2+2).

[0104] Alternatively, a separate block size variable can be set for BDPCM without using log2_transform_skip_max_size_minus2 related to the transform skip condition. For example, the variable MaxBdpcmSize can be used. The size of MaxBdpcmSize can be set based on the value signaled as log2_bdpcm_max_size_minus2. MaxBdpcmSize can be set to 1<<(log2_transform_skip_max_size_minus2+2). log2_transform_skip_max_size_minus2 can be a maximum value at 0, and the maximum value can be one of the values ​​7, 6, 5, 4, 3, 2, and 1. When log2_transform_skip_max_size_minus2 related to the transform skip condition is used, no additional variable setting is required, so there may be no information to be additionally sent from the encoder to the decoder. Otherwise, when log2_bdpcm_max_size_minus2 is used, an additional variable such as log2_bdpcm_max_size_minus2 is required, but the degree of freedom of the block size may increase. Value1 and Value2 may also be set differently in a similar manner to the above.

[0105] The apparatus for processing a video signal may include sps_bdpcm_enabled_flag in the signaling / parsing conditions of the intra-frame BDPCM information intra_bdpcm_flag. It may be similar to sps_bdpcm_enabled_flag&&cbWidth<=Value1&&cbHeight<=Value2.

[0106] More specifically, Figure 11The structure of the required information in units of coding blocks to be predicted is shown, and the encoder can signal according to the corresponding conditions, and the decoder can also parse and obtain information from the bitstream according to the corresponding conditions. Referring to line 1110, the device for processing a video signal can determine whether pcm_flag[x0][y0] at the upper left coordinate (x0, y0) of the corresponding coding block indicates that the PCM mode is not applied. Referring to line 1120, if pcm_flag[x0][y0] at the upper left coordinate (x0, y0) of the coding block is equal to the value 0 indicating that the PCM mode is not applied, the device for processing the video signal can check whether treeType is SINGLE_TREE or DUAL_TREE_LUMA. In addition, when treeType is SINGLE_TREE or DUAL_TREE_LUMA, the device for processing the video signal can determine whether BDPCM enable information sps_bdpcm_enabled_flag indicates that BDPCM is enabled, whether the width of the current block is less than or equal to the first value Value1, or whether the height of the current block is less than or equal to the second value Value2. In line 1130, whether the BDPCM enable information sps_bdpcm_enabled_flag indicates that BDPCM is enabled is not described, but it is possible to determine whether the BDPCM enable information sps_bdpcm_enabled_flag indicates that BDPCM is enabled. Here, the first value and second value areas may each be the maximum block size MaxTsSize that allows transform skipping. Since the maximum block size MaxTsSize that allows transform skipping has already been described, its redundant description will be omitted.

[0107] Referring to line 1140 , when BDPCM enabling information sps_bdpcm_enabled_flag indicates that BDPCM is enabled, the width of the current block is less than or equal to the first value, and the height of the current block is less than or equal to the second value, the apparatus for processing a video signal may perform step 720 of parsing intra BDPCM information intra_bdpcm_flag from a bitstream.

[0108] The intra_bdpcm_flag information of the intra-frame BDPCM may indicate whether BDPCM is applied to the current block. The intra_bdpcm_flag information of the intra-frame BDPCM may be expressed in a format such as intra_bdpcm_flag[x0][y0]. Here, x0 and y0 may be the coordinates of the current block. More specifically, x0 and y0 may be the coordinates of the top left pixel of the current block.

[0109] Referring to line 1150, the apparatus for processing a video signal may determine whether intra-frame BDPCM information intra_bdpcm_flag[x0][y0] indicates the use of BDPCM. Referring to line 1160, when the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is applied to the current block, step 730 of parsing intra-frame BDPCM direction information intra_bdpcm_dir_flag for the current block from the bitstream may be performed. The intra-frame BDPCM direction information intra_bdpcm_dir_flag may indicate a horizontal direction or a vertical direction. For example, when the intra-frame BDPCM direction information intra_bdpcm_dir_flag is 0, the horizontal direction may be indicated. Alternatively, when the intra-frame BDPCM direction information intra_bdpcm_dir_flag is 1, the vertical direction may be indicated. However, the present invention is not limited to this. When the intra BDPCM direction information intra_bdpcm_dir_flag is 1, it may indicate a horizontal mode, and when the intra BDPCM direction information intra_bdpcm_dir_flag is 0, it may indicate a vertical mode.

[0110] Intra-frame BDPCM direction information intra_bdpcm_dir_flag can indicate the prediction mode applied to BDPCM. The prediction mode can be intra-frame prediction mode number 18 or intra-frame prediction mode number 50. Intra-frame prediction mode number 18 can be a horizontal prediction mode, and / or intra-frame prediction mode number 50 can be a vertical prediction mode. If the intra-frame BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 0, the BDPCM prediction direction can indicate the horizontal direction, and when the intra-frame BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 1, the BDPCM prediction direction can indicate the vertical direction. In addition, if the intra-frame BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 0, intra-frame prediction mode number 18 can be indicated, and if the intra-frame BDPCM direction information intra_bdpcm_dir_flag[x0][y0] value is 1, intra-frame prediction mode number 50 can be indicated. Whether a corresponding function is used in a coding block may be determined by a value of BDPCM enabling information sps_bdpcm_enabled_flag defined at a higher level.

[0111] Intra-frame BDPCM information intra_bdpcm_flag and intra-frame BDPCM direction information intra_bdpcm_dir_flag can be parsed for each chroma component and each luma component. Intra-frame BDPCM information intra_bdpcm_flag and intra-frame BDPCM direction information intra_bdpcm_dir_flag can be parsed for the luma component independently of the chroma component. That is, the apparatus for processing a video signal can parse intra-frame BDPCM information intra_bdpcm_luma_flag for the luma component or intra-frame BDPCM direction information intra_bdpcm_luma_dir_flag for the luma component in the same manner as described above, and can similarly parse intra-frame BDPCM information intra_bdpcm_chroma_flag for the chroma components or intra-frame BDPCM direction information intra_bdpcm_chroma_dir_flag for the chroma components.

[0112] The process for obtaining intra-frame BDPCM information intra_bdpcm_luma_flag for the luma component and intra-frame BDPCM direction information intra_bdpcm_luma_dir_flag for the luma component may be slightly different from the process for obtaining intra-frame BDPCM information intra_bdpcm_chroma_flag for the chroma component and intra-frame BDPCM direction information intra_bdpcm_chroma_dir_flag for the chroma component. This is because the current block of the luma component and the current block of the chroma component may be different from each other. More specifically, the size or position of the current block of the luma component may be different from the size or position of the current block of the chroma component. When the BDPCM enable information sps_bdpcm_enabled_flag indicates that BDPCM is enabled, the width of the current luma coding block is less than or equal to a first value, and the height of the current luma coding block is less than or equal to a second value, the apparatus for processing a video signal may parse the intra-frame BDPCM information intra_bdpcm_luma_flag for the luma component from the bitstream. Similarly, when the BDPCM enable information sps_bdpcm_enabled_flag indicates that BDPCM is enabled, the width of the current chroma coding block is less than or equal to the first value, and the height of the current chroma coding block is less than or equal to the second value, the apparatus for processing a video signal may parse the intra-frame BDPCM information intra_bdpcm_chroma_flag for the chroma component from the bitstream. In addition, when the intra-frame BDPCM information intra_bdpcm_luma_flag for the luma component indicates that BDPCM is applied to the current luma coding block, the apparatus for processing a video signal may perform the step of parsing the luma intra-frame BDPCM direction information intra_bdpcm_luma_dir_flag for the current luma coding block from the bitstream. Similarly, when the intra-frame BDPCM information intra_bdpcm_chroma_flag for the chroma component indicates that BDPCM is applied to the current chroma coding block, the apparatus for processing a video signal may perform a step of parsing the chroma intra-frame BDPCM direction information intra_bdpcm_chroma_dir_flag for the current chroma coding block from the bitstream. Here, the first value and the second value may each be a maximum block size MaxTsSize allowed for transform skipping.

[0113] In the present disclosure, the intra-frame BDPCM information intra_bdpcm_flag may include intra-frame BDPCM information intra_bdpcm_luma_flag for the luma component and intra-frame BDPCM information intra_bdpcm_chroma_flag for the chroma component. In addition, in the present disclosure, the intra-frame BDPCM direction information intra_bdpcm_dir_flag may include intra-frame BDPCM direction information intra_bdpcm_luma_dir_flag for the luma component and intra-frame BDPCM direction information intra_bdpcm_chroma_dir_flag for the chroma component.

[0114] The apparatus for processing a video signal may perform step 740 of reconstructing the current block based on the intra-frame BDPCM direction information intra_bdpcm_dir_flag. Figure 8 Step 740 of reconstructing the current block based on the intra BDPCM direction information intra_bdpcm_dir_flag is described, and thus a redundant description thereof will be omitted.

[0115] Figure 12 is a diagram showing a portion of the transform unit syntax.

[0116] For the compilation block that applies BDPCM, you can refer to Figure 8 The described method encodes the residual signal without a transform process. The syntax variable that prevents the transform process from being applied to the corresponding block may be transform skip information transform_skip_flag. That is, the transform skip information transform_skip_flag may indicate whether the transform is applied to the corresponding block. Alternatively, when the transform skip information transform_skip_flag is equal to a predetermined value, the transform skip information transform_skip_flag may indicate that the transform is not applied to the current block. When the transform skip information transform_skip_flag is 1, the transform may be skipped relative to the corresponding transform block. In addition, when the transform skip information transform_skip_flag is 0, the transform may not be skipped relative to the corresponding transform block. However, the present invention is not limited to this. When the transform skip information transform_skip_flag is 0, the transform may be skipped relative to the corresponding transform block. In addition, when the transform skip information transform_skip_flag is 1, the transform may not be skipped relative to the corresponding transform block.

[0117] For each color component, transform skip information transform_skip_flag can be expressed in a format such as transform_skip_flag[x0][y0]. Here, x0 and y0 may be the coordinates of the corresponding transform block. More specifically, x0 and y0 may be the coordinates of the upper left pixel of the corresponding block. As already described, the current block may include at least one transform block. The encoder may perform transform in units of transform blocks, and the decoder may perform inverse transform in units of transform blocks.

[0118] As conditions for signaling / parsing transform skip information transform_skip_flag[x0][y0], first, the value of tu_cbf_luma[x0][y0] must be 1, treeType must be different from DUAL_TYPE_TREE_CHROMA, the width and height of the coding unit must be less than or equal to 32, intraSubPartitionsSplit[x0][y0] must be equal to ISP_NO_SPLIT, cu_sbt_flag must be 0, and intra BDPCM information intra_bdpcm_flag[x0][y0] must be 0. In addition, the condition transform_skip_enabled_flag && tbWidth <= MaxTsSize && tbHeight <= MaxTsSize must be satisfied. tbWidth may be a variable indicating the width of a transform block, and tbHeight may be a variable indicating the height of a transform block.

[0119] The above conditions are exemplary, and some of the above conditions may be replaced or deleted with other conditions. Other conditions may also be added. However, some of the above conditions may be maintained to improve the encoding or decoding efficiency of the video image. For example, as already described, since transform skip is applied to the coding block to which BDPCM is applied, the application of transform skip can be known by inference without signaling / parsing separate information. That is, when the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is applied to the current block, the transform skip information transform_skip_flag indicating whether the transform is not applied to the current block may not be parsed. As already described, when the intra-frame BDPCM information intra_bdpcm_flag is 1, it may indicate that BDPCM is applied to the current block. When the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is not applied to the current block, the device for processing the video signal may determine whether to parse the transform skip information transform_skip_flag by further determining at least one of the above conditions.

[0120] When some of the above conditions are not met, since the transform skip information transform_skip_flag is not parsed, the transform skip information transform_skip_flag[x0][y0] may not exist. For example, when the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is applied to the current block, the transform skip information transform_skip_flag[x0][y0] may not exist. The apparatus for processing a video signal can know whether to apply transform skip by inferring transform_skip_flag based on the intra-frame BDPCM information intra_bdpcm_flag.

[0121] For example, if the transform skip information transform_skip_flag[x0][y0] does not exist and the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is 1, the apparatus for processing a video signal may infer the transform skip information transform_skip_flag[x0][y0] as a first inference value. Here, the fact that the intra-frame BDPCM information intra_bdpcm_flag is 1 may indicate that BDPCM is applied to the current block. When the value of the transform skip information is the first inference value, it may indicate that transform is not applied to the block corresponding to the transform skip information.

[0122] In addition, if the transform skip information transform_skip_flag[x0][y0] does not exist and the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is 0, the device for processing the video signal may infer the transform skip information transform_skip_flag[x0][y0] as a second inference value. Here, the fact that the intra-frame BDPCM information intra_bdpcm_flag is 0 may indicate that BDPCM is not applied to the current block. When the value of the transform skip information is the second inference value, it may indicate that the transform is applied to the block corresponding to the transform skip information. Here, the first inference value may be 1, and the second inference value may be 0. However, the present invention is not limited to this, and the first inference value may be 0, and the second inference value may be 1.

[0123] If the transform skip information transform_skip_flag[x0][y0] of the block to which BDPCM is applied is 1, the residual_ts_coding() function can be called. Figure 8In addition, MinBdpcmSize conditions for tbWidth and tbHeight can be added in the same way. The corresponding values ​​can be signaled and calculated in a similar way at a higher level. MinBdpcmSize conditions can also be added and applied to Figure 13 conditions shown.

[0124] Figure 13 is a diagram illustrating conditions for signaling / parsing a transform skip flag within a portion of a transform unit syntax.

[0125] Figure 13 is similar to Figure 12 Since transform skipping is applied to coding blocks to which BDPCM is applied, the application of transform skipping can be known by inference without signaling / parsing separate information. Therefore, a condition indicating that BDPCM is not applied can be added to the conditions for signaling / parsing the transform skip flag.

[0126] like Figure 13 As shown, the apparatus for processing a video signal may use a condition such as (transform_skip_enabled_flag&&tbWidth<=MaxTsSize&&tbHeight<=MaxTsSize&&(!intra_bdpcm_flag[x0][y0])) as a condition for parsing the transform skip information transform_skip_flag. In addition, when transform_skip_enabled_flag is equal to 1, tbWidth<=MaxTsSize, tbHeight<=MaxTsSize, and intra_bdpcm_flag[x0][y0] is equal to 0, the apparatus for processing a video signal may parse the transform skip information transform_skip_flag. That is, transform_skip_flag[x0][y0] may be signaled / parsed only for blocks to which the transform skip condition and BDPCM are not applied.

[0127] The conditions for signaling / parsing the transform skip information transform_skip_flag[x0][y0] may be as follows. Referring to line 1310, the video signal processing device may check whether the value of tu_cbf_luma[x0][y0] is 1, whether treeType is different from DUAL_TYPE_TREE_CHROMA, whether the width tbWidth and height tbHeight of the transform block are less than or equal to 32, whether IntraSubPartitionsSplit[x0][y0] is equal to ISP_NO_SPLIT, whether cu_sbt_flag is equal to 0, and whether the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is equal to 0. As already described, the fact that the intra-frame BDPCM information intra_bdpcm_flag is equal to 0 may mean that BDPCM is not applied to the current block. In addition, referring to line 1320 , the apparatus for processing a video signal may determine whether a condition of transform_skip_enabled_flag&&tbWidth<=MaxTsSize&&tbHeight<=MaxTsSize is satisfied.

[0128] The above conditions are exemplary, and some of the above conditions may be replaced or deleted with other conditions. Other conditions may also be added. However, some of the above conditions may be maintained to improve the encoding or decoding efficiency of the video image. For example, as already described, since the transform skip is applied to the coding block to which BDPCM is applied, separate information may not be signaled / parsed. That is, when the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is applied to the current block, the transform skip information transform_skip_flag indicating whether the transform is not applied to the current block may not be parsed. As already described, when the intra-frame BDPCM information intra_bdpcm_flag is 1, it may indicate that BDPCM is applied to the current block. When the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is not applied to the current block, the device for processing the video signal may determine whether to parse the transform skip information transform_skip_flag by further determining at least one of the above conditions.

[0129] When some of the above conditions are not met, a situation may occur where the transform skip information transform_skip_flag[x0][y0] does not exist. For example, when the intra-frame BDPCM information intra_bdpcm_flag indicates that BDPCM is applied to the current block, the transform skip information transform_skip_flag[x0][y0] may not exist. The device for processing a video signal can know whether to apply transform skip by inferring transform_skip_flag based on the intra-frame BDPCM information intra_bdpcm_flag. For example, if the transform skip information transform_skip_flag[x0][y0] does not exist and the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is 1, the device for processing a video signal can infer the transform skip information transform_skip_flag[x0][y0] to be 1. Here, the fact that the intra-frame BDPCM information intra_bdpcm_flag is 1 can indicate that BDPCM is applied to the current block. On the contrary, if the transform skip information transform_skip_flag[x0][y0] does not exist and the intra-frame BDPCM information intra_bdpcm_flag[x0][y0] is 0, the device for processing the video signal may infer the transform skip information transform_skip_flag[x0][y0] to be 0. Here, the fact that the intra-frame BDPCM information intra_bdpcm_flag is 0 may indicate that BDPCM is not applied to the current block. As described above, since the encoder does not transmit redundant information and the decoder does not parse the redundant information, the encoding / decoding efficiency can be improved. Since the encoder does not generate transform_skip_flag, the encoding efficiency can be improved and the bitstream capacity can be reduced. In addition, the decoder can improve the computational efficiency by inferring information without a parsing process.

[0130] The transform skip information transform_skip_flag may be parsed for each chroma component and each luma component. The chroma component may include Cb and Cr. The transform skip information transform_skip_flag may be parsed for each Cb and each Cr. The transform skip information transform_skip_flag may be parsed for the luma component independently of the chroma component. The transform skip information transform_skip_flag may be parsed for the chroma component independently of the luma component. The apparatus for processing a video signal may obtain the transform skip information transform_skip_flag for the luma component and obtain the transform skip information transform_skip_flag for the chroma component. In addition, when the transform skip information transform_skip_flag does not exist, the transform skip information transform_skip_flag may be inferred for each chroma component and each luma component. The apparatus for processing a video signal may infer the transform skip information transform_skip_flag using the method already described. Alternatively, the apparatus for processing a video signal may infer transform skip information transform_skip_flag for chroma components by using transform skip information transform_skip_flag for luma components.

[0131] Figure 14 : is a diagram showing the relationship between a block to which BDPCM is applied and an intra prediction mode variable.

[0132] For a block to which BDPCM is applied, the intra prediction mode may be indicated by the value of intra_bdpcm_dir_flag[x0][y0]. For example, when the intra BDPCM direction information intra_bdpcm_dir_flag is 0, the apparatus for processing a video signal may perform a step of selecting an intra prediction mode (mode number 18) corresponding to the horizontal direction from among a plurality of intra modes as the intra prediction mode for the current block. In addition, when the intra BDPCM direction information intra_bdpcm_dir_flag is 1, the apparatus for processing a video signal may perform a step of selecting an intra prediction mode (mode number 50) corresponding to the vertical direction from among a plurality of intra modes as the intra prediction mode for the current block.

[0133] The intra prediction mode used in the block to which BDPCM is applied is the same as the general intra prediction mode, so the corresponding mode can be stored as the variable IntraPredModeY[xCb][yCb], which indicates the intra prediction mode of the current prediction block and is used when deriving the MPM of the general coding block. That is, the intra prediction mode of the current block can be used to determine the intra prediction mode of the adjacent block to be reconstructed after the current block. In addition, the device for processing the video signal can store the intra prediction mode of the current block as a candidate for determining the intra prediction mode of the adjacent block to be reconstructed after the current block. The device for processing the video signal can determine the intra prediction mode of the adjacent block to be reconstructed after the current block by selecting one of the multiple stored candidates based on the parsed information.

[0134] In addition, the intra-frame prediction mode of the reconstructed coding block can be used to determine the intra-frame prediction mode of the current block. The apparatus for processing a video signal can store the intra-frame prediction mode of the reconstructed coding block as a candidate for determining the intra-frame prediction mode of the current block. The apparatus for processing a video signal can determine the intra-frame prediction mode of the current block by selecting one of the plurality of stored candidates based on the parsed information.

[0135] For example, if the current block is a normal block that is not a block to which BDPCM is applied, one of the reconstructed neighboring blocks is a block to which BDPCM is applied, and intra_bdpcm_dir_flag[x0][y0] is 0, intra-frame prediction mode number 18 may be stored in IntraPredModeY[xCb][yCb]. To encode or decode a normal coding block, a device for processing a video signal may use intra-frame prediction mode number 18 of the reconstructed neighboring block. More specifically, when deriving an MPM for the current block, the device for processing a video signal may use intra-frame prediction mode number 18 of the reconstructed neighboring block. Since the prediction mode for a block to which BDPCM is applied aims to minimize the final residual signal, the prediction method may be the same, but a preset value may be used because the residual signal pattern may differ from the typical case. The DC mode may be set to one of the vertical-to-horizontal mode of BDPCM, one of the horizontal-to-vertical mode of BDPCM, or one of the two-directional modes of BDPCM.

[0136] Although the above description has been described from the perspective of a decoder, it can also be applied to an encoder. In the above description, the term parsing is mainly described in terms of the process of obtaining information from a bitstream, but from the perspective of an encoder, parsing can be interpreted as composing the corresponding information in the bitstream. Therefore, the term parsing is not limited to decoder operations, and the term parsing can be interpreted as the act of composing a bitstream from the perspective of an encoder.

[0137] The above-mentioned embodiments of the present invention can be implemented by various means. For example, the embodiments of the present invention can be implemented by hardware, firmware, software or a combination thereof.

[0138] For the case of implementation through hardware, the method according to the embodiment of the present invention can be implemented by one or more of an application-specific integrated circuit (ASIC), a digital signal processor (DSP), a digital signal processing device (DSPD), a programmable logic device (PLD), a field programmable gate array (FPGA), a processor, a controller, a microcontroller, a microprocessor, etc.

[0139] In the case of implementation by firmware or software, the method according to the embodiment of the present invention can be implemented in the form of a module, process or function that performs the above-mentioned functions or operations. The software code can be stored in a memory and driven by a processor. The memory can be located inside or outside the processor and can exchange data with the processor through various known methods.

[0140] The above description of the present invention is for illustrative purposes only, and it will be understood that those skilled in the art to which the present invention pertains may make changes to the present invention without changing the technical concept or essential features of the present invention, and that the present invention may be easily modified in other specific forms. Therefore, the above embodiments are illustrative and not limiting in all respects. For example, each component described as a single entity may be distributed and implemented, and similarly, components described as distributed may also be implemented in an associated manner.

[0141] The scope of the present invention is defined by the appended claims rather than the detailed description above, and all changes or modifications derived from the meaning and scope of the appended claims and their equivalents should be construed as being included in the scope of the present invention.

Claims

1. A method for decoding a video signal, the method comprising: Parsing BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled from the bitstream; When the BDPCM enabling information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; When the intra BDPCM information indicates that the BDPCM is applied to the current block, parsing intra BDPCM direction information associated with the current block, the intra BDPCM direction information indicating a prediction direction of the BDPCM applied to the current block; and reconstructing the current block based on the intra-frame BDPCM direction information, When the intra BDPCM information indicates that the BDPCM is applied to the current block: - not parsing transform skip information from the bitstream, the transform skip information indicating whether a transform is applied to a transform block corresponding to the current block, - inferring the value of the transform skip information as a value indicating that the transform is not applied to the transform block.

2. The method according to claim 1, in, The first value and the second value are related to a maximum block size that is allowed to be skipped by a transform.

3. The method according to claim 1, in, The intra BDPCM information and the intra BDPCM direction information are parsed for the luma component independently of the chroma components.

4. The method according to claim 1, in, The BDPCM enabling information is signaled in a sequence parameter set.

5. The method according to claim 1, in, The intra-frame BDPCM direction information indicates one of a horizontal direction or a vertical direction.

6. The method according to claim 5, When the intra BDPCM direction information indicates the horizontal direction, the intra prediction mode of the current block is the intra prediction mode corresponding to the horizontal direction, and When the intra BDPCM direction information indicates the vertical direction, the intra prediction mode of the current block is an intra prediction mode corresponding to the vertical direction.

7. The method according to claim 6, further comprising: include: Wherein, when the value of the intra-frame BDPCM direction information is 0, the intra-frame BDPCM direction information indicates the horizontal direction; and When the value of the intra-frame BDPCM direction information is 1, the intra-frame BDPCM direction information indicates the vertical direction.

8. The method according to claim 7, in, The intra prediction mode of the current block is included in intra prediction mode candidates for signaling intra prediction modes of neighboring blocks to be reconstructed after the current block.

9. A device for decoding a video signal, the device comprising: processor; Wherein, the processor is configured to: Parsing BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled from the bitstream; When the BDPCM enabling information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; When the intra BDPCM information indicates that the BDPCM is applied to the current block, parsing intra BDPCM direction information associated with the current block, the intra BDPCM direction information indicating a prediction direction of the BDPCM applied to the current block; and reconstructing the current block based on the intra-frame BDPCM direction information, When the intra BDPCM information indicates that the BDPCM is applied to the current block: - not parsing transform skip information from the bitstream, the transform skip information indicating whether a transform is applied to a transform block corresponding to the current block, - inferring the value of the transform skip information as a value indicating that the transform is not applied to the transform block.

10. The device according to claim 9, in, The first value and the second value are related to a maximum block size that is allowed to be skipped by a transform.

11. The device according to claim 9, in, The intra BDPCM information and the intra BDPCM direction information are parsed for the luma component independently of the chroma components.

12. The apparatus according to claim 9, in, The BDPCM enabling information is signaled in a sequence parameter set.

13. The apparatus according to claim 9, in, The intra-frame BDPCM direction information indicates one of a horizontal direction or a vertical direction.

14. The device according to claim 13, When the intra BDPCM direction information indicates the horizontal direction, the intra prediction mode of the current block is the intra prediction mode corresponding to the horizontal direction, and When the intra BDPCM direction information indicates the vertical direction, the intra prediction mode of the current block is an intra prediction mode corresponding to the vertical direction.

15. The device according to claim 14, in, When the value of the intra-frame BDPCM direction information is 0, the intra-frame BDPCM direction information indicates the horizontal direction; and When the value of the intra-frame BDPCM direction information is 1, the intra-frame BDPCM direction information indicates the vertical direction.

16. The device according to claim 15, in, The intra prediction mode of the current block is included in intra prediction mode candidates for signaling intra prediction modes of neighboring blocks to be reconstructed after the current block.

17. A device for encoding a video signal, the device comprising: processor; Wherein, the processor is configured to: obtain a bitstream decoded by a decoder using a decoding method, The decoding method includes: Parsing BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled from the bitstream; When the BDPCM enabling information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; When the intra BDPCM information indicates that the BDPCM is applied to the current block, parsing intra BDPCM direction information associated with the current block, the intra BDPCM direction information indicating a prediction direction of the BDPCM applied to the current block; and reconstructing the current block based on the intra-frame BDPCM direction information, When the intra BDPCM information indicates that the BDPCM is applied to the current block: - not parsing transform skip information from the bitstream, the transform skip information indicating whether a transform is applied to a transform block corresponding to the current block, - inferring the value of the transform skip information as a value indicating that the transform is not applied to the transform block.

18. The apparatus according to claim 17, in, The first value and the second value are related to a maximum block size that is allowed to be skipped by a transform.

19. A method for obtaining a bitstream, the method comprising: obtain a bitstream decoded by a decoder using a decoding method, The decoding method includes: Parsing BDPCM enable information indicating whether block-based delta pulse code modulation (BDPCM) is enabled from the bitstream; When the BDPCM enabling information indicates that the BDPCM is enabled, the width of the current block is less than or equal to a first value, and the height of the current block is less than or equal to a second value, parsing intra-frame BDPCM information indicating whether the BDPCM is applied to the current block from the bitstream; When the intra BDPCM information indicates that the BDPCM is applied to the current block, parsing intra BDPCM direction information associated with the current block, the intra BDPCM direction information indicating a prediction direction of the BDPCM applied to the current block; and reconstructing the current block based on the intra-frame BDPCM direction information, When the intra BDPCM information indicates that the BDPCM is applied to the current block: - not parsing transform skip information from the bitstream, the transform skip information indicating whether a transform is applied to a transform block corresponding to the current block, - inferring the value of the transform skip information as a value indicating that the transform is not applied to the transform block.