18#include <OpenImageIO/imagebuf.h>
48[[nodiscard]]
bool isLinearToken(std::string_view colorspace)
noexcept;
74[[nodiscard]] std::expected<void, ErrorHandling::CoreError>
81[[nodiscard]] std::string
getColorSpace(
const OIIO::ImageBuf& buf)
noexcept;
Central error handling system for CaptureMoment Core library.
bool isLinearToken(std::string_view colorspace) noexcept
Checks whether an OIIO-detected color space token represents linear data.
ColorSpaceInfo analyzeColorSpace(const OIIO::ImageSpec &spec) noexcept
Analyzes whether an image's pixel data is stored in a linear color space.
std::expected< void, ErrorHandling::CoreError > transformToColorSpace(OIIO::ImageBuf &image, std::string_view target_cs)
Converts an image buffer to a target color space (in-place).
std::pair< bool, std::string > ColorSpaceInfo
Result of a color space analysis.
std::string getColorSpace(const OIIO::ImageBuf &buf) noexcept
Extracts the color space name from an OIIO image buffer metadata.