Decoding method for video signals

By using encoding blocks and transformation blocks of various shapes and adjusting the encoding sequence according to the in-screen prediction mode, the problem of low encoding efficiency of high-resolution image in the prior art is solved, and more efficient video signal encoding is achieved.

CN114222139BActive Publication Date: 2025-06-17KONINKLIJKE PHILIPS NV
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202210049201.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Priority Date
2017-05-16
Filing Date
2017-05-26
Publication Date
2025-06-17
Estimated Expiration
2037-05-26

AI Technical Summary

Technical Problem

When existing video signal encoding technology processes high-resolution images, the encoding efficiency is low and it is difficult to effectively utilize the characteristics and prediction modes of the images, resulting in an increase in transmission and storage costs.

Method used

The encoding blocks and transformation blocks of various shapes are used to determine the encoding order of the transformation blocks according to the in-screen prediction mode of the current block, and scan the multiple transformation areas by dividing the transformation blocks to improve the encoding efficiency.

Benefits of technology

The encoding efficiency of video signals is improved, especially when processing high-resolution images, the cost of transmission and storage is reduced, and the encoding efficiency of in-screen prediction is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114222139B_ABST
    Figure CN114222139B_ABST
Patent Text Reader

Abstract

The present invention relates to a method for decoding a video signal. A method for decoding a video signal according to an embodiment of the present invention includes a scanning method for scanning a transform block having a plurality of transform coefficient groups, and includes the following steps: obtaining transform region information indicating at least one or more of a plurality of transform regions included in the transform block; dividing the transform block into at least one transform region among the plurality of transform regions based on the transform region information; respectively obtaining scanning methods for the transform regions; and scanning a part of the transform region based on the obtained scanning methods.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] This application is a divisional application of a patent application with an application date of May 26, 2017, an application number of 201780033620.7, and a title of "Video Signal Encoding or Decoding Method and Apparatus". Technical Field

[0002] The present invention relates to a method for decoding a video signal. Background Art

[0003] Recently, there has been an increasing need for high-resolution and high-quality images such as high definition (HD) images and ultra high definition (UHD) images in various application fields. To make image data high-resolution and high-quality, the amount of data has increased relatively compared to conventional image data. Therefore, when transmitting image data using a medium such as a conventional wired or wireless broadband circuit or storing it using a conventional storage medium, the transmission cost and storage cost increase. To solve such problems caused by the high-resolution and high-quality of image data, an efficient image compression technique is used.

[0004] Video compression techniques include spatial prediction and / or temporal prediction to reduce or remove redundancy inherent in a video sequence. In a block-based video coding process, a video frame or slice may be divided into blocks. Each block may be further divided. Blocks in an intra-coded I-frame or slice are encoded using spatial prediction for reference samples in adjacent blocks in the same frame or slice. Blocks in a slice of an inter-coded P or B frame may use spatial prediction for reference samples in adjacent blocks in the same frame or slice or temporal prediction for reference samples in other reference frames. Spatial or temporal prediction may generate a prediction block related to the encoded block. Residual data represents the pixel difference between the encoded original block and the prediction block.

[0005] Generally, a current block encodes an image using square coding units (CUs) and transform units (TUs) of the same size. Based on the size of each coding block or prediction block, multiple transform units are applied to the coding block through a quadtree segmentation structure. However, in the case of using such square coding blocks, it is necessary to transmit the prediction mode and prediction information of each coding block. Therefore, depending on the type of image, unnecessary information is transmitted, resulting in a decrease in coding efficiency. Also, there is a problem that the characteristics of the residual block signal generated according to the characteristics of the image corresponding to the coding block and the prediction mode have not been considered.

[0006] Also, in a video centennial decoder, multiple-sized coding units are utilized. Thus, encoding can be effectively performed by considering the spatial resolution and characteristics of the image. Generally, when the resolution of the image is small or the pixel values locally increase, it is more effective to use small-sized coding units to perform intra-picture and inter-picture prediction. As described above, when using small-sized coding units, the amount of header bits for encoding increases. However, relatively, prediction can be performed precisely, and thus, the amount of bits for encoding quantization errors and transform coefficients decreases.

[0007] Conversely, in regions where the spatial resolution of the image is large or the change in pixel values is small, using large coding units can improve the encoding efficiency. In this case, compared with the case of using small coding units, using large coding units does not significantly increase the prediction error. Therefore, when encoding such blocks, using large coding units can effectively reduce the transmission bit amount. However, even using various conventional coding units, it is difficult to effectively encode various images with high resolution.

[0008] In video compression techniques for improving encoding efficiency, motion prediction is used to remove the temporal redundancy between multiple consecutive pictures. To detect the temporal redundancy, multiple reference pictures are used to predict the motion of the current block, and motion compensation is performed to generate a predicted block. The motion information includes at least one reference picture index and at least one motion vector.

[0009] Also, to obtain the motion information, the current block performs bidirectional prediction to form a list of predicted motion vectors of the current block, and uses it to transmit the differential motion vector, which is the difference value from the motion vector of the current block, to the decoder. In this case, the lists of predicted motion vectors including the predicted motion vectors for each direction are independent of each other. However, multiple sizes are used for inter-picture prediction and increase the correlation between the motion information of the current block and the motion information of one or more adjacent blocks. Therefore, according to the conventional compression method, the size of the picture is larger than that of a high-quality picture. When multiple sizes are used for motion prediction and motion compensation, the compression efficiency of the motion information decreases. Summary of the Invention

[0010] Technical Problem

[0011] The technical problem to be solved by the present invention is to provide an encoding and decoding apparatus for video signals, that is, by using coding blocks and transform blocks of various shapes according to the image, thereby improving the encoding efficiency.

[0012] Also, another problem to be solved by the present invention is to provide a method and apparatus for encoding and decoding video signals, that is, to determine the encoding order of transform blocks that can improve the encoding efficiency according to the intra-picture prediction mode of the current block.

[0013] The technical problem to be solved by the present invention is to provide a decoding method and apparatus for video signals, that is, to improve the coding efficiency of intra-picture prediction by using transform blocks of various shapes.

[0014] Furthermore, the technical problem to be solved by the present invention is to provide a decoding method and apparatus for video signals, that is, to improve the coding efficiency by encoding a set of transform coefficients in a low-frequency region first compared to a high-frequency region.

[0015] The technical problem to be solved by the present invention is to provide a method and apparatus for constructing a prediction motion vector list, which utilizes highly relevant information during bidirectional prediction of a current block, thereby improving the coding efficiency of inter-picture prediction.

[0016] Furthermore, the technical problem to be solved by the present invention is to provide a method and apparatus for constructing a prediction motion vector list that improves the coding efficiency according to whether reference pictures used for bidirectional prediction of a current block are the same or not.

[0017] Technical solution

[0018] A decoding method for a video signal according to an embodiment of the present invention for solving the above problems includes a scanning method for scanning a transform block having a plurality of sets of transform coefficients, including the following steps: obtaining transform region information indicating at least one or more of a plurality of transform regions included in the transform block; dividing the transform block into at least one transform region among the plurality of transform regions based on the transform region information; respectively obtaining scanning methods for the transform regions; and scanning a part of the transform region based on the obtained scanning methods.

[0019] A decoding method for a video signal according to an embodiment of the present invention for solving the above problems includes: a step of setting a structure of an encoding block constituting a current image; a step of setting a structure of a plurality of transform blocks corresponding to the encoding block; and a step of generating a prediction signal by using the plurality of transform blocks, wherein the encoding block includes one or more of a square block and a non-square block.

[0020] The above transform block includes one or more of square transform blocks and non-square transform blocks having the same size and a smaller size in the above encoding block.

[0021] In one embodiment, the above square transform block is a transform block having a quadtree structure, and the above non-square transform block is a transform block having a non-square binary tree structure or a non-square quadtree structure. Furthermore, the decoding method for the video signal may further include a step of receiving transform block segmentation information indicating the shape and size of the transform block.

[0022] In one embodiment, the above transformation block includes one or more of a non-square transformation sub-block and a square transformation sub-block for segmentation, and further includes a step of further dividing the above transformation block into a plurality of sub-transformation blocks. In the case of being further divided into the above plurality of sub-transformation blocks, the above prediction signal is generated corresponding to each of the above sub-transformation blocks. And, the above plurality of sub-transformation blocks includes one or more of a non-square sub-transformation block and a square sub-transformation block.

[0023] In one embodiment, the above method for decoding a video signal may further include: when performing intra prediction on the above current block, a step of determining which of a first mode region having an angle of more than 90 degrees and less than 180 degrees, a second mode region having an angle of more than 180 degrees and less than 225 degrees, and a third region having an angle of more than 45 degrees and less than 90 degrees the direction of the intra prediction mode of the above current block belongs to; and a step of variably determining the encoding order of the above transformation block based on the mode region to which the above intra prediction mode belongs.

[0024] When the direction of the above intra prediction mode is in the second mode region, the above transformation block is encoded in the order from the lower left end to the upper right end. If the above transformation block is a square transformation block, it is encoded in the order of the lower left end, the lower right end, the upper left end, and the upper right end. If the above transformation block is a square transformation block, it is encoded in the order of the lower left end, the upper left end, the lower right end, and the upper right end.

[0025] And, if the above transformation block is a non-square transformation block divided vertically, it is encoded in the order from left to right. If the above transformation block is a non-square transformation block divided horizontally, it is encoded in the order from the lower end to the upper end.

[0026] When the direction of the above intra prediction mode is in the third region mode, the above transformation block is encoded in the order from the upper right end to the lower left end. If the above transformation block is a square transformation block, it is encoded in the order of the upper right end, the upper left end, the lower right end, and the lower left end. If the above transformation block is a square transformation block, it is encoded in the order of the upper right end, the lower right end, the upper left end, and the lower left end.

[0027] And, if the above transformation block is a non-square transformation block divided vertically, it is encoded in the order from right to left. If the above transformation block is a non-square transformation block divided horizontally, it is encoded in the order from the upper end to the lower end.

[0028] The decoding device for a video signal according to another embodiment of the present invention for solving the above problems includes: a block setting unit that sets the structure of coding blocks constituting a current image and sets the structure of a plurality of transform blocks corresponding to the coding blocks; and a prediction signal generation unit that generates a prediction signal using the plurality of transform blocks. The coding blocks and the transform blocks include one or more of square blocks and non-square blocks. The prediction signal generation unit encodes the plurality of transform blocks in a variable coding order according to which mode region among a plurality of mode regions divided according to a prediction direction the coding block belongs to in an intra prediction mode of the coding block.

[0029] The decoding method for a video signal according to an embodiment of the present invention for solving the above problems scans a transform block including a plurality of transform coefficient groups. The method includes: a step of obtaining transform region information indicating one or more transform regions included in the transform block; a step of scanning a plurality of transform coefficient groups included in a first transform region based on the transform region information; and a step of scanning a plurality of transform coefficient groups included in a second transform region within the transform block.

[0030] Among the plurality of transform coefficient groups, the transform coefficient groups in a low-frequency region are scanned preferentially compared to the transform coefficient groups in a high-frequency region.

[0031] In one embodiment, the transform region information is received from an encoder or obtained from one or more of a sequence parameter set and a slice header. And the transform region information is obtained by a preset method in a decoder.

[0032] Before the step of obtaining the transform region information, it further includes a step of determining whether the transform block is a non-square block. The determination step is performed based on the horizontal length and the vertical length of the transform block.

[0033] The decoding device for a video signal according to an embodiment of the present invention for solving the above another problem includes: a transform region information acquisition unit that acquires transform region information indicating one or more transform regions included in a transform block; and a transform coefficient group scanning unit that, based on the transform region information, sequentially scans a plurality of transform coefficient groups included in each of the one or more transform regions.

[0034] The method for constructing a prediction motion vector list according to an embodiment of the present invention for solving the above problems includes: a step of obtaining a motion vector related to a first direction of a current block; and a step of using the motion vector related to the first direction to set one or more candidate prediction motion vectors in a second direction that constitute the prediction motion vector list in the second direction.

[0035] One or more candidate predicted motion vectors in the above second direction are set by copying the motion vectors related to the above first direction, and the reference picture related to the above first direction and the reference picture related to the above second direction have the same picture information. Further, the candidate predicted motion vectors in the above second direction are assigned to indices in the order of having the smallest codewords.

[0036] In one embodiment, the candidate predicted motion vectors in the above second direction are set by scaling the motion vectors related to the above first direction based on picture information, and the picture information of the reference picture related to the above first direction and the reference picture related to the above second direction is different. The candidate predicted motion vectors in the above second direction are assigned to indices in the order of having the smallest codewords.

[0037] Before the step of setting one or more candidate predicted motion vectors in the above second direction, there is further a step of determining whether the picture information of the reference picture related to the above first square and the reference picture related to the above second direction is the same.

[0038] An apparatus for constructing a predicted motion vector list according to another embodiment of the present invention for solving the above problems includes: a motion vector acquisition unit for acquiring motion vectors related to a first direction of a current block; and a second direction predicted motion vector list setting unit for setting one or more candidate predicted motion vectors in the second direction that constitute the predicted motion vector list in the above second direction by using the motion vectors related to the above first direction.

[0039] The above second direction predicted motion vector list setting unit includes: a first candidate predicted motion vector setting unit for setting one or more candidate predicted motion vectors in the above second direction by using the motion vectors related to the above first direction; and a second candidate predicted motion vector setting unit for setting one or more candidate predicted motion vectors in the above second direction by using spatially and temporally adjacent blocks of the above current block.

