Req Set Subtitle Frame Rate
Any progress with this issue?
Only the work you done on it.
Hi,

I have the same problem, and I'd like to try to implement it.
Any tips where to start will be highly appreciated!
See next post.
deleted. corrected version below
Just a suggestion. Consider the "subtitles offset" tool after the "sound" button.

It lets you slide forward or backward for max 1 minute to set an offset. This is OK for subtitles at the same speed of the movie.

To grasp it mathematically, this means:

t = timestamp of the subtitle in e.g. the .SRT file
o = offset of the subtitle
t' = t+o or the time the subtitle is actually shown

Actually, if the movie is played at a different rate, there is something like a speed factor. Let's call it "s".

s = speed factor
so a new expression for t' is now:

t' = s*t + o

At a constant speed difference, the subtitles should remain in sync.

However, getting a grip on that speed factor could be tedious, but it is a quite simple problem to solve mathematically, and with the help of an enhanced "subtitle offset" tool. How?

Simply let's calibrate on two places in the movie:
- calibrate for an offset one time and store
- cue the movie for some 15 minutes, calibrate another offset and store

Now it's up to the tool to do some calculations

We have:
t'1 = t1 + o1
t'2 = t2 + o2

offset evolves linearly with play time:

(o - o1) = (t - t1) / (t2 - t1)
o = o1 + (o2 - o1) * (t - t1) / (t2 - t1)

t' = t + o1 + (o2 - o1) * (t - t1) / (t2 - t1)
= (1 + (o2 - o1) / (t2 - t1) )* t +o1 - (o2 - o1) / (t2 - t1) * t1

so the constants "s" and "o" in our equation "t' = s*t + o" are:

s = 1 + (o2 - o1) / (t2 - t1)
o = o1 - (o2 - o1) / (t2 - t1) * t1

Quite a simple solution for a very annoying problem, I thought.
Is anyone following up on making this modification?

Does not look like anyone is interested in this.
HowTo setup NFS for Kodi: NFS (wiki)
HowTo configure avahi (zeroconf): Avahi_Zeroconf (wiki)
READ THE IOS FAQ!: iOS FAQ (wiki)
(2013-09-15, 08:28)botribun Wrote:
(2013-09-14, 22:50)Ned Scott Wrote: I was always under the impression that most subtitles are time stamped based, not frame rate based.
I don't know exactly but with XBMC the subtitles will get out of sync if you have different frame rates. Eg, your video is 25 fps but the subs are made for a 23,978 fps video, the timestamps will not match somehow and the subtitles moving far ahead as later the movie goes.

To fix this I used the SubtitleCreator tool and convert the fps, but as said before if you have a lot of TV shows with different frame rates its really getting a demanding job. (specially when you have a impatient wife)

So what I'm asking is, would it be possible to add some frame rate setting for the subtitles, that do some kind of live converting the timestamps to match the frame rates and not running out of sync?

I would liké that too, im tired of keeping thé subtitles offset opened for thé whole vidéo
I had to change the fps in subtitle workshop the other day, So yes, same way to re-stamp the subtitles times from between kodi would be nice.
I also vote for this feature .... it would be nice to toggle through the various combinations and permutations of common frame speeds while watching on Kodi. That way you can simultaneously adjust/sample both delay-advance times and frame rate stretching-shrinking.

As mentioned in an earlier post you don't need to know the current frame rate to implement this feature ... just try toggle through the different frame rate ratios.

Also, remember to store the final Delay-Advance, Stretch-Shrink settings for any particular subtitle file, for when the movie is later resumed (e.g., after when the wife watches a different movie before I can get back to mine).

common fps that i have found:
15
23.976
24
25
29.97
Sorry it occurred to me there might be an easy solution. Just have an expand-contract bar underneath the delay-advance bar. The math behind the bar that changes the timings might be a bit tricky, but the approach would be applicable for all subtitle types (.srt, .sub, .ssa) and you wouldn't have to know anything about framerates.
Hello

This issue is very annoying, any progress on this ?
Uh, didn't know this thread is still alive.

Years later, me still sitting at the PC and editing srt's for my wife with Subtitle Workshop 6.0b, it never gets old.
(2017-07-15, 14:13)Longtime Collector Wrote: Sorry it occurred to me there might be an easy solution. Just have an expand-contract bar underneath the delay-advance bar. The math behind the bar that changes the timings might be a bit tricky, but the approach would be applicable for all subtitle types (.srt, .sub, .ssa) and you wouldn't have to know anything about framerates.

That would actually be quite elegant; in the offset window have a second bar which converts from 23.976 <> 25; so you'd have:

Offset: [-60] -------------------- [0] -------------------- [+60]
Adj fps: [25 to 23.976]     -     [0]     -     [23.976 to 25]

(You could have all the other increments in there too but I suspect most sync issues involve just 23.976 and 25fps).