WO2012097751A1 - 非整像素位置运动矢量的坐标值取整方法和装置 - Google Patents

非整像素位置运动矢量的坐标值取整方法和装置 Download PDF

Info

Publication number
WO2012097751A1
WO2012097751A1 PCT/CN2012/070681 CN2012070681W WO2012097751A1 WO 2012097751 A1 WO2012097751 A1 WO 2012097751A1 CN 2012070681 W CN2012070681 W CN 2012070681W WO 2012097751 A1 WO2012097751 A1 WO 2012097751A1
Authority
WO
WIPO (PCT)
Prior art keywords
motion vector
coordinate
pixel position
integer
dimension
Prior art date
Application number
PCT/CN2012/070681
Other languages
English (en)
French (fr)
Inventor
杨名远
林四新
周建同
于浩平
Original Assignee
华为技术有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 华为技术有限公司 filed Critical 华为技术有限公司
Priority to EP12736638.3A priority Critical patent/EP2661082A4/en
Publication of WO2012097751A1 publication Critical patent/WO2012097751A1/zh
Priority to US13/946,705 priority patent/US9521408B2/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/513Processing of motion vectors
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/523Motion estimation or motion compensation with sub-pixel accuracy
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/503Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving temporal prediction
    • H04N19/51Motion estimation or motion compensation
    • H04N19/533Motion estimation using multistep search, e.g. 2D-log search or one-at-a-time search [OTS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N19/00Methods or arrangements for coding, decoding, compressing or decompressing digital video signals
    • H04N19/50Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding
    • H04N19/59Methods or arrangements for coding, decoding, compressing or decompressing digital video signals using predictive coding involving spatial sub-sampling or interpolation, e.g. alteration of picture size or resolution

Definitions

  • the present invention relates to the field of communication technologies, and in particular, to a coordinate value rounding method and apparatus for a non-integer pixel position motion vector in video codec.
  • Motion prediction and motion compensation are important technologies in video compression. Some bits in the video compression code stream are used to transmit motion vector information, especially in the case of low bit rate, for high-definition video, for transmitting motion vector information. The cost of bits typically exceeds fifty percent of the total number of bits in the stream. Therefore, it is necessary to improve the coding efficiency by selecting the optimal motion vector.
  • For video encoding of continuous motion pictures how many consecutive images are divided?
  • the frame data is compressed according to the correlation between the current frame and the adjacent previous frame (I frame or P frame); for the B frame, it is based on the adjacent frame. The correlation of the previous frame, the current frame, and the next frame of data is predicted to compress the frame. For the difference between the P frame and the B frame, when the motion vector is selected, the P frame only needs to obtain the motion vector set according to the previous frame, and the B frame can obtain the motion vector set according to the previous frame and the subsequent frame.
  • the motion vector is used to describe the motion offset relationship between this frame and the adjacent frame as a reference.
  • the prior art uses a non-integral pixel interpolation technique to improve inter-frame prediction accuracy.
  • FIG. 1 a half-precision pixel or a quarter-precision pixel positional relationship of pixels in adjacent frames as a reference block when inter-prediction is performed is described.
  • the uppercase A/B/C/D/E/F... represents the integer pixel precision position
  • the lowercase b/h/j/m/t/aa/hh/dd/ee... represents one-half The precision pixel position
  • the precision position pixel is a non-integer pixel position pixel obtained by integer pixel interpolation.
  • the interpolation process uses an interpolation filter.
  • the acquisition of one-half pixel b can use the interpolation filter (1 - 5, 20, 20, -5, 1) /64 to the integer pixel point D/E/F/G/
  • the H/I interpolation is obtained, and the quarter-precision pixel a can be obtained by interpolation filtering of the integer pixel point F and the half-pixel point b by the integer interpolation filter (1, 1 ) /2.
  • a motion estimation and compensation scheme in the prior art is: including, in each frame image, a plurality of code blocks to be coded, and for a code block to be coded, according to the code block of the code block to be coded (usually The motion vector of the left code block, the upper left code block, the upper code block, and the upper right code block of the code block to be coded obtains a spatial candidate motion vector, and a median motion vector calculated according to the spatial candidate motion vector; a code block at the same position in the previous frame of the code block to be coded, and motion vectors of the four neighboring and eight neighborhood code blocks, to obtain a time domain candidate motion vector; from the above spatial domain candidate motion vector, median motion vector and time domain
  • One or more optimal motion vectors are selected from the candidate motion vector sets composed of candidate motion vectors as motion compensated forward motion vectors and/or backward motion vectors of the current block.
  • the general selection process is: using a reference block in a forward or backward reference frame pointed by each motion information in a candidate motion vector set of a block to be coded as a template block, and the mirror position of the motion vector information is followed by Obtain a block corresponding to the template in the forward reference frame, calculate the difference between the two templates and the corresponding block of the template (you can use the mean square error or the absolute value of the pixel interpolation), and select the motion information with the smallest difference as the current block to be coded.
  • Optimal motion vector The motion vector is used for motion prediction compensation to achieve encoding and decoding.
  • the embodiment of the present invention provides a method and apparatus for rounding motion vector coordinates of non-integer pixel positions in a video encoding and decoding process, so as to solve the problem of high complexity in selecting an optimal motion vector in an existing motion vector candidate set, while maintaining Good coding performance.
  • the embodiment of the present application provides a method for rounding out coordinate values of a non-integer pixel position motion vector, including: performing a rounding operation on a coordinate value of a non-integer pixel position motion vector, where the rounding operation includes a motion vector for a non-integer pixel position For each dimension of the coordinate, when the dimension coordinate is a non-integer pixel position, if the coordinate of the dimension non-integral pixel position motion vector is away from the coordinate position A of the two integer pixels adjacent to the non-integer pixel position of the dimension, the B distance phase At the same time, the coordinate value of the dimension non-integer position motion vector is rounded to one of the coordinate positions A, B of the whole pixel, and the coordinate position of the whole pixel is determined by the symbol of the motion vector coordinate value of the dimension non-integral pixel position determine.
  • the embodiment of the present application further provides a coordinate value rounding device for a non-integer pixel position motion vector, which includes:
  • the rounding unit is configured to perform a rounding operation on the coordinate values of the non-integer pixel position motion vector, where the rounding operation includes each dimension of the coordinates of the non-integer pixel position motion vector, when the dimensional coordinate is a non-integral pixel position If the coordinate of the non-integer position motion vector of the dimension is the same as the coordinate position A and the B distance of two integer pixels adjacent to the non-integer pixel position of the dimension, the coordinate value of the motion vector of the non-integral pixel position of the dimension is rounded off. Up to one of the coordinate positions A, B of the integer pixel, the determination of the coordinate position of the integer pixel is determined by the sign of the coordinate value of the dimension non-integral pixel position motion vector.
  • the rounding operation is performed on the coordinate value of the motion vector of the non-integral pixel position, and the rounding operation includes each dimension of the coordinate of the motion vector of the non-integral pixel position, when the dimension When the coordinate is a non-integer pixel position, if the coordinate of the non-integer pixel position motion vector of the dimension is away from the coordinate position A and the B distance of the two integer pixels adjacent to the non-integer pixel position of the dimension, the dimension is not the integer pixel position.
  • the coordinate value of the vector is rounded up to one of the coordinate positions A, B of the whole pixel, and the determination of the coordinate position of the whole pixel is determined by the symbol of the symbol of the motion vector coordinate of the dimension of the non-integral pixel position, and the existing method is solved.
  • the motion vector candidate set selects the optimal motion vector process with high complexity, while maintaining good coding performance.
  • Figure 1 is a schematic diagram of the position of the motion vector accuracy
  • FIG. 2A is a flow chart of a second embodiment of the present invention.
  • 2B is a schematic diagram of motion vector selection of a coding block in a B frame according to an embodiment of the present application
  • 2C is a schematic diagram of a model for uniform linear motion of a B frame according to an embodiment of the present application.
  • FIG. 3 is a schematic diagram of an apparatus according to an embodiment of the present invention. detailed description
  • Embodiment 1 is a diagrammatic representation of Embodiment 1:
  • An embodiment of the present invention provides a method for rounding a coordinate value of a non-integer pixel position motion vector, including: performing a rounding operation on a coordinate value of a non-integer pixel position motion vector, where the rounding operation includes a motion vector for a non-integer pixel position For each dimension of the coordinate, when the dimension coordinate is a non-integer pixel position, if the coordinate of the dimension non-integral pixel position motion vector is away from the coordinate position A of the two integer pixels adjacent to the non-integer pixel position of the dimension, the B distance phase At the same time, the coordinate value of the dimension non-integer position motion vector is rounded to one of the coordinate positions A, B of the whole pixel, and the coordinate position of the whole pixel is determined by the symbol of the motion vector coordinate value of the dimension non-integral pixel position determine.
  • the technical solution proposed by the embodiment of the present invention performs a rounding operation by using a coordinate value of a motion vector of a non-integer pixel position, where the rounding operation includes each dimension of the coordinate of the motion vector of the non-integral pixel position, when the dimension coordinate
  • the position is a non-integer pixel position
  • the coordinate of the motion vector of the non-integer pixel position of the dimension is the same as the coordinate position A and the B distance of two integer pixels adjacent to the non-integer pixel position of the dimension, the dimension is not the integer pixel position motion vector.
  • the coordinate value is rounded up to one of the coordinate positions A, B of the whole pixel, and the determination of the coordinate position of the whole pixel is determined by the symbol of the symbol of the motion vector coordinate of the dimension non-integral pixel position, and the existing motion is solved.
  • the vector candidate set selects the optimal motion vector process with high complexity, while maintaining good coding performance.
  • determining the coordinate position of the integer pixel by the symbol of the dimension non-integer pixel position motion vector coordinate value comprises:
  • the motion vector coordinate value for the quarter-pixel position is rounded to The integer pixel precision position is such that the coordinate value of the dimension non-integral pixel position motion vector is rounded to the nearest full pixel coordinate position.
  • the method before performing the rounding operation on the coordinate values of the non-integer pixel position motion vector, the method further includes: acquiring a candidate motion vector set of the current encoded or decoded block, and adding one to the motion vector in the initial candidate motion vector set.
  • the inverse motion vector generates a new candidate motion vector set according to the inverse motion vector and the motion vector in the initial candidate motion vector set for performing a rounding operation.
  • the coordinate value rounding method of the non-integer pixel position motion vector is described by taking a half-position pixel position as an example, but does not constitute a limitation on the present invention. Rounding the target, rounding the half-pixel position and/or the quarter-pixel position to the entire pixel position; in another real-time mode, taking the integer pixel position and the half-pixel position as rounding The target then treats the one-half pixel position as an integer pixel position and the quarter-pixel position and/or the eighth-pixel position to the full pixel and one-half pixel positions. That is, at this time, the entire pixel position in the embodiment of the present invention includes a half pixel position.
  • Embodiment 2 it will be apparent to those skilled in the art that further methods of expansion are readily contemplated.
  • a first embodiment of a method for rounding a non-integer position motion vector coordinate of the present application is as follows:
  • Step 101 Acquire an initial candidate motion vector set of the current coding block or the decoding block.
  • the spatial domain candidate motion vector is obtained according to the peripheral coding block or the decoding block of the current coding block or the decoding block
  • the time domain candidate motion vector of the current coding block or the decoding block is obtained according to the reference frame, where the reference frame may be the current coding block or the decoding.
  • the previous frame of the current frame in which the block is located, or the next frame, or the previous frame and the subsequent frame form a spatial motion vector and a time domain candidate motion vector to form an initial motion vector set.
  • FIG. 2B a motion vector selection diagram of a coded block or a decoded block in a B frame having a bidirectional motion compensation characteristic is shown.
  • the coded block or decoded block mv in the current frame is the current coded block or decoded block
  • the peripheral coded block or decoded block of the current coded block or decoded block mv generally refers to the left coded block or decoded of the mv shown in FIG. 2B.
  • a block mv a , an upper coding block or a decoding block mv b , an upper right coding block or a decoding block mv e , an upper left coding block or a decoding block mv d according to the above coding block or decoding block mv a , mv b , mv e , mv d obtain the spatial domain candidate motion vector of the current coding block or the decoding block mv; assuming that the reference frame is the previous frame in the current frame as an example, the current coding block or the decoding block mv is the coding block at the corresponding position in the previous frame or
  • the decoding block is mv ⁇ 1 , and the corresponding four-domain and eight-neighbor coding block or decoding block of mv ⁇ 1 are respectively mv.
  • the coding block or decoding block mv e at the corresponding position in the subsequent frame according to the current coding block or the decoding block mv may also be used.
  • its four neighborhood and eight neighborhood coding blocks or decoding blocks mvo, to mv 7 obtain time domain candidate motion vectors.
  • Step 102 Add a reverse motion vector to the motion vector in the initial candidate motion vector set.
  • the inverse motion vector may be added to the motion vector in the initial candidate motion vector set according to the preset motion model.
  • the preset motion model includes a hook speed linear motion model or an accelerated motion model. Taking a uniform linear motion model as an example, see Fig. 2C, which is a schematic diagram of a uniform linear motion of a B-frame. It is assumed that the backward motion vector is a forward motion vector, the distance between the B frame and the forward reference frame is 7>, and the distance from the backward reference frame is 7, and the uniform velocity shown in FIG. 2C is For a linear motion model, each pair of forward motion vectors and backward motion vectors satisfies the following relationship:
  • V f l T f -V h IT h .
  • the above inversion operation may operate on each motion vector in the initial candidate motion vector set, or may not perform the operation on the inverse motion relationship in the initial candidate motion vector set, but perform the operation on the remaining motion vectors.
  • Step 103 Generate a new candidate motion vector set according to the motion vector in the inverse motion vector and the initial candidate motion vector set.
  • the forward motion vector and all the forward motion vectors in the motion vector in the original initial candidate motion vector set are combined into a forward candidate motion.
  • the vector set, and all backward motion vectors compose the backward candidate motion vector set.
  • all forward motion vectors and backward motion vectors may also be included in a new candidate motion vector set, and the new candidate motion vectors may be included.
  • the set contains several sets of motion vectors. Each set of motion vectors has corresponding forward motion vectors and backward motion vectors. Each set of corresponding forward motion vectors and backward motion vectors can be distinguished by identification information. .
  • Step 104 Perform a rounding operation on the motion vector in the new candidate motion vector set.
  • the rounding operation is performed according to the position of the motion vector.
  • the dimension coordinate is a non-integer pixel position
  • the coordinate of the dimension non-integral pixel position motion vector is from the coordinate position A of the two integer pixels adjacent to the non-integer pixel position of the dimension
  • B the coordinate value of the dimension non-integral pixel position motion vector is rounded to one of the coordinate positions A, B of the whole pixel, and the coordinate position of the whole pixel is determined by the dimension non-integer pixel position motion vector coordinate value.
  • the motion vector in the candidate motion vector set is quarter precision, it is rounded according to the proximity principle, for example, when the motion vector (xl, yl) points to the a position, due to the two integer pixel positions adjacent to a For F(x2, y2) and G(x3, y3), and a distance F is closer than distance G, so a is rounded to position F, and candidate motion vector (xl, yl) is rounded to (x2) , y2). Similarly, point c is rounded to the G position.
  • the motion vector in the candidate motion vector set is one-half precision, since the motion vector is pointed at a distance equal to the distance between two adjacent integer pixel positions, when the rounding is performed, the symbol according to the current motion vector is needed.
  • the distance in the ordinate direction is the distance F(x2, y2) and N(x4, y4).
  • the y coordinate is rounded to the N point coordinate y4, when yl is negative, the yl coordinate is rounded to the N point coordinate y4.
  • the above rounding process can also be reversed. If the sign of xl is positive, the abscissa of points F and G is also positive, and the absolute value of the abscissa of F is smaller than the absolute value of the abscissa of point G, then the xl dimension of b The coordinates are rounded to the coordinate of the G point x3.
  • the abscissa of the F and G points is also negative, and the absolute value of the F abscissa is greater than the absolute value of the abscissa of the G point, and the xl dimension coordinate of b Round to the coordinate of point G x3.
  • the abscissa and ordinate values are MV_X and MV_y, respectively, for taking MV_x as an example, as follows:
  • iTmp MV-X
  • iAbs abs( iTmp );
  • iTmp ((( iAbs + 2 ) » 2 ) « 2 );
  • iTmp ((MV_x » 2 ) « 2 );
  • the specific description of the above rounding process is to perform the rounding operation on the abscissa and the ordinate of the candidate motion vector respectively.
  • the abscissa uses the lowest two of the abscissa to determine whether the current abscissa is one-half pixel or four-quarter.
  • One pixel taking the absolute value of the coordinate value of the motion vector of the quarter-pixel position, adding two, shifting two bits to the right, and then shifting two digits to the left to obtain the absolute value of the dimension coordinate of the dimension, the dimension coordinate The symbol remains the same.
  • the dimension coordinate of the coordinate value of the one-half pixel position motion vector is shifted to the right by two bits, and then the left two-bit operation is performed to obtain the rounded coordinate value of the dimension.
  • the rounding operation is not performed, and the rounding operation can also be performed in the implementation for convenience.
  • Step 105 Select a motion vector for encoding or decoding from the rounded candidate motion vector set for encoding or decoding.
  • a corresponding reference block in a forward or backward reference frame pointed to by each motion information in a candidate motion vector set of a block to be coded or a decoded block is used as a template block, and the mirror position of the motion vector information is backward.
  • obtaining a template corresponding to the template in the forward reference frame calculating a difference between the two templates and the corresponding block of the template, and selecting the motion information with the smallest difference as the optimal motion vector of the current block to be encoded.
  • the motion vector is used for motion prediction or compensation to implement the encoding and decoding process.
  • Embodiment 3 In the second embodiment, the motion prediction and compensation process with quarter precision is taken as an example to describe the method of the present invention. When the motion prediction and compensation precision is one-half pixel, the rounding method is eight points. The rounding method at one pixel, or the rounding operation is defined as an operation of normalizing one quarter and one eighth point to one half and an integer pixel precision position and the operation of the second embodiment of the present invention The process is similar.
  • the rounding target of the rounding method of the present application can be extended according to the actual system requirements.
  • the whole pixel position is taken as the rounding target, and one-half and/or one-quarter is rounded to the whole pixel position. ;
  • the half pixel position is regarded as the whole pixel position, and one quarter and/or one eighth is rounded to the whole pixel and One-half pixel position.
  • Embodiment 4 Another implementation of rounding
  • step 104 in the first embodiment may also adopt the following rounding process for the pseudo code description of the horizontal coordinate:
  • MV_pos MV x &0x3
  • iTmp ((MV- x » 2 ) « 2 );
  • the specific description of the above rounding process is to perform the rounding operation according to the abscissa and the ordinate of the candidate motion vector, taking the abscissa as an example, when the lowest two of the abscissa is 1, and the abscissa is negative, the abscissa is reduced by one. When the lowest two of the abscissa is 3, and the abscissa is positive, the abscissa is incremented by one; after the above operation, the abscissa is shifted to the right by two digits, and then the left is shifted by two digits to obtain the rounded abscissa value.
  • the rounding process of the abscissa is to perform the rounding operation according to the abscissa and the ordinate of the candidate motion vector, taking the abscissa as an example, when the lowest two of the abscissa is 1, and the abscissa is negative, the abscis
  • the pseudo code schemes in the second embodiment and the fourth embodiment are only the other specific implementation manners of the rounding method.
  • any softness that can embody the essence of the present invention The hardware implementation solutions are all within the scope of the present invention.
  • the embodiment of the present invention provides a coordinate value rounding device for a non-integer pixel position motion vector, and the device includes:
  • the rounding unit 301 is configured to perform a rounding operation on coordinate values of the non-integer pixel position motion vector, where the rounding operation includes each dimension of the coordinates of the non-integer pixel position motion vector, when the dimensional coordinate is a non-integral pixel In position, if the coordinate of the non-integer position motion vector of the dimension is the same as the coordinate position A and the B distance of two integer pixels adjacent to the non-integer pixel position of the dimension, the coordinate value of the motion vector of the dimension non-integral pixel position is taken Up to one of the coordinate positions A, B of the whole pixel, the determination of the coordinate position of the integer pixel is determined by the sign of the motion vector coordinate value of the dimension non-integral pixel position
  • the technical solution proposed by the embodiment of the present invention performs a rounding operation by using a coordinate value of a motion vector of a non-integer pixel position, where the rounding operation includes each dimension of the coordinate of the motion vector of the non-integral pixel position, when the dimension coordinate
  • the position is a non-integer pixel position
  • the coordinate of the motion vector of the non-integer pixel position of the dimension is the same as the coordinate position A and the B distance of two integer pixels adjacent to the non-integer pixel position of the dimension, the dimension is not the integer pixel position motion vector.
  • the coordinate value is rounded to the coordinate position of the entire pixel A, B, the determination of the coordinate position of the whole pixel is determined by the symbol of the dimension of the non-integer pixel position motion vector coordinate value, and the process complexity of selecting the optimal motion vector in the existing motion vector candidate set is solved. High problem, while maintaining good coding performance.
  • the apparatus further includes:
  • An acquiring unit 302 a candidate motion vector set for acquiring a current encoded or decoded block; adding unit 303: configured to add a reverse motion vector to the motion vector in the initial candidate motion vector set;
  • the generating unit 304 is configured to generate a new candidate motion vector set according to the motion vector in the reverse motion vector and the initial candidate motion vector set, for performing a rounding operation.
  • the apparatus further includes:
  • the coding unit 305 is configured to select a motion vector for encoding or decoding from the rounded candidate motion vector set for encoding and decoding.
  • the apparatus of the embodiments of the present invention is used to perform the method steps of the embodiments of the present invention, and the content of the method part may be applied to the apparatus part. It will be apparent to those skilled in the art that the techniques in the embodiments of the present invention can be implemented by means of software plus a necessary general hardware platform.
  • the computer software product may be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., and includes a plurality of instructions for causing a computer device (which may be an individual) A computer, server, or network device, etc.) performs the methods described in various embodiments of the present invention or in certain portions of the embodiments.
  • a storage medium such as a ROM/RAM, a magnetic disk, an optical disk, etc.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Compression Or Coding Systems Of Tv Signals (AREA)

