Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion. Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules. |
|
|
Thread Tools | Search this Thread | Display Modes |
8th April 2021, 16:56 | #1 | Link |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,869
|
XAVC Intra Class 300 and 480 in x264 (test volunteers required)
Hi there,
I'm looking for volunteers to test XAVC Intra Class 300 and 480 in x264 as they're not officially supported as classes. XAVC Intra is a set of profile established by Sony that encode all frames as Intra according to the framerate of the profile. The classes are: XAVC Intra Class 50, XAVC Intra Class 100, XAVC Intra Class 200, XAVC Intra Class 300, XAVC Intra Class 480. The number refers to the bitrate of a 29.970fps stream and is adjusted accordingly. For instance, XAVC Intra Class 300 has a bitrate of 300 Mbit/s for 29.970fps and it doubles up to 600 Mbit/s if the framerate doubles to 59.940fps. The bit depth is 10bit planar and the sampling is 4:2:2 planar (except for a particular case in which, for Class 50, 4:2:0 planar is also accepted). The table shows the framerates relative to the classes: Reference: Sony XAVC Specs Classes are divided between XAVC Intra Class HD and XAVC Intra Class 4K where for the 4K ones interlaced encode is not supported. Those classes have been implemented in x264 and can be called using: Code:
x264.exe "AVS Script.avs" --avcintra 50 --avcintra-flavor sony Code:
x264.exe "AVS Script.avs" --avcintra 100 --avcintra-flavor sony Code:
x264.exe "AVS Script.avs" --avcintra 200 --avcintra-flavor sony Code:
x264.exe "AVS Script.avs" --avcintra 300 --avcintra-flavor sony Code:
x264.exe "AVS Script.avs" --avcintra 480 --avcintra-flavor sony The reason for the latter command "--avcintra-flavor sony" is that there are two flavors: the sony one, namely XAVC Intra and the Panasonic one, namely AVC Intra. The specifications for the Panasonic one differ from the Sony one, for instance the value for "--slices" is different. The Panasonic specs can be found here: AVC Intra Specs. Encoding in x264 with classes 50, 100, 200 is currently officially supported, while classes 300 and 480 support is experimental. Builds: Link Source code: Link This is how the MediaInfo of an XAVC Intra Class 480 50p PAL HLG HDR 1000 nits 3840x2160 Level 5.2 Profile Intra 4:2:2 planar 10bit 800 Mbit/s looks like after it has been encoded with x264 and muxed with BBC BMX in mxf: This file has been successfully tested on the Versio UHD Playout Ports at Sky. Such file has also been tried on AVID and it was recognized correctly as XAVC Intra Class 480. If you're not willing to use the pseudo-official implementation and you would rather like to call the official x264 and encode it yourself, you can try to force the parameters yourself, however you won't be using things like the ad hoc quantization matrix: Code:
avs4x264mod.exe "AVS Script.avs" --x264-binary "x264-10b.exe" --input-depth 16 --preset medium --profile high422 --level 5.2 --keyint 1 --no-cabac --slices 8 --bitrate 500000 --vbv-maxrate 500000 --vbv-bufsize 10000 --overscan show --colormatrix bt2020nc --range tv --log-level info --thread-input --transfer arib-std-b67 --colorprim bt2020 --videoformat component --nal-hrd cbr --output-csp i422 --output-depth 10 --output "raw_video.h264" ffmpeg.exe -i "raw_video.h264" -i "AVS Script.avs" -map 0:0 -c:v copy -map 1:1 -c:a pcm_s24le -ar 48000 -f mxf "pre-final_output_UHD.mxf" bmxtranswrap.exe --umid-type uuid -p -y 10:00:00:00 -o "final_output_UHD.mxf" "pre-final_output_UHD.mxf" pause All credits to "ifb" for showing us the quantization matrix and implementing the code in his branch hoping it to be merged, to JPSD (Jean Philippe Scotto di Rinaldi) for actually merging the code to his branch and provide t_mod builds, to Steipal (Steinar Apalnes), emcodem and momocampo (Benjamin Dissoubret) for allowing me to code and implement the Sony Class Support in FFAStrans and to algie (Livio Aloja) for testing on NLE. I would very much like to see it merged in the official master, so what I'm asking the community is: A) If you're a broadcaster or a professional working in the field which owns a playout server (so hardware playout ports) which play official XAVC Intra Class 300 or 480 files just fine, please try to encode a sample yourself x264 and try to play it on your hardware playout port. B) Report the result here so that we can gather a list of which servers actually support it and see if there are any incompatibilities and if we can tackle them somehow before committing a patch. The current list is: - Versio Playout Server: Ok, recognized and played fine - AVID Media Composer: Ok, recognized and played fine Thanks everyone, Frank Last edited by FranceBB; 11th February 2023 at 00:12. |
13th April 2021, 21:09 | #2 | Link |
Registered User
Join Date: Dec 2009
Posts: 72
|
No need to reinvent the wheel. There's an existing merge request on GitLab to add XAVC 300/480 if you want something to test:
https://code.videolan.org/videolan/x...rge_requests/6 Current builds here. Code:
x264 "inputfile.y4m" --avcintra 300 --avcintra-flavor sony --output-depth 10 --output-csp i422 -o "raw_video.h264" Code:
x264 "inputfile.y4m" --avcintra 480 --avcintra-flavor sony --output-depth 10 --output-csp i422 -o "raw_video.h264" Last edited by ifb; 13th April 2021 at 22:18. Reason: add example |
25th April 2021, 19:40 | #4 | Link |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,869
|
All results were fine. I also modified the first post and commented in the branch.
I really hope this is merged to the master on GitLab, but I think we're gonna need more and more people to test it and comment there. |
29th April 2021, 18:11 | #7 | Link |
Broadcast Encoder
Join Date: Nov 2013
Location: Royal Borough of Kensington & Chelsea, UK
Posts: 2,869
|
I don't think so. Intra Class 50, 100, 200 were already there, so if those were available in the official master, I don't see anything preventing us from adding Class 300 and 480 as well, so... I don't think there's any problem in using those builds.
|
Thread Tools | Search this Thread |
Display Modes | |
|
|