Blender  V2.93
Macros | Functions
math_bits_inline.c File Reference
#include "BLI_math_bits.h"

Go to the source code of this file.

Macros

#define __MATH_BITS_INLINE_C__
 

Functions

MINLINE unsigned int bitscan_forward_uint (unsigned int a)
 
MINLINE unsigned int bitscan_forward_uint64 (unsigned long long a)
 
MINLINE int bitscan_forward_i (int a)
 
MINLINE unsigned int bitscan_forward_clear_uint (unsigned int *a)
 
MINLINE int bitscan_forward_clear_i (int *a)
 
MINLINE unsigned int bitscan_reverse_uint (unsigned int a)
 
MINLINE unsigned int bitscan_reverse_uint64 (unsigned long long a)
 
MINLINE int bitscan_reverse_i (int a)
 
MINLINE unsigned int bitscan_reverse_clear_uint (unsigned int *a)
 
MINLINE int bitscan_reverse_clear_i (int *a)
 
MINLINE unsigned int highest_order_bit_uint (unsigned int n)
 
MINLINE unsigned short highest_order_bit_s (unsigned short n)
 
MINLINE int count_bits_i (unsigned int i)
 
MINLINE int float_as_int (float f)
 
MINLINE unsigned int float_as_uint (float f)
 
MINLINE float int_as_float (int i)
 
MINLINE float uint_as_float (unsigned int i)
 
MINLINE float xor_fl (float x, int y)
 

Macro Definition Documentation

◆ __MATH_BITS_INLINE_C__

#define __MATH_BITS_INLINE_C__

Definition at line 22 of file math_bits_inline.c.

Function Documentation

◆ bitscan_forward_clear_i()

MINLINE int bitscan_forward_clear_i ( int *  a)

Definition at line 66 of file math_bits_inline.c.

References Freestyle::a, and bitscan_forward_clear_uint().

Referenced by blender::deg::graph_id_tag_update().

◆ bitscan_forward_clear_uint()

MINLINE unsigned int bitscan_forward_clear_uint ( unsigned int *  a)

Definition at line 59 of file math_bits_inline.c.

References Freestyle::a, and bitscan_forward_uint().

Referenced by bitscan_forward_clear_i().

◆ bitscan_forward_i()

MINLINE int bitscan_forward_i ( int  a)

Definition at line 54 of file math_bits_inline.c.

References Freestyle::a, and bitscan_forward_uint().

Referenced by applyMirror(), and BKE_subdiv_to_ccg().

◆ bitscan_forward_uint()

MINLINE unsigned int bitscan_forward_uint ( unsigned int  a)

◆ bitscan_forward_uint64()

MINLINE unsigned int bitscan_forward_uint64 ( unsigned long long  a)

Definition at line 42 of file math_bits_inline.c.

References Freestyle::a, and BLI_assert.

◆ bitscan_reverse_clear_i()

MINLINE int bitscan_reverse_clear_i ( int *  a)

Definition at line 107 of file math_bits_inline.c.

References Freestyle::a, and bitscan_reverse_clear_uint().

◆ bitscan_reverse_clear_uint()

MINLINE unsigned int bitscan_reverse_clear_uint ( unsigned int *  a)

Definition at line 100 of file math_bits_inline.c.

References Freestyle::a, and bitscan_reverse_uint().

Referenced by bitscan_reverse_clear_i(), and TEST().

◆ bitscan_reverse_i()

MINLINE int bitscan_reverse_i ( int  a)

Definition at line 95 of file math_bits_inline.c.

References Freestyle::a, and bitscan_reverse_uint().

◆ bitscan_reverse_uint()

MINLINE unsigned int bitscan_reverse_uint ( unsigned int  a)

◆ bitscan_reverse_uint64()

MINLINE unsigned int bitscan_reverse_uint64 ( unsigned long long  a)

Definition at line 83 of file math_bits_inline.c.

References Freestyle::a, and BLI_assert.

◆ count_bits_i()

MINLINE int count_bits_i ( unsigned int  i)

◆ float_as_int()

MINLINE int float_as_int ( float  f)

Definition at line 139 of file math_bits_inline.c.

Referenced by isect_ray_tri_watertight_v3(), and xor_fl().

◆ float_as_uint()

MINLINE unsigned int float_as_uint ( float  f)

Definition at line 149 of file math_bits_inline.c.

◆ highest_order_bit_s()

MINLINE unsigned short highest_order_bit_s ( unsigned short  n)

Definition at line 120 of file math_bits_inline.c.

Referenced by EDBM_selectmode_toggle_multi().

◆ highest_order_bit_uint()

MINLINE unsigned int highest_order_bit_uint ( unsigned int  n)

Definition at line 112 of file math_bits_inline.c.

References bitscan_reverse_uint().

◆ int_as_float()

MINLINE float int_as_float ( int  i)

◆ uint_as_float()

MINLINE float uint_as_float ( unsigned int  i)

Definition at line 169 of file math_bits_inline.c.

◆ xor_fl()

MINLINE float xor_fl ( float  x,
int  y 
)

Definition at line 179 of file math_bits_inline.c.

References float_as_int(), int_as_float(), x, and y.

Referenced by isect_ray_tri_watertight_v3().