Unfortunately both these commands create a somewhat jerky video on my rx 550 on linux mint and drives CPU crazy (ryzen 3500).
I guess it's my underpowered graphics card, but any way to tweak your grab-screen-lossless for a smoother capture?