9#include <spdlog/spdlog.h>
17 spdlog::warn(
"[WorkingImageCPU_Default::getFullResImage]: Image view is invalid.");
22 auto cpu_image_copy { std::make_unique<Common::ImageRegion>(
29 if (!cpu_image_copy->isValid()) {
33 spdlog::debug(
"[WorkingImageCPU_Default::getFullResImage]: Exported {}x{}.",
36 return cpu_image_copy;
38 }
catch (
const std::bad_alloc& e) {
39 spdlog::critical(
"[WorkingImageCPU_Default::getFullResImage]: Allocation failed: {}", e.what());
ImageView m_view_data_image
The image view bound to this hardware worker.
std::expected< std::unique_ptr< Common::ImageRegion >, ErrorHandling::CoreError > getFullResImage() override
Exports current working data to a new CPU-based ImageRegion.
bool isValid() const override
Checks if the image data is valid.
CoreError
Enumeration of all error codes for CaptureMoment Core.
@ InvalidImageRegion
The provided ImageRegion dimensions or data are invalid.
@ InvalidWorkingImage
The working image state is invalid or corrupted.
@ AllocationFailed
Memory allocation failed.
Common::ImageChan channels
std::span< float > working_data
Mutable span for processing.
Default concrete implementation of IWorkingImageCPU using standard CPU memory.