Menu

Set delay based on video position

Mor Tuadh
2014-03-11
2017-11-18
  • Mor Tuadh

    Mor Tuadh - 2014-03-11

    Set delay is very powerful feature, and the new function: "from first selected..." is one of my favourites.

    I had an idea for an another set delay feature.

    "Set delay based on video position"

    If I use this a similar window pops up, where I can delay the selected title, or all titles from the first selected, based on the current video position. So I don't have to calculate the timecodes, I just pause the video and set the delay.

    This could be combined with the "shift time" function in the settings, that's very important.

     
    • Andrey Spiridonov

      You can do that now. First, set the desired position of the movie. Then select the subtitles that you want and click on Set Show Time (ALT+C). They will all shift so that the first selected subtitle starts at the current position of the movie and the rest of them will keep their durations and pauses.

       
      • Mor Tuadh

        Mor Tuadh - 2014-04-02

        Thanks, I will try it.

         
        • Andrey Spiridonov

          Let me know if this works for you, so that I can close the thread.

           
          • Gab Arito

            Gab Arito - 2014-04-24

            Yes, certainly.
            It's a very nice trick and works wonderfully well.
            I think you may close the thread.

             
          • Anonymous

            Anonymous - 2014-05-30

            Yes, it works, thank you and sorry for my late answer.

             
          • Mor Tuadh

            Mor Tuadh - 2014-05-30

            Yes, it works, thank you and sorry for my late answer.

             
    • Kameleon_

      Kameleon_ - 2017-11-18

      Post removed.

       

      Last edit: Kameleon_ 2024-02-05
  • Anonymous

    Anonymous - 2015-04-03

    Well, I wanted this feature too, because most of the time all the work of re-syncronyze a subtitle is set a delay (+ or -) to all the lines of a subtitle.

    I try the solution made by Andrey and works, but it isn't the ideal solution, because not allways the first line of a subtitle is the better for check the timming and with this solution only the first line selected to the end would be adjusted.

    I made a solution (better in my opinion) and post here to developer consideration.

    It works very well (I compiled and tested) and consist of pre-fill the delay in the delay form based in the difference between the position of the video and the time of the first selected line. This is made in the SetDelayclick Procedure of the main form.

    Code

    procedure TfrmMain.mnuSetDelayClick(Sender: TObject);
    var Difference,StartTime: Integer;     //Added by Pablo
        Node: PVirtualNode;                //Added by Pablo
    begin
      frmSetDelay := TfrmSetDelay.Create(Application);
    //--------------Added by Pablo  begin-------------------------------------------
      if (Player.Initialized) and (mnuVideoPreviewMode.Checked) and (Assigned(lstSubtitles.FocusedNode)) and (lstSubtitles.SelectedCount >= 1) then
      begin
              Node := lstSubtitles.GetFirstSelected;
              StartTime := GetStartTime(Node);
              Difference := GetCurrentPos - StartTime;
              if Difference < 0 then
                  begin
                       frmSetDelay.rdoDelayMinus.Checked := True;
                       Difference := Difference * -1;
                  end
                  else frmSetDelay.rdoDelayPlus.Checked := True;
      frmSetDelay.tmeDelay.Time := Difference;
      end;
    //--------------Added by Pablo  end---------------------------------------------
      frmSetDelay.ShowModal;
      frmSetDelay.Free;
    end;
    

    .

    I dont think what this change affect other parts of the program, but who knows, in a program so complex as Subtitle Workshop better the developers implements this type of changes.

    Cheers!
    Pablo

     
    • Anonymous

      Anonymous - 2016-01-08
      Post awaiting moderation.
  • Anonymous

    Anonymous - 2015-04-03

    I forgot to include in previous message...
    I made a small freeware program to remove credits and rename video files based in subtitle names.
    I anyone want to check is in: http://srtfilter.blogspot.com.ar/

    Cheers!
    Pablo

     
  • Anonymous

    Anonymous - 2015-10-13
    Post awaiting moderation.
  • antekgla

    antekgla - 2017-04-12

    I made the previous post (as Anonymous) with the code for automatically set the delay based in the time of the video.

    If anyone dont want to compile the code and want the program compiled with that improvement, you can download it Here

    I included the original .exe and the compiled by me. The difference in size is because the original is UPX compressed and mine not. The programmers could understand this better.

    You can check the .exe with Virustotal

    Cheers!


    SrtFilter: Remove Credits and Rename Video Files Automatically

     

    Last edit: antekgla 2017-04-13
    • Gab Arito

      Gab Arito - 2017-04-12

      Congratulations for your contribution on the program!
      Please, check your SourceForge messages.

       
  • Anonymous

    Anonymous - 2017-04-23

    I try to code a Pascal script but I can not use type Text to read file to auto sub.
    When run script it can not compile and say undetify type.
    Could you give me a way to read file?

     
    • Bedazzle

      Bedazzle - 2017-04-24
       
  • Arsham

    Arsham - 2019-12-24
    Post awaiting moderation.

Anonymous
Anonymous

Add attachments
Cancel