Yes.
BTW you don’t need videoconvert (it is implicit).
gst-launch-1.0 --verbose videotestsrc ! video/x-raw,format=NV12,width=1920,height=1080,framerate=30/1 ! mpph264enc ! fakesink sync=false
Good luck.
Update:
You you want to go this route, read here what you need:
(IMX415 + NPU demo on ROCK 5B - #19 by avaf)
, or use Jiangfeng Liu’s ppa on Ubuntu 22.04, but i think only Wayland.