Description

非整像素位置运动矢量的坐标值取整方法和装置 本申请要求于 2011年 1月 21 日提交的申请号为 201110024401.7, 发明 名称为 "非整像素位置运动矢量的坐标值取整方法和装置"的中国专利申请和 2011年 1月 24日提交的申请号为 201110025766.1 , 发明名称为"非整像素位 置运动矢量的坐标值取整方法和装置"的中国专利申请的优先权,其全部内容 通过引用结合在本申请中。 技术领域
本发明涉及通信技术领域, 特别涉及视频编解码中的一种非整像素位置 运动矢量的坐标值取整方法和装置。
背景技术
运动预测和运动补偿是视频压縮中的重要技术, 视频压缩码流中的一部 分比特用于传输运动矢量信息, 特别在低码率情况下, 对于高清视频来说, 用于传输运动矢量信息所耗费的比特通常超过码流总比特数的百分之五十。 因此, 需要通过选择最优的运动矢量, 来提高编码效率。针对连续动态图像 的视频编码, 将连续若干幅图像分成?、 B、 I三种类型, 对于 P帧, 是 根据本帧与相邻的前一帧(I帧或 P帧)的相关性进行预测来压缩本帧数 据; 对于 B帧, 则是根据相邻的前一帧、 本帧以及后一帧数据的相关性 进行预测来压缩本帧。 针对 P帧和 B帧的不同, 其在选择运动矢量时, P帧仅需根据其前一帧获得运动矢量集合, 而 B帧可以根据其前一帧和 后一帧获得运动矢量集合。
运动矢量用来描述本帧和作为参考的相邻帧之间的运动偏移关系。 为了提高帧间预测的准确度, 现有技术釆用非整像素插值技术, 提高帧 间预测精度。 如图 1 所示, 描述了进行帧间预测时, 作为参考块的相邻 帧中像素的二分之一精度像素或者四分之一精度像素位置关系。 其中大 写的 A/B/C/D/E/F...表示整像素精度位置, 小写的 b/h/j/m/t/aa/hh/dd/ee... 表示二分之一精度像素位置, 小写的 a/c/d/e/g/i/k/n/p/q/r...表示四分之一 精度像素位置。 其中整像素位置为图像原有像素, 二分之一和四分之一 精度位置像素为通过整像素插值获得的非整像素位置像素。 插值过程使 用插值滤波器, 比如二分之一像素 b的获取可以使用插值滤波器( 1, - 5, 20, 20, -5 , 1 ) /64 对整像素点 D/E/F/G/H/I插值获得, 四分之一精度像素 a可以通过整插值滤波器( 1,1 ) /2 对整像素点 F和二分之一像素点 b插 值滤波获取。
以 B帧为例, 现有技术中一种运动估计和补偿方案为: 在每帧图像中包 含了若干待编码码块,对于一个待编码码块,根据该待编码码块周边码块(通 常指该待编码码块左侧码块、 左上方码块、 上方码块及右上方码块) 的运动 矢量得到空域候选运动矢量 , 以及根据这些空域候选运动矢量计算的中值运 动矢量; 获取该待编码码块前一帧中相同位置上的码块, 及其四邻域、 八邻 域码块的运动矢量, 得到时域候选运动矢量; 从上述空域候选运动矢量、 中 值运动矢量和时域候选运动矢量组成的候选运动矢量集合中选择一个或多个 最优的运动矢量, 作为当前块的运动补偿的前向运动矢量和 /或后向运动矢 量。 通过在编码端和解码端使用相同的最优运动矢量的选取过程, 可以不必 传输运动矢量信息,从而节省运动矢量信息的传输比特。一般的选取过程为: 利用一个待编码块的候选运动矢量集合中每个运动信息所指向的前向或者后 向参考帧中对应的参考块作为模板块, 以该运动矢量信息的镜像位置在后向 或者前向参考帧中获取和模板对应块, 计算两个模板和模板对应块之间的差 异情况(可以使用均方差或者像素插值绝对值和),选取差异最小的运动信息 作为当前待编码块的最优运动矢量。 使用该运动矢量进行运动预测补偿, 实 现编码和解码。
但是由于现有方案中的候选运动矢量集中存在非整像素精度运动矢量, 在使用这些运动矢量计算最优运动矢量时,需要进行大量的分像素插值操作, 复杂度高。 发明内容
本申请实施例提供了一种视频编解码过程中非整像素位置运动矢量坐标 取整的方法和装置, 以解决在现有运动矢量候选集中选取最优运动矢量过程 复杂度高问题, 同时保持较好的编码性能。 本申请实施例提出一种非整像素位置运动矢量的坐标值取整方法, 包括: 对非整像素位置运动矢量的坐标值进行取整操作, 所述取整操作包括对 于非整像素位置运动矢量的坐标的每一维度, 当该维度坐标为非整像素位置 时, 如果该维度非整像素位置运动矢量的坐标距离该维度非整像素位置邻近 的两个整像素的坐标位置 A, B距离相同时, 将该维度非整像素位置运动矢量 的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的 确定由该维度非整像素位置运动矢量坐标值的符号确定。
本申请实施例还提出一种非整像素位置运动矢量的坐标值取整装置, 包 括:
取整单元: 用于对非整像素位置运动矢量的坐标值进行取整操作, 所述 取整操作包括对于非整像素位置运动矢量的坐标的每一维度, 当该维度坐标 为非整像素位置时, 如果该维度非整像素位置运动矢量的坐标距离该维度非 整像素位置邻近的两个整像素的坐标位置 A, B距离相同时, 将该维度非整像 素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像 素的坐标位置的确定由该维度非整像素位置运动矢量坐标值的符号确定。
本发明实施例提出的技术方案, 通过釆用对非整像素位置运动矢量的坐 标值进行取整操作, 所述取整操作包括对于非整像素位置运动矢量的坐标的 每一维度, 当该维度坐标为非整像素位置时, 如果该维度非整像素位置运动 矢量的坐标距离该维度非整像素位置邻近的两个整像素的坐标位置 A, B距离 相同时, 将该维度非整像素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的确定由该维度非整像素位置运动矢 量坐标值的符号确定的技术手段, 解决了在现有运动矢量候选集中选取最优 运动矢量过程复杂度高得问题, 同时保持较好的编码性能。 附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案, 下面将对实 施例或现有技术描述中所需要使用的附图作简单地介绍, 显而易见地, 对于 本领域普通技术人员而言, 在不付出创造性劳动性的前提下, 还可以根据这 些附图获得其他的附图。 图 1为运动矢量精度位置示意图;
图 2A为本发明第二实施例流程图;
图 2B为本申请实施例 B帧中编码块的运动矢量选择示意图;
图 2C为本申请实施例 B帧匀速线性运动的模型示意图;
图 3为本发明实施例的装置示意图。 具体实施方式
本发明如下实施例提供了一种非整像素位置运动矢量坐标取整的方法及 装置。 本发明实施例的上述目的、 特征和优点能够更加明显易懂, 下面结合附图对 本发明实施例中技术方案作进一步详细的说明。
实施例一:
本发明实施例提供一种非整像素位置运动矢量的坐标值取整方法, 包括: 对非整像素位置运动矢量的坐标值进行取整操作, 所述取整操作包括对于非 整像素位置运动矢量的坐标的每一维度, 当该维度坐标为非整像素位置时, 如果该维度非整像素位置运动矢量的坐标距离该维度非整像素位置邻近的两 个整像素的坐标位置 A, B距离相同时, 将该维度非整像素位置运动矢量的坐 标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的确定 由该维度非整像素位置运动矢量坐标值的符号确定。
本发明实施例提出的技术方案, 通过采用对非整像素位置运动矢量的坐 标值进行取整操作, 所述取整操作包括对于非整像素位置运动矢量的坐标的 每一维度, 当该维度坐标为非整像素位置时, 如果该维度非整像素位置运动 矢量的坐标距离该维度非整像素位置邻近的两个整像素的坐标位置 A, B距离 相同时, 将该维度非整像素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的确定由该维度非整像素位置运动矢 量坐标值的符号确定的技术手段, 解决了在现有运动矢量候选集中选取最优 运动矢量过程复杂度高得问题, 同时保持较好的编码性能。
本发明实施例中, 若该维度非整像素位置运动矢量的坐标距离该维度非 整像素位置邻近的两个整像素的坐标位置 A, B距离相同, 则该维度非整像 素位置运动矢量的坐标位置为二分之一像素位置。 则将该维度非整像素位置 运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个包括: 将该维度 非整像素位置运动矢量的坐标值在该维度进行右移两位操作, 再左移两位操 作, 取整至整像素的坐标位置 A, B其中一个。 本发明实施例中, 所述整像素的坐标位置的确定由该维度非整像素位置 运动矢量坐标值的符号确定包括:
当该非整像素位置运动矢量的坐标值的符号为正时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为负时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置, 或者: 当该非整像素位置运动矢量的坐标值的夺号为负时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为正时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置。
某些实施方式中, 若该维度非整像素位置运动矢量的坐标位置不是二分 之一像素位置, 而是四分之一像素位置, 则对于四分之一像素位置运动矢量 坐标值取整至整像素精度位置为, 将该维度非整像素位置运动矢量的坐标值 取整至最近的整像素的坐标位置。
某些实施方式中, 对非整像素位置运动矢量的坐标值进行取整操作之前 还包括: 获取当前编码或者解码块的候选运动矢量集合, 为所述初始候选运 动矢量集合中的运动矢量添加一个反向运动矢量, 根据所述反向运动矢量和 所述初始候选运动矢量集合中的运动矢量生成新的候选运动矢量集合, 以用 于进行取整操作。
本发明所述各实施例中, 以二分之一位置像素位置为例对非整像素位置 运动矢量的坐标值取整方法进行说明, 但并不构成对本发明的限制, 若以整 像素位置为取整目标, 将二分之一像素位置和 /或四分之一像素位置取整至整 像素位置; 另外一种实时方式中, 以整像素位置和二分之一像素位置为取整 目标, 则将二分之一像素位置视为整像素位置, 将四分之一像素位置和 /或八 分之一像素位置取整至整像素和二分之一像素位置。 即此时, 本发明实施例 所说的整像素位置包括二分之一像素位置。 按此思路, 本领域技术人员显然 容易想到进一步的扩展方法。 实施例二:
参见图 2A, 为本申请非整像素位置运动矢量坐标取整方法的第一实施例 流程图:
步骤 101 : 获取当前编码块或解码块的初始候选运动矢量集合。
具体的 , 根据当前编码块或解码块的周边编码块或解码块得到空域候选 运动矢量, 根据参考帧得到当前编码块或解码块的时域候选运动矢量, 该参 考帧可以为当前编码块或解码块所在的当前帧的前一帧, 或后一帧, 或前一 帧和后一帧, 将空域候选运动矢量和时域候选运动矢量组成初始运动矢量集 合。
参见图 2B, 为具有双向运动补偿特性的 B帧中编码块或解码块的运动 矢量选择示意图。 假设当前帧中的编码块或解码块 mv为当前编码块或解码 块,则当前编码块或解码块 mv的周边编码块或解码块通常指图 2B中示出的 mv的左侧编码块或解码块 mva、 上方编码块或解码块 mvb、 右上方编码块或 解码块 mve、 左上方编码块或解码块 mvd, 根据上述编码块或解码块 mva、 mvb、 mve、 mvd获得当前编码块或解码块 mv的空域候选运动矢量; 假设以 参考帧为当前帧中的前一帧为例 , 则当前编码块或解码块 mv在前一帧中对 应位置处的编码块或解码块为 mv∞1, 相应的 mv∞1的四邻域及八邻域编码块 或解码块分别为 mv。至 mv7,根据上述 mv^和 mv。至 mv7获得 mv的时域候 选运动矢量, 同理, 也可以才艮据当前编码块或解码块 mv在后一帧中对应位 置处的编码块或解码块 mve。及其四邻域及八邻域编码块或解码块 mvo,至 mv7,获得时域候选运动矢量。
步骤 102: 为初始候选运动矢量集合中的运动矢量添加反向运动矢量。 具体的, 可以根据预设运动模型为初始候选运动矢量集合中的运动矢量 添加反向运动矢量。预设运动模型包括勾速直线运动模型、或加速运动模型。 以匀速直线运动模型为例, 参见图 2C, 为 B帧匀速线性运动的模型示 意图。 假设 是该后向运动矢量, 是前向运动矢量, B帧与前向参考帧之 间的距离为 7> , 与后向参考帧之间的距离为 7, 则对于图 2C中示出的匀速 直线运动模型来说, 每一对前向运动矢量和后向运动矢量当满足如下关系:
Vf l Tf = -Vh I Th 。 另外, 除了上述图 2C中示出的匀速直线运动模型外, 也可以采用加速运 动模型, 此时两个运动矢量 和 之间可以满足关系 = _ ( * +a ), 其中 a 为速度差。
以上取反操作可以对初始候选运动矢量集合中的每一个运动矢量进行操 作, 也可以对初始候选运动矢量集合中已经构成反向关系的不进行该操作, 而对剩余的运动矢量进行该操作。
步骤 103: 根据反向运动矢量和初始候选运动矢量集合中的运动矢量生 成新的候选运动矢量集合。
在为初始候选运动矢量集合中的运动矢量添加完反向运动矢量后, 将所 添加的反向运动矢量和原来初始候选运动矢量集合中的运动矢量中的所有前 向运动矢量组成前向候选运动矢量集合, 以及所有后向运动矢量组成后向候 选运动矢量集合。
除了上述分别建立前向候选运动矢量集合和后向候选运动矢量集合的方 式外, 也可以在一个新的候选运动矢量集合中包含所有前向运动矢量和后向 运动矢量, 该新的候选运动矢量集合中包含了若干组运动矢量, 每一组运动 矢量中有相对应的前向运动矢量和后向运动矢量, 每一組相对应的前向运动 矢量和后向运动矢量可以通过标识信息进行区别。
步骤 104: 为新的候选运动矢量集合中的运动矢量进行取整操作。
具体的, 对于候选运动矢量集合中的运动矢量, 根据其运动矢量位置的 进行取整操作。 对于候选运动矢量其中每一维度, 当该维度坐标为非整像素 位置时, 如果该维度非整像素位置运动矢量的坐标距离该维度非整像素位置 邻近的两个整像素的坐标位置 A, B距离相同时, 将该维度非整像素位置运动 矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位 置的确定由该维度非整像素位置运动矢量坐标值的符号确定; 以四分之一非整像素精度运动估计和运动补偿为例, 参见图 1所示像素点 位置关系, 如果候选运动矢量集合中的运动矢量指向 F或 G位置, 则为整像素 精度运动矢量, 如果候选运动矢量集合中的运动矢量指向 b位置, 则为二分之 一精度运动矢量,如果候选动矢量集合中的运动矢量指向 a或 c位置, 为四分之 一精度运动矢量。 对于候选动矢量集合中的运动矢量为整像素精度时, 不需 要对其进行取整操作。 对于候选动矢量集合中的运动矢量为四分之一精度时, 根据临近原则对其取整操作, 例如当运动矢量 (xl , yl)指向 a位置时, 由于和 a 临近的两个整像素位置为 F(x2, y2)和 G(x3, y3), 而 a距离 F距离比距离 G距离 更近, 因此将 a取整至 F点位置, 候选运动矢量 (xl, yl)取整至 (x2, y2)。 同理 c 点取整至 G位置。 对于候选运动矢量集合中的运动矢量为二分之一精度时, 由 于该运动矢量指向位置距离其相邻的两个整像素位置距离相等, 因此, 在取 整时, 需要根据当前运动矢量的符号取整至不同的整像素位置。 当运动矢量 (xl , yl)指向图 1中二分之一像素位置 b时, 整像素位置 F和 G距离 b相等。 如果 当对 b取整时, 如果 xl的符号为正, F和 G点的横坐标也为正, 并且, F横坐标 的绝对值小于 G点横坐标的绝对值, 则将 b的 xl维度坐标取整至 F点坐标 x2,如 果 xl符号为负, F和 G点的横坐标也为负, 并且, F横坐标的绝对值大于于 G点 横坐标的绝对值, 将 b的 xl维度坐标取整至 F点坐标 x2; 同理, 当运动矢量 (xl , yl)指向图 1中二分之一像素位置 h时, 其纵坐标方向距离 F(x2, y2)和 N(x4, y4) 距离相等, 对于 yl为正, 将 yl坐标取整至 N点坐标 y4, 当 yl为负, 将 yl坐标取 整至 N点坐标 y4。 以上取整过程也可以反过来, 如果 xl的符号为正, F和 G点 的横坐标也为正, 并且, F横坐标的绝对值小于 G点横坐标的绝对值, 则将 b 的 xl维度坐标取整至 G点坐标 x3 , 如果 xl符号为负, F和 G点的横坐标也为负, 并且, F横坐标的绝对值大于于 G点横坐标的绝对值,将 b的 xl维度坐标取整至 G点坐标 x3。
以上过程可以表示为如下伪代码描述, 对于运动矢量集合中的一个运动 矢量 MV, 其横坐标和纵坐标值分别为 MV— X和 MV_y, 以对 MV— x取整为例, 如下:
iTmp = MV— X;
MV_pos = abs(MV x) & 0x3; If(MV_pos = =3 II MV_pos = =1)
{
iSign = iTmp >= 0 ? 1: -1 ;
iAbs = abs( iTmp );
iTmp = ((( iAbs + 2 ) » 2 ) « 2 );
MV x = iSign * iTmp;
}
Else if(MV_pos = =2)
{
iTmp = ((MV_x » 2 ) « 2 );
MV = iTmp;
}
以上取整过程的具体描述为, 对候选运动矢量横坐标和纵坐标分别进行 取整操作, 以横坐标为例, 利用横坐标最低两位判断当前横坐标是二分之一 像素还是四分之一像素, 对四分之一像素位置运动矢量的坐标值取绝对值, 再加二后, 右移两位, 再左移两位后得到取整后的该维度坐标的绝对值, 该 维度坐标符号保持不变。 对二分之一像素位置运动矢量的坐标值的该维度坐 标进行右移两位操作, 再左移两位操作, 得到取整后的该维度坐标值。 对于 整像素点不进行取整操作, 也可以在实现中为了实现方便, 进行取整操作。
步骤 105: 从取整后的候选运动矢量集合中选择用于编码或解码的运动矢 量进行编码或解码。
具体的利用一个待编码块或解码块的候选运动矢量集合中每个运动信息 所指向的前向或者后向参考帧中对应的参考块作为模板块, 以该运动矢量信 息的镜像位置在后向或者前向参考帧中获取和模板对应块, 计算两个模板和 模板对应块之间的差异情况, 选取差异最小的运动信息作为当前待编码块的 最优运动矢量。。使用该运动矢量进行运动预测或补偿,实现编码和解码过程。
另外, 编码终端也可以利用选择的运动矢量完成其它编码过程, 该过程 与现有技术一致, 在此不再赘述。 实施例三: 实施例二中以四分之一精度的运动预测和补偿过程为例描述 了本发明方案, 当运动预测和补偿精度为二分之一像素时的取整方法, 或者 为八分之一像素时的取整方法, 或者将取整操作定义为将四分之一和八分之 一点归一化至二分之一和整像素精度位置的操作和本发明实施例二的操作过 程类似。
本申请取整方法的取整目标可以根据实际系统要求进行扩展, 对于实施 例一方案, 以整像素位置为取整目标, 将二分之一和 /或四分之一取整至整像 素位置;
或者, 以整像素位置和二分之一像素位置为取整目标, 则将二分之一像 素位置视为整像素位置, 将四分之一和 /或八分之一取整至整像素和二分之一 像素位置。
不同的取整目标选择会带来不同的压缩性能和复杂度, 满足不同的应用 需求。
实施例四: 取整的另一种实现方案
在实施例一中的步骤 104的取整过程的具体实现还可以采用如下对横坐 标取整的伪代码描述的取整过程:
iTmp = MV x;
MV_pos = MV x & 0x3;
if((MV_ pos = =1) && (MV— x <0))
MV = MV -1;
else if((MV_ pos = = 3)&&( MV x >0))
MV = MV +1;
iTmp = ((MV— x » 2 ) « 2 );
MV x = iTmp;
以上取整过程的具体描述为, 根据候选运动矢量横坐标和纵坐标分别进 行取整操作, 以横坐标为例, 当横坐标最低两位为 1, 并且横坐标为负值, 横 坐标减一; 当横坐标最低两位为 3, 并且横坐标为正值, 横坐标加一; 对以上 操作后的横坐标右移两位后, 再左移两位得到取整后的横坐标值, 完成横坐 标的取整过程。 在具体实现时, 实施例二和实施例四中的伪代码方案仅为该取整方法的 易想到其它具体实现方式, 在本发明实施例披露的技术思想下, 任何可以体 现本发明实质的软硬件实现方案均属于本发明保护范围。 如图 3所示, 本发明实施例提出一种非整像素位置运动矢量的坐标值取整 装置, 所述装置包括:
取整单元 301: 用于对非整像素位置运动矢量的坐标值进行取整操作, 所述取整操作包括对于非整像素位置运动矢量的坐标的每一维度, 当该维度 坐标为非整像素位置时, 如果该维度非整像素位置运动矢量的坐标距离该维 度非整像素位置邻近的两个整像素的坐标位置 A, B距离相同时, 将该维度 非整像素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的确定由该维度非整像素位置运动矢量坐标值的符号 确定
所述整像素的坐标位置的确定由该维度非整像素位置运动矢量坐标值的 符号确定包括:
当该非整像素位置运动矢量的坐标值的符号为正时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为负时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置, 或者: 当该非整像素位置运动矢量的坐标值的符号为负时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为正时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置。
本发明实施例提出的技术方案, 通过采用对非整像素位置运动矢量的坐 标值进行取整操作, 所述取整操作包括对于非整像素位置运动矢量的坐标的 每一维度, 当该维度坐标为非整像素位置时, 如果该维度非整像素位置运动 矢量的坐标距离该维度非整像素位置邻近的两个整像素的坐标位置 A, B距离 相同时, 将该维度非整像素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的确定由该维度非整像素位置运动矢 量坐标值的符号确定的技术手段, 解决了在现有运动矢量候选集中选取最优 运动矢量过程复杂度高得问题, 同时保持较好的编码性能。
某些实施方式中, 所述装置还包括:
获取单元 302: 用于获取当前编码或者解码块的候选运动矢量集合; 添加单元 303: 用于为所述初始候选运动矢量集合中的运动矢量添加一 个反向运动矢量;
生成单元 304: 用于根据所述反向运动矢量和所述初始候选运动矢量集 合中的运动矢量生成新的候选运动矢量集合, 以用于进行取整操作。
某些实施方式中, 所述装置还包括:
编码单元 305: 用于从取整后的候选运动矢量集合中选择用于编码或解 码的运动矢量进行编解码。 本发明实施例的装置用于执行本发明实施例的方法步骤, 方法部分的内 容可以适用于装置部分。 本领域的技术人员可以清楚地了解到本发明实施例中的技术可借助软件 加必需的通用硬件平台的方式来实现。 基于这样的理解, 本发明实施例中的 现出来, 该计算机软件产品可以存储在存储介质中, 如 ROM/RAM、 磁碟、 光盘等, 包括若干指令用以使得一台计算机设备(可以是个人计算机, 服务 器, 或者网络设备等)执行本发明各个实施例或者实施例的某些部分所述的 方法。
本说明书中的各个实施例均采用递进的方式描述, 各个实施例之间相同 相似的部分互相参见即可, 每个实施例重点说明的都是与其他实施例的不同 之处。 尤其, 对于系统实施例而言, 由于其基本相似于方法实施例, 所以描 述的比较简单, 相关之处参见方法实施例的部分说明即可。
以上所述的本发明实施方式, 并不构成对本发明保护范围的限定。 任何 在本发明的精神和原则之内所作的修改、 等同替换和改进等, 均应包含在本 发明的保护范围之内。

