...
You can use it directly as a lib, or you can use it as a collection of FFmpeg sample code, and refer to its source code to implement the functions you want.
What can it do
Quickly get a video stream from the sensor
Hardware encoding H264 using h264_v4l2m2m
Hardware decoding H264 using h264_v4l2m2m
Quickly create an H264 stream
Mux MP4/FMP4
Demux MP4/FMP4
Specially provided for Pre-Record
...