Cubie A7S IMX219 image problems

I’m using a generic IMX219 module with the AC008 FPC cable and the camera works, but the images that it creates with the Gstreamer command come out with visual artifacts and weird colors, why does this happen and how can I fix it?

This is the command I’m using, if there are any other details I need to provide please tell me:

sudo gst-launch-1.0 v4l2src device=/dev/video0 num-buffers=30 en-awisp=1 en-largemode=0 ! video/x-raw,format=NV12,width=3280,height=2464 ! jpegenc ! multifilesink location=prueba_tela_%02d.jpg

Link to image

I am also having problems when recording from radxa 4k camera on a7s, it seems that the first recorded frame has normal colors and then every next one is heavily green tinted. The only solution I found to green tint is using software encode in gstreamer and using videoconvert element to use i420, something like

gst-launch-1.0 v4l2src device=/dev/video1 en-awisp=1 en-largemode=1 !
video/x-raw,format=NV12,width=3840,height=2160,framerate=24/1 !
videoconvert ! video/x-raw,format=I420 !
x264enc tune=zerolatency bitrate=3000 speed-preset=ultrafast !
etc to ur desired sink

but this approach does not work with omxh264videoenc, which makes it unfit for me unfortunately.

Did anyone have any luck getting a good hardware encoded image using those?
My pipeline to create a video is:
sudo gst-launch-1.0 -e \
v4l2src device=/dev/video1 do-timestamp=true ! \
video/x-raw,format=NV12,width=3840,height=2160 ! \
omxh264videoenc target-bitrate=8000000 ! \
h264parse config-interval=1 ! \
matroskamux ! \
filesink location=test.mkv

but i also had to download and install the newest cedarc file from the radxa repo for it to work:
allwininer-debian/packages/arm64/libcedarc/libcedarc-dev_2.0.0_arm64.deb at 7f592b79a85cb7b5ef86dabaf2016013b85a8d4d · radxa/allwininer-debian