[0040] The candidate predicted motion vectors in the above second direction obtained from the above first candidate predicted motion vector setting unit are set by copying the motion vectors related to the above first direction, and the picture information of the reference picture related to the above first direction and the reference picture related to the above second direction is the same.

[0041] The candidate predicted motion vectors in the above second direction obtained from the above first candidate predicted motion vector setting unit are set by scaling the motion vectors related to the above first direction based on picture information, and the picture information of the reference picture related to the above first direction and the reference picture related to the above second direction is different. Further, the candidate predicted motion vectors in the above second direction obtained from the above first candidate predicted motion vector setting unit are assigned to indices in the order of having the smallest codewords.

[0042] Beneficial effects

[0043] According to an embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, non-square coding blocks and non-square transform blocks are used according to an image, thereby improving the encoding efficiency.

[0044] Moreover, according to another embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, the encoding order of a transform block is changed according to the direction of an intra prediction mode of a current block, thereby high-resolution images can be encoded and decoded, and the encoding order of a transform block that increases the encoding efficiency can be determined.

[0045] According to an embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, in the case where a transform block is a non-square block, the transform block is divided into one or more transform regions including a part of a plurality of transform coefficient groups, and the transform coefficient groups included in the transform regions are scanned in sequence, thereby improving the encoding efficiency of intra prediction.

[0046] Moreover, according to another embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, the transform block is divided into one or more transform regions, and the transform coefficient groups included in the divided transform regions are scanned in sequence, thereby, compared with a high-frequency region, the transform coefficient groups of a low-frequency region are preferentially encoded, thereby the encoding efficiency can be improved.

[0047] According to an embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, when constructing a prediction motion vector list for a second direction, the motion vector in a first direction of a current block that performs bi-directional prediction is used for setting one or more candidate prediction motion vectors, thereby, when performing inter prediction, information with high correlation is used, thereby improving the encoding efficiency of inter prediction.

[0048] Moreover, according to another embodiment of the present invention, the present invention provides an apparatus for encoding and decoding a video signal, that is, it is determined whether reference pictures for bi-directional prediction of a current block are the same, and according to whether they are the same, the motion vector in a first direction is used as one or more candidate prediction motion vectors when constructing a prediction motion vector list for a second direction through various methods, thereby the encoding efficiency can be improved. Description of the drawings

[0049] Figure 1 It is a block diagram for briefly showing a video encoding apparatus according to an embodiment of the present invention.

[0050] Figure 2 It is a block diagram for briefly showing a video decoding apparatus according to an embodiment of the present invention.

[0051] Figure 3The coding block of the current block for explaining the general method.

[0052] Figures 4a to 4c An illustration of the non-square coding block of the current block showing an embodiment of the present invention.

[0053] Figures 5a to 6d An illustration showing a plurality of transform blocks for the current coding block of an embodiment of the present invention.

[0054] Figures 7a to 10 An illustration showing a plurality of sub-transform blocks of an embodiment of the present invention.

[0055] Figure 11 The coding order and method of the transform block for explaining the general method.

[0056] Figures 12a to 12c An illustration showing a plurality of transform blocks of an embodiment of the present invention.

[0057] Figure 13 An illustration showing the mode area to which the intra prediction mode of an embodiment of the present invention belongs.

[0058] Figure 14a And Figure 14b An illustration showing the coding order of a plurality of transform blocks when the intra prediction mode of the current block of an embodiment of the present invention belongs to the first mode area.

[0059] Figures 15a to 15c An illustration showing the coding order of a plurality of transform blocks when the intra prediction mode of the current block of an embodiment of the present invention belongs to the second mode area.

[0060] Figures 16a to 16c An illustration showing the coding order of a plurality of transform blocks when the intra prediction mode of the current block of an embodiment of the present invention belongs to the third mode area.

[0061] Figures 17a to 19c Illustrations showing various orders of encoding square and non-square transform blocks by applying the coding order of the transform block considering the intra prediction mode of an embodiment of the present invention.

[0062] Figure 20 For explaining the structure of the general transform block.

[0063] Figure 21 For explaining the transform coefficient group constituting the general 16x16 transform block.

[0064] Figure 22 For explaining the transform coefficient group of the general method and the transform scanning method of the above transform coefficient group.

[0065] Figures 23a to 23d For explaining the types of the transform coefficient group of the general method and the scanning method of the above transform coefficient group.

[0066] Figure 24a and Figure 24b Examples for explaining the transform block applicable scanning method in an embodiment of the present invention.

[0067] Figure 25 Examples for explaining the application of the general scanning method to the transform of a 16x8 transform block.

[0068] Figure 26 A flowchart showing a method for scanning a transform coefficient group in an embodiment of the present invention.

[0069] Figure 27 An apparatus for scanning a transform coefficient group in an embodiment of the present invention.

[0070] Figure 28a and Figure 28b Methods for explaining the scanning of the transform coefficient group of a non-square transform block for an embodiment of the present invention.

[0071] Figures 29a to 30d Methods for explaining various scanning methods for a non-square transform block for an embodiment of the present invention.

[0072] Figure 31 For explaining the acquisition of the candidate prediction motion vector (MVP candidate) position of the current block of the general method.

[0073] Figures 32 to 33b Methods for explaining the construction of the prediction motion vector list of the current block of the general method.

[0074] Figure 34 A flowchart for explaining the method of constructing the prediction motion vector list in an embodiment of the present invention.

[0075] Figure 35 A flowchart for explaining the apparatus for constructing the prediction motion vector list in an embodiment of the present invention.

[0076] Figure 36 and Figure 37 A flowchart and an apparatus for showing the method of constructing the prediction motion vector list in another embodiment of the present invention.

[0077] Figure 38a and Figure 38b Methods for explaining the construction of the prediction motion vector list in an embodiment of the present invention.

[0078] Figure 39 A flowchart for showing the method of constructing the prediction motion vector list in another embodiment of the present invention. Detailed implementation manners

[0079] Hereinafter, with reference to the accompanying drawings, preferred embodiments of the present invention will be described in detail.

[0080] The embodiments of the present invention are provided to more completely provide the present invention to those of ordinary skill in the art to which the present invention pertains. The following embodiments can be deformed into various other forms, and the scope of the present invention is not limited to the following embodiments. Instead, these embodiments make the present disclosure more substantial and complete, and fully provide the idea of the present invention to those of ordinary skill in the art of the technology shown in the present invention.

[0081] Also, in the figures, the thickness or size of each unit is enlarged for convenience and clarity of illustration. In the figures, the same reference numerals denote the same structural elements. As used in this specification, the term "and / or" includes all combinations of one or more of the corresponding listed items.

[0082] The terms used in this specification are used to describe specific embodiments and are not intended to limit the present invention. As used in this specification, the singular form does not specify otherwise in the context and may include the plural form. Also, when used in this specification, "comprise" and / or "comprising" the presence of a specifically mentioned shape, number, step, action, component, element, and / or a group of these does not exclude the presence or addition of one or more other shapes, numbers, actions, components, elements, and / or groups.

[0083] In this specification, terms such as first, second, etc. are used to describe various structural elements, components, parts, regions, and / or portions. These structural elements, components, parts, regions, and / or portions are not limited to these terms. These terms are used to distinguish one structural element, component, part, region, or portion from other regions or portions. Therefore, hereinafter, the above-mentioned first structural element, component, part, region, or portion may be referred to as the second structural element, component, part, region, or portion without departing from the gist of the present invention. Also, the term "and / or" includes a combination of multiple related recited items or one of the multiple related recited items.

[0084] When a structural element is "connected" or "coupled" to another structural element, it includes the case of being directly connected or coupled to the above-mentioned other structural element and the case where there are other structural elements between the above-mentioned one structural element and the above-mentioned other structural element. However, when a structural element is "directly connected" or "directly coupled" to another structural element, there are no other structural elements in between, but the above-mentioned one structural element is directly connected or coupled to the above-mentioned other structural element.

[0085] Hereinafter, embodiments of the present invention will be described with reference to the drawings briefly showing the embodiments of the present invention. In the drawings, for example, the size and shape of components are enlarged for convenience and clarity of explanation, and when actually implemented, deformation of the shown shape can be expected. Therefore, the embodiments of the present invention are not limited to the specific shapes of the regions shown in this specification.

[0086] Figure 1 The block diagram briefly showing an image coding device according to an embodiment of the present invention.

[0087] Refer to Figure 1 , the image coding device 1000 includes a picture segmentation unit 1050, an inter-picture prediction unit 1100, an intra / inter-picture prediction unit 1150, a transform unit 1200, a quantization unit 1250, a reordering unit 1300, an entropy coding unit 1350, an inverse quantization unit 1400, an inverse transform unit 1450, a filtering unit 1500, and a memory 1550.

[0088] Figure 1 Each of the structural elements shown is independently shown for presenting different specific functions in the image coding device, and each structural element is not formed by separate hardware or a single software component unit. That is, each structural element is listed as each structural element for convenience of explanation, and in each structural element, at least two structural elements are combined into other structural elements, or one structural element is divided into multiple structural elements. Such embodiments of combining each structural element or separating embodiments also belong to the protection scope of the present invention as long as they do not exceed the essential implementation modes of the present invention.

[0089] The picture segmentation unit 1050 can divide the input picture into at least one picture processing unit. The above processing unit can be a prediction block (Prediction Unit, hereinafter referred to as "PU"), or a transform block (Transform Unit, hereinafter referred to as "TU"), or a coding block (Coding Unit, hereinafter referred to as "CU"). However, in this specification, for convenience of explanation, the prediction block is represented as a prediction unit, the transform block is represented as a transform unit, and the coding or decoding block is represented as a coding unit or a decoding unit.

[0090] In one embodiment, the picture segmentation unit 1050 divides one picture into a combination of multiple coding blocks, prediction blocks, and transform blocks, and selects a combination of one coding block, prediction block, and transform block to code the picture based on a specified criterion (for example, a cost function).

[0091] For example, an image can be divided into multiple coding blocks. In one embodiment, an image uses a recursive tree branch structure such as a quadtree or binary tree structure to divide the above-mentioned coding blocks. The coding blocks that divide an image or the largest coding unit as the root of the tree into other coding blocks have nodes with a certain number of codings for division. Through this process, the coding blocks that cannot be divided any further can become leaf nodes. For example, for a coding block, in the case where only square cutting is possible, it can be divided into, for example, 4 coding blocks.

[0092] However, in the present invention, when the above-mentioned coding blocks, prediction blocks, and / or transform blocks are divided, they are not limited to symmetric division, and can also be asymmetric division. Not only 4 divisions, but also 2 divisions are possible. However, this number of divisions is only an example, and the present invention is not limited thereto. As described above, with reference to Figures 3 to 19c A method and apparatus for encoding and decoding a video signal using non-square blocks in which coding blocks and transform blocks are symmetrically divided will be described.

[0093] The prediction blocks are also divided in the form of at least one square or non-square of the same size within a coding block. Among the prediction blocks divided within a coding block, the shape and size of one prediction block are different from those of other prediction blocks. In one embodiment, the coding block and the prediction block can be the same. That is, without distinguishing between the coding block and the prediction block, prediction is performed based on the divided coding block.

[0094] The inter-picture prediction unit may include an inter-picture prediction unit 1100 that performs inter prediction and an intra-inter-picture prediction unit 1150 that performs intra prediction. To improve the encoding efficiency, instead of encoding the encoded video signal, a specific area within a picture that has been pre-encoded and decoded is used to predict the video, and the residual interpolation value between the original video and the predicted video is encoded. Also, the prediction mode information, motion vector information, etc. used for prediction are encoded together with the residual interpolation value in the entropy encoding unit 1350 and transmitted to the decoding unit. In the case of using a specific coding mode, instead of generating a prediction block through the inter-picture prediction unit 1100 and 1150, the original block is directly encoded and transmitted to the decoding unit.

[0095] In one embodiment, the inter-picture prediction units 1100 and 1150 determine whether to perform inter-picture prediction or intra-picture prediction on a prediction block, and can determine specific information about the above prediction method based on the inter-picture prediction mode, motion vector, and reference picture. In this case, the processing unit that performs the prediction, the prediction method, and the west processing unit are different from each other. For example, the prediction mode and prediction method can be determined according to the prediction block, and the execution of the prediction can be changed according to the transform block.

[0096] The inter-picture prediction units 1100 and 1150 perform prediction on the processing unit of the picture segmented in the picture segmentation unit 1050 to generate a prediction block composed of predicted samples. The picture processing unit in the inter-picture prediction units 1100 and 1150 can be a coding block unit, a transform block unit, or a prediction block unit.

[0097] The inter-picture prediction unit 1100 performs prediction on the prediction block based on information of one or more pictures among the pictures before or after the current picture, and in some cases, performs prediction on the prediction block based on information of a part of the area where the coding within the current picture is completed. The inter-picture prediction unit 1100 may include a reference picture interpolation unit, a motion inter-picture prediction unit, and a motion compensation unit.

[0098] In one embodiment, the information of the above one or more pictures used for prediction in the inter-picture prediction unit 1100 can be information of pre-coded and decoded pictures, or information of pictures stored with deformation in any direction. For example, the pictures stored with deformation by the above arbitrary method can be pictures for which encoding and decoding are performed with magnification or reduction, or pictures for which the brightness of all pixel values within the picture is changed to form a color format.

[0099] The reference picture interpolation unit receives reference picture information from the storage unit 1550 to generate pixel information below positive numbers in the reference picture. In the case of luminance pixels, a discrete cosine transform-based 8-point interpolation filter (DCT-based Interpolation Filter) that changes the coefficients of the filter is used to generate pixel information below positive numbers in units of 1 / 4 pixels. In the case of chrominance information, a 4-point interpolation filter based on the discrete cosine transform of the coefficients of the pen filter is used to generate pixel information below positive numbers in units of 1 / 8 pixels. However, the type of filter and the unit for generating pixel information below positive numbers are not limited to this, and it is possible to determine to use various interpolation filters to generate pixel information below positive numbers.

