Fix JXL encoder

This commit is contained in:
Surma
2020-02-06 16:37:37 -08:00
committed by Ingvar Stepanyan
parent e1dd2796c1
commit b5ad52cfcf
2 changed files with 3 additions and 2 deletions

View File

@@ -12,10 +12,11 @@ val encode(std::string image, int width, int height) {
// jxl::ThreadPool pool; // jxl::ThreadPool pool;
jxl::CodecInOut io; jxl::CodecInOut io;
jxl::PaddedBytes bytes; jxl::PaddedBytes bytes;
jxl::ImageBundle *main = &io.Main();
cparams.speed_tier = jxl::SpeedTier::kFalcon; cparams.speed_tier = jxl::SpeedTier::kFalcon;
cparams.color_transform = jxl::ColorTransform::kNone;
jxl::ImageBundle *main = &io.Main(); uint8_t *inBuffer = (uint8_t *)image.c_str();
auto result = main->SetFromSRGB( auto result = main->SetFromSRGB(
width, height, false, true, true, (uint8_t *)image.c_str(), width, height, false, true, true, (uint8_t *)image.c_str(),

Binary file not shown.