Kodi not auto-detecting some interlaced H264 videos

Running Kodi 16.1 on Windows 7.

I’ve just hit a slight problem. I have rendered some H264 video from Premiere Pro; the video is 720×576@50i, [email protected] (see below for the full spec) and while it plays correctly in MPC Kodi fails to identify it as interlaced and plays it back progressive. Setting deinterlacing=on resolves the issue, but obviously that’s not ideal – particularly since this option seems to have disappeared in Kodi 17.

The headers on the streams show that the scan-type is interlaced and the field-order is set correctly.

What I’ve tried:
– software and hardware video-decoding : same behaviour in both cases
– putting the video-stream in MP4 and MKV containers : same behaviour in both cases
– other video resolutions/profiles/levels : same behaviour again
– Kodi 17rc2 : same behaviour

By default Premiere outputs what it claims is a ‘standard’ MP4 container. I have found that if I tell it to produce a PSP-compliant container instead, the problem goes away; this isn’t a great solution, since I have a pile of existing videos which I’d prefer not to have to re-encode (Premiere won’t simply re-mux, and while AVIDemux can output a PSP-compliant MP4 this doesn’t fix the problem – which suggests that there’s more to it than a simple re-mux anyway).

This does not affect all interlaced H264 material I’ve tried – streams generated by other tools, along with broadcast streams, are detected correctly – it’s just the ones coming out of Premiere. I’m not ruling out the possibility that Premiere is in fact generating junk (it wouldn’t be the first time!) but given that MPC isn’t having problems with the stream I wonder if maybe Kodi’s simply looking at the wrong thing in these files.

I can provide samples of video which exhibit the problem – please let me know Smile

Many thanks!

Video spec:
ID : 1
Format : AVC
Format/Info : Advanced Video Codec
Format profile : [email protected]
Format settings, CABAC : Yes
Format settings, ReFrames : 3 frames
Format settings, GOP : M=4, N=25
Codec ID : V_MPEG4/ISO/AVC
Duration : 58mn 18s
Bit rate mode : Variable
Maximum bit rate : 14.0 Mbps
Width : 720 pixels
Height : 576 pixels
Display aspect ratio : 4:3
Original display aspect ratio : 4:3
Frame rate mode : Constant
Frame rate : 25.000 fps
Standard : PAL
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Interlaced
Scan order : Top Field First
Language : English
Default : Yes
Forced : No
Color range : Limited