Win Lag in starting movie with large local subtitle file
#1
I'll try and make this as succinct as possible.

● OS: Windows 7 Pro SP1 x64
● Running an i5 CPU
● 8GB of RAM
● Kodi: Version 14.2

I attempted to play a movie last night that "hung" for around a minute before the movie began, displaying a "working..." icon on screen. Through some log trawling & troubleshooting, I've narrowed this down to the .sub subtitle file supplied locally with the video file as being the cause in delay.

● If I rename the .sub to something else, like .temp etc. the video plays straight away, without any rescanning of the movie etc.
● Not ALL movies with a .sub file have this issue.
● Whether played from a local source (C:\temp), or from my media server's SMB share, the same movie results in the same lag.
● Whether played directly from "files" or via the library, results in the same lag.
● The same lag is evident across multiple machines (lounge system, bedroom system etc. - same config)
● The same lag occurs whether using Aeon Nox or Confluence skins.

I've narrowed the issue down to the filesize of the .sub file being the cause. Searching for all *.sub files in my media server, then sorting by filesize and starting out playing movies with the smallest .sub file size (1-5mb) and working my way up in 10mb chunks - the "working...." icon gets longer and longer, the larger the filesize of the subtitle file.

I don't really watch a lot of movies these days, so I can't pinpoint when this started occurring (may very well have always been there, just never noticed or had movies with such large subtitle files before). I've added PVR functionality to my lounge system I noticed this behaviour on 1st, however as mentioned above, the same symptom is evident on other machines, that don't have any PVR components of config on them.

Is there any way to speed up KODI reading / loading locally stored sub files?

All logs from testing supplied below, with full debugging turned on:
(process: start KODI, find movie, press play, wait for movie to start. stop movie, exit KODI)

138mb subtitle file. Movie played from SMB Share
138mb subtitle file. Same movie played locally
Same movie with no subtitle file. Played from SMB Share
Different movie with small size (5mb) subtitle file. Played from same SMB Share
Different movie with medium size (55mb) subtitle file. Played from same SMB Share
Reply
#2
Can you upload that large sub file to dropbox or something?
Reply
#3
Can do. Sorry I didn't throw this up with the logs, but after seeing the lag with other movies with a large subtitle file, I figured it wouldn't be an issue with that specific subtitle file.

I've included 3 subtitles files for comparison -

The one I was troubleshooting with (135mb)
One in between the 2 filesizes (206mb)
The largest subtitle file I have (350mb)

Note: When you use the links, it'll give a "Whoops! Unable to process this video" error, but supply a download button. Never really use Google Docs for sharing files - seems to work fine, but gives that error cause it reads the filetype as video

When I was asking my manager this morning at work to test a few of these movies on his system, as he's still using an older XBMC build. (v12: Frodo) When I listed the symptom, he said he tried watching a movie on the weekend that did that - when I checked, it also had a large 200mb+ subtitle file.

So as I mentioned above - this behaviour may have ALWAYS been present, but am only just noticing it now. In having said that, the movie with the largest subtitle file supplied here (The Heat) - I have watched previously, and don't remember any lag on startup...if there was anything like it is now, I'm sure I would have investigated it like I have now.

Anywhoo, any help appreciated :-)

Cheers,

Mungo.
Reply
#4
Just doing some more digging with these subs, and I think I've found the issue, and it's not KODI related. None of these movies with .sub files have any matching .idx files! KODI's probably having a shitfit trying to do anything with it.

I'll either delete the .sub's 'cause they're useless without those idx files, or I'll try and convert them into .srt's. (edit: which I've just read is pretty much impossible as well without the matching .idx file.)

This is just a guess at this point, but I'm going with this theory until I can prove otherwise.

Cheers,

Mungo.
Reply
#5
Yes, the problem is the missing idx file. Kodi tries to open the file as a text based sub file and therefore completely reads it into a buffer.
Reply
#6
Sweet - well that's the end of that chapter :-P. Took a lil bit to get there, but I got there. Thanks for the confirmation. Good to know how these things work Big Grin
Reply

Logout Mark Read Team Forum Stats Members Help
Lag in starting movie with large local subtitle file0