WO2016026283A1 - 一种预测编、解码方法和相应的编、解码器和电子设备 - Google Patents

一种预测编、解码方法和相应的编、解码器和电子设备 Download PDF

Info

Publication number
WO2016026283A1
WO2016026283A1 PCT/CN2015/073048 CN2015073048W WO2016026283A1 WO 2016026283 A1 WO2016026283 A1 WO 2016026283A1 CN 2015073048 W CN2015073048 W CN 2015073048W WO 2016026283 A1 WO2016026283 A1 WO 2016026283A1
Authority
WO
WIPO (PCT)
Prior art keywords
decoding
slice
mode
image
block
Prior art date
Application number
PCT/CN2015/073048
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 中兴通讯股份有限公司
Publication of WO2016026283A1 publication Critical patent/WO2016026283A1/zh

Links

Images

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

Definitions

  • the embodiments of the present invention relate to the field of video coding and decoding, and in particular, to a prediction encoding and decoding method, and corresponding codecs, decoders, and electronic devices.
  • Intra Block Copying (IBC) mode is adopted in the Screen Content Coding (SCC) standard based on the high-definition video coding (HEVC, H.265/High Efficiency Video Coding) standard. .
  • SCC Screen Content Coding
  • HEVC high-definition video coding
  • H.265/High Efficiency Video Coding High Efficiency Video Coding
  • the IBC allows the use of one two-dimensional pixel block that has been recovered within the current image as the prediction block for the current block, while The IBC uses the relative offset between the prediction block and the current block to locate the prediction reference block, which is called Block Copying Vector (BV).
  • BV Block Copying Vector
  • IBC is similar to the inter prediction mode in the H.265/HEVC standard, except that the IBC uses the partially decoded recovered pixels in the current image as the prediction reference, and the inter prediction mode is decoded before the current picture in decoding order. The pixels in the restored image are used as prediction references.
  • the IBC can use the same or similar block partitioning method, and the BBC information of the IBC can use the same or similar predictive coding method as the motion vector (MV, Motion Vector) of the inter prediction mode.
  • MV Motion Vector
  • JCTVC-R0100 and JCTVC-R0190 proposes to use a unified structure of IBC and inter prediction modes in the SCC standard extension.
  • JCTVC-R0100 proposes to add the current decoded image to the last position of list 0 (List 0) of the reference picture list and mark it as "Long-term reference picture" so that The block division and the BV of the IBC are encoded using the block division and MV prediction coding methods of the existing inter prediction mode, and the information about the IBC is written into the code stream using the syntax organization method of the inter prediction mode.
  • JCTVC-R0190 It is proposed to treat the IBC as an inter prediction mode.
  • an "inter-prediction block” is used (ie, the pred_mode_flag value is equal to 0) to represent the IBC block;
  • P-slice or B-slice using "List 0 reference picture index value equal to 1 inter prediction block” (ie pred_mode_flag takes the value equal to 0 and ref_idx_l0 takes the value equal to 1) to represent the IBC block, so that you can use
  • the block partitioning and MV predictive coding methods of the inter prediction mode encode the block partitioning and BV of the IBC, and the information about the IBC is written into the code stream by using the syntax organization method of the inter prediction mode.
  • the above method implements the unified structure IBC and inter prediction mode, and directly applies the predictive block partitioning and motion information coding and other efficient predictive coding methods used in the inter prediction mode to the IBC, and obtains a large coding efficiency improvement. . Nevertheless, the above method still has the following disadvantages:
  • the method of unifying the IBC and inter prediction modes cannot define an All Intra Profile.
  • all images of the video sequence are encoded using intra-prediction encoding methods, eliminating the need to use and construct a reference image list.
  • the method of unifying the IBC and the inter prediction mode needs to add a reference picture list for the full intra-frame level, and increase the correlation with the additional reference picture list in the file definition and the hypothetical reference decoder, the consistency test, the code stream working point, and the like.
  • the complexity of the full intra-frame grade is increased.
  • the high-level architecture of the existing H.265/HEVC full-frame encoder cannot be directly multiplexed.
  • the improvement of the IBC mode needs to modify all the interframes. Predicting the grammatical organization and declaration of mode parameters, adding additional conditional judgments to differentiate between processing IBC and inter prediction modes adds additional processing complexity. In particular, when the IBC mode of the intra-coded picture is improved, it is necessary to adjust the inter-prediction coding mode that is not used for the intra-coded picture, and to increase the correlation condition judgment and the corresponding processing flow.
  • the current unified IBC and inter prediction mode methods are simultaneously applied to intra prediction coding pictures.
  • the image and the interframe predictive coded image so that the IBC mode cannot be improved and optimized separately for the characteristics of the intra prediction coded image and the interframe predictive coded picture.
  • the sampled values of the uncoded and undecoded position pixels in the prediction reference image are used to construct the reference block of the IBC mode, and therefore, the performance of the IBC mode reference block construction process remains to be determined. Upgrade.
  • an embodiment of the present invention provides a predictive coding method and a corresponding decoding method, and an encoder, a decoder, and an electronic device using the foregoing method, which can avoid the result of unified IBC and inter prediction mode.
  • the invention provides a predictive coding method applied to an encoder, comprising:
  • the image of the slice is set as the predicted reference image of the slice, and the coded block of the IBC mode is used for the intra block in the slice, and the first coding mode is used for coding;
  • the coding block using the IBC mode in the slice is coded using a second coding method different from the first coding mode.
  • setting the image of the fragment as the prediction reference image of the fragment includes: inserting the image of the fragment into a prediction reference image list, As a predicted reference image of the slice.
  • the encoding block of the IBC mode is used in the fragment of the inter prediction type, and encoding is performed by using a first encoding manner, including: encoding an IBC mode parameter by using a mode parameter encoding mode of an inter prediction mode.
  • the mode parameter encoding manner of the inter prediction mode is used to encode the IBC mode parameter, including: encoding the IBC mode parameter by using a motion information encoding method of the prediction unit PU;
  • the encoded IBC mode parameters include at least one of the following parameters: block partitioning, reference block indication vector, and reference image index.
  • the encoding block of the IBC mode is used in the fragment of the intra prediction type, and the encoding is performed by using a second encoding manner, including:
  • the encoded IBC mode parameters include at least one of the following parameters: a block partition and a reference block indication vector.
  • the directly encoding the IBC mode parameter in the coding block includes: directly coding the IBC mode parameter in the coding unit CU.
  • the method further includes: encoding the IBC mode identification information.
  • setting the image of the slice as the predicted reference image of the slice includes: directly using the image of the slice as a predicted reference image of the slice;
  • the coding block of the IBC mode is used in the fragment of the inter prediction type, and is coded according to the first coding manner, including:
  • the PU coded IBC mode identification information and IBC mode parameter information are used.
  • the embodiment of the invention further provides a decoding method, which is applied to a decoder, and includes:
  • the first decoding mode is used, the image of the slice is set as the prediction reference image of the slice, and the intra block copy (IBC) is adopted in the slice.
  • the decoded block of the mode is decoded;
  • the decoding block using the IBC mode in the slice is decoded using a second decoding mode different from the first decoding mode.
  • the using the first decoding mode to set the image of the slice as the predicted reference image of the slice includes: inserting the image of the slice into a prediction reference image list as the slice Prediction reference image.
  • the decoding by using the first decoding mode, the decoding block in the IBC mode in the fragment, includes: decoding the decoding block in the IBC mode in the fragment by using a decoding mode of an inter prediction mode.
  • Decoding the IBC mode parameter is obtained by parsing the bit field corresponding to the mode parameter of the inter prediction mode.
  • Obtaining the IBC mode parameter includes: obtaining at least one of the following IBC mode parameters by parsing a prediction unit (PU) and a bit field corresponding to the motion information parameter therein: a block division, a reference block indication vector, and a reference image index.
  • PU prediction unit
  • the decoding by using the second decoding mode different from the first coding mode, the decoding block that uses the IBC mode in the fragment, includes: parsing a bit field corresponding to an IBC mode parameter in the decoding block; At least one of the following IBC mode parameters is obtained: a block partition and a reference block indication vector.
  • parsing the bit field corresponding to the IBC mode parameter in the decoding block includes: parsing a bit field corresponding to an IBC mode parameter in the coding unit CU, and obtaining an IBC mode parameter.
  • the method before parsing the bit field corresponding to the IBC mode parameter in the decoding block, the method further includes: parsing a bit field corresponding to the IBC mode identifier information in the decoding block, and obtaining a value of the corresponding parameter of the IBC mode identifier information.
  • the using the first decoding mode to set the image of the slice as the predicted reference image of the slice includes: directly using the image of the slice as a prediction reference image of the slice;
  • the decoding block of the IBC mode is used in the fragment of the inter prediction type, and the decoding is performed by using the first decoding mode, including:
  • the bit field corresponding to the IBC mode identification information and the IBC mode parameter in the PU is parsed, and the values of the IBC mode identification information and the IBC mode parameter are obtained.
  • the embodiment of the invention further provides an encoder, including:
  • Type setting device set to set the type of the slice
  • a first encoding device configured to slice encoding an inter prediction type, where the image of the slice is set as a predicted reference image of the slice, and an intra block copy IBC is used in the slice
  • the coding block of the mode is encoded using the first coding method
  • the second encoding device is configured to perform slice encoding on the intra prediction type.
  • the encoding block using the IBC mode in the fragment is encoded by using a second encoding manner different from the first encoding manner.
  • the first encoding device encodes the slice of the inter prediction type
  • setting the image of the slice as the predicted reference image of the slice and setting: inserting the image of the slice A reference picture list is predicted as a predicted reference picture of the slice.
  • the first encoding apparatus uses an encoding block of an IBC mode in the fragment of the inter prediction type, and performs encoding using a first encoding manner, and is configured to: encode using a mode parameter encoding manner of an inter prediction mode. IBC mode parameters.
  • the first encoding apparatus encodes an IBC mode parameter by using a mode parameter encoding mode of an inter prediction mode, and is configured to: encode an IBC mode parameter by using a motion information encoding method of the prediction unit PU, where the encoded IBC mode parameter includes At least one of the following parameters: block partitioning, reference block indication vector, and reference image index.
  • the second encoding apparatus uses a coding mode of an IBC mode in the slice of the intra prediction type, and performs coding by using a second coding mode, and is configured to directly encode an IBC mode parameter in the coding block, and coded.
  • the IBC mode parameter includes at least one of the following parameters: a block partition and a reference block indication vector.
  • the second encoding device directly encodes the IBC mode parameter in the encoding block, and is configured to directly encode the IBC mode parameter in the encoding unit CU.
  • the second encoding device is further configured to: encode the IBC mode identification information before the encoding block directly encodes the IBC mode parameter.
  • the first encoding device sets the image of the slice as the predicted reference image of the slice, and sets the image of the slice directly as a predicted reference image of the slice;
  • the first encoding apparatus uses an IBC mode coding block in the slice of the inter prediction type, and performs coding according to the first coding mode, and is set as:
  • the PU coded IBC mode identification information and IBC mode parameter information are used.
  • An embodiment of the present invention further provides a decoder, including:
  • a type parsing device configured to parse a code stream to obtain slice type information
  • a first decoding device configured to decode the slice of the inter prediction type, and when decoding, use the first decoding mode, set the image of the slice as the predicted reference image of the slice, and set the slice Decoding is performed using a decoding block of an intra block copy (IBC) mode;
  • IBC intra block copy
  • the second decoding means is configured to decode the slice of the intra prediction type, and when decoding, decode the decoded block in the IBC mode in the slice using a second decoding mode different from the first decoding mode.
  • the image of the slice is set as the predicted reference image of the slice, and is set to: insert the image of the slice into A reference picture list is predicted as a predicted reference picture of the slice.
  • the first decoding device decodes the decoded block in the IBC mode in the fragment by using a first decoding manner, and is configured to: use an IBC in the fragment by using a decoding mode of an inter prediction mode.
  • the decoded block of the mode is decoded, and the IBC mode parameter is obtained by parsing the bit field corresponding to the mode parameter of the inter prediction mode.
  • the first decoding device obtains an IBC mode parameter by parsing a bit field corresponding to a mode parameter of the inter prediction mode, and is configured to: obtain the following IBC mode parameter by parsing a bit field corresponding to the PU and a motion information parameter thereof At least one of: block partitioning, reference block indication vector, and reference image index.
  • the second decoding device decodes the decoded block in the IBC mode in the fragment by using a second decoding manner different from the first decoding manner, and is configured to: parse the IBC mode parameter in the decoding block. Corresponding bit field, obtaining at least one of the following IBC mode parameters: block The sub- and reference block indication vectors.
  • the second decoding device parses the bit field corresponding to the IBC mode parameter in the decoding block, and sets the bit field corresponding to the IBC mode parameter in the coding unit CU to obtain an IBC mode parameter.
  • the method further includes: parsing a bit field corresponding to the IBC mode identifier information in the decoding block, and obtaining a corresponding parameter of the IBC mode identifier information. Value.
  • the first decoding device uses the first decoding mode to set the image of the slice as the predicted reference image of the slice, and is configured to directly use the image of the slice as the slice. Prediction reference image;
  • the first decoding device uses the first decoding mode to decode the decoding block in the IBC mode in the fragment of the inter prediction type, and the specific setting is:
  • the bit field corresponding to the IBC mode identification information and the IBC mode parameter in the PU is parsed, and the values of the IBC mode identification information and the IBC mode parameter are obtained.
  • An embodiment of the present invention further provides an electronic device, including an encoder and/or a decoder, where:
  • the encoder employs any of the encoders described above;
  • the decoder employs any of the decoders described above.
  • the coding blocks using the IBC mode in the inter-prediction type and the intra-prediction type are coded by different coding modes, thereby avoiding various problems caused by the unified structure, and obtaining the following one. Or a variety of technical effects:
  • the IBC mode is improved and optimized for intra-predictive coded pictures and inter-predictive coded pictures, respectively. Improvements to the IBC mode do not require modification of the grammatical organization and declaration of inter-prediction mode parameters, without the need for additional conditional judgments. When the IBC mode of the intra-coded picture is improved, there is no need to adjust the inter-predictive coding mode that is never used for intra-coded pictures.
  • the IBC mode implements a structure that is consistent with the inter-frame prediction mode, and has various advantages brought by the unified structure.
  • an embodiment of the present invention further provides an image filling method and a corresponding electronic device.
  • An embodiment of the present invention provides an image filling method, which is applied to a predictive encoding and/or decoding process, and includes:
  • the sampled values of the uncoded and/or undecoded position pixel points in the image are filled.
  • filling the sampled values of the uncoded position pixel points in the image including:
  • the decoding unit Before decoding the decoding unit, filling sample values of all or part of undecoded position pixel points in the image, wherein a part of the undecoded position pixel points in the image refers to a current decoding unit and an adjacent decoding unit thereof.
  • the method further includes: writing the corresponding filling mode information into the code stream, where the filling mode information includes the following information. At least one of:
  • the indication information of the filling method used and related parameters When using adaptive padding, the indication information of the filling method used and related parameters;
  • the padding value of the sampled value of the uncoded position pixel used when no adaptive padding is used is used
  • the sampled values of the undecoded pixel points in the image are filled according to the fill mode information parsed from the code stream.
  • the method further includes: after the encoding unit is completed, updating the sampled value of the local decoding of the encoded position pixel in the current encoded image. A sample value of a corresponding pixel in the image, and refilling the sampled value of the uncoded pixel in the image.
  • the method further includes: after the decoding unit decoding is completed, updating the recovered sample value of the decoded position pixel point in the current decoded image. The sampled value of the corresponding pixel in the image, and the sampled value of the undecoded pixel in the image is refilled.
  • An embodiment of the present invention further provides an electronic device, including an encoder and/or a decoder, where:
  • the encoder includes:
  • Determining means arranged to determine an image as a reference when predictive coding is performed on the coding unit
  • the sampled values of the uncoded and/or undecoded position pixel points in the image are filled.
  • a code filling device configured to fill a sampled value of an uncoded pixel in the image
  • the decoder includes:
  • Determining means arranged to determine an image as a reference when decoding the decoding unit
  • a decoding padding device is arranged to fill the sampled values of undecoded pixel points in the image.
  • the code filling device fills a sample value of an uncoded position pixel in the image, and the specific setting is:
  • the partially uncoded position pixel point in the image refers to a current coding unit and an adjacent coding unit thereof.
  • the decoding and filling device fills a sample value of an undecoded pixel in the image, and the specific setting is:
  • the decoding unit Before decoding the decoding unit, filling sample values of all or part of undecoded position pixel points in the image; wherein, the partially undecoded position pixel point in the image refers to a current decoding unit and an adjacent decoding unit thereof.
  • the method further includes: writing the corresponding filling mode information into the code stream, where the filling mode information includes the following information. At least one of:
  • the indication information of the filling method used and related parameters When using adaptive padding, the indication information of the filling method used and related parameters;
  • the padding value of the sampled value of the uncoded position pixel used when no adaptive padding is used is used
  • the decoding and filling device fills the sampled values of the undecoded pixel points in the image according to the filling mode information parsed from the code stream.
  • the code filling device fills the sampled values of the uncoded position pixel points in the image, it is further set to:
  • the sample values of the corresponding pixel points in the image are updated with the locally decoded recovery sample values of the encoded position pixel points in the current coded image, and the uncoded position pixel points in the image are re-imaged.
  • the sampled values are filled.
  • the method further sets the following:
  • the sampled values of the corresponding pixel points in the image are updated with the recovered sample values of the decoded position pixel points in the currently decoded image, and the image is not decoded again.
  • the sampled values of the position pixels are filled.
  • the sampling value of the uncoded and/or undecoded pixel in the prediction reference image is filled, thereby improving the accuracy of the prediction, thereby improving the performance of encoding and decoding.
  • FIG. 1 is a flowchart of an encoding method according to an embodiment of the present invention.
  • FIG. 2 is a flowchart of coding block coding in a slice of an inter prediction type in an embodiment of the present invention
  • FIG. 3 is a flowchart of coding block coding in a slice of an intra prediction type according to an embodiment of the present invention
  • FIG. 4 is a schematic structural diagram of an encoder of an embodiment of the present invention.
  • FIG. 5 is a flowchart of a decoding method according to an embodiment of the present invention.
  • FIG. 6 is a flowchart of decoding a coding block in a slice of an inter prediction type in an embodiment of the present invention
  • FIG. 7 is a flowchart of decoding a coding block in a slice of an intra prediction type according to an embodiment of the present invention.
  • FIG. 8 is a schematic structural diagram of a decoder in an embodiment of the present invention.
  • FIG. 9 is a flow chart of a filling method in an embodiment of the present invention.
  • FIG. 10 is a schematic structural diagram of an encoder in an electronic device according to an embodiment of the present invention.
  • FIG. 11 is a schematic diagram showing the structure of a decoder in an electronic device according to an embodiment of the present invention.
  • a slice is an independent decoding unit in one frame of image, one frame image contains one or more slices, and one slice contains one or more coding blocks.
  • the coding block is at least one of the following block units: a Coding Tree Unit (CTU), a Coding Unit, a Prediction Unit (PU), and a Transform Unit (TU).
  • CTU Coding Tree Unit
  • PU Prediction Unit
  • TU Transform Unit
  • the slice type includes two types of intra prediction type and inter prediction type.
  • the slice of the intra prediction type is an I type slice
  • the slice of the inter prediction type may be a P type slice or a B type slice.
  • the coding block/decode block in the I type slice may adopt the IBC mode or the normal intra prediction mode, but the inter prediction mode is not used.
  • the coding block/decoding block in the P type fragment and the B type fragment may adopt an IBC mode, a normal intra prediction mode, or an inter prediction mode.
  • the present invention mainly studies how to encode/decode a coding block/decoding block of an IBC mode, and encodes an IBC mode coding block/decoding block in an inter prediction type slice and an intra prediction type slice according to different coding modes. /decoding.
  • This embodiment provides a predictive coding method and a corresponding encoder.
  • the encoding process for a slice is as shown in FIG. 1, and includes:
  • Step 110 Set a slice type for the currently coded slice.
  • the encoder may set the slice type of the slice in the image according to the preset prediction structure information, and write the set slice type information into the code stream.
  • the slice type information may be indicated by a slice_type field in a Slice Segment Header.
  • Step 120 if the set fragment type is an inter prediction type, step 130 is performed, otherwise step 160 is performed;
  • Step 130 Set the image of the slice as a predicted reference image of the slice
  • the image of the slice is inserted into the prediction reference image list as the prediction reference image of the slice itself.
  • the list of predicted reference pictures used by each slice in the same frame image is the same.
  • the encoder may place the current encoded image at a fixed position in the predicted reference image list, or may adaptively adjust the position of the current encoded image in the predicted reference image list. For example, the encoder may set, use the adjustment information of the reference image list to adjust the placement position of the current encoded image in the reference image list, and write the adjustment information of the reference image list into the code stream.
  • Step 140 Filling sample values of all or part of uncoded position pixel points in the predicted reference image
  • the embodiment may further perform a filling process on the prediction reference image.
  • the encoder may set a sample value for the pixel points of all uncoded positions in the predicted reference image; or may only fill the sample values of the partially uncoded position pixel.
  • the sampled value of the partially uncoded position pixel may refer to an uncoded position pixel point in the current coded block and its adjacent coded block, or an uncoded position pixel point in the range of the prediction block pointed to by the MV or BV.
  • the specific filling method can be divided into two categories: no adaptive filling and adaptive filling.
  • a type of method that does not use adaptive padding such as setting a sample value of an undecoded position pixel in a predicted reference image to a default preset value, for example, a 1/2, a zero value, a maximum value, and the like of the maximum allowable sample value.
  • a method of using adaptive padding such as setting the sample value of the uncoded position pixel in the predicted reference image to the mean value of the most recently coded block pixel sample value or the sample value of the specified pixel point, or set to each column The sampled value of the last encoded pixel in the direction.
  • the sampling value of the uncoded position pixel in the prediction reference image is set as the output value of the extrapolation filter, and the input of the extrapolation filter is the sampled value of the encoded pixel, and the filter may be along a certain
  • a one-dimensional filter specifying a direction may also be a two-dimensional filter; the filter may be an external interpolation filter using a fixed coefficient or an adaptive filter; the encoder will filter the shape Parameter information such as coefficients and coefficients are written to the code stream.
  • the encoder can use encoder optimization modules (such as the commonly used encoder control module based on rate-distortion criteria) to determine the specific parameters used in the encoding process.
  • the padding mode used may be agreed between the encoder and the decoder, and the padding mode information used may be written into the code stream, and the padding mode information may include at least one of the following information:
  • the indication information of the filling method used and related parameters When using adaptive padding, the indication information of the filling method used and related parameters;
  • the padding value of the sampled value of the uncoded position pixel used when no adaptive padding is used is used
  • the encoder may write the above filling mode information to one or more of the following information elements in the code stream: parameter set, slice header information, coding tree block (CTU), and CU.
  • the sampled values of the undecoded position pixel points in the predicted reference image may be filled according to the filling mode information parsed from the code stream.
  • Step 150 Encode the coding blocks in the slice of the inter prediction type, where the coding block in the IBC mode in the slice is coded according to the first coding mode, and the process ends.
  • Step 160 The coding blocks in the intra prediction type are sequentially encoded, and the coding blocks in the IBC mode in the fragment are coded according to a second coding manner different from the first coding mode.
  • the encoder may also fill the image (cached image) where the intra prediction type slice is located, and the filling manner may adopt various manners described in step 140.
  • the encoder sequentially encodes the code streams of the CTUs in the fragment, and sequentially encodes the codes of each of the CTUs (including at least one of the CU, the PU, and the TU) for each CTU. flow.
  • the method specifically includes:
  • Step 1501 Determine a prediction mode adopted by the current coding block in the slice of the inter prediction type
  • the encoder may use the encoder optimization module to determine to use a normal intra prediction mode, an IBC mode, or an inter prediction mode for the current coding block.
  • Step 1503 if the IBC mode is adopted, step 1505 is performed; otherwise, step 1509 is performed;
  • Step 1505 Encoding the block using the IBC mode in the inter-prediction type slice, using the first coding mode to perform coding;
  • Encoding by using the first coding mode may include: encoding the IBC mode parameter by using a mode parameter coding mode of the inter prediction mode.
  • the IBC mode parameter may be encoded using a motion information encoding method of the prediction unit PU, the encoded IBC mode parameter including at least one of the following parameters: a block partition, a reference block indication vector, and a reference image index.
  • the coding block of the IBC mode is used, and the inter prediction mode identifier can be used instead of encoding the special IBC mode identification information.
  • the coder can determine that it is a decoding block of the IBC mode according to the inter prediction mode identification and the reference image index pointing to the image in which it is located.
  • the prediction block division manner of the IBC is not limited, and may be a conventional rectangular or square block division manner, or may be Nx1 or 1 ⁇ N string division.
  • the String Matching method is a special case when the IBC uses the Nx1 or 1xN string division method.
  • the reference block indication vector represents a relative positional offset between the reference block and the current coded block, ie BV.
  • the reference block indication vector it may be directly encoded; the reference block indication vector parameter may also be used to represent the reference block indication vector, and the reference block indication vector parameter is encoded.
  • the reference block indication vector parameter may include at least one of the following parameters: BV predicted value index number, BV prediction difference.
  • the encoder can limit the dynamic range of the BV to the extent of the slice in which the current coded block is located.
  • the encoder constructs a predicted value of the pixel point sample value in the current coding block according to the IBC mode parameter.
  • the encoder may use one or more reference blocks pointed by the BV to combine the one or more reference blocks into prediction blocks of the same shape as the current coding block according to an IBC mode block division manner, and the pixels included in the prediction block
  • the point sample value is used as a predicted value of the current block, or the pixel point sample value in the prediction block is weighted and processed as an IBC mode reference block.
  • Step 1507 After the encoding of the encoding block is completed, the sampling value is restored by the local decoding of the encoded position pixel in the current encoded image of the encoding block, and the sampling value of the corresponding pixel in the predicted reference image is updated, and the process ends.
  • the method further includes: refilling the sample values of the uncoded position pixel points in the predicted reference image by using the same filling manner.
  • step 1509 the coding block of the other mode is used in the inter prediction type fragment, and the coding is performed according to the coding method specified by the standard.
  • coding block of the inter prediction mode may also be a coding block of the normal intra prediction mode in the inter prediction type slice, and the coding method of these coding blocks may be as specified in the standard.
  • the image of the slice is directly used as the prediction reference image of the slice, and the prediction reference image list is no longer inserted.
  • the encoding block using the IBC mode in the fragment is encoded by using the first encoding method, which may include: using the encoding
  • the unit (CU) encodes the IBC mode identification information, encodes the IBC mode parameter information using a prediction unit (PU), or encodes the IBC mode identification information and the IBC mode parameter information using a prediction unit (PU).
  • the encoder sequentially encodes the code streams of the CTUs in the fragment, and sequentially encodes the code streams of the blocks in the CTU for each CTU.
  • the method specifically includes:
  • Step 1601 Determine a prediction mode adopted by a current coding block in a slice of an intra prediction type
  • the encoder may use the encoder optimization module to determine to use a normal intra prediction mode or an IBC mode for the current coding block.
  • Step 1603 if it is determined to adopt the IBC mode, step 1605 is performed, otherwise, step 1609 is performed;
  • Step 1605 Encoding the block using the IBC mode in the intra prediction type slice, and encoding by using the second coding mode;
  • Encoding using the second encoding method may include directly encoding the IBC mode parameter in the encoding block, the encoded IBC mode parameter including at least one of the following parameters: a block partitioning and a reference block indication vector.
  • the IBC mode parameters can be directly encoded in the coding unit CU.
  • the IBC mode identification information may be encoded before the coding block directly encodes the IBC mode parameter, and the CU coded IBC mode identification information may be used, but is not limited thereto, and the PU coded IBC mode identification information may also be used.
  • Step 1607 After the encoding of the encoding block is completed, the sampling value is restored by the local decoding of the encoded position pixel in the current encoded image of the encoding block, and the sampling value of the corresponding pixel in the image of the fragment is updated, and the process ends.
  • the same padding method may be used to refill the sampled values of the uncoded pixel points in the image where the slice is located.
  • Step 1609 Perform encoding on other types of coding blocks in the intra prediction type fragment according to the coding method specified by the standard;
  • coding blocks of the normal intra prediction mode in the inter prediction type fragment may also be coding blocks of the normal intra prediction mode in the inter prediction type fragment, and the coding methods of these coding blocks may be as specified in the standard.
  • the encoder provided in this embodiment includes:
  • the type setting device 10 is set to set the type of the slice
  • the first encoding device 20 is configured to perform slice encoding on an inter prediction type. When encoding, set the image of the slice as a predicted reference image of the slice, and use intra block copy in the slice.
  • the coding block of the IBC mode is coded using the first coding mode;
  • the second encoding device 30 is configured to perform slice encoding for the intra prediction type.
  • the encoding block using the IBC mode in the fragment is encoded using a second encoding method different from the first encoding method.
  • the image of the slice is set as the predicted reference image of the slice, and may be set to insert the image of the slice into the prediction reference image.
  • a list as a predicted reference image of the slice.
  • the first encoding apparatus 20 uses the coding mode of the IBC mode in the slice of the inter prediction type, and performs coding using the first coding mode, and may be set to: encode the IBC mode parameter by using the mode parameter coding mode of the inter prediction mode. .
  • the first encoding device 20 encodes the IBC mode parameter by using the mode parameter encoding mode of the inter prediction mode, and may be configured to: encode the IBC mode parameter by using the motion information encoding method of the prediction unit PU, where the encoded IBC mode parameter includes the following parameters: At least one of: block partitioning, reference block indication vector, and reference image index.
  • the second encoding device 30 uses the encoding mode of the IBC mode in the slice of the intra prediction type, and performs encoding using the second encoding mode, and may be configured to directly encode the IBC mode parameter in the encoding block, and encode the IBC.
  • the mode parameter includes at least one of the following parameters: a block partition and a reference block indication vector.
  • the second encoding device 30 directly encodes the IBC mode parameter in the encoding block, and can be set to directly encode the IBC mode parameter in the encoding unit CU.
  • the second encoding device may further be configured to: encode the IBC mode identification information before the encoding block directly encodes the IBC mode parameter.
  • the first encoding device 20 may be configured to set the image when the image of the slice is set as the predicted reference image of the slice.
  • the image in which the slice is located directly serves as a predicted reference image of the slice.
  • the first encoding device 20 uses the IBC mode coding block in the slice of the inter prediction type, and performs coding according to the first coding mode, and may be set to use the coding unit (CU) to encode the IBC mode identification information, and use the prediction unit.
  • (PU) encodes IBC mode parameter information; or, the prediction unit (PU) is used to encode IBC mode identification information and IBC mode parameter information.
  • the embodiment provides a decoding method corresponding to the above encoding method and encoder embodiment and a corresponding decoder.
  • the decoding method of this embodiment is applied to a decoder, and the decoding process for a slice is as shown in FIG. 5, and includes:
  • Step 210 Parse the slice layer code stream, and obtain fragment type information of the current decoded slice.
  • the slice type information refers to the slice type information given by the slice_type field in the Slice Segment Header.
  • Step 220 if the fragment type is an inter prediction type fragment, step 230 is performed; otherwise, step 260 is performed;
  • Step 230 using the first decoding mode, setting the image of the slice as the predicted reference image of the slice;
  • the decoder constructs a reference image list, and inserts the image of the slice into the reference image list as the predicted reference image of the slice.
  • the prediction reference picture list used for each slice in the same frame image is the same.
  • the decoder may place the image in which the slice is located at a fixed position in the reference image list, or adaptively adjust the position of the currently decoded image in the reference list.
  • Step 240 filling sample values of all or part of uncoded position pixel points in the predicted reference image
  • the embodiment may further perform a filling process on the prediction reference image.
  • the decoder may set a sample value for the pixel points of all undecoded positions in the prediction reference image; or may only fill the sample values of the partially undecoded position pixel points.
  • the sampled value of the partially undecoded location pixel may refer to the undecoded location pixel in the current decoded block and its adjacent decoded block. Or refers to an uncoded position pixel within the range of prediction blocks pointed to by the MV or BV.
  • the decoder may fill the sampled values of the undecoded position pixel points in the predicted reference image according to the padding mode information parsed from the code stream.
  • Step 250 Decode the decoding blocks in the inter prediction type fragment sequentially, where the decoding block using the IBC mode in the fragment is decoded by using the first decoding manner, and the process ends.
  • Step 260 Decode the decoding blocks in the intra prediction type fragment sequentially, wherein the decoding block adopting the IBC mode in the fragment is decoded by using a second decoding manner different from the first decoding mode.
  • the decoder may further fill the image of the intra prediction type slice (the buffered image), and the filling manner may adopt various manners described in step 240.
  • the decoder sequentially parses the code streams of the CTUs in the fragment, and sequentially parses the codes of each of the CTUs (including at least one of the CU, the PU, and the TU) in each CTU. flow.
  • decoding the current decoding block in the inter prediction type fragment as shown in FIG. 6, it includes:
  • Step 2501 Determine a prediction mode adopted by a current decoding block in a slice of an inter prediction type
  • the "decoding method” includes a representation method and a coding position of the mode-related parameters in the code stream.
  • the decoder may first determine that it is an IBC mode decoding block and then decode the relevant mode parameter.
  • the flag can be an IBC mode identifier.
  • Step 2503 if the IBC mode is adopted, step 2505 is performed; otherwise, step 2509 is performed;
  • Step 2505 Decode the decoding block in the IBC mode in the inter prediction type slice by using the first decoding mode, and end the process;
  • the decoding mode of the inter prediction mode is used to solve the IBC mode in the fragment.
  • the code block is decoded, and the IBC mode parameter is obtained by parsing the bit field corresponding to the mode parameter of the inter prediction mode.
  • the IBC mode parameters may be obtained by parsing a prediction unit (PU) and a bit field corresponding to the motion information parameter therein: a block division, a reference block indication vector, and a reference image index.
  • the decoder constructs a predicted value of the sample point value in the current decoded block according to the IBC mode parameter.
  • Step 2507 after the decoding of the decoding block is completed, updating the sampling value of the corresponding pixel in the predicted reference image with the recovered sampling value of the decoded position pixel in the currently decoded image of the decoding block, and ending;
  • the method further includes: refilling the sampled value of the undecoded pixel in the predicted reference image by using the same filling manner.
  • Step 2509 Decode the block using the other mode in the inter-prediction type slice, and decode according to the decoding mode specified by the standard.
  • decoding block of the inter prediction mode may also be a decoding block of the normal intra prediction mode in the inter prediction type fragment, and the decoding method of these decoding blocks may be as specified in the standard.
  • the first decoding mode is used, and when the image of the slice is set as the predicted reference image of the slice, the slice may be used.
  • the image is directly used as the predicted reference image of the slice.
  • the bit field corresponding to the IBC mode identification information and the IBC mode parameter in the PU is parsed, and the values of the IBC mode identification information and the IBC mode parameter are obtained.
  • step 260 shown in FIG. 5 the decoder sequentially decodes the code streams of the CTUs in the fragment, and sequentially decodes the code streams of the blocks in the CTU for each CTU.
  • the decoder When decoding the current decoded block in the intra prediction type fragment, as shown in FIG. 7, it includes:
  • Step 2601 determining a prediction mode adopted by the currently decoded block in the slice of the intra prediction type
  • the bit field corresponding to the IBC mode identification information in the decoding block may be parsed. Obtain the value of the corresponding parameter of the IBC mode identification information.
  • Step 2603 if it is determined to adopt the IBC mode, step 2605 is performed; otherwise, step 2609 is performed;
  • Step 2605 Decode the decoding block using the IBC mode in the intra prediction type fragment by using a second decoding manner different from the first coding mode.
  • decoding the decoding block in the IBC mode in the fragment by using the second decoding manner includes: parsing a bit field corresponding to an IBC mode parameter in the decoding block, and obtaining at least one of the following IBC mode parameters.
  • Species block partitioning and reference block indication vectors.
  • the bit field corresponding to the IBC mode parameter in the coding unit CU is parsed to obtain an IBC mode parameter.
  • step 2607 after the decoding of the decoded block is completed, the sampled value of the corresponding pixel in the image of the slice is updated by using the restored sample value of the decoded position pixel in the currently decoded image of the decoded block, and the process ends.
  • the same padding method may be used to refill the sampled values of the uncoded pixel points in the image where the slice is located.
  • Step 2609 decoding blocks that use other modes in the intra prediction type fragment, and decoding according to a decoding method specified by a standard;
  • decoding blocks of the normal intra prediction mode in the intra prediction type fragment may also be decoding methods of these decoding blocks may be as specified in the standard.
  • the decoder provided in this embodiment includes:
  • the type analyzing device 50 is configured to parse the code stream to obtain slice type information
  • the first decoding device 60 is configured to decode the slice of the inter prediction type. When decoding, use the first decoding mode to set the image of the slice as the predicted reference image of the slice, and set the segment Decoding in the block using intra block copy (IBC) mode decoding;
  • IBC intra block copy
  • the second decoding device 70 is configured to decode the slice of the intra prediction type, and when decoding, decode the decoded block in the IBC mode in the slice using a second decoding method different from the first decoding mode.
  • the slice is located Like the predicted reference image set as the slice, it may be set to insert the image of the slice into the predicted reference image list as the predicted reference image of the slice.
  • the first decoding device 60 decodes the decoded block in the IBC mode in the slice by using the first decoding mode, and may be configured to decode the IBC mode in the slice by using a decoding mode of the inter prediction mode.
  • the block is decoded, and the IBC mode parameter is obtained by parsing the bit field corresponding to the mode parameter of the inter prediction mode.
  • the first decoding device 60 obtains the IBC mode parameter by parsing the bit field corresponding to the mode parameter of the inter prediction mode, and can be set to obtain the following IBC mode by analyzing the bit field corresponding to the prediction unit (PU) and the motion information parameter therein. At least one of the parameters: block partitioning, reference block indication vector, and reference image index.
  • the second decoding device 70 decodes the decoded block in the IBC mode in the slice by using a second decoding mode different from the first decoding mode, and may be configured to: parse the bit corresponding to the IBC mode parameter in the decoded block. Field, obtaining at least one of the following IBC mode parameters: block partitioning and reference block indication vector.
  • the second decoding device 70 parses the bit field corresponding to the IBC mode parameter in the decoding block, and may set the bit field corresponding to the IBC mode parameter in the coding unit CU to obtain an IBC mode parameter.
  • the second decoding device 70 may further be configured to: analyze a bit field corresponding to the IBC mode identification information in the decoding block, and obtain a value of the corresponding parameter of the IBC mode identification information.
  • the first decoding device 60 uses the first decoding mode, and when the image of the slice is set as the predicted reference image of the slice, it can be set.
  • the image in which the slice is located is directly used as a predicted reference image of the slice.
  • the first decoding device 60 uses the first decoding mode to decode the decoding block in the IBC mode in the slice of the inter prediction type, and may be configured to: parse the bit field corresponding to the IBC mode identification information in the CU, and obtain the IBC.
  • Mode identification information parsing the bit field corresponding to the IBC mode parameter in the PU, and obtaining the value of the IBC mode parameter; or parsing the bit field corresponding to the IBC mode identification information and the IBC mode parameter in the PU, and obtaining the IBC mode identification information and the IBC mode parameter. The value.
  • the embodiment provides an electronic device including an encoder and/or a decoder, wherein the electronic device can use the encoder of the first embodiment to generate a video code stream; and/or, using the decoder in the second embodiment To decode the video stream.
  • the electronic device of this embodiment may be a related code stream generating device and a receiving playing device in a video communication application, such as a mobile phone, a computer, a server, a set top box, a portable mobile terminal, a digital video camera, a television broadcasting system device, and the like.
  • a video communication application such as a mobile phone, a computer, a server, a set top box, a portable mobile terminal, a digital video camera, a television broadcasting system device, and the like.
  • This embodiment provides an image filling method, which is applied to a predictive encoding and/or decoding process.
  • the flow is shown in FIG. 9 and includes:
  • Step 310 Determine an image that is used as a reference when performing predictive coding on a coding unit and/or decoding a decoding unit;
  • the coding unit herein may be the coding block in the foregoing embodiment, but is not limited thereto, and the mode adopted by the coding block is not limited to any one, and may be an IBC mode, an inter prediction mode, a normal intra prediction mode, and the like. .
  • the image referred to herein may be the aforementioned predicted reference image, the image in which the slice is placed, or the like, but the present invention is not limited thereto.
  • Step 320 filling sample values of uncoded and/or undecoded position pixel points in the image. among them,
  • Filling in the sampled values of uncoded position pixels in the image including:
  • the decoding unit Before decoding the decoding unit, filling sample values of all or part of undecoded position pixel points in the image, wherein a part of the undecoded position pixel points in the image refers to a current decoding unit and an adjacent decoding unit thereof.
  • the method further includes: writing the corresponding filling mode information into the code stream, where the filling mode information includes at least one of the following information:
  • the indication information of the filling method used and related parameters When using adaptive padding, the indication information of the filling method used and related parameters;
  • the padding value of the sampled value of the uncoded position pixel used when no adaptive padding is used is used
  • the sampled values of the undecoded pixel points in the image are filled according to the filling mode information parsed from the code stream.
  • the method may further include: after the encoding unit is completed, updating the image by using a locally decoded restored sampling value of the encoded position pixel in the current encoded image. The sampled value of the corresponding pixel in the image, and refills the sampled value of the uncoded pixel in the image.
  • the method may further include: after the decoding unit is decoded, updating the corresponding image in the image with the restored sampling value of the decoded position pixel in the current decoded image.
  • the sampled value of the pixel is refilled with the sampled value of the undecoded pixel in the image.
  • an electronic device provided by this embodiment includes an encoder and/or a decoder, where:
  • the encoder includes:
  • Determining means 11 arranged to determine an image as a reference when predictive coding is performed on the coding unit
  • the code filling means 12 is arranged to fill the sampled values of the uncoded position pixel points in the image.
  • the decoder includes:
  • Determining means 21 arranged to determine an image as a reference when decoding the decoding unit
  • the decoding padding means 22 is arranged to fill the sampled values of the undecoded pixel points in the image.
  • the code filling device 12 fills the sampled values of the uncoded position pixel points in the image, and may be set as:
  • the partially uncoded position pixel point in the image refers to a current coding unit and an adjacent coding unit thereof.
  • the decoding and filling device 22 fills the sampled values of the undecoded pixel points in the image, and may be set as:
  • the decoding unit Before decoding the decoding unit, filling sample values of all or part of undecoded position pixel points in the image; wherein, the partially undecoded position pixel point in the image refers to a current decoding unit and an adjacent decoding unit thereof.
  • the method may further be configured to: write the corresponding fill mode information into the code stream, where the fill mode information includes at least the following information.
  • the indication information of the filling method used and related parameters When using adaptive padding, the indication information of the filling method used and related parameters;
  • the padding value of the sampled value of the uncoded position pixel used when no adaptive padding is used is used
  • the decoding and filling device 22 fills the sampled values of the undecoded pixel points in the image according to the filling mode information parsed from the code stream during the decoding process.
  • the code filling device 12 After the code filling device 12 fills the sampled values of the uncoded position pixel points in the image, it may also be set as:
  • the sample values of the corresponding pixel points in the image are updated with the locally decoded recovery sample values of the encoded position pixel points in the current coded image, and the uncoded position pixel points in the image are re-imaged.
  • the sampled values are filled.
  • the decoding and filling device 22 After the decoding and filling device 22 fills the sampled values of the undecoded pixel in the image, it may also be set as:
  • the sampled values of the corresponding pixel points in the image are updated with the recovered sample values of the decoded position pixel points in the currently decoded image, and the image is not decoded again.
  • the sampled values of the position pixels are filled.
  • the predictive encoding and decoding method and the corresponding encoding, decoding, and electronic device are provided by the embodiment of the present invention.
  • the predictive encoding method includes: setting a type of a slice; and when coding the slice of the inter prediction type, the segment is The image in which the slice is located is set as the predicted reference image of the slice, and the coded block in which the intra block copy IBC mode is used in the slice is encoded by using the first coding mode; when the slice of the intra prediction type is coded, A coding block using the IBC mode in the slice is coded using a second coding mode different from the first coding mode.
  • the embodiment of the present invention further provides a corresponding decoding method, a corresponding encoding, decoding, and an electronic device.
  • the embodiment of the present invention uses different encoding blocks for the inter-prediction type and the intra-prediction type.
  • the coding method is coded and optimized separately to avoid various problems caused by unified IBC and inter prediction modes.

