Lines Matching refs:colr
396 jp2_colr_t *colr = &box->data.colr; in jp2_colr_dumpdata() local
397 …fprintf(out, "method=%d; pri=%d; approx=%d\n", (int)colr->method, (int)colr->pri, (int)colr->appro… in jp2_colr_dumpdata()
398 switch (colr->method) { in jp2_colr_dumpdata()
400 fprintf(out, "csid=%d\n", (int)colr->csid); in jp2_colr_dumpdata()
403 jas_memdump(out, colr->iccp, colr->iccplen); in jp2_colr_dumpdata()
410 jp2_colr_t *colr = &box->data.colr; in jp2_colr_getdata() local
411 colr->csid = 0; in jp2_colr_getdata()
412 colr->iccp = 0; in jp2_colr_getdata()
413 colr->iccplen = 0; in jp2_colr_getdata()
415 if (jp2_getuint8(in, &colr->method) || jp2_getuint8(in, &colr->pri) || in jp2_colr_getdata()
416 jp2_getuint8(in, &colr->approx)) { in jp2_colr_getdata()
419 switch (colr->method) { in jp2_colr_getdata()
421 if (jp2_getuint32(in, &colr->csid)) { in jp2_colr_getdata()
426 colr->iccplen = box->datalen - 3; in jp2_colr_getdata()
427 if (!(colr->iccp = jas_alloc2(colr->iccplen, sizeof(uint_fast8_t)))) { in jp2_colr_getdata()
430 if (jas_stream_read(in, colr->iccp, colr->iccplen) != colr->iccplen) { in jp2_colr_getdata()
450 jp2_colr_t *colr = &box->data.colr; in jp2_colr_destroy() local
451 if (colr->iccp) { in jp2_colr_destroy()
452 jas_free(colr->iccp); in jp2_colr_destroy()
582 jp2_colr_t *colr = &box->data.colr; in jp2_colr_putdata() local
583 if (jp2_putuint8(out, colr->method) || jp2_putuint8(out, colr->pri) || in jp2_colr_putdata()
584 jp2_putuint8(out, colr->approx)) { in jp2_colr_putdata()
587 switch (colr->method) { in jp2_colr_putdata()
589 if (jp2_putuint32(out, colr->csid)) { in jp2_colr_putdata()
594 if (jas_stream_write(out, colr->iccp, in jp2_colr_putdata()
595 JAS_CAST(int, colr->iccplen)) != JAS_CAST(int, colr->iccplen)) in jp2_colr_putdata()