[0100] The inter - picture prediction unit performs motion prediction based on the reference picture interpolated by the above - mentioned picture interpolation unit. Multiple methods are used to calculate the motion vector. The motion vector has a motion vector value in units of increased - speed pixels or 1 / 4 or 1 / 8 pixel units based on the interpolated pixels. In one embodiment, in the inter - picture prediction unit, the motion prediction method is changed to predict the prediction unit of the current block. The above - mentioned motion prediction method can use multiple methods including a hybrid method, an advanced motion vector prediction method, and a skip method. As described above, the information including the index of the reference picture selected in the inter - picture prediction unit 1100, the candidate predicted motion vector, and the residual signal is entropy - encoded and transmitted to the decoder.

[0101] Different from the inter - picture prediction, the intra - picture inter - picture prediction unit 1150 generates a prediction block based on the reference pixel information around the current block, which is the pixel information within the current picture. When the surrounding block of the above - mentioned prediction block is a block for performing inter - picture prediction, the reference pixels included in the block are replaced by the reference pixel information of the block for performing intra - picture prediction around the perimeter and used.

[0102] When the above - mentioned reference pixels cannot be used, it is necessary to set it to a state where the above - mentioned reference pixels can be used. Generally, in the above - mentioned case, among the available surrounding pixels, the above - mentioned available reference pixels are replaced and used by at least one reference pixel or a preset sample value is assigned.

[0103] However, the method of copying the available reference pixels for the unavailable reference pixels has the problem of reducing the intra - picture prediction coding efficiency during the decoding of the current video. According to various embodiments of the present invention, to solve this problem, when encoding the transform block, compared with the area of unavailable reference pixels, the area of available reference pixels is used to perform intra - picture prediction, and the encoding order of multiple transform blocks is changed in various ways along the direction of the intra - picture prediction mode. A detailed description related to this will be described later.

[0104] Moreover, the intra - picture inter - picture prediction unit 1150 can utilize the most likely intra - picture prediction mode obtained from adjacent blocks to encode the intra - picture prediction mode. According to various embodiments of the present invention, the most likely intra - picture prediction mode list composed of the above - mentioned most likely intra - picture prediction modes is formed by various methods.

[0105] When the intra - picture prediction unit 1150 performs intra - picture prediction, the processing unit that performs the prediction and the processing unit that determines the prediction method and specific content are different. For example, when the prediction mode is determined as a prediction unit, the prediction is performed by the above - mentioned prediction unit; when the prediction mode is determined as a prediction unit and is performed by the transform unit that performs the prediction. In one embodiment, the prediction mode is determined as an encoding block, and the above - mentioned encoding block unit is the same as the prediction unit, so that the prediction is performed by the above - mentioned encoding block unit.

[0106] The prediction modes of intra - picture prediction may include 65 directional prediction modes and at least 2 non - directional modes. The above - mentioned non - directional modes may include the DC prediction mode and the planar mode (Planar Mode). The number of the above - mentioned 67 inter - picture prediction modes is only an example, and the present invention is not limited thereto. In order to perform prediction by various methods, intra - picture prediction is performed through more directional or non - directional modes.

[0107] In one embodiment, intra - picture prediction may be applied to generate a prediction block after referring to pixels. In this case, it may be determined whether to apply the above - mentioned reference pixels according to the intra - picture prediction mode and / or size of the current block.

[0108] The prediction unit may determine various sizes and shapes from the coding units that cannot be further divided. For example, in the case of inter - picture prediction, the prediction unit may have a size such as 2Nx2N, 2NxN, Nx2N, or NxN (N is a positive number). In the case of intra - picture prediction, the prediction unit may have a size such as 2Nx2N or NxN (N is a growth rate), and intra - picture prediction may be performed through the above - mentioned square size and non - square size shapes. In this case, the prediction unit with an NxN size is only applicable in specific cases. And in addition to the prediction units of the above - mentioned sizes, intra - picture prediction units with sizes such as NxmN, mNxN, 2NxmN, or mNx2N may also be used.

[0109] The residual block value (residual block or residual block signal) between the prediction block generated in the intra - picture and inter - picture prediction unit 1150 and the original block may be input to the transform unit 1200. And the prediction mode information, interpolation filtering information, etc. used for prediction, together with the residual block value, are encoded in the entropy encoding unit 1350 and transmitted to the decoder.

[0110] The transformation unit 1200 transforms the residual block including the residual block value information of the prediction unit generated by the intra-picture prediction unit 1150 for the original unit and the original block 1100 using a transformation method such as the discrete cosine transform (DCT, Discrete Cosine Transform), the discrete sine transform (DST, Discrete Sine Transform), and the Karhunen-Loeve transform (KLT, Karhunen Loeve Transform). To transform the residual block, the intra-picture prediction mode information of the prediction unit used to generate the residual block is used as a basis to determine the discrete cosine transform, the discrete sine transform, and the Karhunen-Loeve transform.

[0111] The transform block in the transform unit 1200 is a transform block TU, which can have a square structure, a non-square structure, a square quadtree structure, a non-square quadtree structure, or a binary tree structure. In one embodiment, the size of the transform unit can be determined within a specified maximum and minimum size range. Also, the sub-transform blocks of a transform block can be further divided, and the multiple sub-transform blocks can have a square structure, a non-square structure, a square quadtree structure, a non-square quadtree structure, or a binary tree structure.

[0112] The quantization unit 1250 quantizes the residual values transformed in the transform unit 1200 to generate quantization coefficients. In one embodiment, the transformed residual values can be values transformed into the frequency domain. The quantization coefficients are changed according to the importance of the transform unit or the image, and the values calculated in the quantization unit 125 are provided again to the inverse quantization unit 1400 and the reordering unit 1300.

[0113] The reordering unit 1300 can reorder the quantization coefficients provided from the quantization unit 1250. The reordering unit 1300 reorders the quantization coefficients, thereby improving the coding efficiency in the entropy coding unit 1350. The reordering unit 1300 reorders the two-dimensional block-shaped quantization coefficients into a one-dimensional vector shape by a coefficient scanning method. The coefficient scanning method is determined according to the size of the transform unit and the intra-picture prediction mode. The coefficient scanning method can include zigzag scanning, vertical scanning that scans the coefficients in the two-dimensional block shape along the column direction, and horizontal scanning that scans the coefficients in the two-dimensional block shape along the row direction. In one embodiment, the reordering unit 1300 changes the order of coefficient scanning based on the probability statistics of the coefficients transmitted in the quantization unit, thereby improving the entropy coding efficiency in the entropy coding unit 1350.

[0114] The entropy encoding unit 1350 performs entropy encoding on the reordered quantized coefficients through the reordering unit 1300. For example, the entropy encoding can utilize various encoding methods such as Exponential Golomb, Context-Adaptive Variable Length Coding (CAVLC), and Content-Adaptive Binary Arithmetic Coding (CABAC).

[0115] The entropy encoding unit 1350 can read various information such as the quantized coefficient information, block type information, prediction mode information, segmentation unit information, prediction unit information, transmission unit information, motion vector information, reference picture information, block interpolation information, and filtering information of the coded units received from the reordering unit 1300 and the inter-picture prediction units 1100, 1150, and perform encoding. And, in one embodiment, the entropy encoding unit 1350 gives a specified change to the transmitted parameter set or syntax if necessary.

[0116] The inverse quantization unit 1400 performs inverse quantization on the values quantized in the quantization unit 1250, and the inverse transform unit 145 performs inverse transform on the values inverse quantized in the inverse quantization unit 1400. The residual block values generated in the inverse quantization unit 1400 and the inverse transform unit 1450 are combined with the predicted blocks predicted in the inter-picture prediction units 1100, 1150 to generate a reconstructed block. The image composed of the above-generated reconstructed blocks can be a motion-compensated image or a motion-compensated picture.

[0117] The above motion-compensated image can be input to the filtering unit 1500. The filtering unit 1500 can include a deblocking filter unit, a Sample Adaptive Offset (SAO), and an Adaptive Loop Filter (ALF). Briefly, after the above motion-compensated image applies a deblocking filter in the deblocking filter unit to remove or reduce blocking artifacts, the offset input to the SAO can be modified. The picture output in the above SAO is sent to the above adaptive loop filter unit, and the picture passing through the above filter is transmitted to the memory 1550.

[0118] Specifically describe the filtering unit 1500. The deblocking filtering unit removes the distortion within the block generated at the boundary between blocks in the restored picture. To determine whether to perform deblocking, it is determined whether to apply a deblocking filter to the current block based on the pixels in several columns or rows in the block. When the deblocking filter is applicable to the block, a strong filter or a weak filter can be applied according to the required deblocking filtering strength. Also, during the process of applying the deblocking filter, when performing vertical filtering and horizontal filtering, horizontal direction filtering and vertical direction filtering are processed in parallel.

[0119] The offset modification unit modifies the offset from the original image in pixel units for the remaining blocks to which the deblocking filter is applied. To modify the offset for a specific picture, after dividing the pixels in the image into a specified number of regions, the region where the modification is to be performed is determined, and a method of modifying the offset applicable to the corresponding region (Band Offset) or a method of applying the offset considering the edge information of each pixel (Edge Offset) can be applied. However, in one embodiment, for the restored blocks used for inter-picture prediction, no filter is used in the filtering unit 1500.

[0120] Adaptive Loop Filter (Adaptive Loop Filter) is performed only when it is applicable and efficient based on comparing the values of the filtered restored image and the original image. After dividing the pixels in the image into specified groups, one filter applicable to the corresponding group is determined and different filtering is performed for each group. Among the information related to whether to apply the above-mentioned Adaptive Loop Filter, the luminance information can be transmitted for each Coding Unit (CU). According to each block, the shape and filter coefficients of the Adaptive Loop Filter applied are different, and an Adaptive Loop Filter of the same form (fixed form) can be applied regardless of the characteristics of the block to which it is applied.

[0121] The memory 1550 can store the restored blocks or pictures calculated by the filtering unit 1500. The restored blocks or pictures stored in the memory 1550 can be provided to the inter-picture prediction unit 1100 or the intra-picture inter-picture prediction unit 1150 that performs inter-picture prediction. The pixel values of the restored blocks used in the intra-picture inter-picture prediction unit 1150 are data that do not use the deblocking filtering unit, the offset modification unit, and the Adaptive Loop Filter.

[0122] Figure 2 The block diagram of an image decoding device according to a simple and unrestrained embodiment is briefly shown. Refer to Figure 2 , the image decoding device 2000 includes an entropy decoding unit 2100, a reordering unit 2150, an inverse quantization unit 2200, an inverse transform unit 2250, an inter-picture prediction unit 2300, an intra-picture inter-picture prediction unit 2350, a filtering unit 2400, and a memory 2450.

[0123] In the case of inputting an image bitstream from an image encoding device, the input bitstream is decoded through the reverse process of the steps in which the image information in the encoding device is processed. For example, in order to perform entropy encoding in an image encoding device, in the case of using variable length coding (VLC, hereinafter referred to as: VLC) such as CAVLC, the entropy decoding unit 2100 is also embodied as the same variable length coding table used in the encoding device to perform entropy decoding. And, in order to perform entropy encoding in the encoding device, in the case of using CABAC, the entropy decoding unit 2100 correspondingly performs entropy decoding using CABAC.

[0124] Among the information decoded by the entropy decoding unit 2100, the information for generating a prediction block is provided to the inter-picture prediction unit 2300 and the intra / inter-picture prediction unit 2350, and the residual interpolation values obtained by performing entropy decoding in the entropy decoding unit are input to the reordering unit 2150.

[0125] The reordering unit 2150 reorders based on the method by which the bitstream entropy decoded in the entropy decoding unit 2100 is reordered in the image encoder. The reordering unit 2150 receives information related to the coefficient scanning performed in the encoding device, and based on the scanning order executed in the encoding device, performs reordering through the reverse scanning method.

[0126] The inverse quantization unit 2200 performs inverse quantization based on the quantization parameter provided in the encoding device and the coefficient values of the reordered blocks. The inverse transform unit 2250 performs inverse DCT, inverse DST, or inverse KLT on the quantization result performed in the image encoding device, corresponding to the DCT, DST, or KLT performed by the transform unit of the encoding device. The inverse transform is performed based on the transmission unit determined in the encoding device or the segmentation unit of the image. In the transform unit of the encoding device, DCT, DST, or KLT is selectively performed according to information such as the prediction method, the size of the current block, and the prediction direction. The inverse transform unit 2250 of the decoding device determines the inverse transform method based on the transform information performed in the transform unit of the encoding device and performs the inverse transform.

[0127] The inter-picture prediction units 2300, 2305 generate prediction blocks based on the information related to the generation of prediction blocks provided in the entropy decoding unit 2100 and the previously decoded block and / or picture information provided in the memory 2450. The restored block can be generated using the prediction blocks generated in the inter-picture prediction units 2300, 2350 and the residual blocks provided in the inverse transform unit 2250. The specific prediction methods performed by the inter-picture prediction units 2300, 2350 are the same as the prediction methods performed by the inter-picture prediction units 1100, 1150 in the encoding device.

