Glitchy camera snaps

I have a lot of green and glitches in snapshots intended for doods (object detection). But Inalso have theese effects on entity ”avatars”.

Ffmpeg - camera platform.
Rtsp protocol on imou (dahua) cameras. (Two different ones)

Anyone with som hints on how to fix this? Thanx!