As described in this thread https://sourceforge.net/projects/syntekdriver/forums/forum/616182/topic/3521486 video frames are not deinterlaced properly when applications request frames at a rate lower than the native framerate of the device (50/60 HZ). This is because video fields are dropped without being decoded when the frame buffer fills up, but the frame being dropped may contain a video field that is required to decode the next image.
The result is a "ghosting" artifact, where the driver returns the same field to the application repeatedly, even 10-20 times. This causes a "ghost" to appear, where an old field is overlaying a field with the current image.
To fix this, my patch causes two consecutive video fields to be decompressed whenever an image is requested and data frames have been dropped since the last image was delivered. To accomplish this, I must create an extra frame and image buffer. (I tried using one of the image buffers that was already allocated, but there were problems because the user application might still be using the "extra" image buffer. For this reason, I had to allocate a working image buffer which is never returned to the user.)
The fix is turned off by default. I added a module option (ghostprotection) to turn the fix on when needed.
Patch