Hi Kostya
There are two problems with it. First, it's called simply proresenc.c
here, and second, it's not a good idea to mix several things in the
patch.
I was just doing what I was advised to do - I made the patch against
libavcodec, I'm just passing it back here to help. Sorry if that's not
what you want.
1. Fixes chroma block ordering for 4:4:4
That one should be tested and maybe we need to fix our decoder as well.
Luma blocks are
A B
C D
Chroma blocks for 4:4:4 are
A C
B D
The errors in the current version are clearly visible when encoding 444
and viewing in QuickTime.
3. Fixes plane_factor calculation for 4:4:4 chroma planes
I doubt it, your change does not change anything in behaviour.
before:
if (chroma)
plane_factor += chroma_factor - 3;
your change:
if (!chroma || chroma_factor == 3){
//do nothing
}else{
plane_factor += chroma_factor - 3;
}
Result is the same.
Fair enough, but only because CFACTOR_Y444 - 3 == 0 :-)
4. Adds a "4444" profile (min_quant and max_quant may still be wrong
though, verification welcome)
It's kinda pointless without proper pixel format with alpha. Hopefully
Ronald can add it.
It is useful because it sets the quant values to 4 throughout, which is
necessary for the maximum quality required for "444".
5. Sets the colour primaries, transfer function and matrix from the
context options into the ProRes header
Are you sure our enum values correspond to what Apple decoder expects to
see there?
Yes, the values in avcodec.h match those in the Apple headers exactly.
When encoding NTSC, PAL or HD it's necessary to put the correct values in
there to get correct results in decode.
Thanks
Phil
--
Phil Barrett
FilmLight
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel