save camera feed

How can I save camera feed which is h264 format to file.h264 before sending it to h264 parser in deepstream sample-app-4?

In deepstream-test4, it runs

filesrc ! h264parse ! nvv4l2decoder ! nvstreammux !...

You have to customize it to

nvarguscamerasrc bufapi-version=1 ! nvstreammux !...

Please share more information about your camera source. nvarguscamerasrc is for Bayer sensor. ‘camera feed which is h264 format’ does not look like a Bayer sensor. We can give another suggestion per your camera source.