Abstract

一种预测编、解码方法和相应的编、解码器和电子设备,所述预测编码方法包括:设置分片的类型;对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,对所述分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;对帧内预测类型的分片编码时,对所述分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。本发明还提供了相应的解码方法及相应的编、解码器和电子设备,本发明对帧间预测类型分片和帧内预测类型分片中采用IBC模式的编码块采用不同的编码方式进行编码,可以分别加以优化,避免统一结构带来的种种问题。

Description

一种预测编、解码方法和相应的编、解码器和电子设备 技术领域
本发明实施例涉及视频编解码领域,尤指一种预测编、解码方法和相应的编、解码器和电子设备。
背景技术
正在制定的基于高性能视频编码(HEVC,H.265/High Efficiency Video Coding)标准扩展的屏幕内容编码(SCC,Screen Content Coding)标准中,采用了帧内块复制(IBC,Intra Block Copying)模式。与传统的使用当前图像内当前块边界处相邻块已恢复像素预测当前块内像素值的方法不同,IBC允许使用当前图像内已经恢复出的一个二维像素块作为当前块的预测块,同时,IBC使用预测块与当前块之间的相对偏移量来定位预测参考块,该偏移量称之为块复制矢量(BV,Block copying Vector)。
IBC与H.265/HEVC标准中帧间预测模式相似,其不同之处在于IBC使用当前图像中部分解码恢复的像素点作为预测参考,而帧间预测模式采用按解码顺序在当前图像之前已经解码恢复的图像中的像素作为预测参考。类比帧间预测模式,IBC可以使用相同或相似的块划分方法,IBC的BV信息可以使用与帧间预测模式的运动矢量(MV,Motion Vector)相同或相似的预测编码方法。
考虑到IBC与H.265/HEVC已有帧间预测模式之间的相似性,为了避免对采用IBC模式的编码块定义一种全新的编、解码方法而带来的冗余,JCTVC-R0100和JCTVC-R0190均提出在SCC标准扩展中使用统一结构的IBC与帧间预测模式。JCTVC-R0100提出将当前解码图像添加到参考图像列表(reference picture list)的列表0(List 0)的最后一个位置,并将其标记为“长期参考图像(Long-term reference picture)”,这样可以使用已有帧间预测模式的块划分、MV预测编码方法对IBC的块划分和BV进行编码,同时使用帧间预测模式的语法组织方法将IBC的相关信息写入码流。JCTVC-R0190 提出将IBC作为一种帧间预测模式来处理,在帧内分片(I-slice)中,使用“帧间预测块”(即pred_mode_flag取值等于0)来表示IBC块;在帧间分片(P-slice或B-slice)中,使用“列表0参考图像索引值等于1的帧间预测块”(即pred_mode_flag取值等于0且ref_idx_l0取值等于1)来表示IBC块,这样,可以使用已有帧间预测模式的块划分、MV预测编码方法对IBC的块划分和BV进行编码,同时使用帧间预测模式的语法组织方法将IBC的相关信息写入码流。
上述方法实现了统一结构的IBC和帧间预测模式,直接将帧间预测模式上使用的预测块划分、运动信息编码等高效预测编码方法直接应用在IBC上,获得了较大的编码效率的提升。尽管如此,上述方法还是存在如下缺点:
第一,统一IBC与帧间预测模式的方法无法定义全帧内档次(All Intra Profile)。对于全帧内档次而言,视频序列的所有图像均使用帧内预测编码方法进行编码,不需要使用和构造参考图像列表。统一IBC与帧间预测模式的方法需要为全帧内档次增加参考图像列表,在档次定义以及假设参考解码器、一致性测试、码流工作点等多个方法增加针对额外的参考图像列表的相关说明,增加了全帧内档次的复杂度。在编码器设计上,无法直接复用已有的H.265/HEVC全帧内编码器的高层架构。
第二,即使对帧内编码图像,在IBC开启的情况下,仍需要构造和使用参考图像列表,因此,在使用IBC的情况下,对于随机接入图像,需要增加额外的对参考图像列表和解码图像缓冲区的操作。
第三,在统一IBC与帧间预测模式的方法的基础上,由于完全使用特殊帧间预测模式参数(如特定的参考图像)来声明IBC模式,因此,对IBC模式的改进需要修改全部帧间预测模式参数的语法组织结构和声明方式,增加额外的条件判断,以区分处理IBC与帧间预测模式,这样增加了额外的处理复杂度。特别是,对帧内编码图像的IBC模式进行改进时,需要对从不用于帧内编码图像的帧间预测编码模式进行调整,增加相关条件判断及对应的处理流程。
第四,目前的统一IBC与帧间预测模式方法同时应用于帧内预测编码图 像和帧间预测编码图像,这样就无法分别地针对帧内预测编码图像和帧间预测编码图像的特点对IBC模式进行改进和优化。
此外,在目前的预测编码和解码的过程中,预测参考图像中未编码和未解码位置像素点的采样值均用于构造IBC模式的参考块,因此,IBC模式参考块构造过程的性能还有待提升。
发明内容
为了解决上述技术问题,本发明实施例提供了一种预测编码方法及相应的解码方法,以及采用上述方法的编码器、解码器和电子设备,能够避免由于统一IBC与帧间预测模式所带来的技术问题。
本发明提供了一种预测编码方法,应用于编码器,包括:
设置分片的类型;
对帧间预测类型的分片编码时,将分片所在图像设置为分片的预测参考图像,对分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;
对帧内预测类型的分片编码时,对分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。
可选地,所述对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
可选地,所述对帧间预测类型的所述分片中采用IBC模式的编码块,使用第一编码方式进行编码,包括:使用帧间预测模式的模式参数编码方式编码IBC模式参数。
可选地,所述使用帧间预测模式的模式参数编码方式编码IBC模式参数,包括:使用预测单元PU的运动信息编码方法编码IBC模式参数;
编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
可选地,所述对帧内预测类型的所述分片中采用IBC模式的编码块,使用第二编码方式进行编码,包括:
在所述编码块直接编码IBC模式参数;
编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指示矢量。
可选地,所述在编码块直接编码IBC模式参数,包括:在编码单元CU直接编码所述IBC模式参数。
可选地,所述在编码块直接编码IBC模式参数之前,还包括:编码IBC模式标识信息。
可选地,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像直接作为所述分片的预测参考图像;
对帧间预测类型的所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,包括:
使用编码单元CU编码IBC模式标识信息,使用预测单元PU编码IBC模式参数信息;或者,
使用PU编码IBC模式标识信息和IBC模式参数信息。
本发明实施例还提供了一种解码方法,应用于解码器,包括:
解析码流,获得分片的类型信息;
对帧间预测类型的分片解码时,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,并对所述分片中采用帧内块复制(IBC)模式的解码块进行解码;
对帧内预测类型的分片解码时,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
可选地,所述使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
可选地,所述使用第一解码方式,对所述分片中采用IBC模式的解码块进行解码,包括:使用帧间预测模式的解码方式对所述分片中采用IBC模式的解码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数。
可选地,所述通过解析帧间预测模式的模式参数对应的比特字段;
获得IBC模式参数,包括:通过解析预测单元(PU)及其中运动信息参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
可选地,所述使用不同于第一编码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码,包括:解析所述解码块中IBC模式参数对应的比特字段;获得以下IBC模式参数中的至少一种:块划分和参考块指示矢量。
可选地,解析所述解码块中IBC模式参数对应的比特字段,包括:解析编码单元CU中IBC模式参数对应的比特字段,获得IBC模式参数。
可选地,解析所述解码块中IBC模式参数对应的比特字段之前,还包括:解析解码块中IBC模式标识信息对应的比特字段,获得IBC模式标识信息对应参数的取值。
可选地,所述使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像直接作为所述分片的预测参考图像;
所述对帧间预测类型的所述分片中采用IBC模式的解码块,使用第一解码方式进行解码,包括:
解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息;解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者
解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC模式标识信息和IBC模式参数的取值。
本发明实施例又提供了一种编码器,包括:
类型设置装置,设置为设置分片的类型;
第一编码装置,设置为对帧间预测类型的分片编码,编码时,将所述分片所在图像设置为所述分片的预测参考图像,对所述分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;
第二编码装置,设置为对帧内预测类型的分片编码,编码时,对所述分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。
可选地,所述第一编码装置对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
可选地,所述第一编码装置对帧间预测类型的所述分片中采用IBC模式的编码块,使用第一编码方式进行编码,设置为:使用帧间预测模式的模式参数编码方式编码IBC模式参数。
可选地,所述第一编码装置使用帧间预测模式的模式参数编码方式编码IBC模式参数,设置为:使用预测单元PU的运动信息编码方法编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
可选地,所述第二编码装置对帧内预测类型的所述分片中采用IBC模式的编码块,使用第二编码方式进行编码,设置为:在编码块直接编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指示矢量。
可选地,所述第二编码装置在编码块直接编码IBC模式参数,设置为:在编码单元CU直接编码IBC模式参数。
可选地,所述第二编码装置在编码块直接编码IBC模式参数之前,还设置为:编码IBC模式标识信息。
可选地,所述第一编码装置将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像直接作为所述分片的预测参考图像;
所述第一编码装置对帧间预测类型的所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,设置为:
使用CU编码IBC模式标识信息,使用预测单元(PU)编码IBC模式参数信息;或者,
使用PU编码IBC模式标识信息和IBC模式参数信息。
本发明实施例还提供了一种解码器,包括:
类型解析装置,设置为解析码流,获得分片类型信息;
第一解码装置,设置为对帧间预测类型的分片解码,解码时,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,并对所述分片中采用帧内块复制(IBC)模式的解码块进行解码;
第二解码装置,设置为对帧内预测类型的分片解码,解码时,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
可选地,所述第一解码装置对帧间预测类型的分片解码时,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
可选地,所述第一解码装置使用第一解码方式,对所述分片中采用IBC模式的解码块进行解码,设置为:使用帧间预测模式的解码方式对所述分片中采用IBC模式的解码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数。
可选地,所述第一解码装置通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数,设置为:通过解析PU及其中运动信息参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
可选地,所述第二解码装置使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码,设置为:解析所述解码块中IBC模式参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划 分和参考块指示矢量。
可选地,所述第二解码装置解析所述解码块中IBC模式参数对应的比特字段,设置为:解析编码单元CU中IBC模式参数对应的比特字段,获得IBC模式参数。
可选地,所述第二解码装置解析所述解码块中IBC模式参数对应的比特字段之前,还设置为:解析解码块中IBC模式标识信息对应的比特字段,获得IBC模式标识信息对应参数的取值。
可选地,所述第一解码装置使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像直接作为所述分片的预测参考图像;
所述第一解码装置使用第一解码方式,对帧间预测类型的所述分片中采用IBC模式的解码块进行解码,具体设置为:
解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息;解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者
解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC模式标识信息和IBC模式参数的取值。
本发明实施例再提供了一种电子设备,包括编码器和/或解码器,其中:
所述编码器采用如上所述的任一种编码器;
所述解码器采用如上所述的任一种解码器。
采用上述方案,对帧间预测类型分片和帧内预测类型分片中采用IBC模式的编码块采用不同的编码方式进行编码,避免了统一结构带来的种种问题,并取得了以下的一种或多种技术效果:
分别针对帧内预测编码图像和帧间预测编码图像对IBC模式进行了改进和优化。对IBC模式的改进无需修改帧间预测模式参数的语法组织结构和声明方式,无需增加额外的条件判断。对帧内编码图像的IBC模式进行改进时,无需对从不用于帧内编码图像的帧间预测编码模式进行调整。
对全帧内档次,无需增加参考图像列表,在档次定义以及假设参考解码器、一致性测试、码流工作点等多个方法无需增加针对额外的参考图像列表的相关说明,简化了全帧内档次的复杂度。
对帧内编码图像,在IBC开启时,无需构造和使用参考图像列表,对于随机接入图像,无需增加额外的对参考图像列表和解码图像缓冲区的操作。
对于帧间预测编码图像,IBC模式实现了采用与帧间预测模式一致的结构,具有统一结构带来的种种优点。
为了提高编、解码的性能,本发明实施例还提供了一种图像填充方法及相应的电子设备。
本发明实施例提供了一种图像填充方法,应用于预测编码和/或解码过程,包括:
确定对编码单位做预测编码和/或对解码单位做解码时作为参考的图像;
对所述图像中未编码和/或未解码位置像素点的采样值进行填充。
可选地,对所述图像中未编码位置像素点的采样值进行填充,包括:
对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充,其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
对所述图像中未解码位置像素点的采样值进行填充,包括:
对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充,其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
可选地,在预测编码过程中,对所述图像中未编码位置像素点的采样值进行填充之后,还包括:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
是否使用自适应填充的指示信息;
使用自适应填充时,所使用的填充方式的指示信息及相关参数;
不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
可选地,对所述图像中未编码位置像素点的采样值进行填充之后,还包括:在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
可选地,对所述图像中未解码位置像素点的采样值进行填充之后,还包括:在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码位置像素点的采样值进行填充。
本发明实施例还提供了一种电子设备,包括编码器和/或解码器,其中:
所述编码器包括:
确定装置,设置为确定对编码单位做预测编码时作为参考的图像;
对所述图像中未编码和/或未解码位置像素点的采样值进行填充。
编码填充装置,设置为对所述图像中未编码位置像素点的采样值进行填充;
所述解码器包括:
确定装置,设置为确定对解码单位做解码时作为参考的图像;
解码填充装置,设置为对所述图像中未解码位置像素点的采样值进行填充。
可选地,所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充,具体设置为:
对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充;其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
所述解码填充装置对所述图像中未解码位置像素点的采样值进行填充,具体设置为:
对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充;其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
可选地,所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充之后,还设置为:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
是否使用自适应填充的指示信息;
使用自适应填充时,所使用的填充方式的指示信息及相关参数;
不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
所述解码填充装置在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
可选地,所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充之后,还设置为:
在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
可选地,所述解码填充装置对所述图像中未解码位置像素点的采样值进行填充之后,还设置为:
在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码 位置像素点的采样值进行填充。
本发明实施例通过对预测参考图像中未编码和/或未解码位置像素点的采样值进行填充,提高了预测的准确性,从而提升了编码、解码的性能。
附图概述
为了清楚说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单的介绍。下面描述中的附图是示例性的,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它的附图。
图1是本发明实施例的编码方法的流程图;
图2是本发明实施例中对帧间预测类型的分片中的编码块编码的流程图;
图3是本发明实施例中对帧内预测类型的分片中的编码块编码的流程图;
图4是本发明实施例编码器的组成结构示意图;
图5是本发明实施例的解码方法的流程图;
图6是本发明实施例中对帧间预测类型的分片中的编码块解码的流程图;
图7是本发明实施例中对帧内预测类型的分片中的编码块解码的流程图;
图8是本发明实施例中解码器的组成结构示意图;
图9是本发明实施例中填充方法的流程图;
图10是本发明实施例电子设备中编码器的组成结构示意图;
图11是本发明实施例电子设备中解码器的组成结构示意图。
本发明的较佳实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行 清楚、完整的描述。所描述的实施例是本发明的部分实施例,而不是全部实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例,都属于本发明保护的范围。
在H.265/HEVC标准扩展的SCC标准中,分片(Slice)是一帧图像中的独立解码单位,一帧图像包含一个或多个分片,一个分片又包含一个或多个编码块。文中,编码块是一个以下块单元至少之一:编码树块(Coding Tree Unit,CTU)、编码单元(Coding Unit)、预测单元(Prediction Unit,PU)、变换单元(Transform Unit,TU)。解码时,则将上述块单元称为解码块。
在分片层,分片类型包括帧内预测类型和帧间预测类型两类。帧内预测类型的分片即I类型分片,帧间预测类型的分片可以是P类型分片或B类型分片。在块层,I类型分片中的编码块/解码块可以采用IBC模式或普通帧内预测模式,但不会采用帧间预测模式。而P类型分片和B类型分片中的编码块/解码块可以采用IBC模式、普通的帧内预测模式或帧间预测模式。
本发明主要针对IBC模式的编码块/解码块如何编码/解码进行研究,针对帧间预测类型分片和帧内预测类型分片中IBC模式的编码块/解码块,按照不同的编码方式进行编码/解码。
本实施例提供一种预测编码方法及相应的编码器。
本实施例的预测编码方法,对一分片的编码过程如图1所示,包括:
步骤110,为当前编码的分片设置分片类型;
编码器可以根据预先设定的预测结构信息,设置图像中分片的分片类型,并将设置的分片类型信息写入码流。分片类型信息可以由分片划分头信息(Slice Segment Header)中的slice_type字段来指示。
步骤120,如设置的分片类型是帧间预测类型,执行步骤130,否则执行步骤160;
步骤130,将所述分片所在图像设置为所述分片的预测参考图像;
本实施例中,是将所述分片所在图像插入预测参考图像列表,作为所述分片自身的预测参考图像。
同一帧图像中的各个分片所使用的预测参考图像列表是相同的。编码器可以将当前编码图像放置在预测参考图像列表中的固定位置,也可以自适应地调整当前编码图像在预测参考图像列表中的位置。例如,编码器可以设置、使用参考图像列表的调整信息来调整当前编码图像在参考图像列表中的放置位置,并将参考图像列表的调整信息写入码流。
步骤140,对所述预测参考图像中全部或部分未编码位置像素点的采样值进行填充;
该步骤可选。为了提高预测的准确性,提升编码的性能,本实施例可以进一步对预测参考图像进行填充处理。
编码器可以为预测参考图像中全部未编码位置的像素点设置采样值;也可以只为部分未编码位置像素点的采样值进行填充。其中,部分未编码位置像素点的采样值可以指当前编码块及其相邻编码块中的未编码位置像素点,或者指MV或BV指向的预测块范围内的未编码位置像素点。
具体填充方式,可以分为不使用自适应填充和使用自适应填充两大类。不使用自适应填充的一类方式,如可以将预测参考图像中未解码位置像素点的采样值设置为默认预设值,例如,最大容许采样值的1/2、0值和最大值等。使用自适应填充的一类方式,如可以将预测参考图像中未编码位置像素点的采样值设置为最近编码的编码块像素点采样值的均值或指定像素点的采样值,或设置为各列方向上最后一个已编码像素点的采样值。又如,将预测参考图像中未编码位置像素点的采样值设置为外插值滤波器的输出值,该外插值滤波器的输入是已编码像素点的采样值,该滤波器可以是沿某个指定方向(如列方向)的一维滤波器,也可以是二维滤波器;所述滤波器可以是使用固定系数的外插值滤波器,也可以是自适应滤波器;编码器将滤波器形状、系数等参数信息写入码流。编码器可以使用编码器优化模块(如常用的基于率失真准则设计的编码器控制模块)确定编码过程中所使用的具体参数。
编码器和解码器之间可以约定使用的填充方式,也可以将使用的填充方式信息写入码流,所述填充方式信息可以包括以下信息中的至少一种:
是否使用自适应填充的指示信息;
使用自适应填充时,所使用的填充方式的指示信息及相关参数;
不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
编码器可以将上述填充方式信息写入码流中的以下一个或多个信息单元:参数集、分片头信息、编码树块(CTU)和CU。在解码过程中,可以根据从码流中解析出的所述填充方式信息对所述预测参考图像中未解码位置像素点的采样值进行填充。
步骤150,对帧间预测类型的分片中的编码块依次编码,其中,对所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,结束本流程。
步骤160,对帧内预测类型的分片中的编码块依次编码,其中,对所述分片中采用IBC模式的编码块,按照不同于第一编码方式的第二编码方式进行编码。
在步骤160之前,编码器也可以对帧内预测类型分片所在图像(缓存的图像)进行填充,填充方式可以采用步骤140中描述的各种方式。
图1所示的步骤150中,编码器会依次编码分片中各CTU的码流,对每一CTU,依次编码CTU中各分块(包括CU、PU、TU中的至少之一)的码流。对帧间预测类型的分片中的当前编码块编码时,如图3所示,具体包括:
步骤1501,确定帧间预测类型的分片中当前编码块采用的预测模式;
编码器可以使用编码器优化模块确定对当前编码块使用普通的帧内预测模式、IBC模式或帧间预测模式。
步骤1503,如采用IBC模式,执行步骤1505,否则,执行步骤1509;
步骤1505,对帧间预测类型分片中采用IBC模式的编码块,使用第一编码方式进行编码;
使用第一编码方式进行编码,可以包括:使用帧间预测模式的模式参数编码方式编码IBC模式参数。例如,可以使用预测单元PU的运动信息编码方法编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。本实施例采用IBC模式的编码块,可以使用帧间预测模式标识,而不编码专门的IBC模式标识信息。解 码器根据帧间预测模式标识和指向其自身所在图像的参考图像索引,可以确定其为IBC模式的解码块。
本实施例对IBC的预测块划分方式没有限定,可以是传统的矩形、正方形块划分方式,也可以是Nx1或1xN的串划分。串匹配(String Matching)方法是IBC使用Nx1或1xN的串划分方式时的一个特例。参考块指示矢量表示参考块与当前编码块之间的相对位置偏移,即BV。对于参考块指示矢量,可以直接对其进行编码;也可以使用参考块指示矢量参数表示参考块指示矢量,并对所述参考块指示矢量参数进行编码。参考块指示矢量参数可以包括以下参数至少之一:BV预测值索引序号、BV预测差。可选地,编码器可以将BV的动态范围限定在当前编码块所在分片的范围内。
编码器根据IBC模式参数构造当前编码块中像素点采样值的预测值。编码器可使用一个或多个BV指向的参考块,按照IBC模式块划分方式,将所述一个或多个参考块组合成与当前编码块相同形状的预测块,将该预测块中包含的像素点采样值作为当前块的预测值,或者将该所述预测块中的像素点采样值进行加权处理后作为IBC模式参考块。
步骤1507,对编码块编码完成后,以该编码块当前编码图像中已编码位置像素点的本地解码恢复采样值,更新所述预测参考图像中相应像素点的采样值,结束本流程。
本步骤中,在更新所述预测参考图像中相应像素点的采样值之后,还可以进一步包括:采用相同的填充方式对所述预测参考图像中未编码位置像素点的采样值进行重新填充。
步骤1509,对帧间预测类型分片中采用其他模式的编码块,按照标准规定的编码方式进行编码。
帧间预测类型分片中还可能存在帧间预测模式的编码块和普通帧内预测模式的编码块,这些编码块的编码方法遵循标准中的规定即可。
在本实施例的一个变例中,对于帧间预测类型的分片,将分片所在图像直接作为所述分片的预测参考图像,不再插入预测参考图像列表。而对分片中采用IBC模式的编码块使用第一编码方式进行编码,可以包括:使用编码 单元(CU)编码IBC模式标识信息,使用预测单元(PU)编码IBC模式参数信息;或者使用预测单元(PU)编码IBC模式标识信息和IBC模式参数信息。
图1所示的步骤160中,编码器会依次编码分片中各CTU的码流,对每一CTU,依次编码CTU中各分块的码流。对帧内预测类型的分片中的当前编码块编码时,如图4所示,具体包括:
步骤1601,确定帧内预测类型的分片中当前编码块采用的预测模式;
编码器可以使用编码器优化模块确定对当前编码块使用普通的帧内预测模式或IBC模式。
步骤1603,如确定采用IBC模式,执行步骤1605,否则,执行步骤1609;
步骤1605,对帧内预测类型分片中采用IBC模式的编码块,使用第二编码方式进行编码;
使用第二编码方式进行编码,可以包括:在编码块直接编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指示矢量。例如可以在编码单元CU直接编码IBC模式参数。在编码块直接编码IBC模式参数之前,可以编码IBC模式标识信息,可使用CU编码IBC模式标识信息,但不局限于此,也可以使用PU编码IBC模式标识信息。
步骤1607,对编码块编码完成后,以该编码块当前编码图像中已编码位置像素点的本地解码恢复采样值,更新所述分片所在图像中相应像素点的采样值,结束本流程。
在更新所述分片所在图像中相应像素点的采样值之后,还可以采用相同的填充方式对所述分片所在图像中未编码位置像素点的采样值重新填充。
步骤1609,对帧内预测类型分片中采用其他模式的编码块,按照标准规定的编码方式进行编码;
帧间预测类型分片中还可能存在普通帧内预测模式的编码块,这些编码块的编码方法遵循标准中的规定即可。
相应地,如图4所示,本实施例提供的编码器包括:
类型设置装置10,设置为设置分片的类型;
第一编码装置20,设置为对帧间预测类型的分片编码,编码时,将所述分片所在图像设置为所述分片的预测参考图像,对所述分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;
第二编码装置30,设置为对帧内预测类型的分片编码,编码时,对所述分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。
上述第一编码装置20对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,可以设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
上述第一编码装置20对帧间预测类型的所述分片中采用IBC模式的编码块,使用第一编码方式进行编码,可以设置为:使用帧间预测模式的模式参数编码方式编码IBC模式参数。
上述第一编码装置20使用帧间预测模式的模式参数编码方式编码IBC模式参数,可以设置为:使用预测单元PU的运动信息编码方法编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
上述第二编码装置30对帧内预测类型的所述分片中采用IBC模式的编码块,使用第二编码方式进行编码,可以设置为:在编码块直接编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指示矢量。
上述第二编码装置30在编码块直接编码IBC模式参数,可以设置为:在编码单元CU直接编码IBC模式参数。
上述所述第二编码装置在编码块直接编码IBC模式参数之前,还可以设置为:编码IBC模式标识信息。
作为本实施例的一个变例。对于帧间预测类型的分片,第一编码装置20在将所述分片所在图像设置为所述分片的预测参考图像时,可以设置为将所 述分片所在图像直接作为所述分片的预测参考图像。而第一编码装置20对帧间预测类型的所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,可以设置为使用编码单元(CU)编码IBC模式标识信息,使用预测单元(PU)编码IBC模式参数信息;或者,使用预测单元(PU)编码IBC模式标识信息和IBC模式参数信息。
本实施例提供一种与上述编码方法和编码器实施例相对应的解码方法及相应的解码器。
本实施例的解码方法,应用于解码器,其对一分片的解码过程如图5所示,包括:
步骤210,解析分片层码流,获得当前解码分片的分片类型信息;
分片类型信息指的是分片划分头信息(Slice Segment Header)中由slice_type字段给出的分片类型信息。
步骤220,如分片类型是帧间预测类型分片,则执行步骤230;否则,执行步骤260;
步骤230,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像;
本实施例中,解码器构造参考图像列表,将所述分片所在图像插入参考图像列表,作为所述分片的预测参考图像。同一帧图像中的各个分片所使用的预测参考图像列表相同。解码器可将所述分片所在图像放置在参考图像列表中的固定位置,也可自适应地调整当前解码图像在参考列表中的位置。
步骤240,对所述预测参考图像中全部或部分未编码位置像素点的采样值进行填充;
该步骤可选。为了提高预测的准确性,提升编码的性能,本实施例还可以进一步对预测参考图像进行填充处理。
解码器可以为预测参考图像中全部未解码位置的像素点设置采样值;也可以只为部分未解码位置像素点的采样值进行填充。其中,部分未解码位置像素点的采样值可以指当前解码块及其相邻解码块中的未解码位置像素点, 或者指MV或BV指向的预测块范围内的未编码位置像素点。
在具体填充方式上,可以使用步骤140中描述的几种填充方式,这里不再赘述。如编码器将使用的填充方式信息写入码流,则解码器可以根据从码流中解析出的填充方式信息对预测参考图像中未解码位置像素点的采样值进行填充。
步骤250,对帧间预测类型分片中的解码块依次解码,其中,使用第一解码方式对所述分片中采用IBC模式的解码块进行解码,结束本流程;
步骤260,对帧内预测类型分片中的解码块依次解码,其中,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
另,在步骤260之前,解码器也可以进一步对帧内预测类型分片所在图像(缓存的图像)进行填充,填充方式可以采用步骤240中描述的各种方式。
图5所示的步骤250中,解码器会依次解析分片中各CTU的码流,对每一CTU,依次解析CTU中各分块(包括CU、PU、TU中的至少之一)的码流。对帧间预测类型分片中的当前解码块解码时,如图6所示,包括:
步骤2501,确定帧间预测类型的分片中当前解码块采用的预测模式;
“解码方式”包括模式相关参数在码流里面的表示方法和编码位置。在帧间预测类型的分片中,对于使用参考图像索引隐含标识IBC模式的情况,在解析到参考图像索引时才能判断出是否是IBC模式的解码块,此时IBC模式参数中块划分方式、参考图像索引序号已经获得。如果IBC模式在帧间预测类型分片中使用“先标志(flag)后参数”的“显式”码流组织方式,解码器可以先确定是一个IBC模式的解码块再对相关模式参数解码。其中的flag可以是IBC模式标识。
步骤2503,如采用IBC模式,执行步骤2505,否则,执行步骤2509;
步骤2505,使用第一解码方式对帧间预测类型分片中采用IBC模式的解码块进行解码,结束本流程;
本实施例使用帧间预测模式的解码方式对所述分片中采用IBC模式的解 码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数。例如,可以通过解析预测单元(PU)及其中运动信息参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
解码器根据IBC模式参数构造当前解码块中采样点取值的预测值。
步骤2507,对解码块解码完成后,以该解码块当前解码图像中已解码位置像素点的恢复采样值更新所述预测参考图像中相应像素点的采样值,结束;
本步骤更新所述预测参考图像中相应像素点的采样值之后,还可以进一步包括:采用相同的填充方式对所述预测参考图像中未解码位置像素点的采样值进行重新填充。
步骤2509,对帧间预测类型分片中采用其他模式的解码块,按照标准规定的解码方式进行解码。
帧间预测类型分片中还可能存在帧间预测模式的解码块和普通帧内预测模式的解码块,这些解码块的解码方法遵循标准中的规定即可。
在本实施例的一个变例中,对于帧间预测类型的分片,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像时,可以将所述分片所在图像直接作为所述分片的预测参考图像。对帧间预测类型的所述分片中采用IBC模式的解码块,使用第一解码方式进行解码,包括:
解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息,解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者
解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC模式标识信息和IBC模式参数的取值。
图5所示的步骤260中,解码器会依次解码分片中各CTU的码流,对每一CTU,依次解码CTU中各分块的码流。对帧内预测类型分片中的当前解码块解码时,如图7所示,包括:
步骤2601,确定帧内预测类型的分片中当前解码块采用的预测模式;
本步骤中,可以通过解析解码块中IBC模式标识信息对应的比特字段, 获得IBC模式标识信息对应参数的取值。
步骤2603,如确定采用IBC模式,执行步骤2605,否则,执行步骤2609;
步骤2605,使用不同于第一编码方式的第二解码方式对帧内预测类型分片中采用IBC模式的解码块进行解码;
本实施例中,使用第二解码方式对所述分片中采用IBC模式的解码块进行解码,包括:解析所述解码块中IBC模式参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分和参考块指示矢量。例如,解析编码单元CU中IBC模式参数对应的比特字段,获得IBC模式参数。
步骤2607,对解码块解码完成后,以该解码块当前解码图像中已解码位置像素点的恢复采样值更新所述分片所在图像中相应像素点的采样值,结束本流程。
在更新所述分片所在图像中相应像素点的采样值之后,还可以采用相同的填充方式对所述分片所在图像中未编码位置像素点的采样值重新填充。
步骤2609,对帧内预测类型分片中采用其他模式的解码块,按照标准规定的解码方式进行解码;
帧内预测类型分片中还可能存在普通帧内预测模式的解码块,这些解码块的解码方法遵循标准中的规定即可。
相应地,如图8所示,本实施例提供的解码器包括:
类型解析装置50,设置为解析码流,获得分片类型信息;
第一解码装置60,设置为对帧间预测类型的分片解码,解码时,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,并对所述分片中采用帧内块复制(IBC)模式的解码块进行解码;
第二解码装置70,设置为对帧内预测类型的分片解码,解码时,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
上述第一解码装置60对帧间预测类型的分片解码时,将所述分片所在图 像设置为所述分片的预测参考图像,可以设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
上述第一解码装置60使用第一解码方式,对所述分片中采用IBC模式的解码块进行解码,可以设置为:使用帧间预测模式的解码方式对所述分片中采用IBC模式的解码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数。
上述第一解码装置60通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数,可以设置为:通过解析预测单元(PU)及其中运动信息参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
上述第二解码装置70使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码,可以设置为:解析所述解码块中IBC模式参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分和参考块指示矢量。
上述第二解码装置70解析所述解码块中IBC模式参数对应的比特字段,可以设置为:解析编码单元CU中IBC模式参数对应的比特字段,获得IBC模式参数。
上述第二解码装置70解析所述解码块中IBC模式参数对应的比特字段之前,还可以设置为:解析解码块中IBC模式标识信息对应的比特字段,获得IBC模式标识信息对应参数的取值。
作为本实施例的一个变例,对于帧间预测类型的分片,第一解码装置60使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像时,可以设置为将所述分片所在图像直接作为所述分片的预测参考图像。第一解码装置60使用第一解码方式,对帧间预测类型的所述分片中采用IBC模式的解码块进行解码时,可以设置为:解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息;解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者,解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC模式标识信息和IBC模式参数的取值。
本实施例提供一种电子设备,包括编码器和/或解码器,其中,所述电子设备可使用实施例一的编码器来产生视频码流;和/或,使用实施例二中的解码器来解码视频码流。
本实施例的电子设备可以是视频通信应用中相关码流生成设备和接收播放设备,例如,手机、计算机、服务器、机顶盒、便携式移动终端、数字摄像机,电视广播系统设备等。
本实施例提供一种图像填充方法,应用于预测编码和/或解码过程,其流程如图9所示,包括:
步骤310,确定对编码单位做预测编码和/或对解码单位做解码时作为参考的图像;
此处的编码单位可以是前述实施例中的编码块但不局限于此,编码块采用的模式也不局限于任何一种,可以是IBC模式,帧间预测模式、普通帧内预测模式等等。此处作为参考的图像,可以是前述的预测参考图像,分片所在图像等,但本发明也不局限于此。
步骤320,对所述图像中未编码和/或未解码位置像素点的采样值进行填充。其中,
对所述图像中未编码位置像素点的采样值进行填充,包括:
对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充,其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
对所述图像中未解码位置像素点的采样值进行填充,包括:
对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充,其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
可选地,在预测编码过程中,对所述图像中未编码位置像素点的采样值 进行填充之后,还包括:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
是否使用自适应填充的指示信息;
使用自适应填充时,所使用的填充方式的指示信息及相关参数;
不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
相应地,在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
对所述图像中未编码位置像素点的采样值进行填充之后,还可以包括:在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
对所述图像中未解码位置像素点的采样值进行填充之后,还可以包括:在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码位置像素点的采样值进行填充。
相应地,本实施例提供的一种电子设备,包括编码器和/或解码器,其中:
如图10所示,所述编码器包括:
确定装置11,设置为确定对编码单位做预测编码时作为参考的图像;
编码填充装置12,设置为对所述图像中未编码位置像素点的采样值进行填充。
如图11所示,所述解码器包括:
确定装置21,设置为确定对解码单位做解码时作为参考的图像;
解码填充装置22,设置为对所述图像中未解码位置像素点的采样值进行填充。
所述编码填充装置12对所述图像中未编码位置像素点的采样值进行填充,可以设置为:
对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充;其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
所述解码填充装置22对所述图像中未解码位置像素点的采样值进行填充,可以设置为:
对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充;其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
所述编码填充装置12对所述图像中未编码位置像素点的采样值进行填充之后,还可以设置为:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
是否使用自适应填充的指示信息;
使用自适应填充时,所使用的填充方式的指示信息及相关参数;
不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
相应地,所述解码填充装置22在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
所述编码填充装置12对所述图像中未编码位置像素点的采样值进行填充之后,还可以设置为:
在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
所述解码填充装置22对所述图像中未解码位置像素点的采样值进行填充之后,还可以设置为:
在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码 位置像素点的采样值进行填充。
本领域普通技术人员可以理解上述方法中的全部或部分步骤可通过程序来指令相关硬件完成,所述程序可以存储于计算机可读存储介质中,如只读存储器、磁盘或光盘等。可选地,上述实施例的全部或部分步骤也可以使用一个或多个集成电路来实现。相应地,上述实施例中的各模块/单元可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。本发明不限制于任何特定形式的硬件和软件的结合。
本发明还可有其他多种实施例,在不背离本发明精神及其实质的情况下,熟悉本领域的技术人员当可根据本发明作出各种相应的改变和变形,但这些相应的改变和变形都属于本发明所附的权利要求的保护范围。
工业实用性
本发明实施例提出的预测编、解码方法和相应的编、解码器和电子设备,所述预测编码方法包括:设置分片的类型;对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,对所述分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;对帧内预测类型的分片编码时,对所述分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。本发明实施例还提供了相应的解码方法及相应的编、解码器和电子设备,本发明实施例对帧间预测类型分片和帧内预测类型分片中采用IBC模式的编码块采用不同的编码方式进行编码,分别加以优化,避免了由于统一IBC与帧间预测模式所带来的的种种问题。

