Video decoding method and apparatus, encoding method and storage method
The video encoding and decoding method addresses the inefficiencies in existing codecs by using motion vectors to find predicted candidates, improving compression ratios and enhancing the encoding and decoding of high-resolution video content.
Patent Information
- Application Number
- JP2024065857
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Priority Date
- 2014-10-31
- Filing Date
- 2024-04-16
- Publication Date
- 2025-09-25
- Estimated Expiration
- 2035-11-02
AI Technical Summary
Existing video codecs have limitations in efficiently encoding and decoding high-resolution or high-quality video content due to their reliance on a limited encoding scheme based on tree-structured coding units, which do not effectively utilize motion vectors to improve compression ratios.
A video encoding and decoding method that utilizes a motion vector to search for various predicted motion vector candidates, reducing bit representation and improving compression ratio by employing a prediction mode different from skip and merge modes, and generating motion vector predictor candidates based on specific distances and neighboring block information.
This approach enhances the compression efficiency of video codecs by reducing bit representation and improving the compression ratio through the use of additional motion vector predictor candidates, thereby optimizing the encoding and decoding of high-resolution video content.
Smart Images

Figure 0007744462000002 
Figure 0007744462000003 
Figure 0007744462000004
Abstract
Description
[Technical Field]
[0001] The present invention relates to an apparatus and method for video encoding and decoding. [Background technology]
[0002] With the development and widespread use of hardware capable of playing and storing high-resolution or high-quality video content, the need for video codecs that can effectively encode and decode high-resolution or high-quality video content is increasing. With existing video codecs, video is encoded using a limited encoding scheme based on a tree-structured coding unit.
[0003] Using frequency transform, spatial domain video data is transformed into frequency domain coefficients. To speed up frequency transform calculations, video codecs divide video into blocks of a predetermined size, perform DCT transform on each block, and encode frequency coefficients for each block. Compared to spatial domain video data, frequency domain coefficients have a form that is easier to compress. In particular, since spatial domain video pixel values are represented by prediction errors through inter-prediction or intra-prediction of video codecs, when frequency transform is performed on the prediction errors, much of the data is converted to zero. Video codecs reduce data volume by replacing continuously and repeatedly occurring data with small-sized data. Summary of the Invention [Problem to be solved by the invention]
[0004] A video encoding method and a video decoding method are provided that use a motion vector to search for various predicted motion vector candidates, reduce bit representation, and improve compression ratio. [Means for solving the problem]
[0005] According to one aspect, a video decoding method performed by a video decoding device includes the steps of: determining prediction mode information of a current block and an index indicating a prediction candidate from a bitstream; determining a predictor candidate list based on the prediction mode information; if the prediction mode information of the current block indicates a preset prediction mode, determining a motion vector indicated by the index in the predictor candidate list, and determining a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector; and determining a motion vector of the current block based on the predicted motion vector, wherein the preset prediction mode is a prediction mode different from skip mode and merge mode. [Effects of the Invention]
[0006] A video encoding method and a video decoding method are provided that use a motion vector to search for various predicted motion vector candidates, reduce bit representation, and improve compression ratio. [Brief explanation of the drawings]
[0007] [Figure 1] 1 is a block diagram of a video encoding device according to one embodiment; [Figure 2] 1 is a flowchart of a video encoding method according to one embodiment. [Figure 3] 1 is a block diagram of a video decoding device according to one embodiment; [Figure 4] 1 is a flowchart of a video decoding method according to one embodiment. [Figure 5A] 10 is a diagram illustrating a process of determining a motion vector predictor candidate according to an embodiment; [Figure 5B] 10 is a diagram illustrating a process of determining a motion vector predictor candidate according to an embodiment; [Figure 5C] 10 is a diagram illustrating a process of determining a motion vector predictor candidate according to an embodiment; [Figure 5D]10 is a diagram illustrating a process of determining a motion vector predictor candidate according to an embodiment; [Figure 6A] 10 is a diagram illustrating a bit representation method when pre-set prediction mode information is inserted into an existing predictor candidate list, according to an embodiment; [Figure 6B] 10 is a diagram illustrating a bit representation method when pre-set prediction mode information is inserted into an existing predictor candidate list, according to an embodiment; [Figure 6C] 10 is a diagram illustrating a bit representation method when pre-set prediction mode information is inserted into an existing predictor candidate list, according to an embodiment; [Figure 7] 10 is a diagram illustrating a bit representation method of a predicted motion vector according to an embodiment; [Figure 8] 1 is a block diagram of a video encoding device based on a tree-structured coding unit according to one embodiment; [Figure 9] 1 is a block diagram of a video decoding device based on a tree-structured coding unit according to one embodiment; [Figure 10] 1 is a diagram illustrating a concept of a coding unit according to an embodiment; [Figure 11] FIG. 2 is a block diagram of a coding unit-based video encoder according to one embodiment. [Figure 12] FIG. 2 is a block diagram of a coding unit-based video decoder according to one embodiment. [Figure 13] 1 is a diagram illustrating coding units and partitions according to one embodiment. [Figure 14] 1 is a diagram illustrating a relationship between coding units and transform units according to one embodiment. [Figure 15] 1 is a diagram illustrating encoding information according to an embodiment; [Figure 16] 1 is a diagram illustrating a coding unit according to an embodiment. [Figure 17] 1 is a diagram illustrating a relationship between a coding unit, a prediction unit, and a transform unit according to an embodiment. [Figure 18] 1 is a diagram illustrating a relationship between a coding unit, a prediction unit, and a transform unit according to an embodiment. [Figure 19] 1 is a diagram illustrating a relationship between a coding unit, a prediction unit, and a transform unit according to an embodiment. [Figure 20] 10 is a diagram illustrating the relationship between coding units, prediction units, and transform units according to coding mode information in Table 2. [Figure 21] 1 is a diagram illustrating the physical structure of a disk on which a program is stored, according to one embodiment. [Figure 22] 1 is a diagram illustrating a disk drive for recording and reading a program using a disk. [Figure 23] 1 is a diagram illustrating the overall structure of a content supply system for providing a content distribution service. [Figure 24] 1 is a diagram illustrating an external structure of a mobile phone to which a video encoding method and a video decoding method of the present invention are applied, according to an embodiment; [Figure 25] 1 is a diagram illustrating an internal structure of a mobile phone to which a video encoding method and a video decoding method of the present invention are applied, according to an embodiment; [Figure 26] 1 is a diagram illustrating a digital broadcasting system to which a communication system according to the present invention is applied; [Figure 27] 1 is a diagram illustrating a network structure of a cloud computing system using a video encoding device and a video decoding device according to an embodiment. DETAILED DESCRIPTION OF THE INVENTION
[0008] The present invention will be readily understood by the following detailed description in conjunction with the accompanying drawings, in which reference numerals refer to structural elements.
[0009] According to one aspect, a video decoding method performed by a video decoding device includes the steps of: determining prediction mode information of a current block and an index indicating a prediction candidate from a bitstream; determining a predictor candidate list based on the prediction mode information; if the prediction mode information of the current block indicates a preset prediction mode, determining a motion vector indicated by the index in the predictor candidate list, and determining a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector; and determining a motion vector of the current block based on the predicted motion vector, wherein the preset prediction mode is a prediction mode different from skip mode and merge mode.
[0010] Furthermore, the predictor candidate list according to the preset prediction mode may include, as motion vector predictor candidates, candidates that are at a certain distance from the base motion vector.
[0011] The base motion vector is also one of the motion vector predictor candidates used in the skip mode or merge mode of the current block.
[0012] In addition, the step of determining a candidate predicted motion vector for the current block may determine candidate predicted motion vectors that are a first pixel distance from the base motion vector as a first candidate group, and candidate predicted motion vectors that are a second pixel distance from the base motion vector as a second candidate group.
[0013] In addition, the motion prediction information related to the motion vector includes at least one of a reference direction, an index of a reference picture, a value of the motion vector, and motion vector differential value information obtained from neighboring blocks of the current block, and the step of determining a predicted motion vector of the current block can determine a predicted motion vector of the current block by combining or transforming the reference direction, the index of the reference picture, the value of the motion vector, and the motion vector differential value information.
[0014] In addition, the indexes indicated by the predicted motion vector candidates included in the predictor candidate list include indexes indicating predicted motion vector candidates according to skip mode or merge mode, and indexes indicating predicted motion vector candidates according to the preset prediction mode, and the indexes indicating predicted motion vector candidates according to the preset prediction mode can also be generated between existing indexes.
[0015] Also, the prediction mode information of the preset prediction mode may be obtained between the skip flag and the merge mode flag, or after the skip flag and the merge mode flag.
[0016] According to another aspect, a video encoding method performed by a video decoding device includes the steps of: determining a predictor candidate list according to a preset prediction mode; if prediction mode information of a current block indicates the preset prediction mode, determining a motion vector indicated by an index in the predictor candidate list, and determining a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector; determining a motion vector of the current block based on the predicted motion vector; and encoding prediction mode information indicating the preset prediction mode, wherein the preset prediction mode is a prediction mode different from skip mode and merge mode.
[0017] Furthermore, the predictor candidate list according to the preset prediction mode may include, as motion vector predictor candidates, candidates that are at a certain distance from the base motion vector.
[0018] The base motion vector is also one of the motion vector predictor candidates used in the skip mode or merge mode of the current block.
[0019] In addition, the step of determining a candidate predicted motion vector for the current block may determine candidate predicted motion vectors that are a first pixel distance from the base motion vector as a first candidate group, and candidate predicted motion vectors that are a second pixel distance from the base motion vector as a second candidate group.
[0020] In addition, the indexes indicated by the predicted motion vector candidates included in the predictor candidate list include indexes indicating predicted motion vector candidates according to skip mode or merge mode, and indexes indicating predicted motion vector candidates according to the preset prediction mode, and the indexes indicating predicted motion vector candidates according to the preset prediction mode can also be generated between existing indexes.
[0021] Also, the prediction mode information of the preset prediction mode may be inserted between the skip flag and the merge mode flag, or after the skip flag and the merge mode flag.
[0022] According to another aspect, the present invention includes a determination unit that determines prediction mode information of a current block and an index indicating a prediction candidate from a bitstream, and determines a predictor candidate list based on the prediction mode information; and a decoding unit that, if the prediction mode information of the current block indicates a preset prediction mode, determines a motion vector indicated by the index in the predictor candidate list, determines a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector, and performs motion compensation of the current block based on the motion vector of the current block obtained from the predicted motion vector, wherein the preset prediction mode is a prediction mode different from skip mode and merge mode.
[0023] According to another aspect, the present invention includes an encoding unit that determines a predictor candidate list based on preset prediction mode information, and if prediction mode information of a current block indicates the preset prediction mode, determines a motion vector indicated by an index in the predictor candidate list, determines a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector, and performs motion prediction of the current block based on the motion vector of the current block obtained from the predicted motion vector, and a bitstream generation unit that generates a bitstream including prediction mode information indicating the preset prediction mode, wherein the preset prediction mode is a prediction mode different from skip mode and merge mode.
[0024] The terms used in this invention are currently commonly used and general terms that have been selected as much as possible while taking into consideration the functions of the present invention. However, they may vary depending on the intentions of those skilled in the art, precedents, or the emergence of new technologies. In addition, in certain cases, the applicant may arbitrarily select terms, and in such cases, their meanings will be described in detail in the description of the invention. Therefore, the terms used in this invention are not simply the names of terms, but are defined based on the meanings that the terms have and the overall content of the present invention.
[0025] Throughout this specification, when a part "comprises" a certain component, it does not mean that it excludes other components and may further include other components, unless specifically stated to the contrary. Furthermore, the term "module" used in this specification refers to software or a hardware component such as an FPGA or ASIC, and a "module" performs a certain function. However, the term "module" is not limited to software or hardware. A "module" may be configured to reside on an addressable storage medium or to execute one or more processors. Thus, by way of example, "module" includes components such as software components, object-oriented software components, class components, and task components, as well as processes, functions, attributes, procedures, subroutines, program code segments, drivers, firmware, microcode, circuits, data, databases, data structures, tables, arrays, and variables. The functionality provided in a component or "module" may be combined into fewer components and "modules," or may be further separated into additional components and "modules."
[0026] Terms such as "first" and "second" are used to describe various elements, but the elements are not limited by these terms. These terms are used only to distinguish one element from another. For example, a first element may be termed a "second element," and similarly, a second element may be termed a "first element," without departing from the scope of the present invention. The term "and / or" includes a combination of two or more related listed items or any one of two or more related listed items.
[0027] DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS
[0023] The present invention will now be described in detail with reference to the accompanying drawings, so that those skilled in the art can easily practice the present invention. However, the present invention may be embodied in many different forms and should not be construed as limited to the embodiments set forth herein. Hereinafter, a video encoding method and a video decoding method according to an embodiment will be proposed with reference to FIGS.
[0028] Also, with reference to FIGS. 8 to 20, a video encoding method and a video decoding method based on a tree-structured coding unit according to an embodiment, which can be applied to the previously proposed video encoding method and video decoding method, are disclosed.
[0029] 21 to 27, an embodiment to which the previously proposed video encoding method and video decoding method can be applied is disclosed.
[0030] Hereinafter, "image" refers to video stills and moving images, i.e., the video itself.
[0031] Hereinafter, the term "current block" refers to a block of an image to be encoded or decoded.
[0032] Hereinafter, a "neighboring block" refers to at least one block to be coded or decoded that is adjacent to a current block. For example, the neighboring block may be located at the top edge of the current block, the top right edge of the current block, the left side of the current block, or the top left edge of the current block. The neighboring block may include not only spatially adjacent blocks but also temporally adjacent blocks. For example, the temporally adjacent neighboring block may include a neighboring block of the current block in the reference picture. The neighboring block may also include a co-located block of the current block in the reference picture or a spatially adjacent block of the co-located block.
[0033] 1 is a block diagram of a video encoding device according to an embodiment. Referring to FIG. 1, the video encoding device 10 may include an encoding unit 12 and a bitstream generation unit 14. However, none of the components shown in the figure are essential components. The video encoding device 10 may be implemented with more or fewer components than those shown in the figure. The components will be described below.
[0034] In inter-prediction, a video encoding device 10 (e.g., an encoder) can find a prediction block that is most similar to a current block from a reference picture and then transmit information related to the prediction block to a video decoding device 20 (e.g., a decoder).
[0035] Video encoding device 10 can search for the best predictive block from a reference picture through a motion estimation process, and generate the predictive block through a motion compensation process.
[0036] Hereinafter, "motion estimation" refers to searching for an optimal prediction block from a reference picture. For more precise motion estimation, video encoding device 10 may interpolate a reconstructed picture and then perform motion estimation on the interpolated image in sub-pixel units, depending on the type of video codec.
[0037] Hereinafter, "motion compensation" refers to generating a prediction block based on motion information related to the optimal prediction block found in the motion estimation process, where the motion information may be, but is not limited to, a motion vector or a reference picture index.
[0038] According to one disclosure, in inter prediction, the video encoding device 10 transmits motion estimation result direction information, reference indices for distinguishing reference pictures in a reference list, motion vector information, and the like to the video decoding device 20. Here, the motion estimation result direction information is also direction information for distinguishing between reference picture list 0 and reference picture list 1. In order to reduce the amount of motion information transmitted per prediction unit, the video encoding device 10 may use a prediction mode that utilizes the correlation of motion information between neighboring blocks and the current block. The prediction mode may be, but is not limited to, skip mode, merge mode, or advanced motion vector prediction (AMVP), and may include other prediction modes.
[0039] The encoding unit 12 can construct a list of candidate blocks for deriving motion information and select a candidate block from the list. For example, the motion information is also the motion vector of the current block. That is, the encoding unit 12 can determine a prediction candidate list for deriving motion information.
[0040] Hereinafter, in this specification, a "prediction candidate" refers to a candidate block. A "prediction candidate list" refers to a list of motion vectors of a candidate block. A "prediction candidate list" may also refer to a list of indexes indicating motion vectors of a candidate block. A "base motion vector" refers to a motion vector for which a candidate block indicates a reference block. A "predictor motion vector" refers to a vector derived from a "base motion vector" and is selected to predict the motion vector of a current block from among motion vector candidates determined using motion prediction information related to the base motion vector.
[0041] The encoding unit 12 may determine a prediction candidate list based on preset prediction mode information. Here, the preset prediction mode may be a prediction mode different from skip mode and merge mode. The preset prediction mode may generate motion vector predictor candidates using information used in encoding and decoding an image as well as information used in skip mode or merge mode, and may determine one of the motion vector predictor candidates as a motion vector predictor.
[0042] For example, the encoding unit 12 may generate motion vector predictor candidates using at least one of reference direction information for classifying a reference picture list, a reference picture index, a motion vector value, and a motion vector difference value according to the preset prediction mode, and determine one of the motion vector predictor candidates as a motion vector predictor. This will be described with reference to Figures 5A to 5D.
[0043] In another example, the encoding unit 12 may modify at least one of the reference direction information, reference picture index, motion vector value, and motion vector differential value that divide the reference picture list according to the preset prediction mode, and may generate predicted motion vector candidates by using only the modified information or by using the modified information and the information before the modification, and may determine one of the predicted motion vector candidates as the predicted motion vector.
[0044] According to one disclosure, the prediction candidate list according to the preset prediction mode may include motion vector predictor candidates that are within a certain distance from the base motion vector. The related process of determining the motion vector predictor candidates will be described with reference to Figures 5A to 5D.
[0045] The prediction candidate list may include spatial candidates or temporal candidates. The spatial candidates are neighboring blocks determined according to the division form of the prediction unit based on the assumption that the motion of the current block and neighboring blocks is similar. For example, a 2Nx2N prediction unit can use five blocks located around the current block as spatial candidates. 2NxN, Nx2N, 2NxnU, 2NxnD, nLx2N, and nRx2N prediction units can also use five blocks located around the current block as spatial candidates. Furthermore, once spatial candidate configuration is complete, the encoding unit 12 may determine temporal candidates. Furthermore, once spatial candidate or temporal candidate configuration is complete, additional candidates may be determined by combining the completed candidates.
[0046] If the prediction mode information of the current block indicates the preset prediction mode, the encoding unit 12 may determine a motion vector indicated by a prediction candidate index in the prediction candidate list. The encoding unit 12 may determine a motion vector predictor of the current block based on at least one of the motion prediction information related to the motion vector. The encoding unit 12 may combine the motion prediction information related to the motion vector to obtain motion vector predictor candidates, and may determine a motion vector predictor based on a prediction block that is most similar to the current block from the motion vector predictor candidates.
[0047] The motion prediction information related to the motion vector may include at least one of a reference direction obtained from a neighboring block of the current block, an index of a reference picture, a motion vector value, and motion vector differential value information, but is not limited thereto.
[0048] The encoding unit 12 can combine and shift the reference direction, the reference picture index, the motion vector value, and the motion vector differential value information to obtain a new predicted motion vector candidate, and determine the predicted motion vector of the current block from the new predicted motion vector candidate.
[0049] The encoding unit 12 can also configure each candidate group with a different number of motion vector predictor candidates. The encoding unit 12 can determine a motion vector predictor candidate that is a first pixel distance from a base motion vector as a first candidate group, a motion vector predictor candidate that is a second pixel distance from a base motion vector as a second candidate group, and a motion vector predictor candidate that is an n-th pixel distance from a base motion vector as an n-th candidate group. Here, the motion vector predictor candidate that is a certain pixel distance may include a motion vector predictor candidate that is a certain pixel distance and a pixel distance within a predetermined error range. The encoding unit 12 can also configure motion vector predictor candidates such that the pixel distance increases with an increase in the number of groups, and the distance between pixel distances increases linearly or nonlinearly.
[0050] The encoding unit 12 can determine a candidate index indicating the group to which the motion vector predictor belongs, from the first candidate group and the second candidate group.
[0051] Meanwhile, the indexes indicating motion vector predictor candidates included in the predictor candidate list may include indexes indicating motion vector predictor candidates according to a skip mode or a merge mode, and indexes indicating motion vector predictor candidates according to a preset prediction mode. The indexes indicating motion vector predictor candidates according to the preset prediction mode may be generated between existing indexes.
[0052] The prediction mode information of the preset prediction mode may be indicated using a flag or index of the preset prediction mode. The preset prediction mode may include, but is not limited to, skip mode, merge mode, and AMVP mode. The video encoding device 10 may determine a predicted motion vector by deriving a reference direction, a reference picture index, a motion vector value, etc. from a neighboring block according to the skip mode and merge mode. The video encoding device 10 may transmit a reference direction, a reference picture index, and a motion vector difference value different from those of the skip mode and merge mode to the video decoding device 20 according to the AMVP mode.
[0053] For example, a flag indicating whether to use a preset prediction mode may be inserted between an existing skip flag and a merge mode flag. If the preset prediction mode flag is on, the video encoding device 10 may not transmit syntax information related to motion prediction, except for an index of a motion vector predictor candidate, or may transmit information related to a residual component. In this case, whether or not to transmit information related to the residual component may be explicitly transmitted in a flag. The video encoding device 10 may reduce bit representation and improve compression rate by representing prediction mode information of the preset prediction mode using a flag or index of an existing mode.
[0054] As another example, a flag indicating whether to use a preset prediction mode may be inserted after a merge mode flag. As in the previous example, if the preset prediction mode flag is on, the video encoding device 10 may not send syntax information related to motion prediction, except for an index of a motion vector predictor candidate, or may send information related to a residual component. In this case, whether to send information related to a residual component may be explicitly set in a flag.
[0055] When prediction mode information of a preset prediction mode is inserted into an existing index list, the bit representation of the index after the prediction mode information is inserted changes, as will be described with reference to Figures 6A to 6C.
[0056] Furthermore, the encoding unit 12 can determine the motion vector of the current block using the predicted motion vector, and perform motion prediction of the current block based on the motion vector of the current block.
[0057] The bitstream generation unit 14 can generate a bitstream including prediction mode information indicating a preset prediction mode. The video encoding device 10 can transmit the generated bitstream to the video decoding device 20. The video encoding device 10 can effectively reduce the amount of motion-related data by transmitting predictor motion vector information selected in the predictor candidate list to the video decoding device 20.
[0058] Furthermore, the video encoding device 10 can transform, quantize, and entropy encode a residual signal, which is a difference value between a predicted block obtained by inter-prediction and an original block.
[0059] The video encoding device 10 may include a central processor (not shown) that controls the encoding unit 12 and the bitstream generation unit 14. The central processor (not shown) may be implemented as an array of multiple logic gates or as a combination of a general-purpose microprocessor and a memory storing a program executed by the microprocessor. Those skilled in the art will understand that the central processor (not shown) may also be implemented as other types of hardware. Alternatively, the encoding unit 12 and the bitstream generation unit 14 may be operated by their own processors (not shown), and the video encoding device 10 may be operated as a whole by the processors (not shown) operating in an integrated manner. Alternatively, the encoding unit 12 and the bitstream generation unit 14 may be controlled by a processor (not shown) external to the video encoding device 10.
[0060] The video encoding device 10 may include one or more memories (not shown) for storing input and output data of the encoding unit 12 and the bitstream generation unit 14. The video encoding device 10 may also include a memory control unit (not shown) for controlling data input and output from the memory.
[0061] The following describes various operations and applications performed by the video encoding device 10. However, even if the configuration of the encoding unit 12 and the bitstream generation unit 14 is not specified, the content that can be clearly understood and expected by a person skilled in the art of the present invention is understood as a common implementation, and the scope of the present invention is not limited by the names or physical / logical structures of specific components. The operation of the video encoding device 10 will be described below with reference to FIG. 2.
[0062] 2 is a flowchart of a video encoding method according to an embodiment. At step S11 of FIG. 2, the video encoding device 10 may determine a prediction candidate list according to a preset prediction mode. Here, the preset prediction mode is a prediction mode different from a skip mode and a merge mode. The preset prediction mode is a mode in which motion vector predictor candidates are generated using information used in encoding and decoding an image as well as information used in the skip mode or merge mode, and one of the motion vector predictor candidates is determined as a motion vector predictor.
[0063] For example, the video encoding device 10 may generate predicted motion vector candidates using at least one of reference direction information, reference picture index, motion vector value, and motion vector differential value that divide a reference picture list according to a preset prediction mode, and determine one of the predicted motion vector candidates as a predicted motion vector.
[0064] According to one disclosure, the prediction candidate list according to the preset prediction mode may include candidate motion vectors that are a certain distance away from a base motion vector, and the base motion vector is also one of the candidate motion vector predictors used in a skip mode or a merge mode for the current block.
[0065] In operation S13, if the prediction mode information of the current block indicates a preset prediction mode, the video encoding device 10 may determine a motion vector indicated by a prediction candidate index in the prediction candidate list. The video encoding device 10 may determine a predicted motion vector of the current block based on at least one of the motion prediction information related to the motion vector.
[0066] The video encoding device 10 can determine a predicted motion vector candidate based on at least one of the motion prediction information, and can determine a predicted motion vector based on a predicted block that is most similar to the current block from the determined predicted motion vector candidates.
[0067] The motion prediction information related to the motion vector may include, but is not limited to, at least one of a reference direction, a reference picture index, a motion vector value, and motion vector differential value information obtained from neighboring blocks of the current block. The video encoding device 10 may determine a predicted motion vector for the current block by combining or transforming the reference direction, the reference picture index, the motion vector value, and the motion vector differential value information.
[0068] The video encoding device 10 generates predicted motion vector candidates using at least one of reference direction information, reference picture index, motion vector value, and motion vector differential value that divide the reference picture list according to the preset prediction mode, and can determine one of the predicted motion vector candidates as the predicted motion vector.
[0069] Meanwhile, the indexes indicating the motion vector predictor candidates included in the prediction candidate list may include indexes indicating the motion vector predictor candidates in the skip mode or merge mode, and indexes indicating the motion vector predictor candidates in the preset prediction mode.
[0070] Here, an index indicating a motion vector predictor candidate according to a preset prediction mode may be generated between existing indexes, and prediction mode information of the preset prediction mode may be inserted between a skip flag and a merge mode flag or after the skip flag and the merge mode flag.
[0071] Furthermore, the video encoding device 10 can group m motion vector predictor candidates into one candidate group to generate n candidate groups (where m and n are positive integers). For example, the video encoding device 10 can determine four motion vector predictor candidates that are 1 / 4 pixel apart as a first candidate group. The video encoding device 10 can determine four motion vector predictor candidates that are 1 / 2 pixel apart as a second candidate group.
[0072] In step S15, the video encoding apparatus 10 may determine a motion vector for the current block based on the predicted motion vector.
[0073] In operation S17, the video encoding device 10 may encode prediction mode information indicating a preset prediction mode. The video encoding device 10 may generate a bitstream including prediction mode information indicating the preset prediction mode. The video encoding device 10 may transmit the generated bitstream to the video decoding device 20. The video encoding device 10 may also operate in cooperation with an internal video encoding processor or an external video encoding processor to output the encoding result of the prediction mode information. The internal video encoding processor of the video encoding device 10 may not only be a separate processor, but may also include a case in which the video encoding device 10, a central processing unit, or a graphics processing unit includes a video encoding processing module to implement basic video encoding operations.
[0074] 3 is a block diagram of a video decoding device according to an embodiment. Referring to FIG. 3, the video decoding device 20 may include a decision unit 22 and a decoding unit 24. However, none of the components shown in the figure are essential components. The video decoding device 20 may be implemented with more or fewer components than those shown in the figure. The components will be described below.
[0075] If the prediction mode of the current block is inter prediction mode, the video decoding device 20 performs motion compensation using reference picture information and reference block information transmitted from the video encoding device 10. The video decoding device 20 can generate a prediction block through motion compensation. The video decoding device 20 can reconstruct an image by combining the generated prediction block with a residual signal generated through entropy coding, inverse quantization, and inverse transform processes.
[0076] The determination unit 22 receives a bitstream and determines prediction mode information for the current block and an index indicating a prediction candidate from the received bitstream. Those skilled in the art will understand that the prediction mode may include, but is not limited to, skip mode, merge mode, and AMVP mode, and may include other prediction modes. The skip mode and merge mode are modes for determining a predicted motion vector by deriving a reference direction, a reference picture index, a motion vector value, etc. from neighboring blocks. The AMVP mode transmits a reference direction, a reference picture index, and a motion vector different from those of the skip mode and merge mode from the video encoding device 10. The prediction mode may also be preset based on information used for encoding and decoding video.
[0077] The determining unit 22 can form a list of candidate blocks for deriving motion information and select a candidate block from the list. For example, the motion information is also a predicted motion vector of the current block. That is, the determining unit 22 can determine a prediction candidate list for deriving motion information.
[0078] A "prediction candidate" refers to a candidate block. A "prediction candidate list" refers to a list of motion vectors of a candidate block. A "prediction candidate list" may also refer to a list of indexes indicating the motion vectors of a candidate block. A "base motion vector" refers to a motion vector for which a candidate block indicates a reference block. A "predictor motion vector" refers to a vector derived from a "base motion vector" and is selected to predict the motion vector of a current block from among motion vector candidates determined using motion prediction information related to the base motion vector. The determination unit 22 may determine the prediction candidate list according to prediction mode information.
[0079] If the prediction mode information of the current block indicates a preset prediction mode, the decoding unit 24 may determine a motion vector indicated by a prediction candidate index in the prediction candidate list and determine a predicted motion vector of the current block based on at least one of the motion prediction information related to the motion vector. The decoding unit 24 may perform motion compensation for the current block based on the motion vector of the current block obtained from the predicted motion vector. The decoding unit 24 may obtain information related to a difference between the predicted motion vector and the original motion vector and reconstruct the motion vector of the current block by adding the difference to the predicted motion vector. The preset prediction mode is a prediction mode different from skip mode and merge mode. The preset prediction mode is a mode in which predicted motion vector candidates are generated using not only information used in skip mode or merge mode but also information used in encoding and decoding an image, and one of the predicted motion vector candidates is determined as a predicted motion vector.
[0080] For example, the decoding unit 24 may generate a predicted motion vector candidate using at least one of reference direction information, reference picture index, motion vector value, and motion vector differential value that divides the reference picture list according to the preset prediction mode, and may determine the motion vector of the reference block among the predicted motion vector candidates as the predicted motion vector.
[0081] In another example, the decoding unit 24 may modify at least one of the reference direction information, reference picture index, motion vector value, and motion vector differential value that divide the reference picture list according to the preset prediction mode, use only the modified information, or use the modified information and information before the modification, to generate predicted motion vector candidates, and determine one of the predicted motion vector candidates as the predicted motion vector.
[0082] That is, the decoding unit 24 can generate motion vector predictor candidates according to the preset prediction mode and determine one of the motion vector predictor candidates as the motion vector predictor.
[0083] According to one disclosure, a prediction candidate list according to a preset prediction mode may include candidates at a certain distance from an existing motion vector as motion vector predictor candidates. The process of determining the motion vector predictor candidate in this case will be described with reference to Figures 5A to 5D. Here, the "base motion vector" is one of the motion vector predictor candidates used in the skip mode or merge mode of the current block.
[0084] The decoding unit 24 can determine a motion vector predictor candidate that is a first pixel distance from the base motion vector as a first candidate group, and determine a motion vector predictor candidate that is a second pixel distance from the base motion vector as a second candidate group. Here, the motion vector predictor candidate that is the first pixel distance may include a motion vector predictor candidate that is the first pixel distance and a pixel distance within a preset error range.
[0085] The predictor candidate list may include spatial candidates or temporal candidates. The spatial candidates may be neighboring blocks determined according to the division form of the prediction unit based on the assumption that the motion of the current block and neighboring blocks is similar. For example, a 2Nx2N prediction unit may use five blocks located around the current block as spatial candidates. A 2NxN, Nx2N, 2NxnU, 2NxnD, nLx2N, or nRx2N prediction unit may use five blocks located around the current block as spatial candidates. Furthermore, once spatial candidate configuration is complete, the determination unit 22 may determine temporal candidates. Furthermore, once spatial candidate or temporal candidate configuration is complete, additional candidates may be determined by combining the completed candidates.
[0086] If the prediction mode information of the current block indicates a preset prediction mode, the decoding unit 24 may determine a motion vector indicated by a prediction candidate index in the prediction candidate list. The decoding unit 24 may determine a motion vector predictor of the current block based on at least one of the motion prediction information related to the motion vector. The decoding unit 24 may acquire motion vector predictor candidates by combining the motion prediction information related to the motion vector, and may determine a motion vector indicated by a prediction candidate index from among the motion vector predictor candidates.
[0087] The motion prediction information related to the motion vector may include at least one of a reference direction obtained from a neighboring block of the current block, an index of a reference picture, a motion vector value, and motion vector differential value information, but is not limited thereto.
[0088] The decoding unit 24 can combine and shift the reference direction, the reference picture index, the motion vector value, and the motion vector differential value information to obtain new predicted motion vector candidates, and determine the predicted motion vector of the current block from the new predicted motion vector candidates.
[0089] The decoding unit 24 can determine a candidate index indicating the group to which the motion vector predictor belongs, from the first candidate group and the second candidate group.
[0090] The indexes indicating motion vector predictor candidates included in the predictor candidate list may include indexes indicating motion vector predictor candidates according to skip mode or merge mode, and indexes indicating motion vector predictor candidates according to a preset prediction mode. The indexes indicating motion vector predictor candidates according to the preset prediction mode may be modified based on existing indexes. The existing indexes are indexes indicating motion vector predictor candidates according to skip mode or merge mode. The related details will be described with reference to Figures 6A to 6C.
[0091] In addition, the prediction mode information of the preset prediction mode may be obtained next to the skip flag and the merge mode flag, or may be obtained from the AMVP mode syntax element.
[0092] The skip flag is located at the beginning of a coding unit call and indicates whether the current block is in skip mode. If the current block is in skip mode, no syntax related to motion prediction is sent except for the skip index. The skip index indicates the position of a selected candidate from a list of neighboring block candidates. Information retrieved from the neighboring block as candidate information includes a reference direction, a reference picture index, a motion vector predictor, etc.
[0093] The merge flag is located at the beginning of a prediction unit call and indicates whether the prediction unit block of the current block is in merge mode. If it is in merge mode, the video encoding device 10 sends a merge index, but does not send syntax related to the motion vector difference, prediction direction, or reference picture index. The merge index indicates a candidate selected from a list of neighboring block candidates. Information obtained as candidate information from the candidate block includes the reference direction, reference picture index, and motion vector prediction value.
[0094] In the AMVP mode, the video encoding device 10 transmits an MVD, which is a difference between a motion vector and a predicted motion vector, to the video decoding device 20. If the AMVP mode is determined, the video decoding device 20 can receive syntax related to the AMVP flag, motion vector difference, prediction direction, and reference picture index. The AMVP flag determines one of two candidates configured as neighboring block candidates.
[0095] The decoder 24 can decode video using video symbols parsed from the bitstream. If the video decoding device 20 receives a stream coded based on tree-structured coding units, the decoder 24 can perform decoding based on the tree-structured coding units for each maximum coding unit of the stream. Details related to the maximum coding unit will be described with reference to FIG. 8.
[0096] The decoding unit 24 can obtain coding information and coded data by performing entropy decoding for each maximum coding unit. The decoding unit 24 can restore the residual component by performing inverse quantization and inverse transform on the coded data obtained from the stream. The decoding unit 24 can also directly receive a bitstream of quantized transform coefficients. The residual component of the image can also be restored by performing inverse quantization and inverse transform on the quantized transform coefficients.
[0097] The decoder 24 may generate a prediction block based on motion information of a prediction block that is most similar to the current block. Here, the motion information may include a motion vector and a reference picture index of the prediction block. The decoder 24 may reconstruct an image by adding a residual component, which is the difference between the prediction block and the original block, to the prediction block.
[0098] The video decoding device 20 may include a central processor (not shown) that controls the decision unit 22 and the decoding unit 24. The central processor (not shown) may be implemented as an array of multiple logic gates, or may be implemented as a combination of a general-purpose microprocessor and a memory storing a program executed by the microprocessor. Those skilled in the art will understand that the central processor (not shown) may also be implemented as other types of hardware. Alternatively, the decision unit 22 and the decoding unit 24 may be operated by their own processors (not shown), and the video decoding device 20 may be operated as a whole by the processors (not shown) operating in an integrated manner. Alternatively, the decision unit 22 and the decoding unit 24 may be controlled by a processor (not shown) external to the video decoding device 20.
[0099] The video decoding device 20 may include one or more memories (not shown) that store input and output data of the decision unit 22 and the decoding unit 24. The video decoding device 20 may also include a memory control unit (not shown) that controls data input and output from the memory.
[0100] Hereinafter, various operations and applications performed by the video decoding device 20 will be described, but even if the configuration of the decision unit 22 and the decoding unit 24 is not specified, the content that can be clearly understood and expected by a person skilled in the art of the present invention will be understood as a common implementation, and the scope of the present invention is not limited by the name or physical / logical structure of a specific configuration. Hereinafter, the operation of the video decoding device 20 will be described with reference to FIG.
[0101] 4 is a flowchart of a video decoding method according to an embodiment. In step S21 of FIG. 4, the video decoding device 20 may determine prediction mode information of a current block and an index indicating a prediction candidate from a bitstream. The prediction mode may include, but is not limited to, skip mode, merge mode, and AMVP mode.
[0102] In step S23, the video decoding device 20 may determine a predictor candidate list according to the prediction mode information.
[0103] In step S25, if the prediction mode information of the current block indicates a preset prediction mode, the video decoding device 20 determines a motion vector indicated by an index in the predictor candidate list, and can determine a predicted motion vector based on at least one of the motion prediction information related to the motion vector.
[0104] The motion prediction information related to the motion vector may include, but is not limited to, at least one of a reference direction, a reference picture index, a motion vector value, and motion vector differential value information obtained from neighboring blocks of the current block. The video decoding device 20 may determine a predicted motion vector of the current block by combining or transforming the reference direction, the reference picture index, the motion vector value, and the motion vector differential value information.
[0105] The preset prediction mode may be a prediction mode different from the skip mode and the merge mode. The predictor candidate list according to the preset prediction mode may include candidates at a certain distance from the base motion vector as the motion vector predictor candidate. The base motion vector may be one of the motion vector predictor candidate used in the skip mode or the merge mode of the current block.
[0106] Meanwhile, the video decoding device 20 can group motion vector predictor candidates derived from a base motion vector based on a certain distance. Specifically, the video decoding device 20 can determine motion vector predictor candidates that are a first pixel distance from the base motion vector as a first candidate group, and motion vector predictor candidates that are a second pixel distance from the base motion vector as a second candidate group.
[0107] The video decoding device 20 may determine the group to which the motion vector predictor belongs, either the first or second candidate group, as the candidate index obtained from the bitstream.
[0108] In step S27, the video decoding apparatus 20 may determine a motion vector for the current block based on the predicted motion vector. The video decoding apparatus 20 may perform motion compensation for the current block based on the motion vector for the current block.
[0109] The video decoding device 20 extracts information related to the difference between the predicted motion vector and the original motion vector, and then adds the difference to the predicted motion vector to reconstruct the motion vector of the current block.
[0110] The video decoding device 20 may perform a video decoding operation by operating in conjunction with an internal video decoding processor or an external video decoding processor to restore video through video decoding. The internal video decoding processor of the video decoding device 20 may not only be a separate processor, but may also include a case where the video decoding device 20, a central processing unit, or a graphics processing unit includes a video decoding processing module to implement basic video decoding operations.
[0111] 5A to 5D are diagrams illustrating a process of determining a motion vector predictor candidate according to an embodiment.
[0112] According to one disclosure, when the prediction mode of the current block is a preset prediction mode other than skip mode, merge mode, and AMVP mode, the video decoding device 20 may determine a motion vector predictor candidate using a base motion vector. Here, the base motion vector is one of the motion vector predictor candidates used in the skip mode or merge mode of the current block. The base motion vector is also one of the motion vector candidates used in a predetermined prediction mode other than skip mode or merge mode.
[0113] The base motion vector is determined from the motion vector of a coded block of the picture currently being coded, or from the motion vector of a coded block of a picture that the current picture can temporally refer to. For example, the base motion vector is one of the candidate motion vector predictors used in the skip mode or merge mode of the current block.
[0114] The basic motion vectors are also determined through operations between the basic motion vectors.
[0115] Furthermore, in the first prediction mode, if the prediction candidate includes motion vector information, the video decoding device 20 can determine the motion vector information as the base motion vector.
[0116] 5A to 5D, the video decoding device 20 may determine a spirally distributed motion vector in the motion vector predictor candidate configuration. The spiral distribution may have an N-gonal shape such as a diamond or a square, or a shape similar to a circle.
[0117] The video decoding device 20 can determine candidates at a certain distance in the base motion vector as motion vector predictor candidates. The video decoding device 20 can determine motion vector predictor candidates at a first pixel distance in the base motion vector as a first candidate group, motion vector predictor candidates at a second pixel distance as a second candidate group, and motion vector predictor candidates at an n-th pixel distance as an n-th candidate group. Here, the video decoding device 20 can determine the closest motion vector predictor candidate in the base motion vector as the first candidate group, and the next closest motion vector predictor candidate as the second candidate group, and the candidate group numbers increase in order as the pixel distance increases.
[0118] Assuming that the pixel distance is 1 / 4 pixel unit, as the candidate group number increases, the pixel distance interval is determined to be a logarithmic interval or a nonlinear interval, etc. The pixel distance interval is also determined by user definition.
[0119] The number of motion vector predictor candidates in each candidate group is determined to be 1, 2, 3, . . . up to M.
[0120] 5A and 5B illustrate a case where the number of motion vector predictor candidates in each candidate group is four (M=4). Here, an example is given in which the candidate groups are three groups, but the present invention is not limited to this.
[0121] 5A, the video decoding device 20 may determine candidate motion vector predictors having a diamond-shaped distribution based on a base motion vector. Although the interval between each pixel is a quarter pixel, the component values of the candidate vectors will be scaled by four times for convenience.
[0122] The video decoding device 20 can determine the predicted motion vector candidates ((base_x+1,base_y)502, (base_x-1,base_y)503, (base_x,base_y+1)504, (base_x,base_y-1)505) that are located at a distance of 1 / 4 pixel from the base motion vector (base_x,base_y)501 as the first candidate group.
[0123] The video decoding device 20 can determine the predicted motion vector candidates ((base_x+2,base_y)506, (base_x-2,base_y)507, (base_x,base_y+2)508, (base_x,base_y-2)509) that are located at a distance of 1 / 2 pixel from the base motion vector (base_x,base_y)501 as the second candidate group.
[0124] The video decoding device 20 can determine the predicted motion vector candidates ((base_x+4,base_y)510, (base_x-4,base_y)511, (base_x,base_y+4)512, (base_x,base_y-4)513) that are one pixel away from the base motion vector (base_x,base_y)501 as the third candidate group.
[0125] 5B, the video decoding device 20 may determine motion vector predictor candidates having a rectangular distribution based on the base motion vector. Although the interval between each pixel is a quarter pixel, the component values of the vector candidates will be scaled by four times for convenience.
[0126] Similarly, the video decoding device 20 can determine the predicted motion vector candidates ((base_x+1,base_y+1)521, (base_x+1,base_y-1)522, (base_x-1,base_y+1)523, (base_x-1,base_y-1)524) that are approximately 1 / 4 pixel away from the base motion vector (base_x,base_y)501 as the first candidate group.
[0127] The video decoding device 20 can determine the predicted motion vector candidates ((base_x+2,base_y+2)525, (base_x+2,base_y-2)526, (base_x-2,base_y+2)527, (base_x-2,base_y-2)528) that are approximately 1 / 2 pixel away from the base motion vector (base_x,base_y)501 as the second candidate group.
[0128] The video decoding device 20 can determine the predicted motion vector candidates ((base_x+4,base_y+4)529, (base_x+4,base_y-4)530, (base_x-4,base_y+4)531, (base_x-4,base_y-4)532) that are approximately one pixel away from the base motion vector (base_x,base_y)501 as the third candidate group.
[0129] 5C, the video decoding device 20 may determine a different number of motion vector predictor candidates for each group. Although the pixel spacing is 1 / 4 pixel, the component values of the vector candidates are scaled by 4 times for convenience.
[0130] Specifically, the video decoding device 20 can determine eight predicted motion vector candidates ((base_x+1, base_y) 502, (base_x-1, base_y) 503, (base_x, base_y+1) 504, (base_x, base_y-1) 505, (base_x+1, base_y+1) 521, (base_x+1, base_y-1) 522, (base_x-1, base_y+1) 523, (base_x-1, base_y-1) 524) located approximately 1 / 4 pixel away from the base motion vector as the first candidate group.
[0131] In addition, the video decoding device 20 can determine eight predicted motion vector candidates ((base_x+2,base_y)506, (base_x-2,base_y)507, (base_x,base_y+2)508, (base_x,base_y-2)509, (base_x+2,base_y+2)525, (base_x+2,base_y-2)526, (base_x-2,base_y+2)527, (base_x-2,base_y-2)528) located approximately 1 / 2 pixel away from the base motion vector as a second candidate group.
[0132] The video decoding device 20 can determine four predicted motion vector candidates ((base_x+4,base_y)510, (base_x-4,base_y)511, (base_x,base_y+4)512, (base_x,base_y-4)513) that are approximately one pixel away from the base motion vector as a third candidate group.
[0133] 5D, the video decoding apparatus 20 may determine motion vector predictor candidates by candidate group and may determine various distribution patterns for each candidate group. Specifically, the video decoding apparatus 20 may determine motion vector predictor candidates 502, 503, 504, and 505 having a diamond-shaped distribution based on the base motion vector 501 as a first candidate group. The video decoding apparatus 20 may also determine motion vector predictor candidates 525, 526, 527, and 528 having a rectangular distribution based on the base motion vector 501 as a second candidate group. The video decoding apparatus 20 may also determine motion vector predictor candidates 510, 511, 512, and 513 having a diamond-shaped distribution based on the base motion vector 501 as a third candidate group. As shown in FIG. 5D, the distribution of the motion vector predictor candidates in each candidate group may be determined in various distribution patterns in addition to the distribution pattern shown in FIG. 5D.
[0134] The video decoder 20 can determine one or more basic motion vectors. If there are two basic motion vectors, prediction motion vector candidates can also be generated using each basic motion vector.
[0135] The video decoder 20 is capable of bidirectional motion prediction. If the basic motion vector is performed by bidirectional prediction using reference pictures in List 0 and List 1, the motion vectors in each reference direction are changed to the magnitude of the opposite sign.
[0136] For example, if the POC of the currently decoded picture exists between the POCs of two predicted reference pictures (POC of the reference picture in List 0 < POC of the currently decoded picture < POC of the reference picture in List 1), if the video decoder 20 determines the prediction motion vector candidate indicating the reference picture in List 0 as (x + 1, y) for the basic motion vector in the currently decoded picture, the prediction motion vector candidate indicating the reference picture in List 1 can be determined as (x - 1, y) for the basic motion vector. Here, the List 0 motion vector and the List 1 motion vector are also vectors in which the x - component value or the y - component value of the basic motion vector is moved by the amount of change in the opposite sign. For example, from the basic motion vector (x, y), the x - component changes by +1 and -1, the L0 motion vector is determined as (x + 1), and the L1 motion vector is determined as (x - 1, y).
[0137] If the POC of the currently decoded picture does not exist between the POCs of the reference pictures in List 0 and List 1, the prediction motion vector candidates indicating the reference pictures in List 0 and List 1 are the same or change to the magnitude of different signs.
[0138] 6A to 6C are diagrams illustrating a bit representation method when preset prediction mode information is inserted into an existing predictor candidate list according to an embodiment, that is, diagrams illustrating an example of indicating use of a preset prediction mode using one of five indexes in a skip mode or a merge mode.
[0139] If the skip mode or merge mode uses five candidates and one additional index is used to indicate the preset prediction mode, the skip mode or merge mode can use a total of six candidates. When parsing the skip mode or merge mode index, if the video decoding device 20 obtains index information that is expected by using the preset prediction mode, it determines that the preset prediction mode is used, and can parse an index of a motion vector predictor candidate. In this case, the index of a skip mode or merge mode indicating the use of the preset prediction mode for each sequence, picture, or slice can be interpreted from parsed information at a higher level. An example of the higher level may include header information. The video encoding device 10 can determine, for each sequence, picture, or slice, which skip mode or merge mode index is to be indicated as the usage information of the preset prediction mode.
[0140] According to one disclosure, the video encoding device 10 may statistically accumulate hit ratio information between an index indicating the use of a preset prediction mode and an index of an existing candidate for skip mode or merge mode, and adaptively determine an order on a sequence-by-sequence, picture-by-picture, or slice-by-slice basis. The index indicating the use of a preset prediction mode may be explicitly signaled in the header of the next picture or slice. Therefore, the video decoding device 20 may interpret which index indicates the use of a preset prediction mode based on information acquired in the header of the picture or slice.
[0141] FIG. 6A illustrates five skip mode or merge mode motion vector predictor candidate indexing methods expressed as a truncated unary method.
[0142] 6B is a diagram illustrating positions where prediction mode information of a preset prediction mode can be inserted into an existing index list. The existing index list refers to a list before prediction mode information of a prediction mode is inserted into the index list. For example, the existing index list may be an index list indicating candidates for a skip mode or a merge mode. The prediction mode information of a preset prediction mode can be inserted into the index list in the form of one candidate. As shown in FIG. 6B, six positions 601, 602, 603, 604, 605, and 606 are possible positions in the existing index list where prediction mode information of a preset prediction mode can be inserted.
[0143] 6C is a diagram illustrating a change in representation bits when prediction mode information of a preset prediction mode is inserted into IDX3 in an existing index list. As shown in FIG. 6C, if prediction mode information of a preset prediction mode is inserted after IDX2, index 610 of the prediction mode information is represented as 1110 by the truncated unary method, and the previous IDX3 and IDX4 are represented by bits increased by 1 bit each.
[0144] FIG. 7 is a diagram illustrating a bit representation method of a predicted motion vector according to an embodiment.
[0145] The video encoding device 10 may index and transmit motion vector predictor candidates generated according to a certain criterion, rather than signaling the absolute position of the motion vector predictor candidate. For example, signaling the absolute position of the motion vector predictor candidate may mean transmitting the difference between a base motion vector and the motion vector predictor candidate, and the certain criterion may be selecting the motion vector predictor candidate in a spiral distribution. As shown in FIG. 7, which motion vector predictor candidate is used may be represented by bits.
[0146] Referring to Figure 7, NIDX is information related to which base motion vector is used. Specifically, information on the first base motion vector is assigned to IDX0, and information on the second base motion vector is assigned to IDX1. The NIDX to which information on each base motion vector is assigned is determined based on the frequency with which the base motion vector is used as a base motion vector related to a predicted motion vector. Index information on each base motion vector may be represented by bits, as shown in 701 of Figure 7.
[0147] In addition, motion vector predictor candidates derived from the same base motion vector may be grouped into candidate groups according to a certain criterion. Here, the certain criterion also serves as a criterion for determining candidates at the same pixel distance from the base motion vector as motion vector predictor candidates. Index information for each group may be expressed in bits, as shown in 702 of FIG. 7.
[0148] When the index of the preset prediction mode is defined as IDX3, a motion vector predictor candidate derived from a base motion vector in IDX3 may be expressed as NIDX. Each NIDX may include a group of motion vector predictor candidates based on the base motion vector. The NIDX may be expressed using a fixed length coding (FLC) method or a truncated unary method.
[0149] 7 shows an example of representation using a truncated unary method. NIDX information is displayed using a truncated unary method to indicate which group a predicted motion vector is included in. Each candidate group associated with a base motion vector can also be represented using a fixed length coding (FLC) method or a truncated unary method.
[0150] When each candidate group related to a motion vector predictor is represented by a truncated unit, it can be adaptively represented by different bit representations in units of pictures or slices. For example, if the video encoding device 10 calculates the cumulative hit rate by group and finds that the candidates in the third candidate group are most frequently selected as motion vector predictors, it signals this information in the header of the next picture or slice, and represents the third candidate group with the shortest bit representation, "0."
[0151] In this case, the index of the most frequently selected candidate group can be signaled in the header of the next picture or slice. For example, assume that the order of the most frequently selected groups is as follows:
[0152] 3rd candidate group > 2nd candidate group > 4th candidate group > 1st candidate group > 5th candidate group > 0th candidate group > 6th candidate group > 7th candidate group For example, to transmit the top three pieces of information, three pieces of three-bit information (total of eight candidates) are required, and nine bits of representation information are required for every picture or slice. If the top three pieces of candidate group information that are expected to occur frequently are to be transmitted, the representation bits for the third candidate group, "011," the representation bits for the second candidate group, and the representation bits for the fourth candidate group, "010," and "100," are signaled, respectively.
[0153] Meanwhile, a bit representation is required to signal candidate group information and indicate which of the four candidates in a candidate group it is. Referring to 703 of Figure 7, candidates existing in a four-direction concept can be divided into two or more groups and a CABAC context model (context-based adaptive binary arithmetic coding context model) can be applied. A context model can also be applied to flags that divide horizontal component candidates and vertical component candidates into two groups of two each. Referring to 704 of Figure 7, after flag parsing, a context model can also be applied to flags that determine which of the two candidates to use.
[0154] In a video encoding device 10 and a video decoding device 20 according to an embodiment, blocks into which video data is divided are divided into maximum coding units, and each maximum coding unit is encoded / decoded based on a tree-structured coding unit. Hereinafter, with reference to Figures 8 to 20, video encoding methods and apparatuses therefor and video decoding methods and apparatuses therefor based on tree-structured coding units and transform units according to various embodiments will be disclosed.
[0155] FIG. 8 illustrates a block diagram of a video encoding device 800 based on a tree-structured coding unit according to one embodiment of the present invention.
[0156] A video encoding device 800 with video prediction based on a coding unit with a tree structure according to an embodiment includes a coding unit determination unit 820 and an output unit 830. Hereinafter, for convenience of description, the video encoding device 800 with video prediction based on a coding unit with a tree structure according to an embodiment will be abbreviated to "video encoding device 800."
[0157] The coding unit determination unit 820 may partition the current picture based on a maximum coding unit, which is a coding unit of the largest size for the current picture of the video. If the current picture is larger than the maximum coding unit, the video data of the current picture may be divided into at least one maximum coding unit. According to an embodiment, the maximum coding unit may be a data unit of size 32x32, 64x64, 128x128, 256x256, etc., or may be a square data unit whose vertical and horizontal dimensions are a power of two.
[0158] According to an embodiment, a coding unit is characterized by a maximum size and a depth. The depth indicates the number of times a coding unit is spatially divided from the maximum coding unit, and as the depth increases, the coding units for each depth may be divided from the maximum coding unit to the minimum coding unit. The depth of the maximum coding unit may be defined as the highest depth, and the minimum coding unit may be defined as the lowest coding unit. As the depth of the maximum coding unit increases, the size of the coding units for each depth decreases, so a coding unit of a higher depth may include multiple coding units of lower depths.
[0159] As described above, the image data of the current picture may be divided into maximum coding units according to the maximum size of the coding unit, and each maximum coding unit may include coding units divided by depth. Since the maximum coding units according to an embodiment are divided by depth, image data of the spatial domain included in the maximum coding units may also be hierarchically classified by depth.
[0160] There are preset maximum depth and maximum coding unit size limits that limit the total number of times the height and width of the largest coding unit can be hierarchically divided.
[0161] The coding unit determination unit 820 encodes at least one divided region obtained by dividing the region of the largest coding unit for each depth, and determines a depth at which a final coding result is output for each divided region. That is, the coding unit determination unit 820 encodes video data in coding units for each depth for each largest coding unit of the current picture, selects a depth at which a minimum coding error occurs, and determines it as a final depth. The determined final depth and video data for each largest coding unit are output to the output unit 830.
[0162] The video data in the maximum coding unit is coded based on coding units for each depth with at least one depth equal to or less than the maximum depth, and the coding results based on the coding units for each depth are compared. After comparing the coding errors of the coding units for each depth, the depth with the smallest coding error is selected. At least one final depth is determined for each maximum coding unit.
[0163] As the depth of a maximum coding unit increases, the coding unit is divided into layers, and the number of coding units increases. Even for coding units of the same depth included in one maximum coding unit, the coding error for each piece of data is measured to determine whether to divide it into sub-depths. Therefore, even for data included in one maximum coding unit, the coding error for each depth varies depending on the position, so the final depth is determined differently depending on the position. Therefore, one or more final depths are set for one maximum coding unit, and the data of the maximum coding unit is partitioned by coding units of one or more final depths.
[0164] Therefore, the coding unit determination unit 820, according to one embodiment, determines a tree-structured coding unit included in the current largest coding unit. The "tree-structured coding unit" according to one embodiment includes a coding unit of a depth determined as the final depth among all depth-specific coding units included in the current largest coding unit. The coding unit of the final depth is determined hierarchically according to depth within the same region within the largest coding unit, and is determined independently for other regions. Similarly, the final depth for the current region is determined independently of the final depths for other regions.
[0165] According to one embodiment, the maximum depth is an index related to the number of divisions from the largest coding unit to the smallest coding unit. According to one embodiment, the first maximum depth may indicate the total number of divisions from the largest coding unit to the smallest coding unit. According to one embodiment, the second maximum depth may indicate the total number of depth levels from the largest coding unit to the smallest coding unit. For example, if the depth of the largest coding unit is 0, the depth of a coding unit obtained by dividing the largest coding unit once is set to 1, and the depth of a coding unit obtained by dividing the largest coding unit twice is set to 2. In this case, if the coding unit obtained by dividing the largest coding unit four times is the smallest coding unit, depth levels of 0, 1, 2, 3, and 4 exist, so the first maximum depth is set to 4 and the second maximum depth is set to 5.
[0166] Predictive coding and transformation are also performed for the maximum coding unit. Predictive coding and transformation are also performed for each maximum coding unit and for each depth less than the maximum depth based on the depth-specific coding unit.
[0167] Since the number of coding units for each depth increases each time the maximum coding unit is divided by depth, coding including predictive coding and transform must be performed on all coding units for each depth generated as the depth increases. For convenience of explanation, predictive coding and transform will be described below based on a coding unit of a current depth among at least one maximum coding unit.
[0168] The video encoding device 800 according to an embodiment may select various sizes or shapes of data units for encoding video data. The video data may be encoded through steps such as predictive encoding, transform encoding, and entropy encoding, and the same data unit may be used throughout all steps, or the data unit may be changed for each step.
[0169] For example, the video encoding device 800 can select not only a coding unit for encoding video data, but also a data unit different from the coding unit to perform predictive encoding of the video data of the coding unit.
[0170] For predictive coding of the maximum coding unit, predictive coding is performed based on a coding unit of the final depth, i.e., a coding unit that is not further divided, according to an embodiment. Hereinafter, a coding unit that is the basis of predictive coding and is not further divided will be referred to as a "prediction unit." Partitions into which a prediction unit is divided may include the prediction unit and data units into which at least one of the height and width of the prediction unit is divided. A partition is a data unit into which a prediction unit of a coding unit is divided, and a prediction unit may also be a partition of the same size as the coding unit.
[0171] For example, if a coding unit of size 2Nx2N (where N is a positive integer) is not further divided, it becomes a prediction unit of size 2Nx2N, and the partition size may be 2Nx2N, 2NxN, Nx2N, NxN, etc. Partition modes according to one embodiment may selectively include not only symmetric partitions in which the height or width of the prediction unit is divided at a symmetric ratio, but also partitions divided at an asymmetric ratio such as 1:n or n:1, partitions divided in a geometric shape, partitions of an arbitrary shape, etc.
[0172] The prediction mode of a prediction unit is at least one of intra mode, inter mode, and skip mode. For example, intra mode and inter mode are performed on partitions of 2Nx2N, 2NxN, Nx2N, and NxN sizes. Also, skip mode is performed only on partitions of 2Nx2N size. Each prediction unit within a coding unit is coded independently, and a prediction mode with the smallest coding error is selected.
[0173] In addition, the video encoding device 800 according to an embodiment may convert video data of a coding unit based on not only a coding unit for encoding video data but also a data unit different from the coding unit. To convert a coding unit, conversion is performed based on a transform unit that is smaller than or equal to the coding unit. For example, the transform unit may include a data unit for an intra mode and a transform unit for an inter mode.
[0174] In one embodiment, in a manner similar to the tree-structured coding unit, the transform units within the coding unit are also recursively divided into smaller transform units, and the residual data of the coding unit is partitioned by the tree-structured transform units according to the transform depth.
[0175] According to an embodiment, the height and width of a coding unit are divided, and a transformation depth indicating the number of divisions required to reach the transformation unit is set for the transformation unit. For example, if the size of the transformation unit of a current coding unit having a size of 2Nx2N is 2Nx2N, the transformation depth is set to 0; if the size of the transformation unit is NxN, the transformation depth is set to 1; and if the size of the transformation unit is N / 2xN / 2, the transformation depth is set to 2. That is, for the transformation unit, a tree-structured transformation unit is set depending on the transformation depth.
[0176] The depth-based division information requires not only depth but also prediction-related information and transform-related information. Therefore, the coding unit determination unit 820 may determine not only the depth at which the minimum coding error occurs, but also a partition mode for dividing the prediction unit into partitions, a prediction mode for each prediction unit, a size of the transform unit for transform, etc.
[0177] A method for determining coding units and prediction units / partitions based on a tree structure of the largest coding unit and a transform unit according to an embodiment will be described in detail with reference to FIGS. 17 to 19. FIG.
[0178] The coding unit determination unit 820 may measure the coding error of the coding unit for each depth using a rate-distortion optimization technique based on a Lagrangian multiplier.
[0179] The output unit 830 outputs the maximum coding unit of image data coded based on at least one depth determined by the coding unit determination unit 820 and depth-based division information in the form of a bitstream.
[0180] The encoded video data is also the result of encoding video residual data.
[0181] The depth-based partition information may include depth information, partition mode information of a prediction unit, prediction mode information, partition information of a transform unit, and the like.
[0182] The final depth information is defined using depth-specific division information indicating whether to encode using a coding unit of a lower depth instead of encoding using the current depth. If the current depth of the current coding unit is depth, the current coding unit is encoded using the coding unit of the current depth, and therefore the division information of the current depth is defined so that it is not further divided into lower depths. Conversely, if the current depth of the current coding unit is not depth, encoding using a coding unit of a lower depth must be attempted, and therefore the division information of the current depth is defined so that it is divided into coding units of lower depths.
[0183] If the current depth is not a depth, coding is performed on the coding units divided into coding units of lower depths. Since there are one or more coding units of lower depths within the coding unit of the current depth, coding is performed repeatedly for each coding unit of lower depth, and recursive coding is performed for each coding unit of the same depth.
[0184] Since a tree-structured coding unit is determined within one maximum coding unit and at least one piece of partition information must be determined for each depth coding unit, at least one piece of partition information is determined for one maximum coding unit. Furthermore, since data of the maximum coding unit is hierarchically partitioned according to depth and the depth varies depending on the position, depth and partition information are set for the data.
[0185] Therefore, the output unit 830 according to an embodiment allocates coding information regarding the depth and coding mode to at least one of the coding unit, the prediction unit, and the smallest unit included in the largest coding unit.
[0186] According to one embodiment, the minimum unit is a square data unit having a size obtained by dividing the minimum coding unit, which is the lowest depth, into four. According to one embodiment, the minimum unit is also a square data unit of the largest size included in all coding units, prediction units, partition units, and transform units included in the maximum coding unit.
[0187] For example, the coding information output through the output unit 830 is classified into coding information for each coding unit per depth and coding information for each prediction unit. The coding information for each coding unit per depth may include prediction mode information and partition size information. The coding information transmitted for each prediction unit may include information related to an estimation direction in inter mode, information related to a reference picture index in inter mode, information related to a motion vector, information related to a chroma component in intra mode, information related to an interpolation method in intra mode, etc.
[0188] Information regarding the maximum size of a coding unit defined for each picture, slice, or GOP, and information regarding the maximum depth are inserted into a bitstream header, a sequence parameter set, or a picture parameter set.
[0189] In addition, information regarding the maximum size of the transform unit allowed for the current video and information regarding the minimum size of the transform unit are also output via a bitstream header, a sequence parameter set, a picture parameter set, etc. The output unit 830 may encode and output reference information, prediction information, slice type information, etc. related to prediction.
[0190] According to the simplest embodiment of the video encoding device 800, a coding unit for each depth is a coding unit having a size that is half the height and width of a coding unit for a next higher depth. That is, if the size of a coding unit for a current depth is 2Nx2N, the size of a coding unit for a lower depth is NxN. Also, a current coding unit of 2Nx2N size may include up to four coding units of a lower depth of NxN size.
[0191] Therefore, the video encoding device 800 may determine a coding unit of an optimal shape and size for each maximum coding unit based on the size and maximum depth of the maximum coding unit determined in consideration of the characteristics of the current picture, and may construct the coding units according to a tree structure. Also, since each maximum coding unit can be coded using various prediction modes, conversion methods, etc., an optimal coding mode is determined in consideration of the image characteristics of coding units of various image sizes.
[0192] Therefore, if an image with a very high resolution or a large amount of data is encoded using the existing macroblock unit, the number of macroblocks per picture becomes excessively large. As a result, the amount of compression information generated for each macroblock also increases, which increases the transmission burden of the compression information and tends to reduce data compression efficiency. Therefore, a video encoding device according to an embodiment can increase the maximum size of a coding unit in consideration of the size of an image and adjust the coding unit in consideration of image characteristics, thereby improving image compression efficiency.
[0193] FIG. 9 illustrates a block diagram of a video decoding device 900 based on tree-structured coding units, according to various embodiments.
[0194] A video decoding device 900 with video prediction based on a coding unit with a tree structure according to an embodiment includes a receiving unit 910, a video data and coding information extracting unit 920, and a video data decoding unit 930. Hereinafter, for convenience of explanation, the video decoding device 900 with video prediction based on a coding unit with a tree structure according to an embodiment will be referred to simply as "video decoding device 900."
[0195] The definitions of various terms such as coding unit, depth, prediction unit, transform unit, and various partition information for the decoding operation of the video decoding device 900 according to one embodiment are the same as those described with reference to FIG. 8 and the video encoding device 800.
[0196] The receiving unit 910 receives and parses a bitstream related to coded video. The video data and coding information extracting unit 920 extracts coded video data for each coding unit according to a tree structure for each maximum coding unit from the parsed bitstream and outputs the extracted video data to the video data decoding unit 930. The video data and coding information extracting unit 920 may extract information related to the maximum size of the coding unit of the current picture from a header, sequence parameter set, or picture parameter set related to the current picture.
[0197] The video data and coding information extraction unit 920 also extracts final depth and partition information related to the tree-structured coding units for each maximum coding unit from the parsed bitstream. The extracted final depth and partition information are output to the video data decoding unit 930. That is, the video data of the bitstream is divided into maximum coding units, and the video data decoding unit 930 decodes the video data for each maximum coding unit.
[0198] The maximum depth and partition information for each coding unit may be set for one or more pieces of depth information, and the partition information for each depth may include partition mode information, prediction mode information, and partition information for a transform unit of the corresponding coding unit. In addition, the partition information for each depth may be extracted as the depth information.
[0199] The depth and partition information for each maximum coding unit extracted by the video data and coding information extraction unit 920 is depth and partition information determined to generate a minimum coding error by repeatedly encoding each coding unit for each maximum coding unit depth at the encoding end, as in the video encoding device 800 according to an embodiment of the present invention. Therefore, the video decoding device 900 can restore the image by decoding the data using an encoding method that generates a minimum coding error.
[0200] According to an embodiment, coding information regarding the depth and the coding mode is assigned to a predetermined data unit among the coding unit, the prediction unit, and the minimum unit, so that the video data and coding information extraction unit 920 can extract depth and partition information for each predetermined data unit. If the depth and partition information of the maximum coding unit is recorded for each predetermined data unit, predetermined data units having the same depth and partition information are inferred as data units included in the same maximum coding unit.
[0201] The video data decoder 930 decodes video data of each largest coding unit based on the depth and partition information for each largest coding unit to restore a current picture. That is, the video data decoder 930 may decode coded video data for each coding unit in a tree-structured coding unit included in the largest coding unit based on the partition mode, prediction mode, and transform unit determined for each coding unit. The decoding process may include a prediction process including intra prediction and motion compensation, and an inverse transform process.
[0202] The video data decoder 930 may perform intra prediction or motion compensation for each coding unit according to the partition and prediction mode information of the prediction unit of the depth-based coding unit.
[0203] In addition, the video data decoder 930 may read transform unit information according to a tree structure for each coding unit to perform inverse transform for each coding unit, and perform inverse transform based on the transform unit for each coding unit. Through the inverse transform, pixel values in the spatial domain of the coding unit are restored.
[0204] The video data decoder 930 may determine the depth of the current largest coding unit using the depth-specific partition information. If the partition information indicates that no further partitioning will occur at the current depth, the current depth is determined. Therefore, the video data decoder 930 may decode the coding unit of the current depth for the video data of the current largest coding unit using the partition mode, prediction mode, and transform unit size information of the prediction unit.
[0205] That is, the coding information set for a predetermined data unit from among the coding unit, prediction unit, and minimum unit is observed, and data units having coding information including the same partition information are collected and regarded as one data unit to be decoded in the same coding mode by the video data decoder 930. For each coding unit determined in this way, information related to the coding mode is obtained, and the current coding unit is decoded.
[0206] As a result, the video decoding device 900 recursively encodes each maximum coding unit in the encoding process, acquires information about the coding unit that generates the smallest coding error, and uses the information to decode the current picture. That is, it is possible to decode video data encoded by the coding unit determined as the optimal coding unit according to the tree structure for each maximum coding unit.
[0207] Therefore, even for high-resolution images or images with excessively large data volume, the image data can be efficiently decoded and restored using the optimal division information transmitted from the encoding end and the coding unit size and coding mode adaptively determined according to the characteristics of the image.
[0208] FIG. 10 illustrates the concept of a coding unit according to various embodiments.
[0209] Examples of coding units, where the size of a coding unit is expressed as width x height, may include coding units of size 64x64, to 32x32, 16x16, and 8x8. A 64x64 coding unit may be partitioned into partitions of sizes 64x64, 64x32, 32x64, and 32x32, a 32x32 coding unit may be partitioned into partitions of sizes 32x32, 32x16, 16x32, and 16x16, a 16x16 coding unit may be partitioned into partitions of sizes 16x16, 16x8, 8x16, and 8x8, and an 8x8 coding unit may be partitioned into partitions of sizes 8x8, 8x4, 4x8, and 4x4.
[0210] For video data 1010, the resolution is set to 1920x1080, the maximum coding unit size is set to 64, and the maximum depth is set to 2. For video data 1020, the resolution is set to 1920x1080, the maximum coding unit size is set to 64, and the maximum depth is set to 3. For video data 1030, the resolution is set to 352x288, the maximum coding unit size is set to 16, and the maximum depth is set to 1. The maximum depth shown in Figure 10 indicates the total number of divisions from the maximum coding unit to the minimum coding unit.
[0211] When the resolution is high or the amount of data is large, it is desirable to have a relatively large maximum encoding size, not only to improve encoding efficiency but also to accurately reflect video characteristics. Therefore, the maximum encoding size of the video data 1010 and 1020, which have higher resolution than the video data 1030, is selected to be 64.
[0212] Since the maximum depth of the video data 1010 is 2, the coding units 1015 of the video data 1010 may be divided twice from the maximum coding unit with a major axis size of 64 to a depth of two layers, and may include coding units with major axis sizes of 32 and 16. Meanwhile, since the maximum depth of the video data 1030 is 1, the coding units 1035 of the video data 1030 may be divided once from the maximum coding unit with a major axis size of 16 to a depth of one layer, and may include coding units with major axis sizes of 8.
[0213] Since the maximum depth of the video data 1020 is 3, the coding units 1025 of the video data 1020 may be divided three times from the maximum coding unit with a major axis size of 64, and may include coding units with major axis sizes of 32, 16, and 8, which are three levels deeper than the maximum coding unit with a major axis size of 64. The deeper the depth, the better the ability to express detailed information.
[0214] FIG. 11 illustrates a block diagram of a coding unit-based video encoder 1100 according to various embodiments.
[0215] The video encoder 1100 according to an embodiment performs the same operations as those performed by the picture encoder 1520 of the video encoder 800 to encode video data. That is, the intra predictor 1120 performs intra prediction for each prediction unit of intra-mode coding units of the current image 1105, and the inter predictor 1115 performs inter prediction for each prediction unit of inter-mode coding units using the current image 1105 and a reference image acquired from the reconstructed picture buffer 1110. The current image 1105 is divided into maximum coding units and then sequentially encoded. At this time, encoding is performed on coding units obtained by dividing the maximum coding unit into a tree structure.
[0216] Residue data is generated by subtracting prediction data for a coding unit of each mode output from the intra prediction unit 1120 or the inter prediction unit 1115 from data related to a coding unit to be encoded in the current image 1105. The residue data passes through the transform unit 1125 and the quantization unit 1130 and is output as transform coefficients quantized for each transform unit. The quantized transform coefficients are restored to spatial domain residue data through the inverse quantization unit 1145 and the inverse transform unit 1150. The restored spatial domain residue data is added to prediction data related to a coding unit of each mode output from the intra prediction unit 1120 or the inter prediction unit 1115 to restore spatial domain data related to the coding unit of the current image 1105. The restored spatial domain data passes through the deblocking unit 1155 and the SAO performing unit 1160 to create a restored image. The generated restored image is stored in the restored picture buffer 1110. The reconstructed image stored in the reconstructed picture buffer 1110 is used as a reference image for inter-prediction of other images. The transform coefficients quantized by the transform unit 1125 and the quantization unit 1130 are output as a bitstream 1140 via an entropy coding unit 1135.
[0217] In order for the video encoding unit 1100 according to one embodiment to be applied to the video encoding device 800, the components of the video encoding unit 1100, such as the inter prediction unit 1115, the intra prediction unit 1120, the transform unit 1125, the quantization unit 1130, the entropy encoding unit 1135, the inverse quantization unit 1145, the inverse transform unit 1150, the deblocking unit 1155 and the SAO performing unit 1160, can perform operations based on each coding unit among the tree-structured coding units for each maximum coding unit.
[0218] In particular, the intra prediction unit 1120 and the inter prediction unit 1115 determine the partition mode and prediction mode of each coding unit among the tree-structured coding units taking into account the maximum size and maximum depth of the current largest coding unit, and the transform unit 1125 can determine whether to divide the transform units according to a quadtree within each coding unit among the tree-structured coding units.
[0219] FIG. 12 illustrates a block diagram of a coding unit-based video decoder 1200 according to various embodiments.
[0220] The entropy decoding unit 1215 parses the coded video data to be decoded and coding information required for decoding from the bitstream 1205. The coded video data is quantized transform coefficients, and the inverse quantization unit 1220 and the inverse transform unit 1225 restore residue data from the quantized transform coefficients.
[0221] The intra prediction unit 1240 performs intra prediction for each prediction unit for intra-mode coding units, and the inter prediction unit 1235 performs inter prediction for each prediction unit for inter-mode coding units of the current picture using reference pictures acquired from the reconstructed picture buffer 1230.
[0222] Spatial domain data related to the coding unit of the current image 1105 is restored by adding residue data and prediction data related to the coding unit of each mode that has passed through the intra prediction unit 1240 or the inter prediction unit 1235, and the restored spatial domain data is output as a restored image 1260 via the deblocking unit 1245 and the SAO performing unit 1250. In addition, the restored image stored in the restored picture buffer 1230 is output as a reference image.
[0223] In order to decode image data, the picture decoder 930 of the video decoder 900 performs the steps following the entropy decoder 1215 of the video decoder 1200 according to an embodiment of the present invention.
[0224] Because the video decoding unit 1200 is applied to the video decoding device 900 according to one embodiment, the components of the video decoding unit 1200, such as the entropy decoding unit 1215, the inverse quantization unit 1220, the inverse transform unit 1225, the intra prediction unit 1240, the inter prediction unit 1235, the deblocking unit 1245, and the SAO performing unit 1250, can perform operations based on each coding unit among the coding units according to the tree structure for each maximum coding unit.
[0225] In particular, the intra prediction unit 1240 and the inter prediction unit 1235 determine the partition mode and prediction mode for each coding unit among the coding units based on the tree structure, and the inverse transform unit 1225 can determine whether to divide the transform unit based on the quadtree structure for each coding unit.
[0226] FIG. 13 illustrates coding units and partitions for each depth according to various embodiments.
[0227] The video encoding device 800 and the video decoding device 900 according to an embodiment use hierarchical coding units to take into account image characteristics. The maximum height, width, and depth of the coding unit are adaptively determined according to image characteristics and are variously set according to user requests. The size of the coding unit for each depth is determined according to a preset maximum size of the coding unit.
[0228] The coding unit hierarchical structure 1300 according to one embodiment illustrates a case where the maximum height and width of the coding units are 64 and the maximum depth is 3. In this case, the maximum depth indicates the total number of divisions from the maximum coding unit to the minimum coding unit. As the depth increases along the vertical axis of the coding unit hierarchical structure 1300 according to one embodiment, the height and width of the coding units for each depth are each divided. Furthermore, prediction units and partitions that are the basis for predictive coding of each coding unit for each depth are illustrated along the horizontal axis of the coding unit hierarchical structure 1300.
[0229] That is, coding unit 1310 is the largest coding unit in coding unit hierarchical structure 1300, has a depth of 0, and has a coding unit size, i.e., height and width, of 64x64. Depth increases along the vertical axis, with depth 1 coding unit 1320 having a size of 32x32, depth 2 coding unit 1330 having a size of 16x16, and depth 3 coding unit 1340 having a size of 8x8. Depth 3 coding unit 1340 having a size of 8x8 is the smallest coding unit.
[0230] The prediction units and partitions of the coding units are arranged along the horizontal axis for each depth. That is, if a 64x64 coding unit 1310 at depth 0 is a prediction unit, the prediction unit is divided into a 64x64 partition 1310, a 64x32 partition 1312, a 32x64 partition 1314, and a 32x32 partition 1316 included in the 64x64 coding unit 1310.
[0231] Similarly, the prediction unit of a coding unit 1320 of size 32x32 at depth 1 is divided into a partition 1320 of size 32x32, a partition 1322 of size 32x16, a partition 1324 of size 16x32, and a partition 1326 of size 16x16, all of which are included in the coding unit 1320 of size 32x32.
[0232] Similarly, the prediction unit of a coding unit 1330 of size 16x16 at depth 2 is divided into a partition 1330 of size 16x16, a partition 1332 of size 16x8, a partition 1334 of size 8x16, and a partition 1336 of size 8x8 contained in the coding unit 1330 of size 16x16.
[0233] Similarly, the prediction unit of a coding unit 1340 of size 8x8 at depth 3 is divided into a partition 1340 of size 8x8, a partition 1342 of size 8x4, a partition 1344 of size 4x8, and a partition 1346 of size 4x4 contained in the coding unit 1340 of size 8x8.
[0234] In order to determine the depth of the largest coding unit 1310, the coding unit determination unit 820 of the video encoding device 800 according to one embodiment must perform encoding for each coding unit of each depth included in the largest coding unit 1310.
[0235] The number of coding units for each depth to contain data of the same range and size increases as the depth increases. For example, data containing one coding unit for depth 1 requires four coding units for depth 2. Therefore, to compare the coding results of the same data by depth, it must be coded using one coding unit for depth 1 and four coding units for depth 2.
[0236] For each depth-based coding, coding is performed for each prediction unit of the depth-based coding unit along the horizontal axis of the coding unit hierarchical structure 1300, and a representative coding error, which is the minimum coding error at the corresponding depth, is selected. Furthermore, as the depth increases along the vertical axis of the coding unit hierarchical structure 1300, coding is performed for each depth, and the representative coding errors for each depth are compared to find the minimum coding error. In the largest coding unit 1310, the depth and partition at which the minimum coding error occurs are selected as the depth and partition mode of the largest coding unit 1310.
[0237] FIG. 14 illustrates the relationship between coding units and transform units, according to various embodiments.
[0238] The video encoding device 800 or the video decoding device 900 according to an embodiment encodes or decodes video using coding units that are smaller than or equal to the maximum coding unit for each maximum coding unit. The size of the transform unit for transforming during the encoding process is selected based on a data unit that is not larger than each coding unit.
[0239] For example, in the video encoding device 800 according to an embodiment or the video decoding device 900 according to an embodiment, when the current coding unit 1410 has a size of 64x64, a transform unit 1420 having a size of 32x32 is used for transforming.
[0240] Furthermore, data of the 64x64 size coding unit 1410 is transformed and coded using transform units of sizes smaller than 64x64, 32x32, 16x16, 8x8, and 4x4, and then the transform unit with the smallest error from the original is selected.
[0241] FIG. 15 illustrates encoding information according to various embodiments.
[0242] The output unit 830 of the video encoding device 800 according to one embodiment may encode and transmit information 1500 related to the partition mode, information 1510 related to the prediction mode, and information 1520 related to the transform unit size as partition information for each coding unit of each depth.
[0243] The partition mode information 1500 indicates information regarding the type of partitions into which a prediction unit of the current coding unit is divided as a data unit for predictive coding of the current coding unit. For example, a current coding unit CU_0 having a size of 2Nx2N is used by being divided into one of a partition 1502 having a size of 2Nx2N, a partition 1504 having a size of 2NxN, a partition 1506 having a size of NxN, and a partition 1508 having a size of NxN. In this case, the partition mode information 1500 of the current coding unit is set to indicate one of the partition 1502 having a size of 2Nx2N, the partition 1504 having a size of 2NxN, the partition 1506 having a size of NxN, and the partition 1508 having a size of NxN.
[0244] The prediction mode information 1510 indicates a prediction mode of each partition. For example, the prediction mode information 1510 sets whether the partition indicated by the partition mode information 1500 is to be predictively encoded in one of intra mode 1512, inter mode 1514, and skip mode 1516.
[0245] The information about the transform unit size 1520 indicates the transform unit based on which the current coding unit is transformed. For example, the transform unit may be one of a first intra transform unit size 1522, a second intra transform unit size 1524, a first inter transform unit size 1526, and a second inter transform unit size 1528.
[0246] The video data and coding information extraction unit 1610 of the video decoding device 900 according to one embodiment can extract information 1500 related to the partition mode, information 1510 related to the prediction mode, and information 1520 related to the transformation unit size for each depth-based coding unit and use them for decoding.
[0247] FIG. 16 illustrates coding units for each depth according to various embodiments.
[0248] To indicate a change in depth, partition information is used, which indicates whether a coding unit of a current depth is divided into coding units of a lower depth.
[0249] A prediction unit 1610 for predictive coding of a depth 0 and 2N_0x2N_0 size coding unit 1600 may include a 2N_0x2N_0 size partition mode 1612, a 2N_0xN_0 size partition mode 1614, an N_0x2N_0 size partition mode 1616, and an N_0xN_0 size partition mode 1618. Although only partitions 1612, 1614, 1616, and 1618 in which the prediction unit is divided into symmetric ratios are illustrated, as mentioned above, the partition modes are not limited thereto and may include asymmetric partitions, arbitrary partitions, geometric partitions, etc.
[0250] For each partition mode, predictive coding must be iteratively performed on one 2N_0x2N_0 sized partition, two 2N_0xN_0 sized partitions, two N_0x2N_0 sized partitions, or four N_0xN_0 sized partitions. For partitions of size 2N_0x2N_0, size N_0x2N_0, size 2N_0xN_0, and size N_0xN_0, predictive coding is performed in intra and inter modes. For skip mode, predictive coding is performed only on partitions of size 2N_0x2N_0.
[0251] If the coding error due to one of the partition modes 1612, 1614, 1616 of sizes 2N_0x2N_0, 2N_0xN_0 and N_0x2N_0 is minimal, then there is no need to further partition to a lower depth.
[0252] If the encoding error with the partition mode 1618 of size N_0xN_0 is the smallest, then the depth 0 is changed to 1 and partitioned (1620), and encoding is iteratively performed on the coding unit 1630 of the partition mode of depth 2 and size N_0xN_0 to search for the smallest encoding error.
[0253] A prediction unit 1640 for predictive coding of a coding unit 1630 of depth 1 and size 2N_1x2N_1 (=N_0xN_0) may include a partition mode of size 2N_1x2N_1 1642, a partition mode of size 2N_1xN_1 1644, a partition mode of size N_1x2N_1 1646, and a partition mode of size N_1xN_1 1648.
[0254] Also, if the encoding error by the partition mode 1648 of size N_1xN_1 is the smallest, the depth 1 is changed to depth 2 and partitioned (1650), and encoding is performed iteratively on the coding unit 1660 of depth 2 and size N_2xN_2 to search for the smallest encoding error.
[0255] When the maximum depth is d, coding units by depth are set up to depth d-1, and partition information is set up to depth d-2. That is, when partitioning 1670 is performed from depth d-2 and coding is performed up to depth d-1, a prediction unit 1690 for predictive coding of a coding unit 1680 of depth d-1 and size 2N_(d-1)x2N_(d-1) may include a partition mode 1692 of size 2N_(d-1)x2N_(d-1), a partition mode 1694 of size 2N_(d-1)xN_(d-1), a partition mode 1696 of size N_(d-1)x2N_(d-1), and a partition mode 1698 of size N_(d-1)xN_(d-1).
[0256] In the partition mode, predictive coding is performed iteratively for one partition of size 2N_(d-1)x2N_(d-1), two partitions of size 2N_(d-1)xN_(d-1), two partitions of size N_(d-1)x2N_(d-1), and four partitions of size N_(d-1)xN_(d-1), and the partition mode that produces the minimum coding error is searched for.
[0257] Even if the coding error due to the partition mode 1698 of size N_(d-1)xN_(d-1) is minimum, since the maximum depth is d, the coding unit CU_(d-1) of depth d-1 does not undergo any further partitioning process to lower depths, and the depth related to the current maximum coding unit 1600 is determined to be depth d-1, and the partition mode is determined to be N_(d-1)xN_(d-1). Also, since the maximum depth is d, partition information is not set for the coding unit 1652 of depth d-1.
[0258] The data unit 1699 is a "smallest unit" related to the current largest coding unit. According to one embodiment, the smallest unit is a square data unit having a size obtained by dividing the smallest coding unit, which is the lowest depth, into four. Through this iterative coding process, the video encoding device 800 according to one embodiment compares coding errors for each depth of the coding unit 1600, selects the depth at which the smallest coding error occurs, and determines the depth. The corresponding partition mode and prediction mode are set as the coding mode for the depth.
[0259] In this way, the minimum coding error for each depth of all depths 0, 1, ..., d-1, d is compared, and the depth with the minimum error is selected and determined as the depth. The depth, partition mode, and prediction mode of the prediction unit are coded and transmitted as partition information. In addition, since the coding unit must be partitioned from depth 0 to depth , only the partition information of the depth is set to '0', and the partition information for each depth excluding the depth must be set to '1'.
[0260] The video data and coding information extraction unit 920 of the video decoding device 900 according to an embodiment may extract information related to a depth and a prediction unit related to the coding unit 1600 and use the extracted information for decoding the coding unit 1612. The video decoding device 900 according to an embodiment may recognize a depth having partition information of “0” as a depth using partition information by depth, and use partition information related to the corresponding depth for decoding.
[0261] 17, 18 and 19 illustrate the relationship between coding units, prediction units and transform units according to various embodiments.
[0262] The coding unit 1710 is a coding unit for each depth determined by the video encoding device 800 according to an embodiment of the present invention for the maximum coding unit. The prediction unit 1760 is a partition of the prediction unit of each coding unit for each depth in the coding unit 1710, and the transform unit 1770 is a transform unit of each coding unit for each depth.
[0263] Assuming that the depth of the maximum coding unit of depth-specific coding unit 1710 is 0, coding units 1712 and 1754 have a depth of 1, coding units 1714, 1716, 1718, 1728, 1750, and 1752 have a depth of 2, coding units 1720, 1722, 1724, 1726, 1730, 1732, and 1748 have a depth of 3, and coding units 1740, 1742, 1744, and 1746 have a depth of 4.
[0264] Some partitions 1714, 1716, 1722, 1732, 1748, 1750, 1752, and 1754 of the prediction unit 1760 are formed by dividing the coding unit. That is, partitions 1714, 1722, 1750, and 1754 are in a 2NxN partition mode, partitions 1716, 1748, and 1752 are in an Nx2N partition mode, and partition 1732 is in an NxN partition mode. The prediction units and partitions of the depth-specific coding unit 1710 are smaller than or the same as the respective coding units.
[0265] Video data of a transform unit 1752 among the transform units 1770 is transformed or inverse transformed in a data unit of a smaller size than the coding unit. Also, transform units 1714, 1716, 1722, 1732, 1748, 1750, 1752, and 1754 are data units of different sizes or shapes compared to the corresponding prediction units and partitions in the prediction unit 1760. That is, the video encoding device 800 according to an embodiment and the video decoding device 900 according to another embodiment may perform intra prediction / motion estimation / motion compensation operations and transform / inverse transform operations related to the same coding unit based on separate data units.
[0266] Thus, for each largest coding unit, coding units of a hierarchical structure for each region are recursively coded, and an optimal coding unit is determined, thereby constructing coding units with a recursive tree structure. The coding information may include partition information, partition mode information, prediction mode information, and transform unit size information related to the coding unit. Table 1 below shows an example of settings in the video encoding device 800 and the video decoding device 900 according to an embodiment.
[0267] [Table 1] The output unit 830 of the video encoding device 800 according to one embodiment outputs encoding information for a coding unit based on a tree structure, and the encoding information extraction unit 920 of the video decoding device 900 according to one embodiment can extract encoding information for a coding unit based on a tree structure from a received bitstream.
[0268] The partition information indicates whether the current coding unit is divided into coding units of lower depths. If the partition information of the current depth d is 0, the depth at which the current coding unit is not further divided into lower coding units is the depth, and therefore, partition mode information, prediction mode, and transform unit size information are defined for the depth. If further division is required according to the partition information, each of the four divided coding units of lower depths must be coded independently.
[0269] The prediction mode can be represented by one of intra mode, inter mode, and skip mode. The intra mode and inter mode are defined for all partition modes, while the skip mode is only defined for the 2Nx2N partition mode.
[0270] The partition mode information may indicate symmetric partition modes 2Nx2N, 2NxN, Nx2N, and NxN in which the height or width of the prediction unit is divided at a symmetric ratio, and asymmetric partition modes 2NxnU, 2NxnD, nLx2N, and nRx2N in which the height or width of the prediction unit is divided at an asymmetric ratio. The asymmetric partition modes 2NxnU and 2NxnD indicate that the height is divided at a ratio of 1:3 and 3:1, respectively, and the asymmetric partition modes nLx2N and nRx2N indicate that the width is divided at a ratio of 1:3 and 3:1, respectively.
[0271] The transform unit size is set to two sizes in intra mode and two sizes in inter mode. That is, if the transform unit split information is 0, the size of the transform unit is set to 2Nx2N, the size of the current coding unit. If the transform unit split information is 1, the transform unit is set to the size into which the current coding unit is divided. Also, if the partition mode related to the current coding unit of size 2Nx2N is a symmetric partition mode, the size of the transform unit is set to NxN, and if it is an asymmetric partition mode, the size is set to N / 2xN / 2.
[0272] According to an embodiment, coding information of a coding unit having a tree structure is assigned to at least one of a coding unit of depth, a prediction unit, and a minimum unit. A coding unit of depth may include one or more prediction units and minimum units having the same coding information.
[0273] Therefore, by checking the coding information held by each of adjacent data units, it can be determined whether they are included in a coding unit of the same depth. Also, by using the coding information held by each data unit, it is possible to determine the coding unit of the corresponding depth, so that the depth distribution within the maximum coding unit can be inferred.
[0274] Therefore, in this case, when the current coding unit makes a prediction by referring to a neighboring data unit, coding information of a data unit in a depth-dependent coding unit adjacent to the current coding unit is directly referenced and used.
[0275] In another embodiment, when predictive coding is performed on a current coding unit by referring to neighboring coding units, the neighboring coding units are referenced by searching for data adjacent to the current coding unit within the depth-specific coding unit using the coding information of the neighboring depth-specific coding unit.
[0276] FIG. 20 illustrates the relationship between coding units, prediction units, and transform units according to the coding mode information in Table 7.
[0277] The maximum coding unit 2000 includes depth coding units 2002, 2004, 2006, 2012, 2014, 2016, and 2018. Among them, one coding unit 2018 is a depth coding unit, and therefore the partition information is set to 0. The partition mode information of the coding unit 2018 of size 2Nx2N is set to one of partition modes 2Nx2N 2022, 2NxN 2024, Nx2N 2026, NxN 2028, 2NxnU 2032, 2NxnD 2034, nLx2N 2036, and nRx2N 2038.
[0278] The transform unit partition information (TU size flag) is a type of transform index, and the size of the transform unit corresponding to the transform index changes depending on the prediction unit type or partition mode of the coding unit.
[0279] For example, when the partition mode information is set to one of symmetric partition modes 2Nx2N 2022, 2NxN 2024, Nx2N 2026 and NxN 2028, if the transform unit division information is 0, a transform unit 2042 of size 2Nx2N is set, and if the transform unit division information is 1, a transform unit 2044 of size NxN is set.
[0280] When the partition mode information is set to one of the asymmetric partition modes 2NxnU 2032, 2NxnD 2034, nLx2N 2036 and nRx2N 2038, if the transform unit division information (TU size flag) is 0, a transform unit 2052 of size 2Nx2N is set, and if the transform unit division information is 1, a transform unit 2054 of size N / 2xN / 2 is set.
[0281] The transform unit division information (TU size flag) described with reference to Fig. 20 is a flag having a value of 0 or 1, but the transform unit division information according to one embodiment is not limited to a 1-bit flag, and may be increased to 0, 1, 2, 3, ..., etc. depending on the setting, thereby dividing the transform units hierarchically. The transform unit division information is used as one embodiment of a transform index.
[0282] In this case, the size of the transform unit actually used can be expressed by using the transform unit partition information according to an embodiment together with the maximum size and minimum size of the transform unit. The video encoding device 800 according to an embodiment can encode the maximum transform unit size information, the minimum transform unit size information, and the maximum transform unit partition information. The encoded maximum transform unit size information, the minimum transform unit size information, and the maximum transform unit partition information are inserted into the SPS. The video decoding device 900 according to an embodiment can use the maximum transform unit size information, the minimum transform unit size information, and the maximum transform unit partition information for video decoding.
[0283] For example, (a) if the current coding unit is 64x64 in size and the maximum transform unit size is 32x32, (a-1) when the transform unit split information is 0, the size of the transform unit is set to 32x32, (a-2) when the transform unit split information is 1, the size of the transform unit is set to 16x16, and (a-3) when the transform unit split information is 2, the size of the transform unit is set to 8x8.
[0284] As another example, (b) if the current coding unit is 32x32 in size and the minimum transform unit size is 32x32, (b-1) when the transform unit split information is 0, the size of the transform unit is set to 32x32, and since the size of the transform unit cannot be smaller than 32x32, no further transform unit split information is set.
[0285] As yet another example, (c) if the current coding unit is 64x64 in size and the maximum transform unit partition information is 1, the transform unit partition information is 0 or 1, and no other transform unit partition information is set.
[0286] Therefore, when the maximum transform unit division information is defined as "MaxTransformSizeIndex", the minimum transform unit size is defined as "MinTransformSize", and the transform unit size when the transform unit division information is 0 is defined as "RootTuSize", the minimum transform unit size possible for the current coding unit, "CurrMinTuSize", is defined as follows:
[0287] CurrMinTuSize = max (MinTransformSize, RootTuSize / (2^MaxTransformSizeIndex)) (1) When compared with the minimum transform unit size "CurrMinTuSize" possible in the current coding unit, "RootTuSize", which is the transform unit size when the transform unit partition information is 0, can indicate the maximum transform unit size that can be adopted in the system. That is, according to Equation (1), "RootTuSize / (2^MaxTransformSizeIndex)" is the transform unit size obtained by dividing "RootTuSize", which is the transform unit size when the transform unit partition information is 0, by the number of times corresponding to the maximum transform unit partition information, and "MinTransformSize" is the minimum transform unit size, so the smaller value of these is also the minimum transform unit size "CurrMinTuSize" possible in the current coding unit.
[0288] The maximum transform unit size "RootTuSize" according to one embodiment also varies depending on the prediction mode.
[0289] For example, if the current prediction mode is an inter mode, 'RootTuSize' is determined by the following equation (2): In equation (2), 'MaxTransformSize' indicates the maximum transform unit size, and 'PUSize' indicates the current prediction unit size.
[0290] RootTuSize = min(MaxTransformSize, PUSize) (2) That is, if the current prediction mode is inter mode, "RootTuSize", which is the transform unit size when the transform unit split information is 0, is set to the smaller value of the maximum transform unit size and the current prediction unit size.
[0291] If the prediction mode of the current partition unit is the intra mode, 'RootTuSize' is determined by the following equation (3): 'PartitionSize' indicates the size of the current partition unit.
[0292] RootTuSize = min(MaxTransformSize, PartitionSize) (3) That is, if the current prediction mode is the intra mode, "RootTuSize", which is the transform unit size when the transform unit split information is 0, is set to the smaller value of the maximum transform unit size and the current partition unit size.
[0293] However, it should be noted that the current maximum transform unit size "RootTuSize" according to one embodiment, which varies depending on the partition-based prediction mode, is only one embodiment, and the factors determining the current maximum transform unit size are not limited to this.
[0294] According to the video encoding technique based on the tree-structured coding unit described with reference to Figures 8 to 20, spatial domain video data is encoded for each tree-structured coding unit, and according to the video decoding technique based on the tree-structured coding unit, the spatial domain video data is restored while decoding is performed for each maximum coding unit, and a video, which is a picture and a picture sequence, is restored. The restored video is played back by a playback device, stored on a recording medium, or transmitted over a network.
[0295] Meanwhile, the above-described embodiments of the present invention can be written as a computer-executable program and implemented in a general-purpose digital computer that runs the program using a computer-readable recording medium, including magnetic recording media (e.g., ROM (read-only memory), floppy disk, hard disk, etc.) and optically readable media (e.g., CD-ROM (compact disc read-only memory), DVD (digital versatile disc), etc.).
[0296] For convenience of explanation, the video encoding method and / or video encoding methods previously described with reference to Figures 1 to 20 will be collectively referred to as "video encoding methods of the present invention." Also, the video decoding method and / or video decoding methods previously described with reference to Figures 1 to 20 will be collectively referred to as "video decoding methods of the present invention." 1 to 20, video encoding device 800, or a video encoding device configured with video encoding unit 1100 will be collectively referred to as "video encoding devices of the present invention." Also, the inter-layer video decoding device, video decoding device 900, or a video decoding device configured with video decoding unit 1200 will be collectively referred to as "video decoding devices of the present invention."
[0297] An embodiment in which the computer-readable recording medium storing the program according to the embodiment is a disk 26000 will be described in detail below.
[0298] 21 illustrates the physical structure of a disk 26000 storing programs according to various embodiments. The disk 26000 described as a recording medium may be a hard drive, a CD-ROM disk, a Blu-ray disc, or a DVD disc. The disk 26000 is composed of a number of concentric tracks Tr, and the tracks Tr are divided into a predetermined number of sectors Se along the circumferential direction. Programs for implementing the quantization parameter determination method, video encoding method, and video decoding method described above are allocated and stored in specific areas of the disk 26000 storing the programs according to the above-described embodiment.
[0299] A computer system implemented using a recording medium storing a program for implementing the above-described video encoding and decoding methods will now be described with reference to FIG.
[0300] 22 illustrates a disk drive 26800 for recording and reading a program using a disk 26000. The computer system 26700 can store a program for implementing at least one of the video encoding method and the video decoding method of the present invention on the disk 26000 using the disk drive 26800. In order to execute the program stored on the disk 26000 on the computer system 26700, the disk drive 26800 reads the program from the disk 26000 and transmits the program to the computer system 26700.
[0301] A program for implementing at least one of the video encoding method and the video decoding method of the present invention is stored not only on the disk 26000 illustrated in Figures 21 and 22 but also on a memory card, a ROM cassette, or an SSD (solid state drive).
[0302] A system to which the video encoding method and video decoding method according to the above embodiment are applied will now be described.
[0303] 23 shows the overall structure of a content supply system 11000 for providing a content distribution service. The service area of the communication system is divided into cells of a predetermined size, and radio base stations 11700, 11800, 11900, and 12000, which serve as base stations, are installed in each cell.
[0304] The content delivery system 11000 includes a number of independent devices, such as a computer 12100, a personal digital assistant (PDA) 12200, a video camera 12300, and a mobile phone 12500, which are connected to the Internet 11100 via an Internet service provider 11200, a communication network 11400, and wireless base stations 11700, 11800, 11900, and 12000.
[0305] However, the content supply system 11000 is not limited to the structure shown in Fig. 24, and devices may be selectively connected. The independent devices may be directly connected to the communication network 11400 without going through the wireless base stations 11700, 11800, 11900, and 12000.
[0306] The video camera 12300 is an imaging device capable of capturing video images, such as a digital video camera. The mobile phone 12500 may employ at least one communication method from among various protocols, such as a personal digital communications (PDC) method, a code division multiple access (CDMA) method, a wideband code division multiple access (W-CDMA) method, a global system for mobile communications (GSM) method, and a personal handyphone system (PHS) method.
[0307] The video camera 12300 is connected to the streaming server 11300 via a wireless base station 11900 and a communication network 11400. The streaming server 11300 can stream content transmitted by a user using the video camera 12300 in real time broadcast. The content received from the video camera 12300 is encoded by the video camera 12300 or the streaming server 11300. The video data captured by the video camera 12300 is transmitted to the streaming server 11300 via the computer 12100.
[0308] Video data captured by the camera 12600 is also transmitted to the streaming server 11300 via the computer 12100. The camera 12600 is an imaging device capable of capturing both still and video images, like a digital camera. The video data received from the camera 12600 is encoded by the camera 12600 or the computer 12100. Software for video encoding and video decoding is stored on a computer-readable recording medium such as a CD-ROM disk, floppy disk, hard disk drive, SSD, or memory card that can be accessed by the computer 12100.
[0309] Also, if video is taken by a camera mounted on the mobile phone 12500, the video data is received from the mobile phone 12500.
[0310] The video data is encoded by an LSI (large scale integrated circuit) system installed in the video camera 12300, mobile phone 12500 or camera 12600.
[0311] In a content supply system 11000 according to one embodiment, content recorded by a user using a video camera 12300, a camera 12600, a mobile phone 12500, or other imaging device, such as on-site recording of a concert, is encoded and transmitted to a streaming server 11300. The streaming server 11300 can stream the content data to other clients that have requested the content data.
[0312] The client is a device capable of decoding encoded content data, such as a computer 12100, a PDA 12200, a video camera 12300, or a mobile phone 12500. Thus, the content delivery system 11000 serves as a client to receive and play encoded content data. The content delivery system 11000 also enables the client to receive, decode, and play encoded content data in real time, enabling personal broadcasting.
[0313] The video encoding device and video decoding device of the present invention are applied to the encoding and decoding operations of the independent devices included in the content supply system 11000.
[0314] 24 and 25, one embodiment of the mobile phone 12500 in the content delivery system 11000 will be described in detail.
[0315] 24 illustrates the external structure of a mobile phone 12500 to which the video encoding and decoding methods of the present invention are applied according to various embodiments. The mobile phone 12500 is a smartphone whose functions are not limited and whose functions can be changed or expanded substantially through application programs.
[0316] The mobile phone 12500 includes a built-in antenna 12510 for exchanging RF signals with the wireless base station 12000, and a display screen 12520, such as an LCD (liquid crystal display) or OLED (organic light emitting diode) screen, for displaying images captured by a camera 12530 or images received and decoded by the antenna 12510. The smartphone 12510 includes an operation panel 12540 including control buttons and a touch panel. If the display screen 12520 is a touch screen, the operation panel 12540 further includes a touch-sensitive panel of the display screen 12520. The smartphone 12510 includes a speaker 12580 or other form of audio output unit for outputting voice and sound, and a microphone 12550 or other form of audio input unit for inputting voice and sound. The smartphone 12510 further includes a camera 12530, such as a CCD camera, for capturing video and still images. Smartphone 12510 may also include storage medium 12570 for storing encoded and decoded data, such as video and still images captured by camera 12530, received by electronic mail (E-mail), or otherwise acquired, and slot 12560 for inserting storage medium 12570 into mobile phone 12500. Storage medium 12570 may also be an SD card or other form of flash memory, such as an EEPROM (electrically erasable programmable read-only memory) housed in a plastic case.
[0317] 25 illustrates the internal structure of the mobile phone 12500. In order to coordinately control each part of the mobile phone 12500, which is composed of the display screen 12520 and the operation panel 12540, a power supply circuit 12700, an operation input control unit 12640, a video encoding unit 12720, a camera interface 12630, an LCD control unit 12620, a video decoding unit 12690, a multiplexer / demultiplexer (MUX / DEMUX) 12680, a recording / reading unit 12670, a modulation / demodulation unit 12660, and an audio processing unit 12650 are connected to a central control unit 12710 via a synchronization bus 12730.
[0318] When the user operates the power button and sets the "power on" state from the "power off" state, the power supply circuit 12700 sets the mobile phone 12500 to operating mode by supplying power from the battery pack to each part of the mobile phone 12500.
[0319] The central control unit 12710 includes a CPU (central processing unit), a ROM (read-only memory), and a RAM.
[0320] In the process in which the mobile phone 12500 transmits communication data to the outside, a digital signal is generated in the mobile phone 12500 under the control of the central control unit 12710. For example, a digital audio signal is generated in the audio processing unit 12650, a digital video signal is generated in the video encoding unit 12720, and message text data is generated via the operation panel 12540 and the operation input control unit 12640. When the digital signal is transmitted to the modulation / demodulation unit 12660 under the control of the central control unit 12710, the modulation / demodulation unit 12660 modulates the frequency band of the digital signal, and the communication circuit 12610 performs D / A conversion (digital-analog conversion) and frequency conversion on the band-modulated digital audio signal. The transmission signal output from the communication circuit 12610 is sent to the voice communication base station or radio base station 12000 via the antenna 12510.
[0321] For example, when the mobile phone 12500 is in a call mode, an acoustic signal acquired by the microphone 12550 is converted into a digital acoustic signal in the acoustic processing unit 12650 under the control of the central control unit 12710. The generated digital acoustic signal is converted into a transmission signal via the modulation / demodulation unit 12660 and the communication circuit 12610 and is sent out via the antenna 12510.
[0322] In the data communication mode, when a text message such as an e-mail is to be transmitted, the text data of the message is input using the operation panel 12540, and the text data is transmitted to the central control unit 12610 via the operation input control unit 12640. Under the control of the central control unit 12610, the text data is converted into a transmission signal via the modulation / demodulation unit 12660 and the communication circuit 12610, and is sent to the radio base station 12000 via the antenna 12510.
[0323] To transmit video data in data communication mode, video data captured by the camera 12530 is provided to the video encoding unit 12720 via the camera interface 12630. The video data captured by the camera 12530 is immediately displayed on the display screen 12520 via the camera interface 12630 and the LCD control unit 12620.
[0324] The structure of the video encoding unit 12720 corresponds to the structure of the video encoding device of the present invention described above. The video encoding unit 12720 can encode video data provided from the camera 12530 according to the video encoding method of the present invention described above, convert the encoded video data into compression-encoded video data, and output the encoded video data to the multiplexing / demultiplexing unit 12680. While the camera 12530 is recording, an audio signal acquired by the microphone 12550 of the mobile phone 12500 is also converted into digital audio data via the audio processing unit 12650, and the digital audio data is transmitted to the multiplexing / demultiplexing unit 12680.
[0325] The multiplexing / demultiplexing unit 12680 multiplexes the encoded video data provided from the video encoding unit 12720 together with the audio data provided from the audio processing unit 12650. The multiplexed data is converted into a transmission signal via the modulation / demodulation unit 12660 and the communication circuit 12610, and is sent out via the antenna 12510.
[0326] When the mobile phone 12500 receives communication data from the outside, the signal received via the antenna 12510 is converted into a digital signal through frequency recovery processing and analog-to-digital conversion (A / D) processing. The modulation / demodulation unit 12660 demodulates the frequency band of the digital signal. The band-demodulated digital signal is transmitted to the video decoding unit 12690, the audio processing unit 12650, or the LCD control unit 12620 depending on the type.
[0327] When the mobile phone 12500 is in call mode, it amplifies a signal received via the antenna 12510 and generates a digital audio signal through frequency conversion and A / D (analog-digital) conversion. The received digital audio signal is converted into an analog audio signal through the modulation / demodulation unit 12660 and audio processing unit 12650 under the control of the central control unit 12710, and the analog audio signal is output via the speaker 12580.
[0328] In the data communication mode, when data of a video file accessed from an Internet website is received, the signal received from the radio base station 12000 via the antenna 12510 is processed by the modulation / demodulation unit 12660, which outputs multiplexed data, and the multiplexed data is transmitted to the multiplexing / demultiplexing unit 12680.
[0329] To decode the multiplexed data received via antenna 12510, multiplexer / demultiplexer 12680 demultiplexes the multiplexed data and separates the encoded video data stream from the encoded audio data stream. A synchronization bus 12730 provides the encoded video data stream to video decoder 12690 and the encoded audio data stream to audio processor 12650.
[0330] The structure of the video decoder 12690 corresponds to the structure of the video decoding device of the present invention described above. The video decoder 12690 decodes encoded video data using the video decoding method of the present invention described above, generates restored video data, and provides the restored video data to the display screen 12520 via the LCD controller 12620.
[0331] As a result, video data of the video file accessed from the Internet website is displayed on the display screen 12520. At the same time, the audio processing unit 12650 can also convert audio data into an analog audio signal and provide the analog audio signal to the speaker 12580. As a result, the audio data included in the video file accessed from the Internet website can also be played on the speaker 12580.
[0332] The mobile phone 12500, or other type of communication terminal, may be a transmitting / receiving terminal that includes both the video encoding device and the video decoding device of the present invention, a transmitting terminal that includes only the above-mentioned video encoding device of the present invention, or a receiving terminal that includes only the video decoding device of the present invention.
[0333] The communication system of the present invention is not limited to the structure described with reference to Fig. 24. For example, Fig. 26 illustrates a digital broadcasting system to which communication systems according to various embodiments are applied. The digital broadcasting system according to the embodiment of Fig. 26 can receive digital broadcasts transmitted via a satellite network or a terrestrial network using the video encoding device and video decoding device of the present invention.
[0334] Specifically, a broadcast station 12890 transmits a video data stream via radio waves to a communications or broadcast satellite 12900. The broadcast satellite 12900 transmits a broadcast signal, which is received by a satellite receiver at a home via an antenna 12860. In each home, the encoded video stream is decoded and played by a television (TV) receiver 12810, a set-top box 12870, or other device.
[0335] The video decoding device of the present invention is implemented in the playback device 12830, so that the playback device 12830 can read and decode the encoded video stream recorded on the recording medium 12820, such as a disk or memory card, and the restored video signal is then played back on, for example, a monitor 12840.
[0336] The video decoding device of the present invention is also installed in a set-top box 12870 connected to an antenna 12860 for satellite / terrestrial broadcasting or a cable antenna 12850 for cable TV reception. The output data of the set-top box 12870 is also reproduced on a TV monitor 12880.
[0337] As another example, instead of the set-top box 12870, the TV receiver 12810 itself may also be equipped with the video decoding device of the present invention.
[0338] A vehicle 12920 equipped with an appropriate antenna 12910 can also receive signals transmitted from the satellite 12800 or the radio base station 11700. The decoded video is played on a display screen of a vehicle navigation system 12930 installed in the vehicle 12920.
[0339] A video signal is encoded by the video encoding device of the present invention and then recorded and stored on a recording medium. Specifically, the video signal is stored on a DVD disc 12960 by a DVD recorder, or on a hard disk by a hard disk recorder 12950. As another example, the video signal is stored on an SD card 12970. If the hard disk recorder 12950 is equipped with the video decoding device of the present invention according to an embodiment, the video signal recorded on the DVD disc 12960, the SD card 12970, or another type of recording medium is played back on a monitor 12880.
[0340] The automobile navigation system 12930 may not include the camera 12530, the camera interface 12630, and the video encoder 12720 of Figure 25. For example, the computer 12100 and the TV receiver 12810 may also not include the camera 12530, the camera interface 12630, and the video encoder 12720 of Figure 25.
[0341] FIG. 27 illustrates a network structure of a cloud computing system utilizing a video encoding device and a video decoding device according to various embodiments.
[0342] The cloud computing system of the present invention may include a cloud computing server 14100, a user DB (database) 14100, computing resources 14200, and a user terminal.
[0343] The cloud computing system provides on-demand outsourcing services for computing resources via information and communication networks such as the Internet in response to requests from user terminals. In a cloud computing environment, service providers use virtualization technology to integrate computing resources from data centers in different physical locations and provide services as needed by users. Service users do not need to install computing resources such as applications, storage, operating systems, and security on their own terminals, but can select and use services in a virtual space created through virtualization technology at the desired time and to the desired extent.
[0344] A user terminal of a specific service user connects to the cloud computing server 14100 via an information communication network including the Internet and a mobile communication network. The user terminal receives cloud computing services, particularly video playback services, from the cloud computing server 14100. The user terminal may be any electronic device that can connect to the Internet, such as a desktop PC (personal computer) 14300, a smart TV 14400, a smartphone 14500, a laptop computer 14600, a PMP (portable multimedia player) 14700, or a tablet PC 14800.
[0345] The cloud computing server 14100 can integrate multiple computing resources 14200 distributed across a cloud network and provide them to user terminals. The multiple computing resources 14200 may include various data services and data uploaded from user terminals. In this way, the cloud computing server 14100 integrates video databases distributed across many locations using virtualization technology and provides services requested by user terminals.
[0346] The user DB 14100 stores information about users who subscribe to the cloud computing service. Here, the user information may include login information and personal credit information such as address and name. The user information may also include an index of videos. Here, the index may include a list of videos that have completed playback, a list of videos currently being played, and the stop time of a video currently being played.
[0347] Information related to videos stored in the user DB 14100 is shared between user devices. Therefore, for example, when a playback request is received from the laptop computer 14600 and a certain video service is provided to the laptop computer 14600, the playback history of the certain video service is stored in the user DB 14100. When a playback request for the same video service is received from the smartphone 14500, the cloud computing server 14100 refers to the user DB 14100, searches for the certain video service, and plays it. When the smartphone 14500 receives a video data stream via the cloud computing server 14100, the operation of decoding the video data stream and playing the video is similar to the operation of the mobile phone 12500 described above with reference to FIG. 24.
[0348] The cloud computing server 14100 can also refer to the playback history of a predetermined video service stored in the user DB 14100. For example, the cloud computing server 14100 receives a playback request for a video stored in the user DB 14100 from a user terminal. If the video was previously being played, the cloud computing server 14100 selects whether to play the video from the beginning or from the point where it was previously stopped, and the streaming method varies depending on the selection made by the user terminal. For example, if the user terminal requests playback from the beginning, the cloud computing server 14100 streams the video to the user terminal from the first frame. On the other hand, if the terminal requests playback to continue from the point where it was previously stopped, the cloud computing server 14100 streams the video to the user terminal from the frame where it was stopped.
[0349] In this case, the user terminal may include the video decoding device of the present invention described with reference to Figures 1 to 20. As another example, the user terminal may include the video encoding device of the present invention described with reference to Figures 1 to 20. Furthermore, the user terminal may include both the video encoding device and the video decoding device of the present invention described with reference to Figures 1 to 20.
[0350] Various embodiments in which the video encoding method, video decoding method, video encoding apparatus, and video decoding apparatus described with reference to Figures 1 to 20 are utilized are described with reference to Figures 21 to 27. However, various embodiments in which the video encoding method and video decoding method described with reference to Figures 1 to 20 are stored on a recording medium or in which the video encoding apparatus and video decoding apparatus are implemented in a device are not limited to the embodiments of Figures 21 to 27.
[0351] The present invention can also be embodied as computer-readable code on a computer-readable recording medium. The computer-readable recording medium includes all types of recording devices in which data readable by a computer system is stored. Examples of computer-readable recording media include ROM, RAM, CD-ROM, magnetic tape, floppy disk, optical data storage device, etc. The computer-readable recording medium can also be distributed across computer systems connected to a network, and the computer-readable code can be stored and executed in a distributed manner.
[0352] The present invention has been described above with reference to preferred embodiments. Those skilled in the art will understand that the present invention can be embodied in modified forms without departing from the essential characteristics of the present invention. The scope of the present invention is defined by the claims, not the above description, and all differences within the scope of the claims should be construed as being within the scope of the present invention.
[0353] The means taught by the present application are listed below as examples. (Appendix 1) 1. A video decoding method performed by a video decoding apparatus, comprising: determining prediction mode information of a current block and an index indicating a prediction candidate from a bitstream; determining a prediction candidate list according to the prediction mode information; If the prediction mode information of the current block indicates a preset prediction mode, determining a motion vector indicated by the index in the prediction candidate list, and determining a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector; determining a motion vector for the current block based on the predicted motion vector; The video decoding method, wherein the preset prediction mode is a prediction mode different from a skip mode and a merge mode. (Appendix 2) The prediction candidate list according to the preset prediction mode is 2. The video decoding method of claim 1, including candidate motion vectors that are a fixed distance apart from the base motion vector. (Appendix 3) 3. The video decoding method of claim 2, wherein the base motion vector is one of candidate motion vector predictors used in a skip mode or a merge mode of the current block. (Appendix 4) The step of determining a candidate motion vector predictor for the current block includes: A video decoding method as described in Appendix 2, characterized in that a predicted motion vector candidate that is a first pixel distance from the base motion vector is determined to be a first candidate group, and a predicted motion vector candidate that is a second pixel distance from the base motion vector is determined to be a second candidate group. (Appendix 5) The motion prediction information relating to the motion vector is The motion vector information includes at least one of a reference direction obtained from a neighboring block of the current block, an index of a reference picture, a value of the motion vector, and motion vector difference value information, The step of determining a predicted motion vector of the current block includes: The video decoding method of claim 1, characterized in that the reference direction, the index of the reference picture, the value of the motion vector, and the motion vector differential value information are combined and transformed to determine a predicted motion vector for the current block. (Appendix 6) The index indicated by the motion vector predictor candidate included in the predictor candidate list is an index indicating a motion vector predictor candidate according to a skip mode or a merge mode, and an index indicating a motion vector predictor candidate according to the preset prediction mode; The video decoding method according to Supplementary Note 1, wherein the index indicating the motion vector predictor candidate according to the preset prediction mode is generated among existing indexes. (Appendix 7) The prediction mode information of the preset prediction mode is 2. The video decoding method of claim 1, wherein the skip flag is obtained between the skip flag and the merge mode flag, or obtained next to the skip flag and the merge mode flag. (Appendix 8) 1. A video encoding method performed by a video encoding apparatus, comprising: determining a predictor candidate list according to a preset prediction mode; If prediction mode information of the current block indicates the preset prediction mode, determining a motion vector indicated by an index in the predictor candidate list, and determining a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector; determining a motion vector of the current block based on the predicted motion vector; encoding prediction mode information indicating the preset prediction mode, The video encoding method, wherein the preset prediction mode is a prediction mode different from a skip mode and a merge mode. (Appendix 9) The predictor candidate list according to the preset prediction mode is 9. The video encoding method according to claim 8, wherein the motion vector predictor candidates include candidates within a certain distance from the base motion vector. (Appendix 10) The basic motion vectors are 10. The video encoding method of claim 9, wherein the motion vector predictor candidate is one of the motion vector predictor candidates used in a skip mode or a merge mode of the current block. (Appendix 11) The step of determining a candidate motion vector predictor for the current block includes: A video encoding method as described in Appendix 9, characterized in that, in the base motion vector, predicted motion vector candidates that are a first pixel distance away are determined to be a first candidate group, and predicted motion vector candidates that are a second pixel distance away from the base motion vector are determined to be a second candidate group. (Appendix 12) The index indicated by the motion vector predictor candidate included in the predictor candidate list is an index indicating a motion vector predictor candidate according to a skip mode or a merge mode, and an index indicating a motion vector predictor candidate according to the preset prediction mode; 9. The video encoding method according to claim 8, wherein the index indicating the predicted motion vector candidate according to the preset prediction mode is generated among existing indexes. (Appendix 13) The prediction mode information of the preset prediction mode is 9. The video encoding method of claim 8, wherein the skip flag is inserted between the skip flag and the merge mode flag, or inserted next to the skip flag and the merge mode flag. (Appendix 14) A determination unit that determines prediction mode information of a current block and an index indicating a prediction candidate from the bitstream, and determines a predictor candidate list according to the prediction mode information; a decoding unit that, if prediction mode information of the current block indicates a preset prediction mode, determines a motion vector indicated by the index in the predictor candidate list, determines a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector, and performs motion compensation of the current block based on the motion vector of the current block obtained from the predicted motion vector, The video decoding device, wherein the preset prediction mode is a prediction mode different from a skip mode and a merge mode. (Appendix 15) an encoding unit that determines a predictor candidate list according to preset prediction mode information, and if prediction mode information of a current block indicates the preset prediction mode, determines a motion vector indicated by an index in the predictor candidate list, determines a predicted motion vector of the current block based on at least one of motion prediction information related to the motion vector, and performs motion prediction of the current block based on the motion vector of the current block obtained from the predicted motion vector; a bitstream generating unit that generates a bitstream including prediction mode information indicating the preset prediction mode, The video encoding device, wherein the preset prediction mode is a prediction mode different from a skip mode and a merge mode. [Prior art documents] [Patent documents]
[0354] [Patent Document 1] Special Publication No. 2014-520484 [Patent Document 2] Korean Patent Publication No. 10-2014-0051026
Claims
1. 1. A video decoding method performed by a video decoding apparatus, comprising: obtaining skip mode information indicating whether to perform skip mode prediction on a current block from a bitstream; obtaining motion vector prediction mode information of the current block from the bitstream when prediction is not performed in skip mode for the current block according to the skip mode information; When the motion vector prediction mode of the current block indicates a first prediction mode, information indicating a direction of a sign of a motion vector difference, information indicating a pixel distance of the motion vector difference, and a first index indicating a first motion vector candidate from a first candidate list are obtained from the bitstream; determining the first candidate list including motion vectors of blocks neighboring the current block; determining the first motion vector candidate indicated by the first index from the first candidate list, determining the motion vector difference based on a direction of the sign of the motion vector difference and a pixel distance of the motion vector difference, and determining the motion vector of the current block based on the first motion vector candidate and the motion vector difference; When the motion vector prediction mode of the current block is not the first prediction mode, obtaining a second index indicating a second motion vector candidate from a second candidate list from the bitstream, determining the second candidate list including motion vectors of blocks neighboring the current block, determining the second motion vector candidate indicated by the second index from the second candidate list, and determining the motion vector of the current block based on the second motion vector candidate; determining a reconstruction block of the current block using the prediction block indicated by the motion vector; The signed direction of the motion vector difference is one of a positive horizontal direction, a negative horizontal direction, a positive vertical direction, and a negative vertical direction; The video decoding method, wherein the pixel distance of the motion vector difference is one of a sub-pixel value and an integer pixel value.
2. 1. A video encoding method performed by a video encoding apparatus, comprising: determining a motion vector of a current block; determining skip mode information indicating whether to perform skip mode prediction on the current block; determining motion vector prediction mode information of a current block indicating whether a motion vector of the current block is predicted in a first prediction mode when prediction is not performed on the current block in a skip mode; determining a first candidate list including motion vectors of blocks adjacent to the current block when the current block is predicted using a first prediction mode; determining a first motion vector candidate from the first candidate list; determining a motion vector difference between the first motion vector candidate and the motion vector of the current block; and generating information indicating a direction of a sign of the motion vector difference, information indicating a pixel distance of the motion vector difference, and a first index indicating the first motion vector candidate from the first candidate list; determining a second candidate list including motion vectors of blocks neighboring the current block when the motion vector of the current block is not predicted by the first prediction mode, determining a second motion vector candidate from the second candidate list, and generating a second index indicating the second motion vector candidate from the second candidate list; determining a residual block by subtracting the predicted block indicated by the motion vector from the current block; performing a transform on the residual block to generate transform coefficients of the residual block; The signed direction of the motion vector difference is one of a positive horizontal direction, a negative horizontal direction, a positive vertical direction, and a negative vertical direction; The video encoding method, wherein the pixel distance of the motion vector difference is one of a sub-pixel value and an integer pixel value.
3. a decision unit that acquires skip mode information indicating whether a prediction is to be performed in a skip mode for a current block from a bitstream, and acquires motion vector prediction mode information for the current block from the bitstream when the prediction is not to be performed in the skip mode for the current block according to the skip mode information; a decoding unit that determines a candidate list including motion vectors of blocks adjacent to the current block, determines motion vector candidates from the candidate list, determines a motion vector of the current block based on a motion vector difference, and determines a reconstruction block of the current block using a prediction block indicated by the motion vector, When the motion vector prediction mode of the current block indicates a first prediction mode, the determination unit acquires, from the bitstream, information indicating a direction of a sign of a motion vector difference, information indicating a pixel distance of the motion vector difference, and a first index indicating a first motion vector candidate from a first candidate list; the decoding unit determines the first candidate list including motion vectors of blocks adjacent to the current block; determines the first motion vector candidate indicated by the first index from the first candidate list; determines the motion vector difference based on a direction in which the sign of the motion vector difference exists and a pixel distance of the motion vector difference; and determines the motion vector of the current block based on the first motion vector candidate and the motion vector difference. When the motion vector prediction mode of the current block is not the first prediction mode, the determining unit obtains, from the bitstream, a second index indicating a second motion vector candidate from a second candidate list; the decoding unit determines the second candidate list including motion vectors of blocks adjacent to the current block, determines the second motion vector candidate indicated by the second index in the second candidate list, and determines the motion vector of the current block based on the second motion vector candidate; The signed direction of the motion vector difference is one of a positive horizontal direction, a negative horizontal direction, a positive vertical direction, and a negative vertical direction; The video decoding device, wherein the pixel distance of the motion vector difference is one of a sub-pixel value and an integer pixel value.
4. 1. A method for storing a bitstream generated by a video encoding method on a recording medium, comprising: determining skip mode information indicating whether to perform skip mode prediction on the current block; determining a motion vector for the current block when prediction is not performed in skip mode for the current block; determining motion vector prediction mode information of the current block, which indicates whether the motion vector of the current block is predicted according to a first prediction mode; determining a first candidate list including motion vectors of blocks adjacent to the current block when the current block is predicted using a first prediction mode; determining a first motion vector candidate from the first candidate list; determining a motion vector difference between the first motion vector candidate and the motion vector of the current block; and generating information indicating a direction of a sign of the motion vector difference, information indicating a pixel distance of the motion vector difference, and a first index indicating the first motion vector candidate from the first candidate list; determining a second candidate list including motion vectors of blocks neighboring the current block when the motion vector of the current block is not predicted by the first prediction mode, determining a second motion vector candidate from the second candidate list, and generating a second index indicating the second motion vector candidate from the second candidate list; determining a residual block by subtracting the predicted block indicated by the motion vector from the current block; performing a transform on the residual block to generate transform coefficients of the residual block; storing a bitstream including the skip mode information, the motion vector prediction mode information, and the transform coefficients of the residual block on a recording medium; the bitstream includes one of the first index and the second index; When the bitstream includes the first index, the bitstream includes information indicating a direction in which a sign of the motion vector difference exists and information indicating a pixel distance of the motion vector difference, The signed direction of the motion vector difference is one of a positive horizontal direction, a negative horizontal direction, a positive vertical direction, and a negative vertical direction; The method of claim 1, wherein the pixel distance of the motion vector difference is one of a sub-pixel value and an integer pixel value.
Citation Information
Patent Citations
Moving image encoding device, moving image encoding method, moving image encoding program, and moving image decoding device
JP2014107708A
Integrated merge mode and adaptive motion vector prediction mode candidate selection
JP2014520484A
Method and device for encoding motion information, and method and device for decoding same
JP2014523184A
Method and Apparatus for image encoding
KR1020140051026A
Method and apparatus of motion and disparity vector derivation for 3D video coding and hevc
WO2013053309A1