Void printBlockToStream( std::ostream &ss, const Char *pLinePrefix, TComYuv &src, const UInt numSubBlocksAcross, const UInt numSubBlocksUp, const UInt defWidth ) { const UInt numValidComp=src.getNumberValidComponents(); for (UInt ch=0; ch<numValidComp ; ch++) { const ComponentID compID = ComponentID(ch); const UInt width = src.getWidth(compID); const UInt height = src.getHeight(compID); const UInt stride = src.getStride(compID); const Pel* blkSrc = src.getAddr(compID); const UInt subBlockWidth=width/numSubBlocksAcross; const UInt subBlockHeight=height/numSubBlocksUp; ss << pLinePrefix << " compID: " << compID << "\n"; for (UInt y=0; y<height; y++) { if ((y%subBlockHeight)==0 && y!=0) ss << pLinePrefix << '\n'; ss << pLinePrefix; for (UInt x=0; x<width; x++) { if ((x%subBlockWidth)==0 && x!=0) ss << std::setw(defWidth+2) << ""; ss << std::setw(defWidth) << blkSrc[y*stride + x] << ' '; } ss << '\n'; } ss << pLinePrefix << " --- \n"; } }