Claims (43)

  1. 一种预测编码方法,应用于编码器,包括:设置分片的类型;
    对帧间预测类型的分片编码时,将分片所在图像设置为分片的预测参考图像,对分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;
    对帧内预测类型的分片编码时,对分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。
  2. 如权利要求1所述的预测编码方法,其特征在于:所述对帧间预测类型的分片编码时,将分片所在图像设置为分片的预测参考图像包括:
    将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
  3. 如权利要求1或2所述的预测编码方法,其特征在于:所述对帧间预测类型的所述分片中采用IBC模式的编码块,使用第一编码方式进行编码,包括:使用帧间预测模式的模式参数编码方式编码IBC模式参数。
  4. 如权利要求3所述的预测编码方法,其特征在于:所述使用帧间预测模式的模式参数编码方式编码IBC模式参数,包括:
    使用预测单元PU的运动信息编码方法编码IBC模式参数;
    编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
  5. 如权利要求1或2或4所述的预测编码方法,其特征在于:所述对帧内预测类型的所述分片中采用IBC模式的编码块,使用第二编码方式进行编码,包括:
    在所述编码块直接编码IBC模式参数;
    编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指示矢量。
  6. 如权利要求5所述的预测编码方法,其特征在于:所述在编码块直接编码IBC模式参数,包括:在编码单元CU直接编码所述IBC模式参数。
  7. 如权利要求5所述的预测编码方法,其特征在于:所述在编码块直接编码IBC模式参数之前,还包括:编码IBC模式标识信息。
  8. 如权利要求1所述的预测编码方法,其特征在于:将所述分片所在图像设置为所述分片的预测参考图像,包括:
    将所述分片所在图像直接作为所述分片的预测参考图像;
    对帧间预测类型的所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,包括:
    使用编码单元CU编码IBC模式标识信息,使用预测单元PU编码IBC模式参数信息;或者,
    使用PU编码IBC模式标识信息和IBC模式参数信息。
  9. 一种解码方法,应用于解码器,包括:解析码流,获得分片的类型信息;
    对帧间预测类型的分片解码时,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,并对所述分片中采用帧内块复制(IBC)模式的解码块进行解码;
    对帧内预测类型的分片解码时,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
  10. 如权利要求9所述的解码方法,其特征在于:所述使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
  11. 如权利要求9或10所述的解码方法,其特征在于:所述使用第一解码方式,对所述分片中采用IBC模式的解码块进行解码,包括:
    使用帧间预测模式的解码方式对所述分片中采用IBC模式的解码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参 数。
  12. 如权利要求11所述的解码方法,其特征在于:所述通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数,包括:
    通过解析PU及其中运动信息参数对应的比特字段;获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
  13. 如权利要求9或10或12所述的解码方法,其特征在于:所述使用不同于第一编码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码,包括:
    解析所述解码块中IBC模式参数对应的比特字段;
    获得以下IBC模式参数中的至少一种:块划分和参考块指示矢量。
  14. 如权利要求13所述的解码方法,其特征在于:解析所述解码块中IBC模式参数对应的比特字段,包括:
    解析CU中IBC模式参数对应的比特字段,获得IBC模式参数。
  15. 如权利要求13所述的解码方法,其特征在于:解析所述解码块中IBC模式参数对应的比特字段之前,还包括:
    解析解码块中IBC模式标识信息对应的比特字段,获得IBC模式标识信息对应参数的取值。
  16. 如权利要求9所述的解码方法,其特征在于:所述使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,包括:将所述分片所在图像直接作为所述分片的预测参考图像;
    所述对帧间预测类型的所述分片中采用IBC模式的解码块,使用第一解码方式进行解码,包括:
    解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息;解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者
    解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC 模式标识信息和IBC模式参数的取值。
  17. 一种编码器,其特征在于,所述编码器包括:
    类型设置装置,设置为设置分片的类型;
    第一编码装置,设置为对帧间预测类型的分片编码,编码时,将所述分片所在图像设置为所述分片的预测参考图像,对所述分片中采用帧内块复制IBC模式的编码块,使用第一编码方式进行编码;
    第二编码装置,设置为对帧内预测类型的分片编码,编码时,对所述分片中采用IBC模式的编码块,使用不同于第一编码方式的第二编码方式进行编码。
  18. 如权利要求17所述的编码器,其特征在于:
    所述第一编码装置对帧间预测类型的分片编码时,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
  19. 如权利要求17或18所述的编码器,其特征在于:
    所述第一编码装置对帧间预测类型的所述分片中采用IBC模式的编码块,使用第一编码方式进行编码,设置为:使用帧间预测模式的模式参数编码方式编码IBC模式参数。
  20. 如权利要求19所述的编码器,其特征在于:
    所述第一编码装置使用帧间预测模式的模式参数编码方式编码IBC模式参数,设置为:使用预测单元PU的运动信息编码方法编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
  21. 如权利要求17或18或20所述的编码器,其特征在于:
    所述第二编码装置对帧内预测类型的所述分片中采用IBC模式的编码块,使用第二编码方式进行编码,设置为:在编码块直接编码IBC模式参数,编码的所述IBC模式参数包括以下参数中的至少之一种:块划分和参考块指 示矢量。
  22. 如权利要求21所述的编码器,其特征在于:
    所述第二编码装置在编码块直接编码IBC模式参数,设置为:在编码单元CU直接编码IBC模式参数。
  23. 如权利要求21所述的编码器,其特征在于:所述第二编码装置在编码块直接编码IBC模式参数之前,还设置为:编码IBC模式标识信息。
  24. 如权利要求17所述的编码器,其特征在于:
    所述第一编码装置将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像直接作为所述分片的预测参考图像;
    所述第一编码装置对帧间预测类型的所述分片中采用IBC模式的编码块,按照第一编码方式进行编码,设置为:
    使用CU编码IBC模式标识信息,使用PU编码IBC模式参数信息;
    或者,使用PU编码IBC模式标识信息和IBC模式参数信息。
  25. 一种解码器,其特征在于,所述解码器包括:
    类型解析装置,设置为解析码流,获得分片类型信息;
    第一解码装置,设置为对帧间预测类型的分片解码,解码时,使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,并对所述分片中采用IBC模式的解码块进行解码;
    第二解码装置,设置为对帧内预测类型的分片解码,解码时,使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码。
  26. 如权利要求25所述的解码器,其特征在于:
    所述第一解码装置对帧间预测类型的分片解码时,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像插入预测参考图像列表,作为所述分片的预测参考图像。
  27. 如权利要求25或26所述的解码器,其特征在于:
    所述第一解码装置使用第一解码方式,对所述分片中采用IBC模式的解码块进行解码,设置为:使用帧间预测模式的解码方式对所述分片中采用IBC模式的解码块进行解码,通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数。
  28. 如权利要求27所述的解码器,其特征在于:
    所述第一解码装置通过解析帧间预测模式的模式参数对应的比特字段,获得IBC模式参数,设置为:通过解析PU及其中运动信息参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分、参考块指示矢量和参考图像索引。
  29. 如权利要求25或26或28所述的解码器,其特征在于:
    所述第二解码装置使用不同于第一解码方式的第二解码方式,对所述分片中采用IBC模式的解码块进行解码,设置为:解析所述解码块中IBC模式参数对应的比特字段,获得以下IBC模式参数中的至少一种:块划分和参考块指示矢量。
  30. 如权利要求29所述的解码器,其特征在于:
    所述第二解码装置解析所述解码块中IBC模式参数对应的比特字段,设置为:解析编码单元CU中IBC模式参数对应的比特字段,获得IBC模式参数。
  31. 如权利要求29所述的解码器,其特征在于:
    所述第二解码装置解析所述解码块中IBC模式参数对应的比特字段之前,还设置为:解析解码块中IBC模式标识信息对应的比特字段,获得IBC模式标识信息对应参数的取值。
  32. 如权利要求25所述的解码器,其特征在于:
    所述第一解码装置使用第一解码方式,将所述分片所在图像设置为所述分片的预测参考图像,设置为:将所述分片所在图像直接作为所述分片的预 测参考图像;
    所述第一解码装置使用第一解码方式,对帧间预测类型的所述分片中采用IBC模式的解码块进行解码,设置为:
    解析CU中IBC模式标识信息对应的比特字段,获得IBC模式标识信息;解析PU中IBC模式参数对应的比特字段,获得IBC模式参数的取值;或者
    解析PU中IBC模式标识信息和IBC模式参数对应的比特字段,获得IBC模式标识信息和IBC模式参数的取值。
  33. 一种电子设备,包括编码器和/或解码器,其特征在于:
    所述编码器采用如权利要求17至24中任一权利要求所述的编码器;
    所述解码器采用如权利要求25至32中任一权利要求所述的解码器。
  34. 一种图像填充方法,应用于预测编码和/或解码过程,包括:
    确定对编码单位做预测编码和/或对解码单位做解码时作为参考的图像;
    对所述图像中未编码和/或未解码位置像素点的采样值进行填充。
  35. 如权利要求34所述的图像填充方法,其特征在于:
    对所述图像中未编码位置像素点的采样值进行填充,包括:
    对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充,其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
    对所述图像中未解码位置像素点的采样值进行填充,包括:
    对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充,其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
  36. 如权利要求34或35所述的图像填充方法,其特征在于:
    在预测编码过程中,对所述图像中未编码位置像素点的采样值进行填充之后,还包括:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
    是否使用自适应填充的指示信息;
    使用自适应填充时,所使用的填充方式的指示信息及相关参数;
    不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
    在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
  37. 如权利要求34或35所述的图像填充方法,其特征在于:
    对所述图像中未编码位置像素点的采样值进行填充之后,还包括:在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
  38. 如权利要求34或35所述的图像填充方法,其特征在于:
    对所述图像中未解码位置像素点的采样值进行填充之后,还包括:在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码位置像素点的采样值进行填充。
  39. 一种电子设备,包括编码器和/或解码器,其特征在于:
    所述编码器包括:
    确定装置,设置为确定对编码单位做预测编码时作为参考的图像;
    编码填充装置,设置为对所述图像中未编码位置像素点的采样值进行填充;
    所述解码器包括:
    确定装置,设置为确定对解码单位做解码时作为参考的图像;
    解码填充装置,设置为对所述图像中未解码位置像素点的采样值进行填充。
  40. 如权利要求39所述的电子设备,其特征在于:
    所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充,具体设置为:
    对所述编码单位进行编码之前,对所述图像中全部或部分未编码位置像素点的采样值进行填充;其中,所述图像中部分未编码位置像素点指当前编码单位及其相邻编码单位中的未编码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未编码位置像素点;
    所述解码填充装置对所述图像中未解码位置像素点的采样值进行填充,具体设置为:
    对所述解码单位进行解码之前,对所述图像中全部或部分未解码位置像素点的采样值进行填充;其中,所述图像中部分未解码位置像素点指当前解码单位及其相邻解码单位中的未解码位置像素点,或者指运动矢量或块复制矢量指向的预测块范围内的未解码位置像素点。
  41. 如权利要求39或40所述的电子设备,其特征在于:
    所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充之后,还设置为:将相应的填充方式信息写入码流,所述填充方式信息包括以下信息中的至少一种:
    是否使用自适应填充的指示信息;
    使用自适应填充时,所使用的填充方式的指示信息及相关参数;
    不使用自适应填充时,所使用的未编码位置像素点的采样值的填充值;
    所述解码填充装置在解码过程中,根据从码流中解析出的所述填充方式信息对所述图像中未解码位置像素点的采样值进行填充。
  42. 如权利要求39或40所述的电子设备,其特征在于:
    所述编码填充装置对所述图像中未编码位置像素点的采样值进行填充之 后,还设置为:
    在所述编码单位编码完成后,以当前编码图像中已编码位置像素点的本地解码恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未编码位置像素点的采样值进行填充。
  43. 如权利要求39或40所述的电子设备,其特征在于:
    所述解码填充装置对所述图像中未解码位置像素点的采样值进行填充之后,还设置为:
    在所述解码单位解码完成后,以当前解码图像中已解码位置像素点的恢复采样值更新所述图像中相应像素点的采样值,并重新对所述图像中未解码位置像素点的采样值进行填充。
