00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00027 #define OPJ_STATIC
00028 #include <openjpeg.h>
00029
00030 #include "libavutil/avassert.h"
00031 #include "libavutil/common.h"
00032 #include "libavutil/imgutils.h"
00033 #include "libavutil/intreadwrite.h"
00034 #include "libavutil/opt.h"
00035 #include "avcodec.h"
00036 #include "internal.h"
00037
00038 typedef struct {
00039 AVClass *avclass;
00040 opj_image_t *image;
00041 opj_cparameters_t enc_params;
00042 opj_cinfo_t *compress;
00043 opj_event_mgr_t event_mgr;
00044 int format;
00045 int profile;
00046 int prog_order;
00047 int cinema_mode;
00048 int numresolution;
00049 int numlayers;
00050 int disto_alloc;
00051 int fixed_alloc;
00052 int fixed_quality;
00053 } LibOpenJPEGContext;
00054
00055 static void error_callback(const char *msg, void *data)
00056 {
00057 av_log(data, AV_LOG_ERROR, "%s\n", msg);
00058 }
00059
00060 static void warning_callback(const char *msg, void *data)
00061 {
00062 av_log(data, AV_LOG_WARNING, "%s\n", msg);
00063 }
00064
00065 static void info_callback(const char *msg, void *data)
00066 {
00067 av_log(data, AV_LOG_DEBUG, "%s\n", msg);
00068 }
00069
00070 static opj_image_t *mj2_create_image(AVCodecContext *avctx, opj_cparameters_t *parameters)
00071 {
00072 const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(avctx->pix_fmt);
00073 opj_image_cmptparm_t *cmptparm;
00074 opj_image_t *img;
00075 int i;
00076 int sub_dx[4];
00077 int sub_dy[4];
00078 int numcomps;
00079 OPJ_COLOR_SPACE color_space = CLRSPC_UNKNOWN;
00080
00081 sub_dx[0] = sub_dx[3] = 1;
00082 sub_dy[0] = sub_dy[3] = 1;
00083 sub_dx[1] = sub_dx[2] = 1 << desc->log2_chroma_w;
00084 sub_dy[1] = sub_dy[2] = 1 << desc->log2_chroma_h;
00085
00086 numcomps = desc->nb_components;
00087
00088 switch (avctx->pix_fmt) {
00089 case AV_PIX_FMT_GRAY8:
00090 case AV_PIX_FMT_GRAY8A:
00091 case AV_PIX_FMT_GRAY16:
00092 color_space = CLRSPC_GRAY;
00093 break;
00094 case AV_PIX_FMT_RGB24:
00095 case AV_PIX_FMT_RGBA:
00096 case AV_PIX_FMT_RGB48:
00097 case AV_PIX_FMT_RGBA64:
00098 color_space = CLRSPC_SRGB;
00099 break;
00100 case AV_PIX_FMT_YUV410P:
00101 case AV_PIX_FMT_YUV411P:
00102 case AV_PIX_FMT_YUV420P:
00103 case AV_PIX_FMT_YUV422P:
00104 case AV_PIX_FMT_YUV440P:
00105 case AV_PIX_FMT_YUV444P:
00106 case AV_PIX_FMT_YUVA420P:
00107 case AV_PIX_FMT_YUVA422P:
00108 case AV_PIX_FMT_YUVA444P:
00109 case AV_PIX_FMT_YUV420P9:
00110 case AV_PIX_FMT_YUV422P9:
00111 case AV_PIX_FMT_YUV444P9:
00112 case AV_PIX_FMT_YUVA420P9:
00113 case AV_PIX_FMT_YUVA422P9:
00114 case AV_PIX_FMT_YUVA444P9:
00115 case AV_PIX_FMT_YUV420P10:
00116 case AV_PIX_FMT_YUV422P10:
00117 case AV_PIX_FMT_YUV444P10:
00118 case AV_PIX_FMT_YUVA420P10:
00119 case AV_PIX_FMT_YUVA422P10:
00120 case AV_PIX_FMT_YUVA444P10:
00121 case AV_PIX_FMT_YUV420P12:
00122 case AV_PIX_FMT_YUV422P12:
00123 case AV_PIX_FMT_YUV444P12:
00124 case AV_PIX_FMT_YUV420P14:
00125 case AV_PIX_FMT_YUV422P14:
00126 case AV_PIX_FMT_YUV444P14:
00127 case AV_PIX_FMT_YUV420P16:
00128 case AV_PIX_FMT_YUV422P16:
00129 case AV_PIX_FMT_YUV444P16:
00130 case AV_PIX_FMT_YUVA420P16:
00131 case AV_PIX_FMT_YUVA422P16:
00132 case AV_PIX_FMT_YUVA444P16:
00133 color_space = CLRSPC_SYCC;
00134 break;
00135 default:
00136 av_log(avctx, AV_LOG_ERROR,
00137 "The requested pixel format '%s' is not supported\n",
00138 av_get_pix_fmt_name(avctx->pix_fmt));
00139 return NULL;
00140 }
00141
00142 cmptparm = av_mallocz(numcomps * sizeof(*cmptparm));
00143 if (!cmptparm) {
00144 av_log(avctx, AV_LOG_ERROR, "Not enough memory\n");
00145 return NULL;
00146 }
00147 for (i = 0; i < numcomps; i++) {
00148 cmptparm[i].prec = desc->comp[i].depth_minus1 + 1;
00149 cmptparm[i].bpp = desc->comp[i].depth_minus1 + 1;
00150 cmptparm[i].sgnd = 0;
00151 cmptparm[i].dx = sub_dx[i];
00152 cmptparm[i].dy = sub_dy[i];
00153 cmptparm[i].w = avctx->width / sub_dx[i];
00154 cmptparm[i].h = avctx->height / sub_dy[i];
00155 }
00156
00157 img = opj_image_create(numcomps, cmptparm, color_space);
00158 av_freep(&cmptparm);
00159 return img;
00160 }
00161
00162 static av_cold int libopenjpeg_encode_init(AVCodecContext *avctx)
00163 {
00164 LibOpenJPEGContext *ctx = avctx->priv_data;
00165 int err = AVERROR(ENOMEM);
00166
00167 opj_set_default_encoder_parameters(&ctx->enc_params);
00168
00169 ctx->enc_params.cp_rsiz = ctx->profile;
00170 ctx->enc_params.mode = !!avctx->global_quality;
00171 ctx->enc_params.cp_cinema = ctx->cinema_mode;
00172 ctx->enc_params.prog_order = ctx->prog_order;
00173 ctx->enc_params.numresolution = ctx->numresolution;
00174 ctx->enc_params.cp_disto_alloc = ctx->disto_alloc;
00175 ctx->enc_params.cp_fixed_alloc = ctx->fixed_alloc;
00176 ctx->enc_params.cp_fixed_quality = ctx->fixed_quality;
00177 ctx->enc_params.tcp_numlayers = ctx->numlayers;
00178 ctx->enc_params.tcp_rates[0] = FFMAX(avctx->compression_level, 0) * 2;
00179
00180 ctx->compress = opj_create_compress(ctx->format);
00181 if (!ctx->compress) {
00182 av_log(avctx, AV_LOG_ERROR, "Error creating the compressor\n");
00183 return AVERROR(ENOMEM);
00184 }
00185
00186 avctx->coded_frame = avcodec_alloc_frame();
00187 if (!avctx->coded_frame) {
00188 av_log(avctx, AV_LOG_ERROR, "Error allocating coded frame\n");
00189 goto fail;
00190 }
00191
00192 ctx->image = mj2_create_image(avctx, &ctx->enc_params);
00193 if (!ctx->image) {
00194 av_log(avctx, AV_LOG_ERROR, "Error creating the mj2 image\n");
00195 err = AVERROR(EINVAL);
00196 goto fail;
00197 }
00198
00199 memset(&ctx->event_mgr, 0, sizeof(opj_event_mgr_t));
00200 ctx->event_mgr.info_handler = info_callback;
00201 ctx->event_mgr.error_handler = error_callback;
00202 ctx->event_mgr.warning_handler = warning_callback;
00203 opj_set_event_mgr((opj_common_ptr)ctx->compress, &ctx->event_mgr, avctx);
00204
00205 return 0;
00206
00207 fail:
00208 av_freep(&ctx->compress);
00209 av_freep(&avctx->coded_frame);
00210 return err;
00211 }
00212
00213 static int libopenjpeg_copy_packed8(AVCodecContext *avctx, const AVFrame *frame, opj_image_t *image)
00214 {
00215 int compno;
00216 int x;
00217 int y;
00218 int image_index;
00219 int frame_index;
00220 const int numcomps = image->numcomps;
00221
00222 for (compno = 0; compno < numcomps; ++compno) {
00223 if (image->comps[compno].w > frame->linesize[0] / numcomps) {
00224 av_log(avctx, AV_LOG_ERROR, "Error: frame's linesize is too small for the image\n");
00225 return 0;
00226 }
00227 }
00228
00229 for (compno = 0; compno < numcomps; ++compno) {
00230 for (y = 0; y < avctx->height; ++y) {
00231 image_index = y * avctx->width;
00232 frame_index = y * frame->linesize[0] + compno;
00233 for (x = 0; x < avctx->width; ++x) {
00234 image->comps[compno].data[image_index++] = frame->data[0][frame_index];
00235 frame_index += numcomps;
00236 }
00237 }
00238 }
00239
00240 return 1;
00241 }
00242
00243 static int libopenjpeg_copy_packed16(AVCodecContext *avctx, const AVFrame *frame, opj_image_t *image)
00244 {
00245 int compno;
00246 int x;
00247 int y;
00248 int image_index;
00249 int frame_index;
00250 const int numcomps = image->numcomps;
00251 uint16_t *frame_ptr = (uint16_t*)frame->data[0];
00252
00253 for (compno = 0; compno < numcomps; ++compno) {
00254 if (image->comps[compno].w > frame->linesize[0] / numcomps) {
00255 av_log(avctx, AV_LOG_ERROR, "Error: frame's linesize is too small for the image\n");
00256 return 0;
00257 }
00258 }
00259
00260 for (compno = 0; compno < numcomps; ++compno) {
00261 for (y = 0; y < avctx->height; ++y) {
00262 image_index = y * avctx->width;
00263 frame_index = y * (frame->linesize[0] / 2) + compno;
00264 for (x = 0; x < avctx->width; ++x) {
00265 image->comps[compno].data[image_index++] = frame_ptr[frame_index];
00266 frame_index += numcomps;
00267 }
00268 }
00269 }
00270
00271 return 1;
00272 }
00273
00274 static int libopenjpeg_copy_unpacked8(AVCodecContext *avctx, const AVFrame *frame, opj_image_t *image)
00275 {
00276 int compno;
00277 int x;
00278 int y;
00279 int width;
00280 int height;
00281 int image_index;
00282 int frame_index;
00283 const int numcomps = image->numcomps;
00284
00285 for (compno = 0; compno < numcomps; ++compno) {
00286 if (image->comps[compno].w > frame->linesize[compno]) {
00287 av_log(avctx, AV_LOG_ERROR, "Error: frame's linesize is too small for the image\n");
00288 return 0;
00289 }
00290 }
00291
00292 for (compno = 0; compno < numcomps; ++compno) {
00293 width = avctx->width / image->comps[compno].dx;
00294 height = avctx->height / image->comps[compno].dy;
00295 for (y = 0; y < height; ++y) {
00296 image_index = y * width;
00297 frame_index = y * frame->linesize[compno];
00298 for (x = 0; x < width; ++x)
00299 image->comps[compno].data[image_index++] = frame->data[compno][frame_index++];
00300 }
00301 }
00302
00303 return 1;
00304 }
00305
00306 static int libopenjpeg_copy_unpacked16(AVCodecContext *avctx, const AVFrame *frame, opj_image_t *image)
00307 {
00308 int compno;
00309 int x;
00310 int y;
00311 int width;
00312 int height;
00313 int image_index;
00314 int frame_index;
00315 const int numcomps = image->numcomps;
00316 uint16_t *frame_ptr;
00317
00318 for (compno = 0; compno < numcomps; ++compno) {
00319 if (image->comps[compno].w > frame->linesize[compno]) {
00320 av_log(avctx, AV_LOG_ERROR, "Error: frame's linesize is too small for the image\n");
00321 return 0;
00322 }
00323 }
00324
00325 for (compno = 0; compno < numcomps; ++compno) {
00326 width = avctx->width / image->comps[compno].dx;
00327 height = avctx->height / image->comps[compno].dy;
00328 frame_ptr = (uint16_t*)frame->data[compno];
00329 for (y = 0; y < height; ++y) {
00330 image_index = y * width;
00331 frame_index = y * (frame->linesize[compno] / 2);
00332 for (x = 0; x < width; ++x)
00333 image->comps[compno].data[image_index++] = frame_ptr[frame_index++];
00334 }
00335 }
00336
00337 return 1;
00338 }
00339
00340 static int libopenjpeg_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
00341 const AVFrame *frame, int *got_packet)
00342 {
00343 LibOpenJPEGContext *ctx = avctx->priv_data;
00344 opj_cinfo_t *compress = ctx->compress;
00345 opj_image_t *image = ctx->image;
00346 opj_cio_t *stream;
00347 int cpyresult = 0;
00348 int ret, len;
00349
00350
00351
00352 image->x0 = 0;
00353 image->y0 = 0;
00354 image->x1 = (avctx->width - 1) * ctx->enc_params.subsampling_dx + 1;
00355 image->y1 = (avctx->height - 1) * ctx->enc_params.subsampling_dy + 1;
00356
00357 switch (avctx->pix_fmt) {
00358 case AV_PIX_FMT_RGB24:
00359 case AV_PIX_FMT_RGBA:
00360 case AV_PIX_FMT_GRAY8A:
00361 cpyresult = libopenjpeg_copy_packed8(avctx, frame, image);
00362 break;
00363 case AV_PIX_FMT_RGB48:
00364 case AV_PIX_FMT_RGBA64:
00365 cpyresult = libopenjpeg_copy_packed16(avctx, frame, image);
00366 break;
00367 case AV_PIX_FMT_GRAY8:
00368 case AV_PIX_FMT_YUV410P:
00369 case AV_PIX_FMT_YUV411P:
00370 case AV_PIX_FMT_YUV420P:
00371 case AV_PIX_FMT_YUV422P:
00372 case AV_PIX_FMT_YUV440P:
00373 case AV_PIX_FMT_YUV444P:
00374 case AV_PIX_FMT_YUVA420P:
00375 case AV_PIX_FMT_YUVA422P:
00376 case AV_PIX_FMT_YUVA444P:
00377 cpyresult = libopenjpeg_copy_unpacked8(avctx, frame, image);
00378 break;
00379 case AV_PIX_FMT_GRAY16:
00380 case AV_PIX_FMT_YUV420P9:
00381 case AV_PIX_FMT_YUV422P9:
00382 case AV_PIX_FMT_YUV444P9:
00383 case AV_PIX_FMT_YUVA420P9:
00384 case AV_PIX_FMT_YUVA422P9:
00385 case AV_PIX_FMT_YUVA444P9:
00386 case AV_PIX_FMT_YUV444P10:
00387 case AV_PIX_FMT_YUV422P10:
00388 case AV_PIX_FMT_YUV420P10:
00389 case AV_PIX_FMT_YUVA444P10:
00390 case AV_PIX_FMT_YUVA422P10:
00391 case AV_PIX_FMT_YUVA420P10:
00392 case AV_PIX_FMT_YUV420P12:
00393 case AV_PIX_FMT_YUV422P12:
00394 case AV_PIX_FMT_YUV444P12:
00395 case AV_PIX_FMT_YUV420P14:
00396 case AV_PIX_FMT_YUV422P14:
00397 case AV_PIX_FMT_YUV444P14:
00398 case AV_PIX_FMT_YUV444P16:
00399 case AV_PIX_FMT_YUV422P16:
00400 case AV_PIX_FMT_YUV420P16:
00401 case AV_PIX_FMT_YUVA444P16:
00402 case AV_PIX_FMT_YUVA422P16:
00403 case AV_PIX_FMT_YUVA420P16:
00404 cpyresult = libopenjpeg_copy_unpacked16(avctx, frame, image);
00405 break;
00406 default:
00407 av_log(avctx, AV_LOG_ERROR,
00408 "The frame's pixel format '%s' is not supported\n",
00409 av_get_pix_fmt_name(avctx->pix_fmt));
00410 return AVERROR(EINVAL);
00411 break;
00412 }
00413
00414 if (!cpyresult) {
00415 av_log(avctx, AV_LOG_ERROR,
00416 "Could not copy the frame data to the internal image buffer\n");
00417 return -1;
00418 }
00419
00420 opj_setup_encoder(compress, &ctx->enc_params, image);
00421 stream = opj_cio_open((opj_common_ptr)compress, NULL, 0);
00422 if (!stream) {
00423 av_log(avctx, AV_LOG_ERROR, "Error creating the cio stream\n");
00424 return AVERROR(ENOMEM);
00425 }
00426
00427 if (!opj_encode(compress, stream, image, NULL)) {
00428 opj_cio_close(stream);
00429 av_log(avctx, AV_LOG_ERROR, "Error during the opj encode\n");
00430 return -1;
00431 }
00432
00433 len = cio_tell(stream);
00434 if ((ret = ff_alloc_packet2(avctx, pkt, len)) < 0) {
00435 opj_cio_close(stream);
00436 return ret;
00437 }
00438
00439 memcpy(pkt->data, stream->buffer, len);
00440 pkt->flags |= AV_PKT_FLAG_KEY;
00441 *got_packet = 1;
00442 opj_cio_close(stream);
00443 return 0;
00444 }
00445
00446 static av_cold int libopenjpeg_encode_close(AVCodecContext *avctx)
00447 {
00448 LibOpenJPEGContext *ctx = avctx->priv_data;
00449
00450 opj_destroy_compress(ctx->compress);
00451 opj_image_destroy(ctx->image);
00452 av_freep(&avctx->coded_frame);
00453 return 0;
00454 }
00455
00456 #define OFFSET(x) offsetof(LibOpenJPEGContext, x)
00457 #define VE AV_OPT_FLAG_VIDEO_PARAM | AV_OPT_FLAG_ENCODING_PARAM
00458 static const AVOption options[] = {
00459 { "format", "Codec Format", OFFSET(format), AV_OPT_TYPE_INT, { .i64 = CODEC_JP2 }, CODEC_J2K, CODEC_JP2, VE, "format" },
00460 { "j2k", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CODEC_J2K }, 0, 0, VE, "format" },
00461 { "jp2", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CODEC_JP2 }, 0, 0, VE, "format" },
00462 { "profile", NULL, OFFSET(profile), AV_OPT_TYPE_INT, { .i64 = STD_RSIZ }, STD_RSIZ, CINEMA4K, VE, "profile" },
00463 { "jpeg2000", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = STD_RSIZ }, 0, 0, VE, "profile" },
00464 { "cinema2k", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CINEMA2K }, 0, 0, VE, "profile" },
00465 { "cinema4k", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CINEMA4K }, 0, 0, VE, "profile" },
00466 { "cinema_mode", "Digital Cinema", OFFSET(cinema_mode), AV_OPT_TYPE_INT, { .i64 = OFF }, OFF, CINEMA4K_24, VE, "cinema_mode" },
00467 { "off", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = OFF }, 0, 0, VE, "cinema_mode" },
00468 { "2k_24", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CINEMA2K_24 }, 0, 0, VE, "cinema_mode" },
00469 { "2k_48", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CINEMA2K_48 }, 0, 0, VE, "cinema_mode" },
00470 { "4k_24", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CINEMA4K_24 }, 0, 0, VE, "cinema_mode" },
00471 { "prog_order", "Progression Order", OFFSET(prog_order), AV_OPT_TYPE_INT, { .i64 = LRCP }, LRCP, CPRL, VE, "prog_order" },
00472 { "lrcp", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = LRCP }, 0, 0, VE, "prog_order" },
00473 { "rlcp", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = RLCP }, 0, 0, VE, "prog_order" },
00474 { "rpcl", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = RPCL }, 0, 0, VE, "prog_order" },
00475 { "pcrl", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = PCRL }, 0, 0, VE, "prog_order" },
00476 { "cprl", NULL, 0, AV_OPT_TYPE_CONST, { .i64 = CPRL }, 0, 0, VE, "prog_order" },
00477 { "numresolution", NULL, OFFSET(numresolution), AV_OPT_TYPE_INT, { .i64 = 6 }, 1, INT_MAX, VE },
00478 { "numlayers", NULL, OFFSET(numlayers), AV_OPT_TYPE_INT, { .i64 = 1 }, 1, 10, VE },
00479 { "disto_alloc", NULL, OFFSET(disto_alloc), AV_OPT_TYPE_INT, { .i64 = 1 }, 0, 1, VE },
00480 { "fixed_alloc", NULL, OFFSET(fixed_alloc), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 1, VE },
00481 { "fixed_quality", NULL, OFFSET(fixed_quality), AV_OPT_TYPE_INT, { .i64 = 0 }, 0, 1, VE },
00482 { NULL },
00483 };
00484
00485 static const AVClass class = {
00486 .class_name = "libopenjpeg",
00487 .item_name = av_default_item_name,
00488 .option = options,
00489 .version = LIBAVUTIL_VERSION_INT,
00490 };
00491
00492 AVCodec ff_libopenjpeg_encoder = {
00493 .name = "libopenjpeg",
00494 .type = AVMEDIA_TYPE_VIDEO,
00495 .id = AV_CODEC_ID_JPEG2000,
00496 .priv_data_size = sizeof(LibOpenJPEGContext),
00497 .init = libopenjpeg_encode_init,
00498 .encode2 = libopenjpeg_encode_frame,
00499 .close = libopenjpeg_encode_close,
00500 .capabilities = 0,
00501 .pix_fmts = (const enum AVPixelFormat[]) {
00502 AV_PIX_FMT_RGB24, AV_PIX_FMT_RGBA, AV_PIX_FMT_RGB48, AV_PIX_FMT_RGBA64,
00503 AV_PIX_FMT_GRAY8, AV_PIX_FMT_GRAY8A, AV_PIX_FMT_GRAY16,
00504 AV_PIX_FMT_YUV420P, AV_PIX_FMT_YUV422P, AV_PIX_FMT_YUVA420P,
00505 AV_PIX_FMT_YUV440P, AV_PIX_FMT_YUV444P, AV_PIX_FMT_YUVA422P,
00506 AV_PIX_FMT_YUV411P, AV_PIX_FMT_YUV410P, AV_PIX_FMT_YUVA444P,
00507 AV_PIX_FMT_YUV420P9, AV_PIX_FMT_YUV422P9, AV_PIX_FMT_YUV444P9,
00508 AV_PIX_FMT_YUVA420P9, AV_PIX_FMT_YUVA422P9, AV_PIX_FMT_YUVA444P9,
00509 AV_PIX_FMT_YUV420P10, AV_PIX_FMT_YUV422P10, AV_PIX_FMT_YUV444P10,
00510 AV_PIX_FMT_YUVA420P10, AV_PIX_FMT_YUVA422P10, AV_PIX_FMT_YUVA444P10,
00511 AV_PIX_FMT_YUV420P12, AV_PIX_FMT_YUV422P12, AV_PIX_FMT_YUV444P12,
00512 AV_PIX_FMT_YUV420P14, AV_PIX_FMT_YUV422P14, AV_PIX_FMT_YUV444P14,
00513 AV_PIX_FMT_YUV420P16, AV_PIX_FMT_YUV422P16, AV_PIX_FMT_YUV444P16,
00514 AV_PIX_FMT_YUVA420P16, AV_PIX_FMT_YUVA422P16, AV_PIX_FMT_YUVA444P16,
00515 AV_PIX_FMT_NONE
00516 },
00517 .long_name = NULL_IF_CONFIG_SMALL("OpenJPEG JPEG 2000"),
00518 .priv_class = &class,
00519 };