![]() |
Ansel 0.0
A darktable fork - bloat + design vision
|
Drawlayer worker global state shared with drawlayer module. More...
Collaboration diagram for dt_drawlayer_worker_t:Data Fields | |
| dt_iop_module_t * | self |
| gboolean * | painting |
| gboolean * | finish_commit_pending |
| guint * | stroke_sample_count |
| uint32_t * | current_stroke_batch |
| dt_pthread_mutex_t | worker_mutex |
| pthread_cond_t | worker_cond |
| drawlayer_rt_worker_t | workers [DRAWLAYER_RT_WORKER_COUNT] |
| GArray * | backend_history |
| GArray * | stroke_raw_inputs |
| dt_drawlayer_paint_stroke_t * | stroke |
| dt_drawlayer_damaged_rect_t * | backend_path |
| dt_drawlayer_cache_patch_t | heartbeat_patch |
| dt_drawlayer_cache_patch_t | heartbeat_stroke_mask |
| float * | heartbeat_transmittance |
| float * | heartbeat_noise |
| size_t | heartbeat_transmittance_capacity |
| gint64 | live_publish_ts |
| uint32_t | live_publish_serial |
| dt_drawlayer_damaged_rect_t | live_publish_damage |
| guint | commit_idle_id |
| dt_iop_drawlayer_params_t | publish_params |
| GArray* dt_drawlayer_worker_t::backend_history |
Emitted dab history owned by worker.
Definition at line 103 of file worker.c.
Referenced by _rt_destroy_state(), _rt_init_state(), _stroke_begin(), _stroke_clear(), and _stroke_create().
| dt_drawlayer_damaged_rect_t* dt_drawlayer_worker_t::backend_path |
Worker-owned backend damage accumulator.
Definition at line 106 of file worker.c.
Referenced by _rasterize_pending_dab_batch(), _reset_backend_path(), _rt_destroy_state(), and _rt_init_state().
| guint dt_drawlayer_worker_t::commit_idle_id |
GUI-thread commit request in flight, 0 when none. Guarded by worker_mutex.
Definition at line 117 of file worker.c.
Referenced by _backend_worker_on_idle(), _cancel_pending_gui_commit(), and _commit_dabs_on_gui_thread().
| uint32_t* dt_drawlayer_worker_t::current_stroke_batch |
External stroke-batch counter mirror.
Definition at line 99 of file worker.c.
Referenced by _enqueue_stroke_end(), and _rt_init_state().
| gboolean* dt_drawlayer_worker_t::finish_commit_pending |
External commit-request flag mirror.
Definition at line 97 of file worker.c.
Referenced by _backend_worker_process_stroke_end(), _enqueue_input(), _rt_init_state(), _workers_active_locked(), _workers_ready_for_commit_locked(), dt_drawlayer_worker_cancel_async_commit(), dt_drawlayer_worker_get_snapshot(), and dt_drawlayer_worker_request_commit().
| float* dt_drawlayer_worker_t::heartbeat_noise |
Worker-private sprinkle field for the batch path, shared by every dab of a batch.
Definition at line 110 of file worker.c.
Referenced by _ensure_heartbeat_batch_buffers(), _rasterize_pending_dab_batch(), and _rt_destroy_state().
| dt_drawlayer_cache_patch_t dt_drawlayer_worker_t::heartbeat_patch |
Worker-private scratch patch for one heartbeat batch.
Definition at line 107 of file worker.c.
Referenced by _ensure_heartbeat_batch_buffers(), _rasterize_pending_dab_batch(), and _rt_destroy_state().
| dt_drawlayer_cache_patch_t dt_drawlayer_worker_t::heartbeat_stroke_mask |
Worker-private stroke mask for one heartbeat batch.
Definition at line 108 of file worker.c.
Referenced by _ensure_heartbeat_batch_buffers(), _rasterize_pending_dab_batch(), and _rt_destroy_state().
| float* dt_drawlayer_worker_t::heartbeat_transmittance |
Worker-private coverage plane for the batch path, one float per patch pixel.
Definition at line 109 of file worker.c.
Referenced by _ensure_heartbeat_batch_buffers(), _rasterize_pending_dab_batch(), and _rt_destroy_state().
| size_t dt_drawlayer_worker_t::heartbeat_transmittance_capacity |
Allocated floats. Grow-only: the batch box changes by a pixel or two per frame as the pointer moves, and reallocating on any DIFFERENCE rather than on a shortfall would hit the allocator ~50 times a second during a drag.
Definition at line 111 of file worker.c.
Referenced by _ensure_heartbeat_batch_buffers(), and _rt_destroy_state().
| dt_drawlayer_damaged_rect_t dt_drawlayer_worker_t::live_publish_damage |
Worker-owned accumulated publish damage.
Definition at line 116 of file worker.c.
Referenced by _publish_backend_progress(), _rasterize_pending_dab_batch(), and _reset_live_publish().
| uint32_t dt_drawlayer_worker_t::live_publish_serial |
Monotonic live publish serial committed by heartbeat flushes.
Definition at line 115 of file worker.c.
Referenced by _publish_backend_progress(), and _reset_live_publish().
| gint64 dt_drawlayer_worker_t::live_publish_ts |
Realtime publish pacing timestamp.
Definition at line 114 of file worker.c.
Referenced by _live_publish_deadline_reached(), _process_backend_input(), _publish_backend_progress(), and _reset_live_publish().
| gboolean* dt_drawlayer_worker_t::painting |
External painting-state mirror.
Definition at line 96 of file worker.c.
Referenced by _backend_worker_on_idle(), _rt_init_state(), and _workers_ready_for_commit_locked().
| dt_iop_drawlayer_params_t dt_drawlayer_worker_t::publish_params |
Worker-private params blob used by the realtime heartbeat. Seeded from self->params by the GUI thread at stroke begin (dt_drawlayer_worker_snapshot_params), then owned by the worker. The heartbeat must never touch self->params: that blob belongs to the GUI thread, and bumping its hash in place was an unsynchronised read-modify-write of 344 bytes that includes two strings.
Definition at line 118 of file worker.c.
Referenced by _publish_backend_progress(), and dt_drawlayer_worker_snapshot_params().
| dt_iop_module_t* dt_drawlayer_worker_t::self |
Parent module instance.
Definition at line 95 of file worker.c.
Referenced by _drawlayer_worker_main(), _rt_destroy_state(), _rt_init_state(), dt_drawlayer_worker_enqueue_input(), and dt_drawlayer_worker_enqueue_stroke_end().
| dt_drawlayer_paint_stroke_t* dt_drawlayer_worker_t::stroke |
Worker-owned current stroke runtime.
Definition at line 105 of file worker.c.
Referenced by _backend_pending_dabs_locked(), _backend_worker_on_idle(), _backend_worker_process_sample(), _backend_worker_process_stroke_end(), _commit_dabs_on_gui_thread(), _make_backend_ctx(), _stroke_begin(), _stroke_clear(), _stroke_create(), and _stroke_destroy().
| GArray* dt_drawlayer_worker_t::stroke_raw_inputs |
Preserved raw input history for current stroke.
Definition at line 104 of file worker.c.
Referenced by _backend_worker_process_sample(), _rt_destroy_state(), _rt_init_state(), _stroke_begin(), _stroke_clear(), and dt_drawlayer_worker_raw_inputs().
| guint* dt_drawlayer_worker_t::stroke_sample_count |
External per-stroke sample counter mirror.
Definition at line 98 of file worker.c.
Referenced by _enqueue_input(), and _rt_init_state().
| pthread_cond_t dt_drawlayer_worker_t::worker_cond |
Condition variable for worker wakeups.
Definition at line 101 of file worker.c.
Referenced by _backend_worker_process_stroke_end(), _drawlayer_worker_main(), _enqueue_event(), _enqueue_input(), _rt_destroy_state(), _rt_init_state(), _stop_worker(), dt_drawlayer_worker_pause(), dt_drawlayer_worker_request_commit(), dt_drawlayer_worker_resume(), and dt_drawlayer_worker_wait_idle().
| dt_pthread_mutex_t dt_drawlayer_worker_t::worker_mutex |
Mutex guarding queue/flags.
Definition at line 100 of file worker.c.
Referenced by _backend_worker_on_idle(), _backend_worker_process_stroke_end(), _cancel_pending_gui_commit(), _commit_dabs_on_gui_thread(), _drawlayer_worker_main(), _enqueue_event(), _enqueue_input(), _rt_destroy_state(), _rt_init_state(), _rt_workers_active(), _rt_workers_any_active(), _stop_worker(), dt_drawlayer_worker_cancel_async_commit(), dt_drawlayer_worker_get_snapshot(), dt_drawlayer_worker_pause(), dt_drawlayer_worker_request_commit(), dt_drawlayer_worker_reset_backend_path(), dt_drawlayer_worker_reset_live_publish(), dt_drawlayer_worker_reset_stroke(), dt_drawlayer_worker_resume(), dt_drawlayer_worker_snapshot_params(), and dt_drawlayer_worker_wait_idle().
| drawlayer_rt_worker_t dt_drawlayer_worker_t::workers[DRAWLAYER_RT_WORKER_COUNT] |
Worker slots.
Definition at line 102 of file worker.c.
Referenced by _backend_worker(), and _backend_worker_const().