[0128] The inter - picture prediction units 2300 and 2350 may include a prediction unit discrimination unit (not shown), an inter - picture prediction unit 2300, and an intra - picture and inter - picture prediction unit 2350. The prediction unit discrimination unit receives various information such as prediction unit information input in the entropy decoding unit 2100, prediction mode information of the intra - picture prediction method, and motion prediction - related information of the inter - picture prediction method to distinguish the prediction blocks in the current coding block, and determines whether the prediction blocks perform inter - picture prediction or intra - picture prediction.

[0129] The inter - picture prediction unit 2300 uses the information required for the inter - picture prediction of the current prediction block provided in the video encoder to perform the inter - picture prediction of the current prediction block based on the information in at least one of the previous picture or the subsequent picture of the current picture in the current prediction block.

[0130] Specifically, in inter - picture prediction, a reference picture is selected for the current block, and a reference block of the same size as the current block is selected to generate a prediction block related to the current block. At this time, the information of the surrounding blocks of the current picture can be used to utilize the information of the reference picture. For example, methods such as skip mode, merge mode, and Advanced Motion Vector Prediction are used to generate a prediction block related to the current block based on the information of the surrounding blocks.

[0131] The prediction block can generate sample units less than or equal to a positive number such as 1 / 2 pixel sample units and 1 / 4 pixel sample units. In this case, the motion vector is also represented as a unit less than or equal to a positive pixel. For example, the luminance pixels are represented in 1 / 4 - pixel units, and the chrominance pixels are represented in 1 / 8 - pixel units.

[0132] Motion information including the motion vector and the reference picture index required for the inter - picture prediction of the current block is induced correspondingly by receiving skip flags, merge flags, etc. from the coding device.

[0133] The intra - picture and inter - picture prediction unit 2350 generates a prediction block based on the pixel information within the current picture. In the case of a prediction unit that performs intra - picture prediction, intra - picture prediction is performed based on the intra - picture prediction mode information of the prediction unit provided in the video encoder. In the case of a block that performs inter - picture prediction in the surrounding blocks of the above - mentioned prediction unit, that is, in the case of a pixel where the reference pixel performs inter - picture prediction, the reference pixel in the block that performs inter - picture prediction is replaced with the reference pixel information of the block that performs intra - picture prediction in the surrounding area.

[0134] In the case where the above-mentioned reference pixels are unavailable, they are set to an available state. Generally, in the above case, the unavailable reference pixels are replaced by at least one reference pixel among the available surrounding pixel values or used by assigning a preset Yang quality.

[0135] However, in the method of using the unavailable reference pixels by copying the available reference pixels, when decoding the current image, the in-picture prediction coding efficiency is reduced. According to various embodiments of the present invention, to solve this problem, when encoding a transform block, compared with the area of unavailable reference pixels, the area of available reference pixels is used to perform in-picture prediction, and the encoding order of a plurality of transform blocks is changed in various ways along the direction of the in-picture prediction mode. A detailed description related thereto will be described later.

[0136] In addition, the in-picture and inter-picture prediction unit 2350 uses the most probable in-picture prediction mode (MPM: Most Probable Mode) obtained from adjacent blocks to encode the in-picture prediction mode. In one embodiment, the above-mentioned most probable in-picture prediction mode can use the in-picture prediction mode of the spatial adjacent blocks of the current block.

[0137] In one embodiment, the processing unit that performs prediction and the processing unit that determines the prediction method and specific content in the in-picture and inter-picture prediction unit 2350 are different. For example, the prediction mode is determined by the prediction unit and the prediction is performed by the prediction unit, and the prediction mode is determined by the prediction unit and the in-picture prediction is performed by the transform unit.

[0138] In this case, the prediction block determines various sizes and shapes from the coding block that cannot be further divided. For example, in the case of in-picture prediction, the prediction block can have, for example, 2Nx2N or NxN (N is a positive number). Not only the above-mentioned square sizes, but also the in-picture prediction is performed through non-square size shapes of NxmN, mNxN, 2NxmN, or mNx2N (m is a fraction or a positive number). In this case, the prediction unit of NxN size is only applicable in specific cases.

[0139] Also, the transform block can be determined in various sizes and forms. For example, the transform block can have a size such as 2Nx2N or NxN (N is a positive number). Not only the above-mentioned square sizes, but also perform in-picture prediction within the picture by using non-square sizes such as NxmN, mNxN, 2NxmN, or mNx2N (m is a fraction or a positive number). In this case, the prediction unit with the NxN size is only applicable in specific cases. In one embodiment, the transform block can be one of the blocks with a square structure, a non-square structure, a square quadtree structure, a non-square quadtree structure, or a binary tree structure. In one embodiment, the size of the transform block can be determined within the range of a specified maximum and minimum size. Also, one transform block can be divided into sub-transform blocks. In this case, it can be divided into a square structure, a non-square structure, a square quadtree structure, a non-square quadtree structure, or a binary tree structure.

[0140] The intra / inter-picture prediction unit 235 may include an Adaptive IntraSmoothing (AIS) filter unit, a reference pixel interpolation unit, and a DC filter unit. The above-mentioned Adaptive IntraSmoothing filter unit is the part that performs filtering on the reference pixels of the current block, and determines whether to apply the filter according to the prediction mode of the current prediction unit. Use the adaptive intra-smoothing filter information of the prediction unit provided in the video encoder to perform adaptive intra-smoothing filtering on the reference pixels of the current block. In the case where the prediction mode of the current block does not perform adaptive intra-smoothing filtering, the above-mentioned Adaptive IntraSmoothing filter unit is not applicable to the current block.

[0141] The reference pixel interpolation unit interpolates the reference pixels to generate the reference pixels of the pixel units below the positive value in the case of the prediction unit that performs intra-picture prediction based on the sampled values of the interpolated reference pixels in the prediction mode of the prediction unit. In the case where the prediction mode of the current prediction unit does not interpolate the reference pixels, but in the prediction mode of generating the prediction block, the reference pixels are not interpolated. The DC filter unit generates a prediction block by filtering in the case where the prediction mode of the current block is the DC mode.

[0142] The restored block and / or picture can be provided to the filter unit 2400. The filter unit 2400 may include a deblocking filter unit, an offset modification unit, and / or an adaptive loop filter unit in the restored block and / or picture. The above-mentioned deblocking filter unit can receive the information indicating whether to apply the deblocking filter to the target block or picture and the deblocking filter in the case of applying from the video encoder. The above-mentioned deblocking filter unit receives the deblocking filter-related information provided in the video encoder and performs deblocking filtering on the corresponding block in the video decoder.

[0143] The above-mentioned offset modification unit performs offset modification on the restored image based on the type of offset information applicable to the image when encoding, the offset value information, etc. The above-mentioned adaptive loop filter unit is applied in units of coding based on information regarding whether the adaptive loop filter is applicable and coefficient information of the adaptive loop filter provided from the encoder. Information related to the above-mentioned adaptive loop filter is provided included in a specific parameter set.

[0144] The memory 2450 stores the restored picture or block, and uses it as a reference picture or reference block later, and provides the restored picture to the input unit.

[0145] In this specification, for convenience of explanation, it is omitted. The bitstream input to the decoding device goes through a parsing step and is input to the entropy decoding unit. And the parsing process is performed in the entropy decoding unit.

[0146] In this specification, encoding may be interpreted as encoding or decoding according to circumstances, and information includes values, parameters, coefficients, elements, flags, etc. A "picture" or "image" is a unit of an image generally represented at a specific time, and "slice", "frame", etc. are units that form a part of a picture in the actual encoding process of a video signal, and are used in combination with pictures as needed.

[0147] "Pixel", "pel" or "picture element" represents the smallest unit that constitutes an image. And as a term representing a specific pixel value, "sample" can be used. Samples can be divided into luminance (Luma) and chrominance (Chroma) components. Generally, terms that include both of these are used. The above-mentioned chrominance components represent the difference between determined colors and are composed of Cb and Cr.

[0148] A "unit" is a basic unit of image processing or a specific position of an image such as the above-mentioned coding unit, prediction unit, and transform unit, and is used in combination with terms such as "block" or "region" according to circumstances. And a block represents a set of samples or transform coefficients composed of M columns and N rows.

[0149] Figure 3 The coding block of the current block for explaining the prior art.

[0150] Refer to Figure 3, the image corresponding to the current block can be encoded or decoded using square coding blocks 11, 12, 13, 14 of the same size. For example, the current block 10 is inclined to one side within the current block. Thus, in the square coding blocks, only in the case of coding block 112 and coding block 314, it is divided into 4 square coding blocks, and thus, the coding or decoding of coding block 011 and coding block 213, which are coding blocks that do not actually exist, is performed. Therefore, it is necessary to transmit the prediction mode and prediction information for the above-mentioned coding block 011 and coding block 213. Regardless of the characteristics of the image of the corresponding block, a lot of information needs to be transmitted by the above method, so the coding efficiency will be reduced. To solve this problem, the coding blocks of an embodiment of the present invention may include square coding blocks and non-square coding blocks.

[0151] Figures 4a to 4c An example of a non-square coding block representing the current block of an embodiment of the present invention.

[0152] As Figures 4a to 4c shown, the coding blocks may include non-square coding blocks. And, each coding block can independently determine the prediction mode and prediction information to transmit. In one embodiment, the above non-square coding blocks may include non-square coding blocks in the longitudinal direction with a transverse length greater than the longitudinal length and non-square coding blocks in the transverse direction with a longitudinal length less than the transverse length.

[0153] First, referring to Figure 4a , the coding blocks 21 to 27 for encoding the current block include non-square coding blocks 21, 24, 25 in the longitudinal direction. For example, the non-square coding blocks in the longitudinal direction have a size of 16x32 for 21 or may have a size of 8x32 for 24, 25. In the present invention, the ratio of the transverse and longitudinal dimensions of the coding blocks is not limited to this. In one embodiment, the non-square coding blocks in the longitudinal direction are used when the longitudinal change in the image corresponding to the current block is greater than the transverse change.

[0154] And, referring to Figure 4b , the coding blocks 31 to 37 for encoding the current block include non-square coding blocks 31, 34, 35 in the transverse direction. For example, the non-square coding blocks in the transverse direction have a size of 32x16 for 31 or have a size of 32x8 for 34, 35. In the present invention, the transverse and longitudinal dimensions of the coding blocks are not limited to this. In one embodiment, the non-square coding blocks in the transverse direction are utilized when the longitudinal change in the image corresponding to the current block is less than the transverse change. However, this is only an example. The method for determining which direction of non-square coding blocks to use for the current block is not limited to this, and the maximum and minimum sizes of the non-square coding blocks are not limited to this. Also, the number of non-square coding blocks and the ratio of the transverse length to the longitudinal length are not limited to this, and the current block can be divided into 1:N.

[0155] In one embodiment, the prediction block corresponding to the current coding block is not set generously, and the current coding block can directly utilize the prediction block. In this case, as in the general method, the coding block is in a square shape and a non-square shape, and the current block including the above coding block has a 1:N segmentation structure. Also, in another embodiment, the current coding block is used as both the prediction block and the transform block. In this case, as described above, the current block including the current coding block is segmented using a structure segmented into a square block, a structure segmented into a non-square block, and a structure segmented into 1:N.

[0156] Refer to Figure 4c , the Coding Tree Unit (CTU) may include square coding blocks CB0 to CB4, CB8, CB9, CB11, CB12, CB15 of various sizes and non-square coding blocks CB5 to CB7, CB10, CB13, CB14, CB17 to CB19 of various sizes.

[0157] In the encoding process of conventional video signals, only square blocks are used as coding blocks, and only square transform blocks are used as transform blocks. Multiple transform blocks based on the size of each coding block or prediction block are further segmented into a quadtree segmentation structure. For example, in the case of segmenting one transform block into a quadtree structure, the above transform block can be segmented into 4 square sub-transform blocks. The conventional encoding method that only utilizes such square multiple transform blocks hardly considers the characteristics of the residual block signal generated according to the characteristics of the image corresponding to the coding block and the prediction mode. Therefore, the video signal encoding method according to an embodiment of the present invention can utilize non-square coding blocks, non-square transform blocks, and non-square sub-transform blocks as transform blocks.

[0158] Figures 5a to 6c Illustrates an example of multiple transform blocks for the current coding block according to an embodiment of the present invention. Figure 5a And Figure 5b is an example of the composition of the initial transform block for an NxN-sized square current coding block (not shown), Figures 6a to 6c illustrates the composition of the initial transform block for a non-square current coding block.

[0159] In the case of using one or more transform blocks for a square current coding block, the transform blocks constituting the current coding block may include square transform blocks and non-square transform blocks. The above transform blocks can use a transform matrix to transform the residual block signal into the frequency domain.

[0160] Refer to Figure 5a , the square coding block is the composition of the initial transform block, and may be composed of one square transform block 41 or 4 square multiple transform blocks 42 to 45. And refer to Figure 5b, in the case of using square coding blocks, as the initial transform block, it can be composed of 2 non-square transform blocks 46 to 48 or 4 non-square transform blocks 51 to 58. The second non-square transform block can be a vertically-oriented non-square transform block 46, 47 with an N / 2 x N size or a horizontally-oriented non-square transform block 48, 49 with an N x N / 2 size. The 4 non-square transform blocks can be vertically-oriented non-square transform blocks 51 to 54 with an N / 4 x N size or horizontally-oriented non-square transform blocks 55 to 58 with an N x N / 4 size.

[0161] As described above, in the case of constructing a transform block for a square coding block, the initial transform block can be composed of a square transform block and a non-square transform block. 2 or 4 non-square transform blocks were shown before. In the present invention, the size and number of non-square transform blocks are not limited to this. Also, when in-frame prediction is performed on the current coding block, depending on the directionality of the in-frame prediction mode, the composition of the transform block of the current coding block is different. For example, when the current coding block uses a vertical in-frame prediction mode, a horizontally divided non-square transform block is used as the transform block for the current coding block. Thus, using the upper encoded reference sample, a prediction signal is generated for the current transform block.

[0162] According to the reference Figures 5a to 6d of one embodiment, in the case of using one or more transform blocks for a non-square current coding block (not shown), the transform block constituting the current coding block may include a square transform block and a non-square transform block.

[0163] Reference Figure 6a , in the present invention, the coding block can be non-square coding blocks 60a, 60b with different horizontal length A and vertical length B. In this case, when initially constructing the current non-square coding block through one or more transform blocks, a square transform block or a non-square transform block is used to equally divide the coding block.

[0164] Reference Figure 6b , as the composition of the initial transform block for non-square coding blocks 60a, 60b, N square transform blocks 61 with an a x a size can be used. In this case, a of the horizontal and vertical lengths of the square transform block 61 is the same as the smaller length among the horizontal and vertical lengths of the non-square coding block. In one embodiment, the horizontal and vertical lengths of the square transform block 61 are calculated from upper-level parameters or obtained through a preset method.

[0165] Reference Figure 6c, as a configuration of the initial transformation block for non-square coding blocks 60a and 60b, M (where M is a positive number) non-square transformation blocks 62 to 65 can be used. The sizes of the non-square transformation blocks 62 and 63 are the same as those of the non-square coding block 60a, or non-square transformation blocks 64 and 65 with sizes smaller than those of the non-square coding blocks 60a and 60b can be used. In one embodiment, the horizontal length a and the vertical length b of the non-square transformation blocks 62 and 63 are the same as the horizontal and vertical lengths of the coding blocks 60a and 60b. In another embodiment, the horizontal and vertical lengths of the non-square transformation blocks 64 and 65 are calculated through upper-level parameters or obtained through a preset method.

[0166] And, referring to Figure 6d , as a configuration of the initial transformation block for non-square coding blocks 60a and 60b, M non-square or square transformation blocks 66 and 67 of a quadtree structure can be used. The sizes of the non-square or square transformation blocks 66 and 67 are smaller than those of the non-square coding blocks and can be used when the size of the non-square coding block is large and does not correspond to one transformation block. In the present invention, only multiple transformation blocks of a quadtree structure are described, but the number of the non-square or square transformation blocks 66 and 67 is not limited thereto.

[0167] The transformation block constituting the current coding block can be divided into multiple sub-transformation blocks of smaller sizes. The multiple sub-transformation blocks independently perform a transformation process to generate transformation coefficients and can have various shapes and sizes. Also, the division method is determined differently based on the size and shape of the upper-level transformation block before being divided into the multiple sub-transformation blocks, and has an independent shape different from the shape of the upper-level transformation block.

[0168] Figures 7a to 10 An example of a sub-transformation block showing an embodiment of the present invention is shown. Figures 7a to 7d An example of multiple sub-transformation blocks of the transformation block in the case where the transformation block is a square transformation block Figures 8a to 8d An example of multiple sub-transformation blocks in the case of a non-square transformation block in the horizontal direction is shown. Figures 9a to 9d An example of multiple sub-transformation blocks of a non-square transformation block in the horizontal direction is shown. And, Figure 10 A transformation block composed of multiple sub-transformation blocks is shown.

[0169] Referring to Figures 7a to 7d , in the case where the current transformation block is a square transformation block 70 of NxN size, the square transformation block 70 is divided by various methods to generate sub-transformation blocks 71a to 74d. The square transformation block 70 is divided into 4 square multiple sub-transformation blocks 71a to 71d using a square quadtree division method ( Figure 7b) and uses a binary tree splitting method to split into two or more non-square sub-transformation blocks 72a to 72d that are horizontal or vertical. Figure 7c ) In one embodiment, a non-square quadtree splitting method is used to split into four non-square sub-transformation blocks 73a to 73h that are horizontal or horizontal. Figure 7d ) The number and size of the above-mentioned split sub-transformation blocks are only examples, and the present invention is not limited thereto.

[0170] Refer to Figures 8a to 8d , as Figure 8a shown, when the current transformation block is a non-square transformation block 80 with dimensions of A (horizontal length) x B (vertical length), the non-square transformation block 80 is split by various methods to generate sub-transformation blocks 81a to 84d. The non-square transformation block 80 is split into four or more square sub-transformation blocks 81a to 81d using a square quadtree splitting method. Figure 8b ) Here, the horizontal and vertical lengths of the multiple square sub-transformation blocks can be the same as the shorter length among the horizontal and vertical lengths of the non-square transformation block 80. Figure 8a (A in Figure 8b ), and the present invention is not limited thereto. When the vertical length B of the non-square transformation block 80 is a positive multiple of the horizontal length A, the non-square transformation block 80 is split into transformation blocks according to the square splitting method as shown in

[0171] Refer to Figure 8c , the non-square transformation block 80 can be split into two or more non-square sub-transformation blocks 82a to 82d that are vertical or horizontal using a binary tree splitting method. Refer to Figure 8d , using a non-square quadtree splitting method, the non-square transformation block 80 is split into four non-square sub-transformation blocks 83a to 83d. The number and size of the above-mentioned split sub-transformation blocks are only examples, and the present invention is not limited thereto.

[0172] Refer to Figures 9a to 9d , as Figure 9a shown, when the current transformation block is a non-square transformation block 90 with dimensions of A (horizontal length) x B (vertical length), the non-square transformation block 90 is split by various methods to generate sub-transformation blocks 91a to 94d. The non-square transformation block 90 is split into four or more square sub-transformation blocks 91a to 91d using a square quadtree splitting method. Figure 9b ) and is split into four or more sub-transformation blocks (not shown). In this case, the horizontal and vertical lengths of the multiple square sub-transformation blocks can be the same as the shorter length among the horizontal and vertical lengths of the non-square transformation block 90. Figure 9ais the same as B) in, but the present invention is not limited thereto. In the case where the horizontal length A of the non-square transform block 90 is a positive multiple of the vertical length B, the non-square transform block 90 can be divided into sub-transform blocks according to the square division method as shown in Figure 9b .

[0173] Referring to Figure 9c , the non-square transform block 90 is divided into two or more non-square sub-transform blocks 92a to 92d in the vertical or horizontal direction by using a binary tree division method. Referring to Figure 9d , by using a non-square quadtree division method, the non-square transform block 90 can be divided into four non-square sub-transform blocks 93a to 93d. The number and size of the above-mentioned divided sub-transform blocks are only an example, and the present invention is not limited thereto.

[0174] Figure 10 Shows an example of transforming the current coding block by using the division method as shown in Figures 7a to 9d . According to Figure 10 , the current coding block can be not only a square transform block but also a non-square transform block, and the above-mentioned square or non-square transform block can be not only a square sub-transform block but also a non-square sub-transform block. Such a combination of transform block application and sub-transform block division is applied by using one or more of the methods shown in Figures 7a to 9d . Also, the shape and number of the transform blocks or the shape and number of the sub-transform blocks are not limited to the examples of the present invention.

[0175] Generally, when performing in-picture prediction on the current block, a raster scan method is used to decode the transform block, and the reference samples used to generate the prediction signal in the direction of the in-picture prediction mode are determined.

[0176] Figure 11 The coding order and method of the transform block for explaining the general method. Referring to Figure 11 , when the direction of the in-picture prediction mode of the current block is 2 to 10, a plurality of transform blocks TU0 to TU3 always use the reference samples located on the left side of the above-mentioned transform block to generate the prediction signal. In this case, among the plurality of transform blocks, the first transform block TU0 that generates the prediction signal first uses the first reference sample area 111 of the transform block to generate the prediction signal, and the first reference sample area 111 can be composed of available reference samples and / or unavailable reference samples. After that, the second transform block TU1 also forms a second reference sample area 112 for the second transform block TU1 from a part of the pixels of the first transform block TU0. Therefore, the second reference sample area 112 is composed of a part of the pixels of the first transform block TU0 that are samples to be encoded, that is, available reference samples.

[0177] After that, the third transform block TU2 that generates the prediction signal uses the pixels on the left side of the third transform block TU2 as reference samples, without using the pixels of the encoded first transform block TU0 and second transform block TU1. Therefore, the third reference sample region 113 for prediction can be composed of unavailable reference samples. The fourth transform block TU3 is composed of a part of the pixels of the third transform block TU2, and the fourth reference sample region 114 for the fourth transform block TU3. Therefore, the fourth reference sample region 114 can be composed of a part of the pixels of the third transform block TU2 that are encoded samples, that is, available reference samples.

[0178] As described above, according to the conventional encoding order, when generating a prediction signal from a transform block, it is possible to generate a prediction signal using reference samples that cannot be used along the direction of the intra-prediction mode within the picture. Therefore, the encoding method of the video signal according to an embodiment of the present invention can variably determine the encoding order of a plurality of transform blocks along the direction of the intra-prediction mode of the current encoding block, thereby improving the encoding efficiency.

[0179] Figures 12a to 12c An example of a plurality of transform blocks showing an embodiment of the present invention is shown.

[0180] Refer to Figures 12a to 12c , a plurality of transform blocks according to an embodiment of the present invention may have a structure in which four transform blocks of the same size are formed in two lines ( Figure 12a ), and may have a structure in which a plurality of transform blocks of the same size are arranged horizontally or vertically ( Figure 12b and Figure 12c ). The above-mentioned plurality of transform blocks may be further divided into a plurality of sub-transform blocks of a smaller size. When re-dividing, the structure of the plurality of sub-transform blocks is also as Figures 12a to 12c shown.

[0181] If a plurality of transform blocks are encoded without considering the intra-prediction mode of the current block, when generating the prediction signal of each transform block, the unencoded surrounding blocks can be used. In this case, the reference samples used to generate the above prediction signal can be unavailable samples. Therefore, the above unavailable samples that copy the available samples around are used, and the encoding efficiency is not excellent. Therefore, in the present invention, a method is proposed to variably determine the encoding order of the transform block by considering which mode region the intra-prediction mode of the current block corresponding to the plurality of transform blocks belongs to.

[0182] In order to variably determine the encoding order of a plurality of transform blocks according to the intra-prediction mode, first, the intra-prediction mode is re-divided according to the prediction direction. Figure 13 An example of the mode region to which the intra-prediction mode according to an embodiment of the present invention belongs is shown.

[0183] Reference Figure 13 In the intra prediction mode with directivity, the intra prediction mode can be divided into a first mode region to a third mode region 131 to 133) along the prediction direction. Figure 13 In the intra prediction mode shown, the intra prediction mode with an angle of 90 degrees to 180 degrees other than the horizontal and vertical intra prediction modes can be the intra prediction mode constituting the first mode region 131. The second mode region can be the intra prediction mode with a horizontal prediction mode and an angle of 180 degrees to 225 degrees, and the third mode region can be the intra prediction mode with a vertical prediction mode and an angle of 45 degrees to 90 degrees. Based on the mode regions thus distinguished, the coding order of the plurality of transform blocks is variably determined according to the mode region to which the plurality of transform blocks belong.

[0184] Figure 14a and Figure 14b Shows the coding order of the plurality of transform blocks when the intra prediction mode of the current block in an embodiment of the present invention belongs to the first mode region. The coding order of the plurality of transform blocks when belonging to the first mode region is the same as the coding order of the conventional plurality of transform blocks. Figure 14a Indicates the coding order when the plurality of transform blocks have an NxN structure, and can be coded in the order of TB0, TB1, TB2, TB3. Figure 14b Indicates the coding order when the plurality of transform blocks are non-square transform blocks in the horizontal and vertical directions, and are coded in the order from left to right and from top to bottom. For example, they are coded in the order of TB4, TB5, TB6, TB7, TB8, TB9, and TB10.

[0185] Figures 15a to 15c Shows the coding order of the plurality of transform blocks when the intra prediction mode in an embodiment of the present invention belongs to the second mode region. The above-mentioned plurality of transform blocks are coded in the order from the lower left side to the upper right side, and the plurality of transform blocks having an NxN structure can be as Figure 15a and Figure 15b shown in the coding. Refer to Figure 15a , coded in the order from TB2 located at the lower left side to TB3, B0, and TB1, refer to Figure 15b , coded in the order from TB2 located at the lower left side to TB0, TB3, and TB1.

[0186] Furthermore, the non-square plurality of transform blocks in the horizontal and vertical directions are coded in the order from left to right and from bottom to top. Refer to Figure 15c , coded from TB4 located on the left side to TB5 and TB6, and coded in the order from TB10 located at the lower right side to TB9, TB8, and TB7.

[0187] Figures 16a to 16cShows the encoding order of multiple transform blocks in the intra prediction mode of a screen within an embodiment of the present invention belonging to the third mode region. The above-mentioned multiple transform blocks can be encoded in the order from the upper right to the lower left. Multiple transform blocks having an NxN structure are as Figure 16a and Figure 16b encoded. Refer to Figure 16a , encoded in the order from TB1 located at the upper right to TB0, TB3, and TB2. Refer to Figure 16b , encoded in the order from the upper right to TB3, TB0, and TB2.

[0188] Moreover, multiple non-square transform blocks in the horizontal and vertical directions can be encoded in the order from the right to the left and from the upper end to the lower end. Refer to Figure 16c , encoded in sequence from TB7 located at the upper right to the lower TB8, TB9, and TB10 below. Among the multiple vertical non-square transform blocks on the left, the order of TB6, TB5, and TB4 located on the right is encoded.

