tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

h265_inline.cc (1056B)


      1 /*
      2 *  Copyright (c) 2023 The WebRTC project authors. All Rights Reserved.
      3 *
      4 *  Use of this source code is governed by a BSD-style license
      5 *  that can be found in the LICENSE file in the root of the source
      6 *  tree. An additional intellectual property rights grant can be found
      7 *  in the file PATENTS.  All contributing project authors may
      8 *  be found in the AUTHORS file in the root of the source tree.
      9 */
     10 
     11 #include "common_video/h265/h265_inline.h"
     12 
     13 #include <cstdint>
     14 
     15 // Table used by WebRtcVideo_CountLeadingZeros32_NotBuiltin. For each uint32_t n
     16 // that's a sequence of 0 bits followed by a sequence of 1 bits, the entry at
     17 // index (n * 0x8c0b2891) >> 26 in this table gives the number of zero bits in
     18 // n.
     19 const int8_t kWebRtcVideo_CountLeadingZeros32_Table[64] = {
     20    32, 8,  17, -1, -1, 14, -1, -1, -1, 20, -1, -1, -1, 28, -1, 18,
     21    -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 0,  26, 25, 24,
     22    4,  11, 23, 31, 3,  7,  10, 16, 22, 30, -1, -1, 2,  6,  13, 9,
     23    -1, 15, -1, 21, -1, 29, 19, -1, -1, -1, -1, -1, 1,  27, 5,  12,
     24 };