PCT/CN2015/073048 2014-08-22 2015-02-13 一种预测编、解码方法和相应的编、解码器和电子设备 WO2016026283A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201410419875.5 2014-08-22
CN201410419875 2014-08-22

Publications (1)

Publication Number Publication Date
WO2016026283A1 true WO2016026283A1 (zh) 2016-02-25

Family

ID=55350155

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2015/073048 WO2016026283A1 (zh) 2014-08-22 2015-02-13 一种预测编、解码方法和相应的编、解码器和电子设备

Country Status (1)

Country Link
WO (1) WO2016026283A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107770543A (zh) * 2016-08-21 2018-03-06 上海天荷电子信息有限公司 多类匹配参数中按顺序递增截断值的数据压缩方法和装置

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101233760A (zh) * 2005-08-03 2008-07-30 诺基亚公司 在视频编码中用于改进的编码模式控制的方法、设备和模块
US20090190661A1 (en) * 2008-01-17 2009-07-30 Nagori Soyeb N Rate Distortion Optimized Adaptive Intra Refresh for Video Coding
CN101558651A (zh) * 2006-10-16 2009-10-14 诺基亚公司 可伸缩视频编码中的可丢弃较低层自适应
WO2009157669A2 (ko) * 2008-06-24 2009-12-30 에스케이텔레콤 주식회사 인트라 예측 방법 및 장치와 그를 이용한 영상 부호화/복호화 방법 및 장치
CN102934441A (zh) * 2010-05-25 2013-02-13 Lg电子株式会社 新的平面预测模式
CN103609115A (zh) * 2011-06-24 2014-02-26 斯凯普公司 具有基于知觉的帧内切换的模式决策
US20140226721A1 (en) * 2012-07-11 2014-08-14 Qualcomm Incorporated Repositioning of prediction residual blocks in video coding

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101233760A (zh) * 2005-08-03 2008-07-30 诺基亚公司 在视频编码中用于改进的编码模式控制的方法、设备和模块
CN101558651A (zh) * 2006-10-16 2009-10-14 诺基亚公司 可伸缩视频编码中的可丢弃较低层自适应
US20090190661A1 (en) * 2008-01-17 2009-07-30 Nagori Soyeb N Rate Distortion Optimized Adaptive Intra Refresh for Video Coding
WO2009157669A2 (ko) * 2008-06-24 2009-12-30 에스케이텔레콤 주식회사 인트라 예측 방법 및 장치와 그를 이용한 영상 부호화/복호화 방법 및 장치
CN102934441A (zh) * 2010-05-25 2013-02-13 Lg电子株式会社 新的平面预测模式
CN103609115A (zh) * 2011-06-24 2014-02-26 斯凯普公司 具有基于知觉的帧内切换的模式决策
US20140226721A1 (en) * 2012-07-11 2014-08-14 Qualcomm Incorporated Repositioning of prediction residual blocks in video coding

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107770543A (zh) * 2016-08-21 2018-03-06 上海天荷电子信息有限公司 多类匹配参数中按顺序递增截断值的数据压缩方法和装置
CN107770543B (zh) * 2016-08-21 2023-11-10 上海天荷电子信息有限公司 多类匹配参数中按顺序递增截断值的数据压缩方法和装置