[0189] As described above, considering the mode region and the shape of the transform block distinguished by the direction of the intra prediction mode of the current block, the encoding order of the transform block is determined in a variable manner, and the available reference samples of the surrounding blocks decoded by each transform block are used to generate a prediction signal. Therefore, the encoding efficiency can be improved.

[0190] In one embodiment, when multiple transform blocks have the structure of the type described above Figures 12a to 12c , the encoding order of the multiple transform blocks determined according to the mode region to which the intra prediction mode of the current encoding block corresponding to the above multiple transform blocks belongs is as shown in Table 1 below.

[0191] Table 1

[0192]

[0193]

[0194] Figures 17a to 17c Shows the encoding order of the square and non-square multiple transform blocks that make up the current block using the encoding order of the transform blocks recorded in Table 1. Figure 17a Shows the encoding order of the multiple transform blocks of the current block when the intra prediction mode of the current block belongs to the first mode region, Figure 17b Shows the encoding order of the multiple transform blocks of the current block when the intra prediction mode of the current block belongs to the second mode region, Figure 17c Shows the encoding order of the multiple transform blocks of the current block when the intra prediction mode of the current block belongs to the third mode region.

[0195] Refer to Figure 17a, when the in - picture prediction mode of the current block belongs to the first mode region, regardless of the shape of the transform block, multiple transform blocks are encoded in the same order as the general encoding order, from the upper - left end to the lower - right end. And, when the in - picture prediction mode of the current block belongs to the second mode region, when generating a prediction signal for the transform block, the reference sample belonging to the lower - left end block can be used. Therefore, the transform blocks are encoded in the order from the lower - left end to the upper - right end to improve the encoding efficiency. Refer to Figure 17b , during the process of encoding the current block in the order from the lower - left end to the upper - right end, a method of encoding in the order of the lower - left end, the lower - right end, the upper - left end, and the upper - right end is selected.

[0196] When the in - picture prediction mode of the current block belongs to the third mode region, when generating a prediction signal for the transform block, the reference sample belonging to the upper - left end is used. Therefore, the transform blocks are encoded in the order from the upper - right end to the lower - left end to improve the encoding efficiency. Refer to Figure 17c , where a method of encoding in the order of the upper - right end, the upper - left end, the lower - right end, and the lower - left end can be selected.

[0197] In another embodiment, the encoding order of the transform block considering the in - picture prediction mode is determined as shown in Table 2 below.

[0198] Table 2

[0199]

[0200]

[0201] Figures 18a to 18c Illustrates the encoding order of multiple square and non - square transform blocks that make up the current block using the encoding order of the transform blocks recorded in Table 2. Figure 18a Illustrates the encoding order of multiple transform blocks of the current block when the in - picture prediction mode of the current block belongs to the first mode region, Figure 18b Illustrates the encoding order of multiple transform blocks of the current block when the in - picture prediction mode of the current block is in the second mode region, Figure 18c Illustrates the encoding order of multiple transform blocks of the current block when the in - picture prediction mode of the current block is in the third mode region.

[0202] Refer to Figure 18a , regardless of the shape of the transform block when the in - picture prediction mode of the current block belongs to the first mode region, multiple transform blocks are encoded in the order from the upper - left end to the lower - right end in the same order as the general encoding order. And, when the in - picture prediction mode of the current block belongs to the second mode region, when generating a prediction signal, the reference sample belonging to the lower - left end block is used. Therefore, the transform blocks are encoded in the order from the lower - left end to the upper - right end to improve the encoding efficiency. Refer to Figure 18bDuring the sequential encoding of the current block from the lower left to the lower right, a method of sequential encoding from the lower left, upper left, lower right, and upper right is selected.

[0203] When the prediction mode within the picture of the current block belongs to the third mode region and a prediction signal is generated for the transform block, the reference sample belonging to the upper right is used. Therefore, the transform block is encoded sequentially from the upper right to the lower left to improve the encoding efficiency. Refer to Figure 18c , where a method of sequential encoding in the order of upper right, lower right, upper left, and lower left is selected.

[0204] The encoding order of multiple transform blocks based on such mode regions is not limited to the above examples and can also be determined by combinations of the above examples.

[0205] Figures 19a to 19c Shows cross-selection of references Figures 17a to 18c Describes the encoding order of multiple transform blocks in the case of the encoding order of multiple transform blocks in the mode region described.

[0206] Figure 19a Shows the encoding order of multiple transform blocks of the current block when the prediction mode within the picture of the current block belongs to the first mode region, Figure 19b Shows the encoding order of multiple transform blocks of the current block when the prediction mode within the picture of the current block belongs to the second mode region, Figure 19c Shows the encoding order of multiple transform blocks of the current block when the prediction mode within the picture of the current block belongs to the third mode region.

[0207] In the case of the first mode region, as described in reference Figure 17a and Figure 18a , the encoding order of multiple transform blocks can be determined from the upper left to the lower right. In the case of the second mode region, refer to Figure 19b , according to the encoding order determined by reference Figure 17b , multiple transform blocks are encoded in the order of lower left, lower right, upper left, and upper right. Refer to Figure 19c , when the prediction mode within the picture of the current block is the third mode region, according to the encoding order described in reference Figure 18c , multiple transform blocks are encoded in the order of upper right, lower right, upper left, and lower left. In another embodiment, the encoding order of the second mode region and the third mode region can be determined according to the encoding order described in reference Figure 18b and Figure 17c . As described above, for multiple transform blocks of the current block, a combination of multiple encoding orders determined according to the prediction mode within the picture of the current block is used to generate a prediction signal, thereby improving the encoding efficiency.

[0208] Figure 20 and Figure 21 to illustrate the structure of the transform blocks that make up the general method and the transform coefficient groups of the 16x16 transform block.

[0209] Refer to Figure 20 , a coding block CB may include multiple transform blocks TB0, TB1... TB12. The above-mentioned multiple transform blocks may include multiple transform blocks having various shapes and / or sizes. The above-mentioned transform blocks may include blocks with a square shape and non-square shaped blocks, and the above-mentioned transform blocks may be one of the blocks in a square quad tree structure, a non-square quad tree structure, or a binary tree structure.

[0210] Refer to Figure 21 , the transform block 210 may include more than one transform coefficient group CG0, CG1... CG15. For example, if the transform block 210 is a block of 16x16 size, the size of the transform coefficient group in the above-mentioned transform block may be 4x4. That is, a 16x16 size transform block may include 16 transform coefficient groups of 4x4 size, and the indices of the above-mentioned transform coefficient groups may be according to Figure 21 the transform coefficient scanning order as shown.

[0211] Figure 22 To illustrate the transform coefficient groups of the general method and the transform scanning method of the above-mentioned transform coefficient groups.

[0212] Refer to Figure 22 , generally, the transform coefficient group scanning order of the transform block 220 is the same as the scanning order of the transform coefficients. For example, if the transform block 220 is of 8x8 size and the transform coefficient group is a block of 4x4 size, in the case of using the up-right diagonal scanning method for the transform block 20, the transform coefficient group applies the same scanning method as the transform coefficients. As Figure 22 shown, for the transform coefficients 15 to 0 of CG3 of the transform coefficient group included at the lower right end of the right side of the transform block 220, the transform coefficients are scanned by the up-right diagonal, and then, for CG2 of the transform coefficient group at the upper right end, after scanning the transform coefficients by the same method, in the order of the transform coefficient group CG1 at the lower left end and the transform coefficient group CG0 at the upper left end, the transform coefficients included in the above-mentioned transform coefficient groups are scanned by the same method.

[0213] Figures 23a to 23d To illustrate various examples of the transform coefficient groups of the general method and the scanning method of the above-mentioned transform coefficient groups. Figures 23a to 23c Indicates the scanning method of the transform coefficient group in the in-picture prediction mode, Figure 23dA scanning method for a transform coefficient group indicating an inter-picture prediction mode.

[0214] Refer to Figures 23a to 23c , in the case of intra-picture prediction, an upright diagonal scan (Up-right diagonal scan, Figure 23a ) that scans sequentially from the lower right end to the upper left end, a horizontal scan (Horizontal scan, Figure 23b ) that scans from the right to the left and from the lower end line to the upper end, and a vertical scan (Vertical scan, Figure 23c ) that scans from the lower end to the upper end and from the right to the left can be used. Refer to Figure 23d , in the case of inter-picture prediction, only the upright diagonal scan can be used.

[0215] In one embodiment, the scanning method of the transform coefficient group in intra-picture prediction can be determined according to the intra-picture prediction mode. For example, in the case of intra-picture prediction mode indexes 6 to 14 of horizontal prediction in intra-picture prediction, the vertical scan method is used to scan the transform coefficient group. In the case of indexes 20 to 30 of horizontal prediction in intra-picture prediction, the horizontal scan method is used. For the remaining intra-picture prediction modes, the upright diagonal scan method can be used.

[0216] In recent video coding, square transform blocks have always been considered for transform blocks. Therefore, the transform coefficient group and the scanning method of the transform coefficients described above are also suitable for square transform blocks. However, in the case of using a non-square transform block as a transform block, when applying the conventional transform coefficient group and the scanning method of transform coefficients, the coding efficiency is reduced. Therefore, hereinafter, in Figures 24a to 3 0, a method for scanning a transform coefficient group that can improve the coding efficiency of an embodiment of the present invention is described.

[0217] Figure 24a And Figure 24b An example for explaining the application of the general scanning method to the transform block in an embodiment of the present invention.

[0218] Refer to Figure 24a , the current transform block TB1 230a is a non-square block. In the case of having a size of 8x16, if the conventional method is applied by scanning the transform coefficient group and the transform coefficients, three scanning methods can be selected. For example, in an example where the conventional three scanning methods are applied to the current transform block 230a to scan the transform coefficient group, the upright diagonal scan, the vertical scan method, and the horizontal scan method are used to scan the transform coefficient group from the left.

[0219] Refer to Figure 24b, the current transform block TB2 230b is a non-square block. In the case of having a size of 16x8, if the conventional method is applied as the method of scanning the transform coefficient group and the transform coefficients, three scanning methods can be selected. For example, when the three conventional scanning methods are applied to the current transform block 230b to scan the transform coefficient group, the vertical diagonal scanning, the vertical scanning method, and the horizontal scanning method are applied from the left to scan the transform coefficient group.

[0220] Figure 25 An example for explaining the application of the general scanning method to the transform coefficients of a 16x8 transform block.

[0221] Refer to Figure 25 , when the horizontal scanning method is applied to the current transform block TB2 230b, the transform coefficients and the transform coefficient group can be applied in the horizontal mode as the same scanning method. For example, multiple transform coefficient groups including multiple transform coefficients are scanned by each transform coefficient group unit. In the transform block, after scanning the transform coefficients in the transform coefficient group at the lower right end of the rightmost side by the horizontal mode, the transform coefficients in the transform coefficient group to the left of the transform coefficient group at the lower right end of the rightmost side are scanned by the horizontal mode. Then, scanning is performed in the above transform coefficient group unit in the same manner.

[0222] Through this transformation process, most of the energy of the residual signal is concentrated in the DC region at the upper left end. Therefore, for the efficiency of entropy coding, it is more effective for the transform coefficients and / or the transform coefficient group in the low-frequency region to have an index representing the scanning order of small values. However, for non-square transform blocks, as Figures 24a to 25 shown, in the case of applying the scanning order of the general transform coefficient group, the transform coefficient group in the high-frequency region is encoded before the transform coefficient group in the low-frequency region, so the coding efficiency will be reduced.

[0223] Therefore, the scanning method of the transform scanning coefficients according to an embodiment of the present invention includes a method of dividing the transform block into a transform region including an upper region including multiple transform scanning coefficients and scanning the transform scanning coefficients corresponding to each of the divided transform regions.

[0224] Figure 26 And Figure 27 A flowchart and a device showing a method of scanning the transform coefficient group according to an embodiment of the present invention are shown.

[0225] Refer to Figure 26 And Figure 27 , the transform unit obtains transform region information (step S10) representing that multiple transform coefficient groups in the transform block are divided into one or more transform regions in the transform region information acquisition unit 240 in order to scan the transform coefficient group. The above transform block can have various sizes and / or shapes. In one embodiment, the above transform block can be a non-square shaped transform block.

[0226] The above transformation region information can divide the above transformation block into more than one region, and each transformation region can include multiple transformation coefficient groups. The above transformation coefficient groups include multiple transformation coefficients. Also, the above transformation region information can be information received from an encoder. For example, the above transformation region information can be obtained from one or more of a sequence parameter set (SPS) and a slice header. The present invention is not limited thereto, and does not limit whether it has any rank of sentences in any form, as long as it is information received from an encoder.

[0227] In one embodiment, the above transformation region information can be obtained by a method preset in a decoding device. For example, the above transformation region information is based on the horizontal length and vertical length of the transformation block to calculate the horizontal length and vertical length of the transformation region to determine the size and number of the transformation regions and obtain them. Or, in the horizontal and vertical lengths of the transformation block, the small length is divided into the block size of the transformation coefficient group, whereby the size and number of the transformation regions can be determined. The horizontal and vertical lengths, shapes, and numbers of the transformation regions represented by the above transformation region information can be based on the method determined in the decoding device, and are not limited to the above examples.

[0228] After that, the transformation coefficient group scanning unit 250 can scan multiple transformation coefficient groups in one or more transformation regions divided based on the above transformation region information. The transformation coefficient group scanning unit 250 can include a first transformation region scanning unit 251 and a second transformation region scanning unit 252 in order to scan the transformation coefficient groups of the divided transformation regions. The above transformation region scanning unit is not limited to the first transformation region scanning unit 251 and the second transformation region scanning unit 252, and can correspond to the number of transformation regions divided by the above transformation block.

