Fix saving jpeg2k images from Python

Quality was defaulting to lowest and no codec was set.
This commit is contained in:
Campbell Barton 2016-07-12 20:35:02 +10:00
parent 59c59cc402
commit 5798301291
1 changed files with 4 additions and 1 deletions

View File

@ -1118,8 +1118,11 @@ int BKE_image_imtype_to_ftype(const char imtype, ImbFormatOptions *r_options)
return IMB_FTYPE_DPX;
#endif
#ifdef WITH_OPENJPEG
else if (imtype == R_IMF_IMTYPE_JP2)
else if (imtype == R_IMF_IMTYPE_JP2) {
r_options->flag |= JP2_JP2;
r_options->quality = 90;
return IMB_FTYPE_JP2;
}
#endif
else {
r_options->quality = 90;