46#ifndef _INCLUDED_MOT_COMP
47#define _INCLUDED_MOT_COMP
ChromaFormat
Definition: common_types.h:58
Definition of class SequenceHeaderByteIO.
Definition: accessunit_byteio.h:52
CompSort
Types of picture component.
Definition: common.h:87
AddOrSub
Addition or subtraction.
Definition: common.h:90
short ValueType
Type of picture data (including motion compensated residuals)
Definition: common.h:70
PredMode
Prediction modes for blocks.
Definition: common.h:84
A class for picture component data.
Definition: common.h:719
Parameters for overlapped block motion compensation.
Definition: common.h:818
Structure to hold motion parameters when motion comp is used.
Definition: common.h:968
Abstract Motion compensator class.
Definition: mot_comp.h:71
void AdjustBlockBySpatialWeights(TwoDArray< ValueType > &val_block, const ImageCoords &pos, const TwoDArray< ValueType > &wt_array)
virtual void CompensateBlock(TwoDArray< ValueType > &pic_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, PredMode block_mode, ValueType dc, const PicArray &ref1up_data, const MVector &mv1, const PicArray &ref2up_data, const MVector &mv2, const TwoDArray< ValueType > &Weights)
void FlipY(const TwoDArray< ValueType > &Original, TwoDArray< ValueType > &Flipped)
Flips the values in an array in the y direction.
virtual void BlockPixelPred(TwoDArray< ValueType > &block_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, const PicArray &refup_data, const MVector &mv)=0
Predict pixels in a block. Pure virtual. SubClasses need to define it.
TwoDArray< ValueType > * m_macro_block_weights
Definition: mot_comp.h:219
ChromaFormat m_cformat
The chroma format.
Definition: mot_comp.h:208
AddOrSub m_add_or_sub
Definition: mot_comp.h:212
virtual ~MotionCompensator()
Destructor.
TwoDArray< ValueType > * m_sub_block_weights
Definition: mot_comp.h:221
void CompensatePicture(const AddOrSub direction, const MvData &mv_data, Picture *in_pic, Picture *refsptr[2])
Compensate a picture.
MotionCompensator(const PicturePredParams &ppp)
Constructor.
static void CompensatePicture(const PicturePredParams &ppp, const AddOrSub direction, const MvData &mv_data, Picture *in_pic, Picture *refptr[2])
Convenience function to perform motion compensation on a picture.
bool luma_or_chroma
Definition: mot_comp.h:209
PicturePredParams m_predparams
The codec parameters.
Definition: mot_comp.h:205
void CreateBlock(int xbsep, int ybsep, bool FullX, bool FullY, TwoDArray< ValueType > &WeightArray)
Calculates a weighting block.
void FlipX(const TwoDArray< ValueType > &Original, TwoDArray< ValueType > &Flipped)
Flips the values in an array in the x direction.
OLBParams m_bparams
Definition: mot_comp.h:215
TwoDArray< ValueType > * m_block_weights
Definition: mot_comp.h:217
void CalculateWeights(int xbsep, int ybsep, TwoDArray< ValueType > *wt_array)
void CompensateComponent(Picture *pic, Picture *refsptr[2], const MvData &mv_data, const CompSort cs)
Motion-compensate a component.
void AdjustBlockByRefWeights(TwoDArray< ValueType > &val1_block, TwoDArray< ValueType > &val2_block, PredMode block_mode)
MotionCompensator(const MotionCompensator &cpy)
void DCBlock(TwoDArray< ValueType > &block_data, const ValueType dc)
Recalculate the weight matrix and store other key block related parameters.
MotionCompensator & operator=(const MotionCompensator &rhs)
Pixel precision Motion compensator class.
Definition: mot_comp.h:226
virtual void BlockPixelPred(TwoDArray< ValueType > &block_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, const PicArray &refup_data, const MVector &mv)
Motion-compensate a block.
MotionCompensator_Pixel(const PicturePredParams &ppp)
Constructor.
Half Pixel precision Motion compensator class.
Definition: mot_comp.h:246
MotionCompensator_HalfPixel(const PicturePredParams &ppp)
Constructor.
virtual void BlockPixelPred(TwoDArray< ValueType > &block_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, const PicArray &refup_data, const MVector &mv)
Motion-compensate a block.
Quarter Pixel precision Motion compensator class.
Definition: mot_comp.h:264
MotionCompensator_QuarterPixel(const PicturePredParams &ppp)
Constructor.
virtual void BlockPixelPred(TwoDArray< ValueType > &block_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, const PicArray &refup_data, const MVector &mv)
Motion-compensate a block.
Eighth Pixel precision Motion compensator class.
Definition: mot_comp.h:282
virtual void BlockPixelPred(TwoDArray< ValueType > &block_data, const ImageCoords &pos, const ImageCoords &orig_pic_size, const PicArray &refup_data, const MVector &mv)
Motion-compensate a block.
MotionCompensator_EighthPixel(const PicturePredParams &ppp)
Constructor.
Class for all the motion vector data.
Definition: motion.h:220
A class for encapsulating all the data relating to a picture.
Definition: picture.h:52