[0229] First, the first transformation region scanning unit 251 can scan multiple transformation coefficient groups in the first transformation region among the multiple transformation regions divided based on the above transformation region information (step S20). After that, the second transformation region scanning unit 252 can scan multiple transformation coefficient groups in the second transformation region (step S30). When the transformation region scanning unit includes three or more, the transformation coefficient groups in the transformation regions are scanned in sequence.

[0230] In one embodiment, compared with the second transformation region scanning unit 252, the first transformation region scanning unit 251 can include the transformation coefficient groups in the low-frequency region. As described above, the scanning method of the transformation coefficient groups of the present invention determines the scanning in such a way that the transformation coefficient groups in the low-frequency region are scanned before the transformation coefficient groups in the high-frequency region, and the transformation coefficient groups in the high-frequency region are preferentially encoded and transmitted. The transformation coefficient groups in the low-frequency region have large scanning indexes, thereby solving the problem of reducing the coding efficiency.

[0231] Also, in one embodiment, before obtaining the transform region information, it can be determined whether the above-mentioned transform block is a non-square block. The transform coefficient group corresponding to the high-frequency region is scanned prior to the transform coefficient group corresponding to the low-frequency region, and thus a reduction in coding efficiency frequently occurs when the transform block is a non-square block. Therefore, before obtaining the transform region information, it is preferred to determine whether the current transform block is a non-square block.

[0232] In one embodiment, various methods are adopted to determine whether the above-mentioned transform block is a non-square block. For example, by comparing the horizontal length and the vertical length of the above-mentioned transform block, it can be determined whether the above-mentioned transform block is a non-square block. Alternatively, it is determined based on one or more of the information on the size and shape of the above-mentioned transform block received from the encoding device or the segmentation information, direction information, α, β, and pixel information of the above-mentioned transform block already obtained in the decoding device.

[0233] Also, it is determined based on the transform block type information indicating the type of the above-mentioned transform block. The above-mentioned transform block type information can be received from the encoding device, or in the decoding device, it is calculated based on one or more of the segmentation information, direction information, pixel information, and horizontal and vertical length information of the above-mentioned transform block. By the above method, when it is determined that the above-mentioned transform block is a non-square block, by referring to Figure 26 and Figure 27 the above method, the transform region scan corresponding to each transform block scans the transform coefficient group included in the above-mentioned transform region.

[0234] Figure 28a and Figure 28b are used to illustrate the method of scanning the transform coefficient group of the non-square transform block for one embodiment of the present invention.

[0235] Referring to Figure 28a the non-square transform blocks 260a, 260b of the present invention may have a horizontal length A and a vertical length B. The non-square transform blocks 260a, 260b having an AxB size include a plurality of transform coefficient groups and are divided into transform block regions of αxβ size. The above-mentioned α and β represent the number of transform coefficient groups in the transform block. That is, the region of αxβ size is a region with α transform coefficient groups in the horizontal direction and β transform coefficient groups in the vertical direction. In one embodiment, the transform region information may include information on the above-mentioned α and β. Also, the transform region information may include information indicating the horizontal and vertical dimensions of the transform region. For example, when the non-square transform block 260a has a size of 8x16, αxβ representing the structure of the transform region is 2x2, and the size of the transform region dividing the transform block 260a is 8x8.

[0236] This transform region information is calculated in the upper-level parameter or the previous decoding process. Briefly, among the horizontal and vertical lengths of a non-square transform block, it is calculated from the number of the block sizes that divide the transform coefficients with smaller lengths. However, in the present invention, the method for obtaining the transform region information is not limited to this.

[0237] Refer to Figure 28b , for the transform blocks 260a and 260b divided into multiple transform regions, in each transform region, the scanning method determined from the upper-level parameter or the upper-level process is applied to scan the transform coefficient group. For example, for a transform block 260b with a size of 16x8 divided into transform regions with a size of 8x8 (αxβ = 2x2), when scanning the transform region and the transform coefficient group by the vertical diagonal scanning method, the transform coefficient group within (CGRegion1) is first scanned by the vertical diagonal scanning method, and then, the transform coefficient group within (CGRegion0) is scanned by the vertical diagonal scanning method.

[0238] Figures 29a to 30d To illustrate various methods for scanning the transform coefficient group of a non-square transform block for an embodiment of the present invention.

[0239] Refer to Figures 29a to 30d , when the transform block 270 is divided into transform regions with the smaller side length of the transform block, the transform coefficient group can be scanned by various methods. Figure 29a As shown, when the transform block 270 has a size of 16x32, each transform region (CG Region0) 271 and (CG Region1) 272 can have a size of 16x16. Among them, α and β representing the number of horizontal and vertical transform coefficient groups CG are α = β = 4.

[0240] In one embodiment, the transform block 270 can sequentially scan the transform coefficient group in each transform region for each transform region. For example, as Figure 29b shown, when the transform block 270 is scanned by the vertical diagonal scanning method, for the thirty-second transform coefficient group CG 31 in the second transform region (CG Region1) at the lower end, the seventeenth transform coefficient group CG 16 is sequentially scanned, and then, from the sixteenth transform coefficient group CG 15 in the first transform region (CG Region0), the first transform coefficient group CG 0 is sequentially scanned. And when the transform block is divided into two transform regions and the vertical scanning method and the horizontal scanning method are applied to the above transform block, it is the same as shown in Figure 29c and Figure 29d .

[0241] Refer to Figures 30a to 30d, when the transform block 280 is divided into transform regions with a small side length of the transform block 280, the transform coefficient groups can be scanned by various methods. As Figure 30a shown, when the transform block 280 has a size of 32x16, each transform region (CG Region0) 281, (CG Region1) 282 can have a size of 16x16. Among them, α and β indicating the number of horizontal and vertical transform coefficient groups CG can be α = β = 4.

[0242] In one embodiment, the transform block 280 scans the transform coefficient groups in each transform region in order of transform regions. For example, as Figure 30b shown, when the transform block 280 is scanned by the vertical diagonal scanning method, from the thirty-second transform coefficient group CG 31 in the second transform region 282 (CG region 1) on the right, the seventeenth transform coefficient group CG 16 is scanned in order according to the vertical diagonal method. After that, the sixteenth transform coefficient group CG 15 in the first transform region 281 (CG region 0) scans the first transform coefficient group CG 0 in order. And, as Figure 30c shown, when the transform block 280 is scanned by the vertical scanning method, from the thirty-second transform coefficient group CG 31 in the second transform region 282 (CG region 1) on the right, the seventeenth transform coefficient group CG 16 is scanned in order according to the vertical method. After that, from the sixteenth transform coefficient group CG 15 in the first transform region 281 (CG region 0), the first transform coefficient group CG 0 is scanned in order. The transform block is divided into two transform regions. When the horizontal scanning method is applied to the above transform block, it is the same as Figure 30d shown.

[0243] As described above, according to the method of dividing the transform block from one or more transform regions including a plurality of transform coefficient groups and scanning each of the above transform regions correspondingly, compared with the transform coefficient groups in the high-frequency region, the transform coefficient groups in the low-frequency region are preferentially scanned and transmitted, so the coding efficiency can be improved.

[0244] Figure 31 To illustrate the position of the candidate prediction motion vector (MVP candidate) of the current block for obtaining the general method.

[0245] Refer to Figure 31, To form a predicted motion vector list (MVP list), the current block can utilize the motion information of spatially adjacent blocks A0, A1, B0, B1 and the motion information of temporally adjacent blocks T0, T1. The motion information of the spatially adjacent blocks is determined by one motion information in the neighboring blocks on the left side of the current block and one motion information in the neighboring blocks on the upper side of the current block. Also, the motion information of the temporally adjacent blocks can be determined by using the motion information of the neighboring block at the lower right side of the current block or the motion information of the block at the same position as the current block inside the reference picture referred to by the current block.

[0246] For the motion information of the spatially adjacent blocks, scan and search for the motion information in the order of A0 ≥ A1 ≥ scaled A0 ≥ scaled A1 for the neighboring blocks on the left side of the current block. Then, for the neighboring blocks on the upper side of the current block, scan in the order of B0 ≥ B1 ≥ B2. In the case where the reference pictures of the current block and the motion information of blocks A0 and A1 are different, the motion information of blocks A0 and A1 scaled to conform to the reference picture of the current block can be used.

[0247] For the motion information of the temporally adjacent blocks, scan in the order of T0 and T1. In this case, the motion vectors of the temporally adjacent blocks can be scaled to the picture referred to by the current block and used.

[0248] In one embodiment, Advanced Motion Vector Prediction can use two predicted motion vectors. First, scan the motion information of the spatially adjacent blocks to input to the predicted motion vector list. During this process, if the list is not filled, scan the motion information of the temporally adjacent blocks to fill the list. When scanning the motion information of the adjacent blocks, if the same motion information is input to the predicted motion vector list, the duplicate motion information is deleted. Through this process, even after scanning the motion information of the temporal and spatial adjacent blocks, if the predicted motion vector list is not filled, fill the unfilled list with (0, 0) to complete the predicted motion vector list.

[0249] Figures 32 to 33b A method for explaining the predicted motion vector list of the current block constituting the general method.

[0250] Refer to Figure 32 , When the current block CB performs bi - directional prediction, a motion vector can be obtained from the reference picture 301 for the first direction, and a motion vector can be obtained from the reference picture 302 for the second direction. As Figure 32As shown at the lower end, the prediction motion vector list (advanced motion vector prediction list) for inter - picture prediction of the current block includes more than one candidate prediction motion vector (MVP candidate) in each direction. Thereafter, the difference value between one prediction motion vector selected from the candidate prediction motion vectors in the above - mentioned prediction motion vector list and the motion vector of the current block is calculated to obtain a differential motion vector and it is encoded.

[0251] In one embodiment, the one selected prediction motion vector may select the highest coding efficiency among the candidate prediction motion vectors included in the above - mentioned prediction motion vector list. The selected prediction motion vector is encoded in the form of index information representing these, and thus is transmitted together with the above - mentioned differential motion vector.

[0252] Figure 33a A method for the prediction motion vector list of the current block that describes the general method when the bidirectional reference images 320a and 330a referred to by the current block 310 are the same. Figure 33b A method for the prediction motion vector list of the current block that describes the general method when the bidirectional reference images 320b and 330b referred to by the current block 310 are different.

[0253] Refer to Figure 33a , for inter - picture prediction, the reference image 320a that the current block 310 refers to along the first direction and the reference image 330a that it refers to along the second direction have the same POC8. As described above, when the bidirectional reference images 320a and 330a referred to by the current block 310 are the same, as the motion vector MV L0 related to the first direction L0 of the current block 310 and the motion vector MV L1 related to the second direction L1 are very similar. However, the prediction motion vector list of the current block in the general method does not reflect these. For each direction, motion information is obtained from adjacent blocks of the independent current block, and as shown in Table 3 below, the prediction motion vector list is constituted.

[0254] Table 3

[0255]

