mirror of
https://github.com/outbackdingo/UltraGrid.git
synced 2026-03-20 05:40:06 +00:00
vcomp/lavc: warn if JPEG XS is encoding Y444
This won't work if on the other end the jpegxs decoder (preferred) is compiled in because it assumes RGB while lavc encodes YUV.
This commit is contained in:
@@ -1821,6 +1821,14 @@ setparam_oapv(AVCodecContext */*codec_ctx*/, struct setparam_param *param)
|
||||
static void
|
||||
setparam_jxs(AVCodecContext * /* codec_ctx */, struct setparam_param *param)
|
||||
{
|
||||
const struct AVPixFmtDescriptor *pd = av_pix_fmt_desc_get(param->av_pix_fmt);
|
||||
if (pd->log2_chroma_w == 0 && pd->log2_chroma_h == 0 &&
|
||||
(pd->flags & AV_PIX_FMT_FLAG_RGB) == 0) {
|
||||
MSG(ERROR,
|
||||
"JPEG XS is going to to encode YUV 444 is discouraged "
|
||||
"- use jpegxs encoder directly!\n");
|
||||
}
|
||||
|
||||
unsigned decomp_v = 0;
|
||||
if (param->lavc_opts.find("decomp_v") == param->lavc_opts.end()) {
|
||||
unsigned height = param->desc.height;
|
||||
|
||||
Reference in New Issue
Block a user