MayaFlux 1.0.0
Digital-First Multimedia Processing Framework
Loading...
Searching...
No Matches

◆ save_image() [4/4]

bool MayaFlux::IO::IOManager::save_image ( IO::ImageData  data,
const std::string &  filepath,
const IO::ImageWriteOptions &  options = {} 
)

Save an already-downloaded ImageData to disk asynchronously.

For callers that have an ImageData in hand (e.g. from IO::download_image) and want to avoid the GPU download step. Purely CPU-bound from here, so no thread restrictions on the caller.

Definition at line 1262 of file IOManager.cpp.

1266{
1267 track_save_task(std::async(std::launch::async,
1268 [data = std::move(data),
1269 filepath,
1270 options]() -> bool {
1271 return Detail::execute_image_write(filepath, data, options);
1272 }));
1273
1274 return true;
1275}
void track_save_task(std::future< bool > fut)
Retain a save task in m_save_tasks and opportunistically reclaim finished ones.
bool execute_image_write(const std::string &filepath, const ImageData &data, const ImageWriteOptions &options)

References MayaFlux::IO::Detail::execute_image_write(), and track_save_task().

+ Here is the call graph for this function: