On Wed, Apr 10, 2019 at 4:30 PM Carl Eugen Hoyos <ceffm...@gmail.com> wrote:
> 2019-04-10 5:37 GMT+02:00, Jarek Samic <cldfi...@gmail.com>: > > > + // Make sure the input is a format we support > > + if (fmt != AV_PIX_FMT_ARGB && > > + fmt != AV_PIX_FMT_RGBA && > > + fmt != AV_PIX_FMT_ABGR && > > + fmt != AV_PIX_FMT_BGRA && > > + fmt != AV_PIX_FMT_NONE > > + ) { > > + av_log(avctx, AV_LOG_ERROR, "unsupported (non-RGB) format in > > colorkey_opencl.\n"); > > + err = AVERROR(ENOSYS); > > + goto fail; > > + } > > I would have expected that you export a list of supported > pix_fmts and that you can assert on the actual format being > one of them (if you need to). > Hmm, would you be able to clarify what you mean by that? The code above is modeled after code from the tonemap_opencl filter, lines 398-402: if (input_frames_ctx->sw_format != AV_PIX_FMT_P010) { av_log(ctx, AV_LOG_ERROR, "unsupported format in tonemap_opencl.\n"); err = AVERROR(ENOSYS); goto fail; } _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".