C# Класс BooRunner.Tools.Bits

Contains helping methods to with with bits in dword (UInt32).
Показать файл Открыть проект

Открытые методы

Метод Описание
CeilLog2 ( uint x ) : int

Ceil(Log2(x)).

Msb ( uint x ) : int

Counts position of the most significant bit in int. Can also be used as Floor(Log2(x)).

Nlz ( uint x ) : int

Returns number of leading zero bits in int.

Описание методов

CeilLog2() публичный статический Метод

Ceil(Log2(x)).
public static CeilLog2 ( uint x ) : int
x uint Int value.
Результат int

Msb() публичный статический Метод

Counts position of the most significant bit in int. Can also be used as Floor(Log2(x)).
public static Msb ( uint x ) : int
x uint Int value.
Результат int

Nlz() публичный статический Метод

Returns number of leading zero bits in int.
public static Nlz ( uint x ) : int
x uint Int value.
Результат int