CaptureMoment 0.1.0
Free and open-source non-destructive photo editor
Loading...
Searching...
No Matches
state_image_manager.h File Reference

Declaration of StateImageManager class. More...

#include "operations/operation_descriptor.h"
#include "managers/i_source_manager.h"
#include "image_processing/interfaces/i_working_image_hardware.h"
#include "operations/operation_factory.h"
#include "common/types/image_types.h"
#include <vector>
#include <memory>
#include <mutex>
#include <future>
#include <string_view>
#include <string>
#include <optional>
#include <thread>
#include <atomic>
#include <condition_variable>
+ Include dependency graph for state_image_manager.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  CaptureMoment::Core::Managers::StateImageManager
 Manages the working image lifecycle and coordinates asynchronous processing. More...
 

Namespaces

namespace  CaptureMoment
 
namespace  CaptureMoment::Core
 Manages the lifecycle of a single IWorkingImage instance.
 
namespace  CaptureMoment::Core::Pipeline
 
namespace  CaptureMoment::Core::Workers
 
namespace  CaptureMoment::Core::ImageProcessing
 
namespace  CaptureMoment::Core::Managers
 

Detailed Description

Declaration of StateImageManager class.

This class manages the asynchronous processing state of the image being edited. It acts as a coordinator between the image source, the infrastructure contexts (Pipeline & Workers), and the working image memory.

Key Architectural Features:

  • Contexts: Owns PipelineContext (Strategies) and WorkerContext (Executors).
  • Move Semantics: All data processing methods accept ownership of data via std::move.
  • Thread-Safe: Uses mutexes to protect the working image and status flags.
  • Stateless Processing: Does not store operation lists; it receives, processes, and discards.
  • Single Persistent Worker: Uses ONE background thread for all processing, avoiding the overhead of thread creation/destruction during rapid UI interactions.
  • Coalescing Updates: If an update is requested while the worker is busy, the new request overwrites the pending one. Intermediate requests are discarded, ensuring only the latest state is processed.
Author
CaptureMoment Team
Date
2026

Definition in file state_image_manager.h.

CaptureMoment — footer