Blender V4.3
blender::compositor::WorkScheduler Struct Reference

the workscheduler More...

#include <COM_WorkScheduler.h>

Static Public Member Functions

Public API
static void schedule (WorkPackage *package)
 schedule a chunk of a group to be calculated. An execution group schedules a chunk in the WorkScheduler
 
static void initialize (int num_cpu_threads)
 initialize the WorkScheduler
 
static void deinitialize ()
 deinitialize the WorkScheduler free all allocated resources
 
static void start ()
 Start the execution this methods will start the WorkScheduler. Inside this method all threads are initialized. for every device a thread is created.
 
static void stop ()
 stop the execution All created thread by the start method are destroyed.
 
static void finish ()
 wait for all work to be completed.
 
static int get_num_cpu_threads ()
 
static int current_thread_id ()
 

Detailed Description

the workscheduler

Definition at line 18 of file COM_WorkScheduler.h.

Member Function Documentation

◆ current_thread_id()

◆ deinitialize()

void blender::compositor::WorkScheduler::deinitialize ( )
static

◆ finish()

◆ get_num_cpu_threads()

int blender::compositor::WorkScheduler::get_num_cpu_threads ( )
static

◆ initialize()

void blender::compositor::WorkScheduler::initialize ( int num_cpu_threads)
static

initialize the WorkScheduler

during initialization the mutexes are initialized. there are two mutexes (for every device type one) After mutex initialization the system is queried in order to count the number of CPUDevices to be created. For every hardware thread a CPUDevice is created.

Definition at line 263 of file COM_WorkScheduler.cc.

References blender::compositor::COM_threading_model(), blender::compositor::g_work_scheduler, blender::compositor::num_cpu_threads, blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, and blender::compositor::threading_model_queue_initialize().

Referenced by COM_execute().

◆ schedule()

◆ start()

void blender::compositor::WorkScheduler::start ( )
static

Start the execution this methods will start the WorkScheduler. Inside this method all threads are initialized. for every device a thread is created.

See also
initialize Initialization and query of the number of devices

Definition at line 212 of file COM_WorkScheduler.cc.

References blender::compositor::COM_threading_model(), blender::compositor::Queue, blender::compositor::SingleThreaded, blender::compositor::Task, blender::compositor::threading_model_queue_start(), and blender::compositor::threading_model_task_start().

Referenced by blender::compositor::ConstantFolder::fold_operations().

◆ stop()

void blender::compositor::WorkScheduler::stop ( )
static

The documentation for this struct was generated from the following files: