<div dir="ltr">
<p class="">Actually, you may have to shift the subtitles when they comes from another source, under the form of a subtitle file that was prepared for another version of the video you are looking at. I never needed to do it on a DVD.</p>
<div class="gmail_extra"><br><div class="gmail_quote">On Mon, Jun 2, 2014 at 8:09 AM, Julian Scheel <span dir="ltr"><<a href="mailto:julian@jusst.de" target="_blank">julian@jusst.de</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
<div class="">On 02.06.2014 00:28, Pascal Thomet wrote:<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
Thanks for taking the time to answer. I will make some test with a DVD<br>
that includes subtitles. Any ideas about other format that should be<br>
tested as well ?<br>
</blockquote>
<br></div>
You should take DVB into account. Actually I had DVB in mind with my previous mail.<div class=""><br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex">
My impression however is that concerning format like DVD where the<br>
subtitles are muxed into the stream, there should really never be any<br>
need to delay the subtitles : if the subtitles were out of sync on a<br>
dvd, it would means that the DVD is garbage anyway.<br>
</blockquote>
<br></div>
For DVB subtitles I can think of a case where you'd want to resync: On live events are delayed some seconds as they are written on the fly. So it might be worth shifting them if one prefers proper subtitles over fewer overall delay.<br>
<br>
But this is just my 2 cents, in fact I don't use subtitles at all personally. So no clue why and when people shift them :)<br>
<br>
<blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div class="">
Concerning the tooltip I will make it a separate patch.<br>
<br>
I might take me a few days before I can post a corrected set of patches.<br>
<br>
Regards,<br>
<br>
Pascal Thomet<br>
<br>
<br>
<br>
<br>
<br>
On Sun, Jun 1, 2014 at 10:47 AM, Julian Scheel <<a href="mailto:julian@jusst.de" target="_blank">julian@jusst.de</a><br></div><div class="">
<mailto:<a href="mailto:julian@jusst.de" target="_blank">julian@jusst.de</a>>> wrote:<br>
<br>
Am 30/05/14 22:04, schrieb Pascal Thomet:<br>
<br>
This is a follow-up to a patch I made last year<br></div>
(__<u></u>f7211d5efa4cd9ef392230d85fdf34<u></u>__70edefab39)<div class=""><br>
When developping it I stumbled upon a prexisting bug that I could<br>
not correct at that time.<br>
<br>
I now propose a correction for this bug, as well as tooltip that<br>
better<br>
explain the use of the hotkeys introduced by<br></div>
f7211d5efa4cd9ef392230d85fdf34<u></u>__70edefab39<div class=""><br>
<br>
tests passed / compile and runs correctly in debug & release modes<br>
under linux & OSX<br>
<br>
1) Bug correction info :<br>
* * * * * * * * *<br>
<br>
Bug reproduction step : *under linux* (will not happen under OSX)<br>
- launch a video that has a subtitle,<br>
- press Shift-H ("bookmark audio time"),<br>
- wait 5 seconds<br>
- press Shift-J ("bookmark subtitle time")<br>
- press Shift-K ("sync bookmarks")<br>
==> the audio is broken...<br>
(AFAIK this bug seems not to be mentioned on <a href="http://trac.videolan.org" target="_blank">trac.videolan.org</a><br></div>
<<a href="http://trac.videolan.org" target="_blank">http://trac.videolan.org</a>>)<div><div class="h5"><br>
<br>
The subtitle delay ("spu-delay") was previously implemented by<br>
i) setting a variable spu-delay<br>
(var_SetTime(... , "spu-delay", ... ))<br>
ii) this change raised a callback that finaly lead to calling<br>
UpdatePtsDelay().<br>
<br>
The reason UpdatePtsDelay() was called is that the subtitle delay<br>
was programed the same way as the audio delay (for which it is<br>
required<br>
to wait until the audio is actually demuxed)<br>
<br>
*However* the situation for subtitles is quite different, as<br>
they are all in memory<br>
(no need to wait until they are demuxed !)<br>
<br>
<br>
This really depends on the subtitle source. In case of dvb subtitles<br>
in mpeg ts they are not all in memory but come muxed into the stream.<br>
<br>
The code is now more simple (and the bug is fixed !) :<br>
- no more delay calculations inside hotkeys.c, everything is handled<br>
inside subtitle.c through callbacks<br>
- inside subtitle.c :<br>
* adjust_subtitle_time() receives a subtitle timestamp as<br>
input and returns<br>
that timestamp corrected by spu-delay<br>
* set_current_subtitle_by_time() is called when spu-delay<br>
is changed<br>
<br>
2) Tooltip<br>
* * * *<br>
<br>
<br>
imho this should be split into a separate patch.<br>
<br>
This adds a tooltip in the "Track Synchronization" window<br>
on the "subtitle track sycnhronization" label and widget.<br>
It explains better the use of the subtitle sync hotkeys<br>
(Shift H/J/K)<br>
<br>
Also tested under Linux & OSX.<br>
---<br>
<br>
<br>
<br></div></div><div class="">
______________________________<u></u>_________________<br>
vlc-devel mailing list<br>
To unsubscribe or modify your subscription options:<br>
<a href="https://mailman.videolan.org/listinfo/vlc-devel" target="_blank">https://mailman.videolan.org/<u></u>listinfo/vlc-devel</a><br>
<br>
</div></blockquote><div class=""><div class="h5">
______________________________<u></u>_________________<br>
vlc-devel mailing list<br>
To unsubscribe or modify your subscription options:<br>
<a href="https://mailman.videolan.org/listinfo/vlc-devel" target="_blank">https://mailman.videolan.org/<u></u>listinfo/vlc-devel</a><br>
</div></div></blockquote></div><br></div></div>