[0256] When the reference picture 320a in the first direction and the reference picture 330a in the second direction for the current block 310 are the same, the possibility that the motion vectors in each direction are similar is high. Referring again to Figure 33a , it can be confirmed that the motion vector (MV L0 ) related to the first direction of the current block 310 and the motion vector (MV L1They are respectively similar (2, 1) and (2, 2). However, as described above, according to the general method for constructing a predicted motion vector list, the predicted motion vector lists for each direction are independently constructed.

[0257] Therefore, in order to construct the predicted motion vector list for the second direction, the motion vectors of adjacent blocks of the current block 310 that have a low correlation with the motion vector (MV L1 ) related to the second direction are used, so that the coding efficiency of the motion vector (MV L1 ) related to the second direction is reduced. However, the predicted motion vector list of the general method constructs lists independently for each direction, and obtains the differential motion vector MVD L0 =(2, 0) and MVD L1 =(2, 1) to transmit to the decoding device.

[0258] Refer to Figure 33b , when the reference picture 320b in the first direction and the reference picture 330b in the second direction referred to by the current block 310 are different, in the process of constructing the predicted motion vector list according to the general method, the predicted motion vector lists for each direction are independently constructed. The constructed predicted motion vector list is as shown in Table 4 below.

[0259] Table 4

[0260]

[0261] Even if the reference picture 320b in the first direction and the reference picture 330b in the second direction of the current block 310 are different, they are still the pictures referred to by the current block 310. Therefore, it is impossible to rule out the possibility that the motion vectors for each direction are similar according to the distance and correlation of the reference pictures. However, as described above, according to the general method for constructing a predicted motion vector list, the predicted motion vector lists for each direction are independently constructed.

[0262] As Figure 33b shown, the motion vector (MV L0 ) related to the first direction and the motion vector (MV L1 ) related to the second direction are respectively (-5, -8) and (4, 10). As shown in Table 2, a predicted motion vector list can be constructed. In this case, if the advanced motion vector prediction_L0_0 and the advanced motion vector prediction_L1_1 are respectively selected as the predicted motion vectors, the differential motion vectors (MVD L0 , MVD L1 ) transmitted to the decoding device are respectively (-3, -5) and (6, -1).

[0263] As described above, in the case of constructing a predicted motion vector list by a general method, when constructing a predicted motion vector list for a second direction, the motion information of adjacent blocks of the current block is used. Thus, when the reference picture in the second direction has a relatively high correlation with the reference picture in the first direction compared to the current picture, the coding efficiency of the motion vector is reduced instead.

[0264] Therefore, the method for constructing a predicted motion vector list according to an embodiment of the present invention, when bidirectional prediction is performed on the current block, uses the motion vector related to the first direction to construct the predicted motion vector list for the second direction.

[0265] Figure 34 and Figure 35 A flowchart and apparatus for explaining the construction of a predicted motion vector list according to an embodiment of the present invention are shown.

[0266] Referring to Figure 34 and Figure 35 , the predicted motion vector list construction unit 700 may include a first direction predicted motion vector list setting unit 710, a motion vector acquisition unit 720, and a second direction predicted motion vector list setting unit 730. The first direction predicted motion vector list setting unit 710 may set a predicted motion vector list for the first direction. The predicted motion vector list for the first direction may be composed of candidate predicted motion vectors (MVP Candidates) for the first direction obtained from the motion information of temporal and spatial adjacent blocks of the current block. The predicted motion vector list for the first direction may include two or more candidate predicted motion vectors and assign indexes representing the respective candidate predicted motion vectors. The predicted motion vector list for the first direction may be constructed according to the method described with reference to Figure 3 , but the present invention is not limited thereto. Also, the motion information acquisition unit 720 may acquire a motion vector (MV L0 )(step S40). When inter-picture prediction is performed in a conventional video codec for the above motion vector, the current block may be based on the method for acquiring the motion vector, but the present invention is not limited thereto.

[0267] After that, the second direction predicted motion vector list setting unit 730 may set a predicted motion vector list for the second direction (step S50). Among the candidate predicted motion vectors for the second direction that constitute the predicted motion vector list for the second direction, one or more may use the motion vector (MV L0) is set. In one embodiment, the candidate predicted motion vector in the second direction set using the motion vector related to the first direction is set by directly copying the motion vector related to the first direction, or is set by modifying it in various ways such as scaling the motion vector related to the first direction. Further, the candidate predicted motion vector in the second direction may be included in the predicted motion vector list in the second direction.

[0268] Since there is a high possibility that the reference picture relevance for bidirectional prediction of the current block is high, there is a high possibility that the motion vector related to the first direction and the motion vector related to the second direction (MV L0 , MV L1 ) obtained bidirectionally are similar. Thus, when obtaining one or more candidate predicted motion vectors in the second direction using the motion vector related to the first direction (MV L0 ), compared with the conventional method, the coding transmits the differential motion vector (MVD L1 ) in the second direction for small values.

[0269] Further, the second direction predicted motion vector list setting unit 730 simultaneously uses the motion vectors of the temporal adjacent block and the spatial adjacent block of the current block to obtain one or more candidate predicted motion vectors in the second direction, and thus, together with the candidate predicted motion vectors in the second direction obtained using the motion vector related to the first direction, constitutes the predicted motion vector list in the second direction. In the present invention, the number, acquisition order, and index assignment method of the candidate predicted motion vectors in the second direction set using the motion vector related to the first direction and the candidate predicted motion vectors in the second direction set by a general method are not limited.

[0270] Figure 36 and Figure 37 FIGS. show a flowchart and a configuration device for a method of configuring a predicted motion vector list according to another embodiment of the present invention.

[0271] Referring to Figure 36 , first, as shown in FIGS. Figure 34 and Figure 35 , first, a motion vector related to the first direction of the current block may be obtained (step S40). The acquisition of the motion vector related to the first direction is performed regardless of the order of configuring the predicted motion vector list in the first direction. It may be performed after obtaining the motion vector related to the first direction through the configuration of the predicted motion vector list in the first direction, or may be obtained through information independently received from the configuration of the predicted motion vector list in the first direction. The present invention is not limited thereto.

[0272] Referring to Figure 36 and Figure 37, the second-direction predicted motion vector list setting unit 730 includes a first candidate predicted motion vector setting unit 731 and a second candidate predicted motion vector setting unit 732. The first candidate predicted motion vector setting unit 731 sets a first candidate predicted motion vector, and the first candidate predicted motion vector is a candidate predicted motion vector that uses the motion vector (MV L0 ) related to the first direction to form a predicted motion vector list in the second direction, and can be a set candidate predicted motion vector (step S41). The first candidate predicted motion vector can be one or more candidate predicted motion vectors.

[0273] Among the candidate predicted motion vectors, the first candidate predicted motion vector has the highest correlation with the motion vector of the current block. Therefore, when forming the first predicted motion vector list, the first candidate predicted motion vector is assigned an index with the smallest codeword, thereby improving the coding efficiency. In one embodiment, if there are at least two or more of the first candidate predicted motion vectors, the first candidate predicted motion vectors are assigned indexes in the order of having smaller codewords to improve the coding efficiency.

[0274] The second candidate predicted motion vector setting unit 732 also independently of the first candidate predicted motion vector setting unit 731 and regardless of the order, uses the spatial and temporal neighboring blocks of the current block to set one or more candidate predicted motion vectors (step S42). The one or more candidate predicted motion vectors can be second candidate predicted motion vectors. The second candidate predicted motion vector is obtained by referring to the method of obtaining a general predicted motion vector described in Figure 3 , and together with the first candidate predicted motion vector, forms a predicted motion vector list in the second direction. In this case, when forming the predicted motion vector list in the second direction, the number, acquisition order, and index assignment method of the first candidate predicted motion vector and the second candidate predicted motion vector are not limited as long as they are methods that can be implemented by those of ordinary skill in the technical field to which the present invention pertains.

[0275] As described above, in the method and apparatus for forming a predicted motion vector list according to an embodiment of the present invention, when performing bidirectional inter-picture prediction on the current block, one or more of the candidate predicted motion vectors in the second direction are obtained by using the motion vector in the first direction, thereby improving the coding efficiency.

[0276] Figure 38a and Figure 38b is used to illustrate the method of forming a predicted motion vector list according to an embodiment of the present invention.

[0277] Refer to Figure 38a, the current block 310 performs bidirectional prediction. When the pictures 340a and 350a referred to in the first direction and the second direction are the same with POC = 8, the motion vector (MV L0 ) related to the first direction can be used to construct the prediction motion vector list for the second direction. For example, when the motion vector (MV L0 ) related to the first direction of the current block is (2, 1), MV L0 = (2, 1) can be set as the first candidate prediction motion vector for the second direction. In one embodiment, the above first candidate prediction motion vector may have the shortest codeword in the index of the prediction motion vector list for the second direction. However, the present invention is not limited thereto, and an assignment to one index in the prediction motion vector list for the second direction is also possible.

[0278] Refer to Figure 38a and Figure 33a . When the current block 310 performs bidirectional prediction, under the condition that the images referred to in each direction are the same, when the motion information is independently obtained from the adjacent blocks of the current block to construct the prediction motion vector list for the second direction, the differential motion vector for the second direction transmitted is (2, 1). However, when the motion vector related to the first direction is used as the first candidate prediction motion vector for the second direction, the differential motion vector for the second direction can be (0, 1). The composition of the advanced motion vector prediction list according to an embodiment of the present invention is shown in Table 5 below.

[0279] Table 5

[0280]

[0281] As described above, the correlation between the motion vector related to the first direction and the motion vector related to the second direction is high. Therefore, the method of constructing the prediction motion vector list of the present invention by setting the first prediction motion vector of the second direction using the motion vector related to the first direction encodes and transmits a smaller differential motion vector (MVD) compared to the conventional method.

[0282] Figure 38b It shows that when the current block 310 performs bidirectional prediction and the picture 340b referred to in the first direction is different from the picture 350b referred to in the second direction, the motion vector (MV L0)A method for setting the first candidate prediction motion vector that constitutes the prediction motion vector list in the second direction. The above first candidate prediction motion vector is also obtained by using reference picture information such as the reference picture for the first direction and the POC of the reference picture for the second direction. For example, for the reference picture 340b in the first direction of the current block 310, POC = 8, and for the reference picture 350b in the second direction, POC = 12. When the motion vector MV L0 in the first direction related to the current block 310 is (5, 8), as shown in Table 6 below, the first prediction motion vector in the second direction can be (-5, 8) scaled based on POC.

[0283] Table 6

[0284]

[0285] Reference Figure 38b and Figure 33b , when the current block 310 is bi - directionally predicted and the images for direction reference are different, in order to constitute the prediction motion vector list in the second direction (Advanced Motion Vector Prediction_L1), when the motion information related to the first direction is independently obtained from the adjacent blocks of the current block to form the motion information, the differential motion information (MVD L1 ) in the second direction that is transmitted can be (6, -1). However, when using the scaled motion vector related to the first direction (Scaled_MV L0) as the first candidate prediction motion vector, the differential motion vector (MVD L1 ) in the second direction can be (-1, 2).

[0286] As described above, the correlation between the motion vector (MV L0 ) related to the first direction and the motion vector (MV L1 ) related to the second direction is high. Therefore, based on POC, the motion vector related to the first direction is scaled (Scaled_MV L0 ) to set the first prediction motion vector (MV L1 ) in the second direction. The method of constructing the prediction motion vector list of the present invention encodes and transmits a relatively small differential motion vector (MVD L1 ) compared to the conventional method, so the coding efficiency can be improved. In one embodiment, in order to improve the coding efficiency, the above first candidate prediction motion vector has the shortest codeword in the index that constitutes the prediction motion vector list in the second direction. However, the present invention is not limited to this. In the present invention, as the first candidate prediction motion vector in the second direction, a method of scaling the motion vector related to the first direction based on POC is disclosed, but the scaling method is not limited to this.

[0287] Figure 39 FIG. 1 is a flow chart showing a method for constructing a predicted motion vector list according to another embodiment of the present invention. Figure 39 In order to form an advanced motion vector prediction list for the current block, first, the motion vector (MV L0 )(Step S40). The motion vector related to the above-mentioned first direction is obtained in the decoder by using the candidate predicted motion vector and the differential motion vector in the predicted motion vector list of the first direction received from the encoder, and can also be received from the encoder. The method for obtaining the motion vector related to the above-mentioned first direction of the present invention is not limited to this.

[0288] Then, the picture information (POC) of the reference picture related to the first direction of the bidirectional prediction for the current block is determined. ref_L0 ) and picture information of the reference picture related to the second direction (POC ref_L1 ) are the same (step S60). For example, whether the first and second reference pictures are the same or not can be determined by picture information such as POC.

[0289] When the picture information of the reference picture for the first direction and the picture information of the reference picture for the second direction are the same (Yes in S60), the motion vector (MV L0 )(Step S70). The above-mentioned first candidate predicted motion vector may be more than one candidate predicted motion vector. Furthermore, the one or more remaining candidate predicted motion vectors (MVP_L1_N) constituting the predicted motion vector list of the above-mentioned second direction may be set according to a general method (Step S80). When the first candidate predicted motion vector of the above-mentioned second direction is set by copying the motion vector related to the above-mentioned first direction and the acquisition order of the remaining candidate predicted motion vectors of the above-mentioned second direction obtained by the general method and the predicted motion vector list of the second direction are constituted, the index allocation method is not restricted.

[0290] When the picture information of the reference picture in the first direction and the picture information of the reference picture in the second direction are different (No in S60), the scaled value (Scaled_MV L0)(Step S90). The above first candidate predicted motion vector may be more than one candidate predicted motion vector. Also, more than one remaining candidate predicted motion vectors (MVP_L1_N) that form the predicted motion vector list in the above second direction may be set according to a general method (Step S95). When obtaining the first candidate predicted motion vector in the second direction set by scaling the value of the motion vector related to the above first direction and the remaining candidate predicted motion vectors in the second direction obtained by a general method, and when forming the predicted motion vector list in the second direction, the index assignment method is not limited.

[0291] In the advanced motion vector prediction list formed according to the above method, when performing inter-picture prediction, the motion vector in the first direction with high relevance is used to form the predicted motion vector list in the second direction. Therefore, a method for forming a predicted motion vector list with improved coding efficiency for inter-picture prediction can be provided. Also, considering one or more of whether the picture information of the reference picture in the first direction and the reference picture in the second direction is the same and the distance between the above reference highlight and the current picture during bi-directional prediction, more than one candidate predicted motion vector that forms the predicted motion vector list in the second direction is set to improve the coding efficiency.

[0292] The present invention described above is not limited to the above embodiments and the accompanying drawings. Without departing from the technical idea of the present invention, those of ordinary skill in the technical field to which the present invention pertains can make various substitutions, deformations, and changes.

Claims

1. A method for decoding a video signal, including a scanning method for scanning a transform block having a plurality of groups of transform coefficients, comprising the following steps: Obtaining transform region information indicating at least one or more of a plurality of transform regions included in the transform block, wherein, The transform block includes a non-square transform block or a square transform block; Based on the transform region information, the transform block is divided into at least one transform region among the plurality of transform regions; The scanning methods of the transform regions are respectively obtained; The plurality of transform coefficient groups included in the first transform region are scanned by using the obtained scanning method; and The plurality of transform coefficient groups included in the second transform region are scanned by using the scanning method of the second transform region, wherein the plurality of transform coefficient groups respectively include a plurality of transform coefficients.

2. The method for decoding a video signal according to claim 1, wherein, The transform region information is received from an encoder.

3. The method for decoding a video signal according to claim 1, wherein, Before the step of obtaining the transform region information, there is also a step of determining the type of the transform block, wherein the step of determining the type of the transform block includes the following steps: determining that the transform block is a non-square block by comparing the horizontal length and the vertical length of the transform block.

4. The method for decoding a video signal according to claim 2, wherein, The step of determining the type of the transform block is performed based on the horizontal length and the vertical length of the transform block.

Citation Information

Patent Citations

  • Multiple zone scanning order for video coding

    CN103636223A

  • Method for decoding video signal

    CN114222140A

  • Transform coefficient coding for context-adaptive binary entropy coding of video

    US20160080749A1