Similar Documents

Publication Publication Date Title
WO2016026457A1 (zh) 一种预测编、解码方法和相应的编、解码器和电子设备
CN110719469B (zh) 视频编解码方法、设备和存储介质
US11553193B2 (en) Low latency local illumination compensation
KR20230175340A (ko) 병렬 처리로 히스토리 기반 모션 벡터 예측을 위한 방법 및 장치
KR102646839B1 (ko) 비디오 코딩을 위한 방법 및 장치
CN111937326B (zh) 视频解码方法、装置和可读存储介质
KR20200116524A (ko) 비디오 코딩을 위한 방법 및 장치
CN113273185B (zh) 对已编码图片进行解码的方法和相关装置
CN111010579B (zh) 基于成对平均运动矢量预测的视频解码方法和装置
US10812819B2 (en) Method and apparatus for video coding
CN113228667B (zh) 视频编解码的方法、装置及存储介质
US11748729B2 (en) Method and apparatus for video coding
KR20210049930A (ko) 비디오 디코딩을 위한 방법 및 장치
JP2022515850A (ja) 統合位置依存予測組み合わせプロセスを使用するデコードのための方法、装置およびコンピュータ・プログラム
JP7357678B2 (ja) ビデオ復号のための方法、装置、およびプログラム
CN112235573A (zh) 视频编解码的方法、装置、电子设备、存储介质
JP2022509172A (ja) ビデオをデコードするための方法、装置及びプログラム
CN110719462B (zh) 视频解码方法、解码器、计算机可读存储介质以及计算机设备
WO2016026283A1 (zh) 一种预测编、解码方法和相应的编、解码器和电子设备
US20230007305A1 (en) Subpicture partitioning and scaling window information
JP7237410B2 (ja) ビデオビットストリームにおけるピクチャサイズおよび分割情報の効率的なシグナリングのための方法、装置、およびコンピュータプログラム
CN112399180B (zh) 视频解码方法、装置及存储介质
US11012690B2 (en) Method and apparatus for video coding
CN112399186A (zh) 视频解码方法、装置及存储介质
CN113692745B (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: 15833281

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 15833281

Country of ref document: EP

Kind code of ref document: A1