Blender V4.5
types_base.h File Reference
#include <cstdlib>
#include <cstdint>
#include <cstdio>
#include "util/defines.h"
#include "util/optimization.h"
#include "util/simd.h"

Go to the source code of this file.

Macros

#define __KERNEL_PRINTF__
 

Typedefs

using uchar = unsigned char
 
using uint = unsigned int
 
using ushort = unsigned short
 
using device_ptr = uint64_t
 

Functions

ccl_device_inline size_t align_up (const size_t offset, const size_t alignment)
 
ccl_device_inline size_t divide_up (const size_t x, const size_t y)
 
ccl_device_inline size_t round_up (const size_t x, const size_t multiple)
 
ccl_device_inline size_t round_down (const size_t x, const size_t multiple)
 
ccl_device_inline bool is_power_of_two (const size_t x)
 
ccl_device_inline void print_float (const ccl_private char *label, const float a)
 

Macro Definition Documentation

◆ __KERNEL_PRINTF__

#define __KERNEL_PRINTF__

Definition at line 76 of file types_base.h.

Typedef Documentation

◆ device_ptr

Definition at line 44 of file types_base.h.

◆ uchar

using uchar = unsigned char

Definition at line 35 of file types_base.h.

◆ uint

using uint = unsigned int

Definition at line 36 of file types_base.h.

◆ ushort

using ushort = unsigned short

Definition at line 37 of file types_base.h.

Function Documentation

◆ align_up()

ccl_device_inline size_t align_up ( const size_t offset,
const size_t alignment )

◆ divide_up()

◆ is_power_of_two()

ccl_device_inline bool is_power_of_two ( const size_t x)

◆ print_float()

ccl_device_inline void print_float ( const ccl_private char * label,
const float a )

Definition at line 79 of file types_base.h.

References label, and printf.

◆ round_down()

ccl_device_inline size_t round_down ( const size_t x,
const size_t multiple )

Definition at line 62 of file types_base.h.

References x.

◆ round_up()

ccl_device_inline size_t round_up ( const size_t x,
const size_t multiple )

Definition at line 57 of file types_base.h.

References x.

Referenced by blender::RandomNumberGenerator::round_probabilistic().