@ -50,9 +50,12 @@ public:
Halide::Runtime::Buffer<uint16_t> imgs = burst.ToBuffer();
if (imgs.dimensions() != 3 || imgs.extent(2) < 2) {
return output_img;
#if 0
throw std::invalid_argument(
"The input of HDRPlus must be a 3-dimensional buffer with at least "
"two channels.");
#endif
}
const int cfa_pattern = static_cast<int>(burst.GetCfaPattern());
@ -136,7 +136,9 @@ CfaPattern RawImage::GetCfaPattern() const {
} else if (cfa_pattern == std::string{1, 2, 0, 1}) {
return CfaPattern::CFA_GBRG;
throw std::invalid_argument("Unsupported CFA pattern: " + cfa_pattern);
return CfaPattern::CFA_UNKNOWN;