I noticed recently that for some YouTube videos, playback is choppy, on Firefox Dev edition (102.0b9) with hardware decoding on. That is, they appear to be playing at sub 30 FPS (even though the stats report otherwise).
In case anyone comes across this, it was because I only enabled vaapi, but the other two steps regarding
media.navigator.mediadatadecoder_vpx_enabled from Firefox - ArchWiki seem to be required. At least, it fixed the choppy playback.
Note that the other steps don’t appear to be required, e.g. messing with the sandbox.
After checking the stats again, I just realized the choppy videos were ones using the
av01 codec, which makes sense.