Claims

权 利 要求
1. 一种非整像素位置运动矢量的坐标值取整方法, 其特征在于, 所述方 法包括:
对非整像素位置运动矢量的坐标值进行取整操作, 所述取整操作包括对 于非整像素位置运动矢量的坐标的每一维度, 当该维度坐标为非整像素位置 时, 如果该维度非整像素位置运动矢量的坐标距离该维度非整像素位置邻近 的两个整像素的坐标位置 A, B距离相同时, 将该维度非整像素位置运动矢量 的坐标值取整至整像素的坐标位置 A, B其中一个, 所述整像素的坐标位置的 确定由该维度非整像素位置运动矢量坐标值的符号确定。
2. 根据权利要求 1所述的方法, 其特征在于, 所述整像素的坐标位置的 确定由该维度非整像素位置运动矢量坐标值的符号确定包括:
当该非整像素位置运动矢量的坐标值的符号为正时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为负时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置, 或者: 当该非整像素位置运动矢量的坐标值的符号为负时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为正时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置。
3. 根据权利要求 1所述的方法, 其特征在于, 所述对非整像素位置运动矢 量的坐标值进行取整操作之前还包括-.
获取当前编码或者解码块的候选运动矢量集合, 为所述初始候选运动矢 量集合中的运动矢量添加一个反向运动矢量, 根据所述反向运动矢量和所述 初始候选运动矢量集合中的运动矢量生成新的候选运动矢量集合, 以用于进 行取整操作。
4.根据权利要求 1所述的方法, 其特征在于, 所述将该维度非整像素位 置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个包括:
将该维度非整像素位置运动矢量的坐标值在该维度进行右移两位操作, 再左移两位操作, 取整至整像素的坐标位置 A, B其中一个。
5、根据权利要求 1所述的方法, 其特征在于, 所述对非整像素位置运动 矢量的坐标值进行取整操作还包括:
如果该维度非整像素位置运动矢量的坐标位置为四分之一像素位置, 将 该维度非整像素位置运动矢量的坐标值取整至最近的整像素的坐标位置。
6、根据权利要求 5所述的方法, 其特征在于, 所述对四分之一像素位置 运动矢量的坐标值进行取整操作包括:
对四分之一像素位置运动矢量的坐标值的该维度坐标取绝对值, 再加二 后, 右移两位, 再左移两位后得到取整后的该维度坐标的绝对值, 该维度坐 标符号保持不变。
7. 根据权利要求 1所述的方法, 其特征在于, 所述对非整像素位置运动矢 量的坐标值进行取整操作之后还包括:
从取整后的候选运动矢量集合中选择用于编码或解码的运动矢量进行编 解码。
8、根据权利要求 1所述的方法, 其特征在于, 所述非整像素位置运动矢 量的坐标值取整包括:
以整像素位置为取整目标,将二分之一像素位置和 /或四分之一像素位置 取整至整像素位置; 或者, 以整像素位置和二分之一像素位置为取整目标, 则将二分之一像素位置视为整像素位置,将四分之一像素位置和 /或八分之一 像素位置取整至整像素和二分之一像素位置。
9. 一种非整像素位置运动矢量的坐标值取整装置, 其特征在于, 所述装 置包括:
取整单元: 用于对非整像素位置运动矢量的坐标值进行取整操作, 所述 取整操作包括对于非整像素位置运动矢量的坐标的每一维度, 当该维度坐标 为非整像素位置时, 如果该维度非整像素位置运动矢量的坐标距离该维度非 整像素位置邻近的两个整像素的坐标位置 A, B距离相同时, 将该维度非整 像素位置运动矢量的坐标值取整至整像素的坐标位置 A, B其中一个, 所述 整像素的坐标位置的确定由该维度非整像素位置运动矢量坐标值的符号确 定。
10. 根据权利要求 9所述的装置, 其特征在于, 所述整像素的坐标位置的 确定由该维度非整像素位置运动矢量坐标值的符号确定包括:
当该非整像素位置运动矢量的坐标值的符号为正时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为负时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置, 或者: 当该非整像素位置运动矢量的坐标值的符号为负时, 对该非整像素位置 运动矢量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值小的位置; 当该非整像素位置运动矢量的坐标值符号为正时, 对该非整像素位置运动矢 量的坐标值取整后得到的整像素坐标位置为 A和 B中绝对值大的位置。
11.根据权利要求 9所述的装置, 其特征在于, 所述装置还包括: 获取单元: 用于获取当前编码或者解码块的候选运动矢量集合; 添加单元: 用于为所述初始候选运动矢量集合中的运动矢量添加一个反 向运动矢量;
生成单元: 用于根据所述反向运动矢量和所述初始候选运动矢量集合中 的运动矢量生成新的候选运动矢量集合, 以用于进行取整操作。
12.根据权利要求 9所述的装置, 其特征在于, 所述装置还包括: 编码单元: 用于从取整后的候选运动矢量集合中选择用于编解码的运动 矢量进行编解码。
PCT/CN2012/070681 2011-01-21 2012-01-20 非整像素位置运动矢量的坐标值取整方法和装置 WO2012097751A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
EP12736638.3A EP2661082A4 (en) 2011-01-21 2012-01-20 METHOD AND DEVICE FOR ARRONDING A COORDINATED VALUE OF A NON-ENTIRE PIXEL POSITION MOTION VECTOR
US13/946,705 US9521408B2 (en) 2011-01-21 2013-07-19 Method and apparatus for rounding coordinate value of non-integer pixel position motion vector

Applications Claiming Priority (4)

Application Number Priority Date Filing Date Title
CN201110024401 2011-01-21
CN201110024401.7 2011-01-21
CN201110025766.1A CN102611887B (zh) 2011-01-21 2011-01-24 非整像素位置运动矢量的坐标值取整方法和装置
CN201110025766.1 2011-01-24

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US13/946,705 Continuation US9521408B2 (en) 2011-01-21 2013-07-19 Method and apparatus for rounding coordinate value of non-integer pixel position motion vector

Publications (1)

Publication Number Publication Date
WO2012097751A1 true WO2012097751A1 (zh) 2012-07-26

Family

ID=46515171

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2012/070681 WO2012097751A1 (zh) 2011-01-21 2012-01-20 非整像素位置运动矢量的坐标值取整方法和装置

Country Status (4)

Country Link
US (1) US9521408B2 (zh)
EP (1) EP2661082A4 (zh)
CN (1) CN102611887B (zh)
WO (1) WO2012097751A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2982115A1 (en) * 2013-04-05 2016-02-10 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR102231676B1 (ko) * 2014-12-23 2021-03-25 한국전자통신연구원 실감 효과 메타데이터 생성 장치 및 방법
KR102349788B1 (ko) * 2015-01-13 2022-01-11 인텔렉추얼디스커버리 주식회사 영상의 부호화/복호화 방법 및 장치
US11272207B2 (en) 2017-06-12 2022-03-08 Futurewei Technologies, Inc. Selection and signaling of motion vector (MV) precisions
WO2020001578A1 (en) * 2018-06-28 2020-01-02 Huawei Technologies Co., Ltd. Motion vector refinement search with integer pixel resolution
CN110691247B (zh) * 2018-07-06 2023-04-28 杭州海康威视数字技术股份有限公司 一种解码、编码方法和设备
CN109309837B (zh) * 2018-10-29 2020-09-01 珠海市杰理科技股份有限公司 图像帧数据的运动估计方法、装置、设备及可读存储介质
CN112215782B (zh) * 2020-10-29 2022-10-14 中国科学院长春光学精密机械与物理研究所 一种卷帘快门成像装置图像校正方法及装置

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1589031A (zh) * 2004-10-13 2005-03-02 西安电子科技大学 基于数学模型预测的运动估计快速半像素级搜索方法
US20050117810A1 (en) * 2003-11-17 2005-06-02 Gisle Bjontegaard Method for correcting interpolated pixel values
CN101431675A (zh) * 2008-12-09 2009-05-13 青岛海信电子产业控股股份有限公司 一种像素运动估计方法和装置

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3183155B2 (ja) * 1996-03-18 2001-07-03 株式会社日立製作所 画像復号化装置、及び、画像復号化方法
US7305034B2 (en) 2002-04-10 2007-12-04 Microsoft Corporation Rounding control for multi-stage interpolation
US7116831B2 (en) * 2002-04-10 2006-10-03 Microsoft Corporation Chrominance motion vector rounding
CN101194513B (zh) * 2005-06-10 2011-07-20 Nxp股份有限公司 上下交替运动矢量
CN101465002B (zh) * 2009-01-05 2010-09-01 东南大学 椭圆目标的亚像素边缘定位方法
JP2010161747A (ja) * 2009-01-09 2010-07-22 Toshiba Corp サブピクセル生成装置及び方法並びに動き補償装置
CN101860747B (zh) * 2010-03-31 2012-05-23 北京大学 亚像素运动估计系统及方法
JP5786478B2 (ja) * 2011-06-15 2015-09-30 富士通株式会社 動画像復号装置、動画像復号方法、及び動画像復号プログラム

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050117810A1 (en) * 2003-11-17 2005-06-02 Gisle Bjontegaard Method for correcting interpolated pixel values
CN1589031A (zh) * 2004-10-13 2005-03-02 西安电子科技大学 基于数学模型预测的运动估计快速半像素级搜索方法
CN101431675A (zh) * 2008-12-09 2009-05-13 青岛海信电子产业控股股份有限公司 一种像素运动估计方法和装置

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP2661082A4 *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP2982115A1 (en) * 2013-04-05 2016-02-10 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme
US10027975B2 (en) 2013-04-05 2018-07-17 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme
EP2982115B1 (en) * 2013-04-05 2019-05-08 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme
EP3534608A1 (en) * 2013-04-05 2019-09-04 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme
US10582214B2 (en) 2013-04-05 2020-03-03 Canon Kabushiki Kaisha Method and apparatus for encoding and decoding an image with inter layer motion information prediction according to motion information compression scheme
EP3700213A1 (en) * 2013-04-05 2020-08-26 Canon Kabushiki Kaisha Method and apparatus for encoding or decoding an image with inter layer motion information prediction according to motion information compression scheme
US11089324B2 (en) 2013-04-05 2021-08-10 Canon Kabushiki Kaisha Method and apparatus for encoding and decoding an image with inter layer motion information prediction according to motion information compression scheme

