Changeset 296 in 3DVCSoftware for trunk/source/Lib/TLibCommon/ContextTables.h
- Timestamp:
- 20 Feb 2013, 22:07:43 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/Lib/TLibCommon/ContextTables.h
r189 r296 57 57 58 58 #define NUM_MERGE_FLAG_EXT_CTX 1 ///< number of context models for merge flag of merge extended 59 #if MRG_IDX_CTX_RED60 59 #define NUM_MERGE_IDX_EXT_CTX 1 ///< number of context models for merge index of merge extended 61 #else 62 #define NUM_MERGE_IDX_EXT_CTX 4 ///< number of context models for merge index of merge extended 63 #endif 64 65 #if HHI_INTER_VIEW_RESIDUAL_PRED 60 61 #if H3D_IVRP 66 62 #define NUM_RES_PRED_FLAG_CTX 4 ///< number of context for residual prediction flag 67 63 #endif … … 69 65 #define NUM_ALF_CTRL_FLAG_CTX 1 ///< number of context models for ALF control flag 70 66 #define NUM_PART_SIZE_CTX 4 ///< number of context models for partition size 71 #if AMP_CTX72 67 #define NUM_CU_AMP_CTX 1 ///< number of context models for partition size (AMP) 73 #else74 #define NUM_CU_X_POS_CTX 2 ///< number of context models for partition size (AMP)75 #define NUM_CU_Y_POS_CTX 2 ///< number of context models for partition size (AMP)76 #endif77 68 #define NUM_PRED_MODE_CTX 1 ///< number of context models for prediction mode 78 69 … … 95 86 #define NUM_SIG_FLAG_CTX_LUMA 27 ///< number of context models for luma sig flag 96 87 #define NUM_SIG_FLAG_CTX_CHROMA 21 ///< number of context models for chroma sig flag 97 #if LAST_CTX_REDUCTION98 88 #define NUM_CTX_LAST_FLAG_XY 15 ///< number of context models for last coefficient position 99 #else 100 #define NUM_CTX_LAST_FLAG_XY 18 ///< number of context models for last coefficient position 101 #endif 102 103 #if LEVEL_CTX_LUMA_RED 89 104 90 #define NUM_ONE_FLAG_CTX 24 ///< number of context models for greater than 1 flag 105 91 #define NUM_ONE_FLAG_CTX_LUMA 16 ///< number of context models for greater than 1 flag of luma 106 92 #define NUM_ONE_FLAG_CTX_CHROMA 8 ///< number of context models for greater than 1 flag of chroma 107 #if RESTRICT_GR1GR2FLAG_NUMBER108 93 #define NUM_ABS_FLAG_CTX 6 ///< number of context models for greater than 2 flag 109 94 #define NUM_ABS_FLAG_CTX_LUMA 4 ///< number of context models for greater than 2 flag of luma 110 95 #define NUM_ABS_FLAG_CTX_CHROMA 2 ///< number of context models for greater than 2 flag of chroma 111 #else112 #define NUM_ABS_FLAG_CTX 18 ///< number of context models for greater than 2 flag113 #define NUM_ABS_FLAG_CTX_LUMA 12 ///< number of context models for greater than 2 flag of luma114 #define NUM_ABS_FLAG_CTX_CHROMA 6 ///< number of context models for greater than 2 flag of chroma115 #endif116 #else117 #define NUM_ONE_FLAG_CTX 32 ///< number of context models for greater than 1 flag118 #define NUM_ONE_FLAG_CTX_LUMA 24 ///< number of context models for greater than 1 flag of luma119 #define NUM_ONE_FLAG_CTX_CHROMA 8 ///< number of context models for greater than 1 flag of chroma120 #if RESTRICT_GR1GR2FLAG_NUMBER121 #define NUM_ABS_FLAG_CTX 8 ///< number of context models for greater than 2 flag122 #define NUM_ABS_FLAG_CTX_LUMA 6 ///< number of context models for greater than 2 flag of luma123 #define NUM_ABS_FLAG_CTX_CHROMA 2 ///< number of context models for greater than 2 flag of chroma124 #else125 #define NUM_ABS_FLAG_CTX 24 ///< number of context models for greater than 2 flag126 #define NUM_ABS_FLAG_CTX_LUMA 18 ///< number of context models for greater than 2 flag of luma127 #define NUM_ABS_FLAG_CTX_CHROMA 6 ///< number of context models for greater than 2 flag of chroma128 #endif129 #endif130 96 131 97 #define NUM_MVP_IDX_CTX 2 ///< number of context models for MVP index … … 138 104 #define NUM_SAO_UVLC_CTX 2 ///< number of context models for SAO UVLC 139 105 #define NUM_SAO_SVLC_CTX 3 ///< number of context models for SAO SVLC 140 #if SAO_UNIT_INTERLEAVING141 106 #define NUM_SAO_RUN_CTX 3 ///< number of context models for AO SVLC (filter coeff.) 142 107 #define NUM_SAO_MERGE_LEFT_FLAG_CTX 3 ///< number of context models for AO SVLC (filter coeff.) 143 108 #define NUM_SAO_MERGE_UP_FLAG_CTX 1 ///< number of context models for AO SVLC (filter coeff.) 144 109 #define NUM_SAO_TYPE_IDX_CTX 2 ///< number of context models for AO SVLC (filter coeff.) 145 #endif146 #if CABAC_LINEAR_INIT147 110 #define CNU 154 ///< dummy initialization value for unused context models 'Context model Not Used' 148 #else149 #define CNU 119 ///< dummy initialization value for unused context models 'Context model Not Used'150 #endif151 111 152 112 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 153 113 #define NUM_DMM_FLAG_CTX 1 ///< number of context models for DMM flag 154 114 #define NUM_DMM_MODE_CTX 1 ///< number of context models for DMM mode 115 #if LGE_DMM3_SIMP_C0044 116 #define NUM_DMM_DATA_CTX 4 ///< number of context models for DMM data 117 #else 155 118 #define NUM_DMM_DATA_CTX 3 ///< number of context models for DMM data 119 #endif 156 120 #endif 157 121 … … 177 141 178 142 // initial probability for split flag 179 #if CABAC_LINEAR_INIT180 143 static const UChar 181 144 INIT_SPLIT_FLAG[3][NUM_SPLIT_FLAG_CTX] = … … 223 186 INIT_MERGE_IDX_EXT[3][NUM_MERGE_IDX_EXT_CTX] = 224 187 { 225 #if MRG_IDX_CTX_RED226 188 { CNU, }, 227 189 { 122, }, 228 190 { 137, }, 229 #else 230 { CNU, CNU, CNU, CNU, }, 231 { 122, 138, 153, 182, }, 232 { 137, 139, 154, 139, }, 233 #endif 234 }; 235 236 #if HHI_INTER_VIEW_RESIDUAL_PRED 191 }; 192 193 #if H3D_IVRP 237 194 static const UChar 238 195 INIT_RES_PRED_FLAG[3][NUM_RES_PRED_FLAG_CTX] = … … 252 209 }; 253 210 254 #if AMP_CTX255 211 static const UChar 256 212 INIT_CU_AMP_POS[3][NUM_CU_AMP_CTX] = … … 260 216 { 154, }, 261 217 }; 262 #else263 static const UChar264 INIT_CU_X_POS[3][NUM_CU_X_POS_CTX] =265 {266 { CNU, CNU, },267 { 154, 139, },268 { 154, 139, },269 };270 271 static const UChar272 INIT_CU_Y_POS[3][NUM_CU_Y_POS_CTX] =273 {274 { CNU, CNU, },275 { 154, 154, },276 { 154, 139, },277 };278 #endif279 218 280 219 static const UChar … … 354 293 }; 355 294 356 #if LAST_CTX_REDUCTION357 295 static const UChar 358 296 INIT_LAST[3][2*NUM_CTX_LAST_FLAG_XY] = … … 368 306 }, 369 307 }; 370 #else371 static const UChar372 INIT_LAST[3][2*NUM_CTX_LAST_FLAG_XY] =373 {374 { 110, 110, 124, 110, 140, 111, 124, 125, 111, 127, 111, 138, 111, 156, 127, 127, 111, 94,375 108, 123, 63, 63, 139, 124, 93, 108, 125, 111, 110, 63, CNU, CNU, CNU, CNU, CNU, CNU,376 },377 { 125, 110, 124, 110, 125, 110, 153, 125, 111, 111, 110, 153, 139, 111, 111, 111, 125, 139,378 108, 123, 108, 152, 124, 94, 123, 137, 139, 110, 110, 154, CNU, CNU, CNU, CNU, CNU, CNU,379 },380 { 125, 110, 124, 110, 125, 110, 153, 125, 111, 111, 110, 153, 139, 111, 111, 111, 125, 139,381 108, 123, 93, 152, 124, 94, 123, 152, 139, 110, 110, 154, CNU, CNU, CNU, CNU, CNU, CNU,382 },383 };384 #endif385 308 386 309 static const UChar … … 406 329 }; 407 330 408 #if LEVEL_CTX_LUMA_RED409 331 static const UChar 410 332 INIT_ONE_FLAG[3][NUM_ONE_FLAG_CTX] = … … 415 337 }; 416 338 417 #if RESTRICT_GR1GR2FLAG_NUMBER418 339 static const UChar 419 340 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] = … … 423 344 { 107, 167, 91, 107, 107, 167, }, 424 345 }; 425 #else426 static const UChar427 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =428 {429 { 138, 139, 111, 153, 139, 111, 136, 167, 139, 167, 153, 139, 152, 139, 140, 152, 184, 141, },430 { 107, 153, 125, 167, 153, 140, 91, 137, 153, 122, 167, 139, 107, 153, 140, 167, 183, 140, },431 { 107, 153, 125, 167, 153, 140, 91, 137, 153, 107, 167, 139, 107, 153, 140, 167, 183, 140, },432 };433 #endif434 #else435 static const UChar436 INIT_ONE_FLAG[3][NUM_ONE_FLAG_CTX] =437 {438 { 140, 92, 137, 138, 140, 152, 138, 139, 126, 168, 139, 139, 153, 74, 149, 92, 139, 107, 122, 152, 110, 93, 152, 138, 140, 179, 166, 182, 140, 227, 122, 197, },439 { 154, 196, 196, 167, 154, 152, 167, 182, 155, 139, 139, 139, 182, 134, 149, 136, 153, 121, 136, 137, 139, 122, 152, 167, 169, 194, 166, 167, 154, 167, 137, 182, },440 { 154, 196, 167, 167, 154, 152, 167, 182, 155, 139, 139, 139, 182, 134, 149, 136, 153, 121, 136, 122, 139, 107, 152, 152, 169, 208, 166, 167, 154, 152, 167, 182, },441 };442 443 #if RESTRICT_GR1GR2FLAG_NUMBER444 static const UChar445 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =446 {447 { 138, 153, 139, 136, 167, 153, 152, 152, },448 { 107, 167, 139, 91, 122, 152, 107, 167, },449 { 107, 167, 139, 91, 107, 93, 107, 167, },450 };451 #else452 static const UChar453 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =454 {455 { 138, 139, 111, 153, 139, 111, 139, 125, 111, 136, 167, 139, 167, 153, 139, 153, 139, 110, 152, 139, 140, 152, 184, 141, },456 { 107, 153, 125, 167, 153, 140, 139, 154, 155, 91, 137, 153, 122, 167, 139, 152, 138, 139, 107, 153, 140, 167, 183, 140, },457 { 107, 153, 125, 167, 153, 140, 139, 154, 155, 91, 137, 153, 107, 167, 139, 93, 138, 139, 107, 153, 140, 167, 183, 140, },458 };459 #endif460 #endif461 346 462 347 static const UChar … … 516 401 }; 517 402 518 #if SAO_UNIT_INTERLEAVING519 403 static const UChar 520 404 INIT_SAO_MERGE_LEFT_FLAG[3][NUM_SAO_MERGE_LEFT_FLAG_CTX] = … … 540 424 { 200, 140, }, 541 425 }; 542 #endif543 426 544 427 static const UChar … … 549 432 { CNU, 153, 138, 138, CNU, CNU, CNU, CNU, CNU, CNU, }, 550 433 }; 434 435 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX 436 #if FIX_DMM_CTX_INIT_C0034 437 static const UChar 551 438 #else 439 static const Short 440 #endif 441 INIT_DMM_FLAG[3][NUM_DMM_FLAG_CTX] = 442 { 443 { 444 CNU 445 }, 446 { 447 CNU 448 }, 449 { 450 CNU 451 } 452 }; 453 454 #if FIX_DMM_CTX_INIT_C0034 552 455 static const UChar 553 INIT_SPLIT_FLAG[3][NUM_SPLIT_FLAG_CTX] = 554 { 555 { 556 87, 74, 107, 557 558 },559 {560 84, 103, 105,561 562 },563 {564 84, 103, 105,565 566 } ,567 }; 568 569 // initial probability for skip flag 456 #else 457 static const Short 458 #endif 459 INIT_DMM_MODE[3][NUM_DMM_MODE_CTX] = 460 { 461 { 462 CNU 463 }, 464 { 465 CNU 466 }, 467 { 468 CNU 469 } 470 }; 471 472 #if FIX_DMM_CTX_INIT_C0034 570 473 static const UChar 571 INIT_SKIP_FLAG[3][NUM_SKIP_FLAG_CTX] =572 {573 {574 CNU, CNU, CNU,575 576 },577 {578 165, 168, 154,579 580 },581 {582 165, 168, 154,583 584 },585 };586 587 // initial probability for skip flag588 static const UChar589 INIT_ALF_CTRL_FLAG[3][NUM_ALF_CTRL_FLAG_CTX] =590 {591 {592 153,593 594 },595 {596 87,597 598 },599 {600 135,601 602 },603 };604 605 // initial probability for merge flag606 static const UChar607 INIT_MERGE_FLAG_EXT[3][NUM_MERGE_FLAG_EXT_CTX] =608 {609 {610 CNU,611 612 },613 {614 72,615 616 },617 {618 119,619 620 },621 };622 623 static const UChar624 INIT_MERGE_IDX_EXT[3][NUM_MERGE_IDX_EXT_CTX] =625 {626 #if MRG_IDX_CTX_RED627 {628 CNU,629 630 },631 {632 100,633 634 },635 {636 116,637 },638 474 #else 639 { 640 CNU, CNU, CNU, CNU, 641 642 }, 643 { 644 100, 86, 102, 133, 645 646 }, 647 { 648 116, 87, 119, 103, 649 650 }, 651 #endif 652 }; 653 654 // initial probability for PU size 655 static const UChar 656 INIT_PART_SIZE[3][NUM_PART_SIZE_CTX] = 657 { 658 { 659 167, CNU, CNU, CNU, 660 661 }, 662 { 663 119, 87, CNU, CNU, 664 665 }, 666 { 667 119, 87, CNU, CNU, 668 669 }, 670 }; 671 #if AMP_CTX 672 static const UChar 673 INIT_CU_AMP_POS[3][NUM_CU_AMP_CTX] = 674 { 675 { 676 CNU, 677 }, 678 { 679 119, 680 }, 681 { 682 119, 683 }, 684 }; 475 static const Short 476 #endif 477 INIT_DMM_DATA[3][NUM_DMM_DATA_CTX] = 478 { 479 #if LGE_DMM3_SIMP_C0044 480 { 481 CNU, CNU, CNU, CNU 482 }, 483 { 484 CNU, CNU, CNU, CNU 485 }, 486 { 487 CNU, CNU, CNU, CNU 488 } 685 489 #else 686 // initial probability for AMP split position (X)687 static const UChar688 INIT_CU_X_POS[3][NUM_CU_X_POS_CTX] =689 {690 {691 CNU, CNU,692 693 },694 {695 119, 103,696 697 },698 {699 119, 103,700 701 },702 };703 704 // initial probability for AMP split position (Y)705 static const UChar706 INIT_CU_Y_POS[3][NUM_CU_Y_POS_CTX] =707 {708 {709 CNU, CNU,710 711 },712 {713 119, 119,714 715 },716 {717 119, 103,718 719 },720 };721 #endif722 // initial probability for prediction mode723 static const UChar724 INIT_PRED_MODE[3][NUM_PRED_MODE_CTX] =725 {726 {727 CNU,728 729 },730 {731 114,732 733 },734 {735 98,736 737 },738 };739 740 // initial probability for intra direction of luma741 static const UChar742 INIT_INTRA_PRED_MODE[3][NUM_ADI_CTX] =743 {744 {745 167,746 747 },748 {749 119,750 751 },752 {753 150,754 755 },756 };757 758 // initial probability for intra direction of chroma759 static const UChar760 INIT_CHROMA_PRED_MODE[3][NUM_CHROMA_PRED_CTX] =761 {762 {763 53, 103,764 765 },766 {767 85, 87,768 769 },770 {771 101, 87,772 773 },774 };775 776 // initial probability for temporal direction777 static const UChar778 INIT_INTER_DIR[3][NUM_INTER_DIR_CTX] =779 {780 {781 CNU, CNU, CNU, CNU,782 783 },784 {785 CNU, CNU, CNU, CNU,786 787 },788 {789 41, 39, 38, 36,790 791 },792 };793 794 // initial probability for motion vector difference795 static const UChar796 INIT_MVD[3][NUM_MV_RES_CTX] =797 {798 {799 CNU, CNU,800 801 },802 {803 120, 166,804 805 },806 {807 135, 166,808 809 },810 };811 812 // initial probability for reference frame index813 static const UChar814 INIT_REF_PIC[3][NUM_REF_NO_CTX] =815 {816 {817 CNU, CNU, CNU, CNU,818 819 },820 {821 102, 118, 103, CNU,822 823 },824 {825 118, 118, 134, CNU,826 827 },828 };829 830 // initial probability for dQP831 static const UChar832 INIT_DQP[3][NUM_DELTA_QP_CTX] =833 {834 {835 CNU, CNU, CNU,836 837 },838 {839 CNU, CNU, CNU,840 841 },842 {843 CNU, CNU, CNU,844 845 },846 };847 848 static const UChar849 INIT_QT_CBF[3][2*NUM_QT_CBF_CTX] =850 {851 {852 73, 74, CNU, CNU, CNU,853 55, 86, 133, CNU, CNU,854 855 },856 {857 102, 89, CNU, CNU, CNU,858 114, 84, 117, CNU, CNU,859 860 },861 {862 102, 89, CNU, CNU, CNU,863 114, 68, 117, CNU, CNU,864 865 },866 };867 868 static const UChar869 INIT_QT_ROOT_CBF[3][NUM_QT_ROOT_CBF_CTX] =870 {871 {872 CNU,873 874 },875 {876 39,877 878 },879 {880 39,881 882 },883 };884 885 #if LAST_CTX_REDUCTION886 static const UChar887 INIT_LAST[3][2*NUM_CTX_LAST_FLAG_XY] =888 {889 {890 72, 72, 71, 72, 104, 89, 88, 89, 59, 73, 89, 106, 60, 59, 43,891 54, 70, 53, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU,892 },893 {894 57, 72, 55, 72, 57, 72, 88, 73, 73, 72, 103, 73, 89, 73, 57,895 54, 70, 54, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU,896 },897 {898 88, 72, 71, 72, 57, 72, 88, 73, 73, 72, 103, 73, 89, 73, 57,899 54, 70, 69, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU, CNU,900 },901 };902 #else903 static const UChar904 INIT_LAST[3][2*NUM_CTX_LAST_FLAG_XY] =905 {906 {907 72, 72, 71, 72, 104, 89, 71, 88, 89, 59, 73, 86, 89, 106, 60, 59, 43, 55,908 54, 70, 53, 53, 87, 71, 69, 54, 88, 73, 72, 53, CNU, CNU, CNU, CNU, CNU, CNU,909 910 },911 {912 57, 72, 71, 72, 57, 72, 102, 88, 73, 73, 72, 102, 103, 73, 89, 73, 57, 87,913 54, 70, 54, 101, 71, 55, 70, 116, 103, 72, 72, 119, CNU, CNU, CNU, CNU, CNU, CNU,914 915 },916 {917 88, 72, 71, 72, 57, 72, 102, 88, 73, 73, 72, 118, 103, 73, 89, 73, 57, 87,918 54, 70, 69, 85, 71, 55, 70, 85, 103, 72, 72, 119, CNU, CNU, CNU, CNU, CNU, CNU,919 920 },921 };922 #endif923 924 static const UChar925 INIT_SIG_CG_FLAG[3][2 * NUM_SIG_CG_FLAG_CTX] =926 {927 {928 83, 122,929 98, 121,930 931 },932 {933 99, 120,934 67, 119,935 936 },937 {938 99, 120,939 67, 119,940 941 },942 };943 944 static const UChar945 INIT_SIG_FLAG[3][NUM_SIG_FLAG_CTX] =946 {947 {948 74, 73, 88, 72, 72, 55, 71, 54, 71, 88, 103, 71, 53, 87, 134, 86, 84, 70, 68, 89, 90, 84, 88, 74, 130, 118, 88,949 120, 87, 149, 70, 52, 118, 133, 116, 114, 129, 132, 162, 115, 51, 115, 66, 120, 74, 115, 87, 89,950 },951 {952 152, 119, 103, 118, 87, 70, 70, 53, 118, 134, 118, 101, 68, 85, 101, 116, 100, 68, 67, 136, 168, 147, 150, 120, 115, 118, 119,953 136, 102, 70, 53, 67, 117, 102, 117, 115, 114, 84, 115, 99, 100, 83, 114, 152, 168, 131, 150, 120,954 },955 {956 152, 119, 103, 118, 87, 70, 70, 53, 71, 103, 118, 101, 68, 85, 101, 116, 116, 68, 67, 152, 168, 147, 150, 120, 115, 118, 119,957 136, 102, 86, 84, 67, 117, 102, 117, 115, 99, 100, 115, 99, 100, 83, 114, 152, 152, 131, 150, 120,958 },959 };960 961 #if LEVEL_CTX_LUMA_RED962 static const UChar963 INIT_ONE_FLAG[3][NUM_ONE_FLAG_CTX] =964 {965 {966 104, 68, 116, 86, 104, 132, 86, 87, 102, 66, 114, 68, 87, 84, 100, 101,967 104, 130, 147, 149, 104, 196, 100, 165,968 },969 {970 119, 179, 179, 164, 119, 85, 117, 149, 133, 98, 114, 115, 118, 99, 115, 116,971 135, 146, 147, 164, 119, 148, 116, 133,972 },973 {974 119, 179, 148, 164, 119, 85, 117, 149, 133, 98, 114, 115, 118, 99, 115, 100,975 135, 177, 147, 164, 119, 132, 148, 149,976 },977 };978 979 #if RESTRICT_GR1GR2FLAG_NUMBER980 static const UChar981 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =982 {983 {984 86, 102, 115, 117, 101, 101,985 },986 {987 84, 117, 83, 100, 84, 117,988 },989 {990 84, 117, 83, 84, 84, 117,991 },992 };993 #else994 static const UChar995 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =996 {997 {998 86, 103, 73, 102, 103, 73, 115, 117, 103, 117, 118, 103,999 101, 103, 104, 101, 167, 121,1000 },1001 {1002 84, 102, 88, 117, 118, 104, 83, 116, 118, 100, 117, 87,1003 84, 118, 120, 117, 150, 120,1004 },1005 {1006 84, 102, 88, 117, 118, 104, 83, 116, 118, 84, 117, 87,1007 84, 118, 120, 117, 150, 120,1008 },1009 };1010 #endif1011 #else1012 static const UChar1013 INIT_ONE_FLAG[3][NUM_ONE_FLAG_CTX] =1014 {1015 {1016 104, 68, 116, 86, 104, 132, 86, 87, 105, 134, 87, 103, 102, 66, 114, 68, 87, 84, 100, 101, 72, 69, 101, 86,1017 104, 130, 147, 149, 104, 196, 100, 165,1018 },1019 {1020 119, 179, 179, 164, 119, 85, 117, 149, 136, 103, 103, 103, 133, 98, 114, 115, 118, 99, 115, 116, 87, 100, 85, 117,1021 135, 146, 147, 164, 119, 148, 116, 133,1022 },1023 {1024 119, 179, 148, 164, 119, 85, 117, 149, 136, 87, 103, 103, 133, 98, 114, 115, 118, 99, 115, 100, 87, 84, 85, 85,1025 135, 177, 147, 164, 119, 132, 148, 149,1026 },1027 };1028 1029 #if RESTRICT_GR1GR2FLAG_NUMBER1030 static const UChar1031 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =1032 {1033 {1034 86, 102, 103, 115, 117, 102, 101, 101,1035 },1036 {1037 84, 117, 103, 83, 100, 85, 84, 117,1038 },1039 {1040 84, 117, 87, 83, 84, 69, 84, 117,1041 },1042 };1043 #else1044 static const UChar1045 INIT_ABS_FLAG[3][NUM_ABS_FLAG_CTX] =1046 {1047 {1048 86, 103, 73, 102, 103, 73, 103, 88, 89, 115, 117, 103, 117, 118, 103, 102, 103, 72,1049 101, 103, 104, 101, 167, 121,1050 },1051 {1052 84, 102, 88, 117, 118, 104, 103, 119, 136, 83, 116, 118, 100, 117, 87, 85, 86, 103,1053 84, 118, 120, 117, 150, 120,1054 },1055 {1056 84, 102, 88, 117, 118, 104, 87, 119, 136, 83, 116, 118, 84, 117, 87, 69, 86, 87,1057 84, 118, 120, 117, 150, 120,1058 },1059 };1060 #endif1061 #endif1062 // initial probability for motion vector predictor index1063 static const UChar1064 INIT_MVP_IDX[3][NUM_MVP_IDX_CTX] =1065 {1066 {1067 CNU, CNU,1068 1069 },1070 {1071 134, CNU,1072 1073 },1074 {1075 134, CNU,1076 1077 },1078 };1079 1080 // initial probability for ALF flag1081 static const UChar1082 INIT_ALF_FLAG[3][NUM_ALF_FLAG_CTX] =1083 {1084 {1085 118,1086 1087 },1088 {1089 102,1090 1091 },1092 {1093 102,1094 1095 },1096 };1097 1098 // initial probability for ALF side information (unsigned)1099 static const UChar1100 INIT_ALF_UVLC[3][NUM_ALF_UVLC_CTX] =1101 {1102 {1103 120, 119,1104 1105 },1106 {1107 119, 119,1108 1109 },1110 {1111 119, 119,1112 1113 },1114 };1115 1116 // initial probability for ALF side information (signed)1117 static const UChar1118 INIT_ALF_SVLC[3][NUM_ALF_SVLC_CTX] =1119 {1120 {1121 139, 119, 124,1122 1123 },1124 {1125 90, 119, 140,1126 1127 },1128 {1129 90, 119, 124,1130 1131 },1132 };1133 1134 // initial probability for SAO flag1135 static const UChar1136 INIT_SAO_FLAG[3][NUM_SAO_FLAG_CTX] =1137 {1138 {1139 119,1140 1141 },1142 {1143 102,1144 1145 },1146 {1147 102,1148 1149 },1150 };1151 1152 // initial probability for SAO side information (unsigned)1153 static const UChar1154 INIT_SAO_UVLC[3][NUM_SAO_UVLC_CTX] =1155 {1156 {1157 61, 104,1158 1159 },1160 {1161 168, 120,1162 1163 },1164 {1165 184, 120,1166 1167 },1168 };1169 1170 // initial probability for SAO side information (signed)1171 static const UChar1172 INIT_SAO_SVLC[3][NUM_SAO_SVLC_CTX] =1173 {1174 {1175 171, 119, 199,1176 1177 },1178 {1179 169, 119, 151,1180 1181 },1182 {1183 169, 119, 151,1184 1185 },1186 };1187 1188 #if SAO_UNIT_INTERLEAVING1189 static const UChar1190 INIT_SAO_MERGE_LEFT_FLAG[3][NUM_SAO_MERGE_LEFT_FLAG_CTX] =1191 {1192 {1193 118, 118, 118,1194 },1195 {1196 102, 102, 102,1197 },1198 {1199 102, 102, 102,1200 },1201 };1202 1203 static const UChar1204 INIT_SAO_MERGE_UP_FLAG[3][NUM_SAO_MERGE_UP_FLAG_CTX] =1205 {1206 {1207 109,1208 },1209 {1210 102,1211 },1212 {1213 102,1214 },1215 };1216 static const UChar1217 INIT_SAO_TYPE_IDX[3][NUM_SAO_TYPE_IDX_CTX] =1218 {1219 {1220 64, 1041221 },1222 {1223 168, 1201224 },1225 {1226 184, 1201227 },1228 };1229 static const Short1230 INIT_SAO_RUN[3][NUM_SAO_RUN_CTX][2] =1231 {1232 {1233 { 11, 57 }, { -1, 62 }, { 0, 64 }1234 },1235 {1236 { 6, 66 }, { -1, 64 }, { 0, 64 }1237 },1238 {1239 { 1, 73 }, { 2, 61 }, { 0, 64 }1240 }1241 };1242 #endif1243 1244 static const UChar1245 INIT_TRANS_SUBDIV_FLAG[3][NUM_TRANS_SUBDIV_FLAG_CTX] =1246 {1247 {1248 CNU, 162, 148, 100, CNU, CNU, CNU, CNU, CNU, CNU,1249 1250 },1251 {1252 CNU, 71, 86, 55, CNU, CNU, CNU, CNU, CNU, CNU,1253 1254 },1255 {1256 CNU, 102, 86, 86, CNU, CNU, CNU, CNU, CNU, CNU,1257 1258 },1259 };1260 #endif1261 1262 #if HHI_DMM_WEDGE_INTRA || HHI_DMM_PRED_TEX1263 static const Short1264 INIT_DMM_FLAG[3][NUM_DMM_FLAG_CTX] =1265 {1266 {1267 CNU1268 },1269 {1270 CNU1271 },1272 {1273 CNU1274 }1275 };1276 1277 static const Short1278 INIT_DMM_MODE[3][NUM_DMM_MODE_CTX] =1279 {1280 {1281 CNU1282 },1283 {1284 CNU1285 },1286 {1287 CNU1288 }1289 };1290 1291 static const Short1292 INIT_DMM_DATA[3][NUM_DMM_DATA_CTX] =1293 {1294 490 { 1295 491 CNU, CNU, CNU … … 1301 497 CNU, CNU, CNU 1302 498 } 499 #endif 1303 500 }; 1304 501
Note: See TracChangeset for help on using the changeset viewer.