avformat/mpegtsenc: factorize writing registration_descriptor