diff options
author | Antony Riakiotakis <kalast@gmail.com> | 2015-07-13 14:58:17 +0300 |
---|---|---|
committer | Antony Riakiotakis <kalast@gmail.com> | 2015-07-13 14:58:17 +0300 |
commit | e142ae77cadf04103fbc643f21cf60891862f6a8 (patch) | |
tree | 142e25fccd5ba3e748a1652706e7e4f1220ca289 /source/blender/imbuf/intern/cineon/cineon_dpx.c | |
parent | 107bbee4c763c95ea5d07a3b2f08bfe3b6adb24c (diff) |
Imbuf types refactor.
ImBuf types were getting stored as bitflags in a 32bit integer which had
already run out of space. Solved the problem by separating file type to
an ftype enum, and file specific options to foptions.
Reviewed by Campbell, thanks a lot!
Diffstat (limited to 'source/blender/imbuf/intern/cineon/cineon_dpx.c')
-rw-r--r-- | source/blender/imbuf/intern/cineon/cineon_dpx.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/imbuf/intern/cineon/cineon_dpx.c b/source/blender/imbuf/intern/cineon/cineon_dpx.c index 5c0af9e9816..3e2206dc013 100644 --- a/source/blender/imbuf/intern/cineon/cineon_dpx.c +++ b/source/blender/imbuf/intern/cineon/cineon_dpx.c @@ -86,7 +86,7 @@ static struct ImBuf *imb_load_dpx_cineon( } logImageClose(image); - ibuf->ftype = use_cineon ? CINEON : DPX; + ibuf->ftype = use_cineon ? IMB_FTYPE_CINEON : IMB_FTYPE_DPX; if (flags & IB_alphamode_detect) ibuf->flags |= IB_alphamode_premul; @@ -115,17 +115,17 @@ static int imb_save_dpx_cineon(ImBuf *ibuf, const char *filename, int use_cineon return 0; } - if (ibuf->ftype & CINEON_10BIT) + if (ibuf->foptions.flag & CINEON_10BIT) bitspersample = 10; - else if (ibuf->ftype & CINEON_12BIT) + else if (ibuf->foptions.flag & CINEON_12BIT) bitspersample = 12; - else if (ibuf->ftype & CINEON_16BIT) + else if (ibuf->foptions.flag & CINEON_16BIT) bitspersample = 16; else bitspersample = 8; logImage = logImageCreate(filename, use_cineon, ibuf->x, ibuf->y, bitspersample, (depth == 4), - (ibuf->ftype & CINEON_LOG), -1, -1, -1, "Blender"); + (ibuf->foptions.flag & CINEON_LOG), -1, -1, -1, "Blender"); if (logImage == NULL) { printf("DPX/Cineon: error creating file.\n"); |