The RFX_Progressive_CONTEXT block is used to provide information about compressed data.
Inheritance: RFX_Progressive_DataBlock
 /// <summary>
 /// Create context block if needed.
 /// </summary>
 /// <param name="bContext">This is used to indicate if context block needed.</param>
 /// <param name="bSubDiff">This is used to indicate if subband_diffing flag is enabled in context block.</param>
 public virtual void CreateContextBlock(bool bContext, bool bSubDiff)
 {
     // Create context block if needed and add to block list.
     if (bContext)
     {
         byte sdFlag = Convert.ToByte(bSubDiff);
         RFX_Progressive_CONTEXT context_block = new RFX_Progressive_CONTEXT(sdFlag);
         blkList.Add(context_block);
     }
 }
        /// <summary>
        /// Create context block if needed.
        /// </summary>
        /// <param name="bContext">This is used to indicate if context block needed.</param>
        /// <param name="bSubDiff">This is used to indicate if subband_diffing flag is enabled in context block.</param>
        public override void CreateContextBlock(bool bContext, bool bSubDiff)
        {
            // Create context block if needed and add to block list.
            if (bContext)
            {
                byte sdFlag = Convert.ToByte(bSubDiff);
                RFX_Progressive_CONTEXT context_block = new RFX_Progressive_CONTEXT(sdFlag);

                if (bmTestType == RdpegfxNegativeTypes.RfxProgCodec_ContextBlock_IncorrectLen)
                {
                    context_block.blockLen += 1; // Set block length to other than 10.
                }
                if (bmTestType == RdpegfxNegativeTypes.RfxProgCodec_ContextBlock_IncorrectContextId)
                {
                    context_block.ctxId = 0xff;  // Set context Id to other than 0.
                }
                if (bmTestType == RdpegfxNegativeTypes.RfxProgCodec_ContextBlock_IncorrectTileSize)
                {
                    context_block.tileSize += 1;  // Set tile size to other than 64.
                }

                blkList.Add(context_block);
            }
        }