Panda3D
|
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University. More...
Go to the source code of this file.
Functions | |
int | count_bits_in_word (unsigned int x) |
Returns the number of 1 bits in the indicated word. More... | |
int | count_bits_in_word (unsigned long long x) |
Returns the number of 1 bits in the indicated word. More... | |
int | count_bits_in_word (unsigned long x) |
Returns the number of 1 bits in the indicated word. More... | |
int | count_bits_in_word (unsigned short x) |
Returns the number of 1 bits in the indicated word. More... | |
unsigned int | flood_bits_down (unsigned int x) |
Returns a value such that every bit at or below the highest bit in x is 1. More... | |
unsigned long long | flood_bits_down (unsigned long long x) |
Returns a value such that every bit at or below the highest bit in x is 1. More... | |
unsigned long | flood_bits_down (unsigned long x) |
Returns a value such that every bit at or below the highest bit in x is 1. More... | |
unsigned short | flood_bits_down (unsigned short x) |
Returns a value such that every bit at or below the highest bit in x is 1. More... | |
unsigned int | flood_bits_up (unsigned int x) |
Returns a value such that every bit at or above the highest bit in x is 1. More... | |
unsigned long long | flood_bits_up (unsigned long long x) |
Returns a value such that every bit at or above the highest bit in x is 1. More... | |
unsigned long | flood_bits_up (unsigned long x) |
Returns a value such that every bit at or above the highest bit in x is 1. More... | |
unsigned short | flood_bits_up (unsigned short x) |
Returns a value such that every bit at or above the highest bit in x is 1. More... | |
int | get_highest_on_bit (unsigned int x) |
Returns the index of the highest 1 bit in the word. More... | |
int | get_highest_on_bit (unsigned long long x) |
Returns the index of the highest 1 bit in the word. More... | |
int | get_highest_on_bit (unsigned long x) |
Returns the index of the highest 1 bit in the word. More... | |
int | get_highest_on_bit (unsigned short x) |
Returns the index of the highest 1 bit in the word. More... | |
int | get_lowest_on_bit (unsigned int x) |
Returns the index of the lowest 1 bit in the word. More... | |
int | get_lowest_on_bit (unsigned long long x) |
Returns the index of the lowest 1 bit in the word. More... | |
int | get_lowest_on_bit (unsigned long x) |
Returns the index of the lowest 1 bit in the word. More... | |
int | get_lowest_on_bit (unsigned short x) |
Returns the index of the lowest 1 bit in the word. More... | |
int | get_next_higher_bit (unsigned int x) |
Returns the smallest power of 2 greater than x. More... | |
int | get_next_higher_bit (unsigned long long x) |
Returns the smallest power of 2 greater than x. More... | |
int | get_next_higher_bit (unsigned long x) |
Returns the smallest power of 2 greater than x. More... | |
int | get_next_higher_bit (unsigned short x) |
Returns the smallest power of 2 greater than x. More... | |
Variables | |
EXPCL_PANDA_PUTIL const unsigned char | num_bits_on [65536] |
PANDA 3D SOFTWARE Copyright (c) Carnegie Mellon University.
All rights reserved.
All use of this software is subject to the terms of the revised BSD license. You should have received a copy of this license along with this source code in a file named "LICENSE."
Definition in file pbitops.h.
|
inline |
|
inline |
Returns the number of 1 bits in the indicated word.
Definition at line 52 of file pbitops.I.
References count_bits_in_word().
|
inline |
Returns the number of 1 bits in the indicated word.
Definition at line 38 of file pbitops.I.
References count_bits_in_word().
|
inline |
Returns the number of 1 bits in the indicated word.
Definition at line 18 of file pbitops.I.
Referenced by count_bits_in_word(), get_highest_on_bit(), and get_lowest_on_bit().
|
inline |
|
inline |
|
inline |
|
inline |
Returns a value such that every bit at or below the highest bit in x is 1.
Definition at line 64 of file pbitops.I.
Referenced by get_highest_on_bit().
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Returns the index of the highest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 276 of file pbitops.I.
References count_bits_in_word(), and flood_bits_down().
|
inline |
Returns the index of the highest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 310 of file pbitops.I.
References count_bits_in_word(), and flood_bits_down().
|
inline |
Returns the index of the highest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 293 of file pbitops.I.
References count_bits_in_word(), and flood_bits_down().
|
inline |
Returns the index of the highest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 259 of file pbitops.I.
References count_bits_in_word(), and flood_bits_down().
Referenced by get_next_higher_bit().
|
inline |
Returns the index of the lowest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 196 of file pbitops.I.
References count_bits_in_word().
|
inline |
Returns the index of the lowest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 238 of file pbitops.I.
References count_bits_in_word().
|
inline |
Returns the index of the lowest 1 bit in the word.
Returns -1 if there are no 1 bits.
Definition at line 217 of file pbitops.I.
References count_bits_in_word().
|
inline |
|
inline |
Returns the smallest power of 2 greater than x.
Returns the smallest number n such that (1 << n) is larger than x.
Definition at line 338 of file pbitops.I.
References get_highest_on_bit().
|
inline |
Returns the smallest power of 2 greater than x.
Returns the smallest number n such that (1 << n) is larger than x.
Definition at line 358 of file pbitops.I.
References get_highest_on_bit().
|
inline |
Returns the smallest power of 2 greater than x.
Returns the smallest number n such that (1 << n) is larger than x.
Definition at line 348 of file pbitops.I.
References get_highest_on_bit().
|
inline |
Returns the smallest power of 2 greater than x.
Returns the smallest number n such that (1 << n) is larger than x.
Definition at line 328 of file pbitops.I.
References get_highest_on_bit().
Referenced by Texture::down_to_power_2(), and Texture::up_to_power_2().