Changeset 1432 in SHVCSoftware for branches/SHM-dev/source/Lib/TLibDecoder


Ignore:
Timestamp:
10 Aug 2015, 23:04:12 (10 years ago)
Author:
seregin
Message:

CGS code formatting

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/SHM-dev/source/Lib/TLibDecoder/TDecCAVLC.cpp

    r1425 r1432  
    35563556{
    35573557  UInt uiNumRefLayersM1;
    3558   READ_UVLC( uiNumRefLayersM1 , "num_cm_ref_layers_minus1" );
     3558  READ_UVLC( uiNumRefLayersM1, "num_cm_ref_layers_minus1" );
    35593559  assert( uiNumRefLayersM1 <= 61 );
    35603560  for( UInt i = 0 ; i <= uiNumRefLayersM1 ; i++ )
    35613561  {
    35623562    UInt uiRefLayerId;
    3563     READ_CODE( 6 , uiRefLayerId , "cm_ref_layer_id" );
     3563    READ_CODE( 6, uiRefLayerId, "cm_ref_layer_id" );
    35643564    pc3DAsymLUT->addRefLayerId( uiRefLayerId );
    35653565  }
     
    35673567  UInt uiCurOctantDepth, uiCurPartNumLog2, uiInputBitDepthM8, uiOutputBitDepthM8, uiResQaunBit, uiDeltaBits;;
    35683568 
    3569   READ_CODE( 2 , uiCurOctantDepth , "cm_octant_depth" );
    3570   READ_CODE( 2 , uiCurPartNumLog2 , "cm_y_part_num_log2" );     
    3571 
    3572   UInt uiChromaInputBitDepthM8 , uiChromaOutputBitDepthM8;
    3573 
    3574   READ_UVLC( uiInputBitDepthM8 , "cm_input_luma_bit_depth_minus8" );
     3569  READ_CODE( 2, uiCurOctantDepth, "cm_octant_depth" );
     3570  READ_CODE( 2, uiCurPartNumLog2, "cm_y_part_num_log2" );     
     3571
     3572  UInt uiChromaInputBitDepthM8, uiChromaOutputBitDepthM8;
     3573
     3574  READ_UVLC( uiInputBitDepthM8, "cm_input_luma_bit_depth_minus8" );
    35753575  READ_UVLC( uiChromaInputBitDepthM8 , "cm_input_chroma_bit_depth_minus8" );
    3576   READ_UVLC( uiOutputBitDepthM8 , "cm_output_luma_bit_depth_minus8" );
    3577   READ_UVLC( uiChromaOutputBitDepthM8 , "cm_output_chroma_bit_depth_minus8" );
    3578   READ_CODE( 2 , uiResQaunBit , "cm_res_quant_bit" );
    3579 
    3580   READ_CODE( 2 , uiDeltaBits , "cm_flc_bits" );
     3576  READ_UVLC( uiOutputBitDepthM8, "cm_output_luma_bit_depth_minus8" );
     3577  READ_UVLC( uiChromaOutputBitDepthM8 "cm_output_chroma_bit_depth_minus8" );
     3578  READ_CODE( 2, uiResQaunBit, "cm_res_quant_bit" );
     3579
     3580  READ_CODE( 2, uiDeltaBits, "cm_flc_bits" );
    35813581  pc3DAsymLUT->setDeltaBits(uiDeltaBits + 1);
    35823582
     
    35873587  {
    35883588    Int delta = 0;
    3589     READ_SVLC( delta , "cm_adapt_threshold_u_delta" );
     3589    READ_SVLC( delta, "cm_adapt_threshold_u_delta" );
    35903590    nAdaptCThresholdU += delta;
    3591     READ_SVLC( delta , "cm_adapt_threshold_v_delta" );
     3591    READ_SVLC( delta, "cm_adapt_threshold_v_delta" );
    35923592    nAdaptCThresholdV += delta;
    35933593  }
     
    36003600  pc3DAsymLUT->xInitCuboids();
    36013601#endif
    3602   xParse3DAsymLUTOctant( pc3DAsymLUT , 0 , 0 , 0 , 0 , 1 << pc3DAsymLUT->getCurOctantDepth() );
     3602  xParse3DAsymLUTOctant( pc3DAsymLUT, 0, 0, 0, 0, 1 << pc3DAsymLUT->getCurOctantDepth() );
    36033603#if R0164_CGS_LUT_BUGFIX_CHECK
    36043604  printf("============= Before 'xCuboidsFilledCheck()': ================\n");
     
    36103610}
    36113611
    3612 Void TDecCavlc::xParse3DAsymLUTOctant( TCom3DAsymLUT * pc3DAsymLUT , Int nDepth , Int yIdx , Int uIdx , Int vIdx , Int nLength )
     3612Void TDecCavlc::xParse3DAsymLUTOctant( TCom3DAsymLUT * pc3DAsymLUT, Int nDepth, Int yIdx, Int uIdx, Int vIdx, Int nLength )
    36133613{
    36143614  UInt uiOctantSplit = nDepth < pc3DAsymLUT->getCurOctantDepth();
    36153615  if( nDepth < pc3DAsymLUT->getCurOctantDepth() )
    3616     READ_FLAG( uiOctantSplit , "split_octant_flag" );
     3616  {
     3617    READ_FLAG( uiOctantSplit, "split_octant_flag" );
     3618  }
    36173619  Int nYPartNum = 1 << pc3DAsymLUT->getCurYPartNumLog2();
     3620
    36183621  if( uiOctantSplit )
    36193622  {
     
    36253628        for( Int n = 0 ; n < 2 ; n++ )
    36263629        {
    3627           xParse3DAsymLUTOctant( pc3DAsymLUT , nDepth + 1 , yIdx + l * nHalfLength * nYPartNum , uIdx + m * nHalfLength , vIdx + n * nHalfLength , nHalfLength );
     3630          xParse3DAsymLUTOctant( pc3DAsymLUT, nDepth + 1, yIdx + l * nHalfLength * nYPartNum, uIdx + m * nHalfLength, vIdx + n * nHalfLength, nHalfLength );
    36283631        }
    36293632      }
     
    36353638    nFLCbits = nFLCbits >= 0 ? nFLCbits:0;
    36363639
    3637     for( Int l = 0 ; l < nYPartNum ; l++ )
     3640    for( Int l = 0; l < nYPartNum; l++ )
    36383641    {
    36393642      Int shift = pc3DAsymLUT->getCurOctantDepth() - nDepth;
    36403643
    3641       for( Int nVertexIdx = 0 ; nVertexIdx < 4 ; nVertexIdx++ )
     3644      for( Int nVertexIdx = 0; nVertexIdx < 4; nVertexIdx++ )
    36423645      {
    36433646        UInt uiCodeVertex = 0;
    3644         Int deltaY = 0 , deltaU = 0 , deltaV = 0;
    3645         READ_FLAG( uiCodeVertex , "coded_vertex_flag" );
     3647        Int deltaY = 0, deltaU = 0, deltaV = 0;
     3648
     3649        READ_FLAG( uiCodeVertex, "coded_vertex_flag" );
     3650
    36463651        if( uiCodeVertex )
    36473652        {
     
    36513656        }
    36523657
    3653         pc3DAsymLUT->setCuboidVertexResTree( yIdx + (l<<shift) , uIdx , vIdx , nVertexIdx , deltaY , deltaU , deltaV );
     3658        pc3DAsymLUT->setCuboidVertexResTree( yIdx + (l<<shift), uIdx, vIdx, nVertexIdx, deltaY, deltaU, deltaV );
    36543659
    36553660        for( Int m = 1; m < (1<<shift); m++ )
    36563661        {
    3657           pc3DAsymLUT->setCuboidVertexResTree( yIdx + (l<<shift) + m , uIdx , vIdx , nVertexIdx , 0 , 0 , 0 );
     3662          pc3DAsymLUT->setCuboidVertexResTree( yIdx + (l<<shift) + m, uIdx, vIdx, nVertexIdx, 0, 0, 0 );
    36583663#if R0164_CGS_LUT_BUGFIX_CHECK
    36593664          pc3DAsymLUT->xSetFilled( yIdx + (l<<shift) + m , uIdx , vIdx );
     
    36723677        if( u!=0 || v!=0 )
    36733678        {
    3674           for( Int y=0 ; y<nLength*nYPartNum ; y++ )
     3679          for( Int y=0; y<nLength*nYPartNum; y++ )
    36753680          {
    3676             for( Int nVertexIdx = 0 ; nVertexIdx < 4 ; nVertexIdx++ )
     3681            for( Int nVertexIdx = 0; nVertexIdx < 4; nVertexIdx++ )
    36773682            {
    3678               pc3DAsymLUT->setCuboidVertexResTree( yIdx + y , uIdx + u , vIdx + v , nVertexIdx , 0 , 0 , 0 );
     3683              pc3DAsymLUT->setCuboidVertexResTree( yIdx + y, uIdx +  , vIdx + v, nVertexIdx, 0, 0, 0 );
    36793684#if R0164_CGS_LUT_BUGFIX_CHECK
    3680               pc3DAsymLUT->xSetFilled( yIdx + y , uIdx + u , vIdx + v );
     3685              pc3DAsymLUT->xSetFilled( yIdx + y, uIdx + u, vIdx + v );
    36813686#endif
    36823687            }
Note: See TracChangeset for help on using the changeset viewer.