Also Published As

Publication number Publication date
US20130315313A1 (en) 2013-11-28
EP2661082A4 (en) 2013-11-13
CN102611887A (zh) 2012-07-25
EP2661082A1 (en) 2013-11-06
CN102611887B (zh) 2015-08-05
US9521408B2 (en) 2016-12-13

Similar Documents

Publication Publication Date Title
WO2012097751A1 (zh) 非整像素位置运动矢量的坐标值取整方法和装置
WO2012097753A1 (zh) 一种运动预测或补偿方法
TWI617185B (zh) 具有仿射運動補償的視訊編碼的方法以及裝置
JP5081305B2 (ja) フレーム間予測符号化の方法および装置
US11902563B2 (en) Encoding and decoding method and device, encoder side apparatus and decoder side apparatus
CN111385569A (zh) 一种编解码方法及其设备
JP2019013031A (ja) 画像予測方法および関連装置
WO2016131229A1 (zh) 用于视频图像编码和解码的方法、编码设备和解码设备
WO2008067734A1 (en) An encoding/decoding method and device, a fractional pixel interpolation processing method and device
US9118927B2 (en) Sub-pixel interpolation and its application in motion compensated encoding of a video signal
WO2011150840A1 (zh) 一种生成图像预测值的方法和装置
JP2007529175A5 (zh)
WO2013064120A1 (zh) 一种变换模式的编解码方法和装置
TW201220854A (en) Mixed tap filters
TW201216716A (en) Motion compensation using vector quantized interpolation filters
WO2019072246A1 (zh) 视频编码中的运动估计方法、装置、电子设备及存储介质
JP2005501491A (ja) グローバル動きパラメータを用いた動きベクトル符号化方法および装置
NZ590990A (en) Content adaptive and art directable scalable video coding
JP5356909B2 (ja) 動きベクトル変換を用いた飛越し走査映像符号化/復号化方法および装置
WO2021056215A1 (zh) 运动估计方法、系统和存储介质
CN114727114A (zh) 运动矢量的确定方法和装置
JP2005253015A (ja) 動きベクトル検出装置、動きベクトル検出方法、及びプログラム
TW202005388A (zh) 交織預測的應用
WO2012113276A1 (zh) 视频解码方法、编码方法及终端
CN110944209B (zh) 运动矢量的确定方法和装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 12736638

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

WWE Wipo information: entry into national phase

Ref document number: 2012736638

Country of ref document: EP