Changeset View
Changeset View
Standalone View
Standalone View
source/blender/imbuf/intern/iris.c
| Show First 20 Lines • Show All 248 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| /* | /* | ||||
| * longimagedata - | * longimagedata - | ||||
| * read in a B/W RGB or RGBA iris image file and return a | * read in a B/W RGB or RGBA iris image file and return a | ||||
| * pointer to an array of ints. | * pointer to an array of ints. | ||||
| */ | */ | ||||
| struct ImBuf *imb_loadiris(const uchar *mem, size_t size, int flags, char colorspace[IM_MAX_SPACE]) | struct ImBuf *imb_loadiris(const uchar *mem, size_t size, eImBufFlags flags, char colorspace[IM_MAX_SPACE]) | ||||
| { | { | ||||
| uint *base, *lptr = NULL; | uint *base, *lptr = NULL; | ||||
| float *fbase, *fptr = NULL; | float *fbase, *fptr = NULL; | ||||
| uint *zbase, *zptr; | uint *zbase, *zptr; | ||||
| const uchar *rledat; | const uchar *rledat; | ||||
| const uchar *mem_end = mem + size; | const uchar *mem_end = mem + size; | ||||
| MFileOffset _inf_data = {mem, 0}, *inf = &_inf_data; | MFileOffset _inf_data = {mem, 0}, *inf = &_inf_data; | ||||
| IMAGE image; | IMAGE image; | ||||
| ▲ Show 20 Lines • Show All 699 Lines • ▼ Show 20 Lines | while (count) { | ||||
| *optr++ = todo; | *optr++ = todo; | ||||
| *optr++ = cc; | *optr++ = cc; | ||||
| } | } | ||||
| } | } | ||||
| *optr++ = 0; | *optr++ = 0; | ||||
| return optr - (uchar *)rlebuf; | return optr - (uchar *)rlebuf; | ||||
| } | } | ||||
| int imb_saveiris(struct ImBuf *ibuf, const char *name, int flags) | int imb_saveiris(struct ImBuf *ibuf, const char *name, eImBufFlags flags) | ||||
| { | { | ||||
| short zsize; | short zsize; | ||||
| int ret; | int ret; | ||||
| zsize = (ibuf->planes + 7) >> 3; | zsize = (ibuf->planes + 7) >> 3; | ||||
| if (flags & IB_zbuf && ibuf->zbuf != NULL) { | if (flags & IB_zbuf && ibuf->zbuf != NULL) { | ||||
| zsize = 8; | zsize = 8; | ||||
| } | } | ||||
| Show All 12 Lines | |||||