VideoHelp Forum
+ Reply to Thread
Page 1 of 4
1 2 3 ... LastLast
Results 1 to 30 of 109
Thread
  1. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Problem: Samsung S10 HD Camcorder stores video files as .mp4 format with no time & date display.

    Solution: I have produced a VB.Net application that produces a standard widely used subtitle file (.srt) that contains the time & date for the selected file.
    The application also supports creating .srt files for all .mp4 files in a selected folder (files will be created with same name as source file with .mp4 replaced by .srt).

    ************************************************** ***********************************************
    mp4timedate is no longer supported, an improved version has been produced called TimeDateSRTCreator
    It is available from the Videohelp software download section https://www.videohelp.com/software/TimeDateSRTCreator
    or direct from the Sourceforge host on http://sourceforge.net/projects/timedatesrtcreator
    ************************************************** ***********************************************

    To run the application you require the VB.Net 2.0 framework, it can be downloaded from http://www.microsoft.com/downloads/en/details.aspx?FamilyID=0856eacb-4362-4b0d-8edd-aab15c5e04f5&displaylang=en.

    Subtitle file can be used in a variety of video processing programs; I use Freemake Video Converter (http://www.freemake.com/free_video_converter) which has an easy to use interface with extensive output options available.
    Feel free to post comments, suggestions etc regarding the application.

    time2innov8
    Last edited by time2innov8; 5th Jul 2015 at 12:24. Reason: Updated software links
    Quote Quote  
  2. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    It seems to work fine. Tried it on a random mp4,

    Click image for larger version

Name:	sub.png
Views:	2173
Size:	53.6 KB
ID:	7307
    Click image for larger version

Name:	sub2.png
Views:	734
Size:	633.8 KB
ID:	7308
    Quote Quote  
  3. Would you able to make your program also works for M2TS file? It would be very helpful for all my home videos.

    Thanks,
    Jess
    Quote Quote  
  4. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Jess,

    If you can send me 2 M2TS files taken with your camcorder (short videos, just a couple of seconds) I will analyse the structure and see if I can modify my program to output the .srt subtitle file.

    Stuart
    Quote Quote  
  5. Did you ever modify your application to handle m2ts files?
    Quote Quote  
  6. For those looking for .m2ts/avchd support try avchd2srt (there are some GUI's later in the thread)

    https://forum.videohelp.com/threads/316229-Export-AVCHD-frame-specific-metadata-to-subtitles
    Quote Quote  
  7. Hello, I don't know if the original programmer is still here, but I'll post anyway.

    First of all: Great program! This is just what I need. However, the program doesn't use the exact video clip length, only the approximated one in whole seconds. This leads to inaccuracies when joining clips together.

    Please have a look at the following forum post where the problem is described in detail, as well as a (time-consuming manual) workaround.

    https://forum.videohelp.com/threads/371906-XAVC-S-How-to-export-time-date-metadata-to-s...=1#post2391158


    Thanks for reading!
    Quote Quote  
  8. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Hi,
    Original programmer here, that's great you find the app of some use. Due to a similar issue with a second camcorder I recently wrote an updated version called TimeDateSRTCreator (TDSC) which is available at: http://sourceforge.net/projects/timedatesrtcreator. The new application is based around the mediaInfo wrapper and will create srt files for any extension it supports.
    TDSC will only count up to the nearest second as with mp4timedate but if you send me details of what you want to achieve I will try to modify the code to suit.

    time2innov8
    Last edited by time2innov8; 19th May 2015 at 15:09. Reason: file hyperlink changed
    Quote Quote  
  9. Hi, great that you are still here! Thanks for offering to help, I'll explain what I need.

    Please look at the enclosed video clip. Using MediaInfoXP you can see that the duration is 3 s, 360 ms. The time/date it was encoded was UTC 2015-05-16 05:51:53.

    If I run it through the latest version of your program I get the following srt file (without changing any options):

    1
    00:00:00,000 --> 00:00:00,999
    18. mai 2015 14:16:31

    2
    00:00:01,000 --> 00:00:01,999
    18. mai 2015 14:16:32

    3
    00:00:02,000 --> 00:00:02,999
    18. mai 2015 14:16:33
    1) There is a different date and time applied than the date and time it was filmed. Would it be possible to use the "encode date" in mediainfo as the start time? Then I could just use the offset function you have already implemented in your program to convert it to my local time.

    2) The program "misses" the last 360 ms of the clip duration. I'd like the output to be

    1
    00:00:00,000 --> 00:00:00,999
    18. mai 2015 14:16:31

    2
    00:00:01,000 --> 00:00:01,999
    18. mai 2015 14:16:32

    3
    00:00:02,000 --> 00:00:02,999
    18. mai 2015 14:16:33

    4
    00:00:03,000 --> 00:00:03,360
    18. mai 2015 14:16:34


    Do you think this is possible to achieve? If so, it would be excellent. Thanks again for offering to help!
    Image Attached Files
    Quote Quote  
  10. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Version 1.1 uploaded to: https://sourceforge.net/projects/timedatesrtcreator/

    Version 1.1 (18/05/15)
    Time/Date for video file(s) read from encoded parameters, if error occurs the creation Time/Date of the file is used.
    Option added to insert extra subtitle with remainder of video duration in milliseconds after complete seconds have been written.

    time2innov8
    Last edited by time2innov8; 19th May 2015 at 15:10. Reason: file hyperlinked
    Quote Quote  
  11. You sir, are a genius! Your program does exactly what I want now. All I had to do was to add 2 hours offset to get my local time. I just used it to create about 80 srt files with one click, which I later joined together into one srt file using subtitle workshop. I then combined the video clips into one 50 minute clip. Quick and painless.

    I think you deserve a donation. If you use Paypal you can PM me your details and I'll see if I can find out how to donate!
    Quote Quote  
  12. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Thanks for the kind words, I'm happy to have helped resolve your problem in creating the files.
    if you feel the need to provide some financial reward, donate it to some worthwhile charity on my behalf

    All the best

    time2innov8
    Last edited by time2innov8; 19th May 2015 at 03:33.
    Quote Quote  
  13. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Great job time2innov8!

    And indeed, it is always time to innovate, to stand still is to backslide!

    Quote Quote  
  14. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    I added a mirror

    TimeDateSRTCreator

    ( I will make a bigger screenshot later).
    Quote Quote  
  15. I would like to test TDSC. I am getting a "Stopped working" when I launch the program.

    I am on Windows 7 Home Premium and I have .NET 4.5 Full Package installed. TDSC is Version 1.3

    The problem signature is as follows:

    <ProblemSignatures>
    <EventType>CLR20r3</EventType>
    <Parameter0>timedatesrtcreator.exe</Parameter0>
    <Parameter1>1.0.0.0</Parameter1>
    <Parameter2>555c96bc</Parameter2>
    <Parameter3>mscorlib</Parameter3>
    <Parameter4>2.0.0.0</Parameter4>
    <Parameter5>5174de33</Parameter5>
    <Parameter6>1fc6</Parameter6>
    <Parameter7>0</Parameter7>
    <Parameter8>System.IO.FileNotFoundException</Parameter8>
    </ProblemSignatures>

    Is mscorlib part of .NET 4.5?
    Quote Quote  
  16. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Re VB.Net issue,

    I have tried removing runtime versions from my laptop to see if I can replicate your error but the app still runs.
    TDSC is compiled for VB.Net 2 (2.0.50727), I assumed that .Net is fully backward compatible but searches online dispute that.
    You can check your .Net versions by following the instructions here:
    https://msdn.microsoft.com/en-us/library/hh925568(v=vs.110).aspx

    Hope you get success

    time2innov8
    Quote Quote  
  17. Originally Posted by time2innov8 View Post
    Re VB.Net issue,

    I have tried removing runtime versions from my laptop to see if I can replicate your error but the app still runs.
    TDSC is compiled for VB.Net 2 (2.0.50727), I assumed that .Net is fully backward compatible but searches online dispute that.
    You can check your .Net versions by following the instructions here:
    https://msdn.microsoft.com/en-us/library/hh925568(v=vs.110).aspx

    Hope you get success

    time2innov8
    I got TDSC to launch. It turned out to be a missing file (sortkey.nlp) for the .NET Framework 2.0. I would be a good idea to have an exception handler to print out the message. In my case, I caught the exception in a debug environment.

    I would like to create a subtitle file for a folder that contains the video clips. I can select the folder but I cannot start the creation of the .srt file. The button "Create Subtitle File" is disabled. However, I am able to "Create Multiple Subtitle Files".

    /leepan8
    Quote Quote  
  18. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    If you select a folder it is the multiple button that is enabled, its action loops through the directory selected for valid files creating the corresponding .srt files.

    time2innov8
    Quote Quote  
  19. Originally Posted by time2innov8 View Post
    If you select a folder it is the multiple button that is enabled, its action loops through the directory selected for valid files creating the corresponding .srt files.

    time2innov8
    I get it. Thanks.

    I misunderstood the interface. I thought when I selected the folder, I can either create multiple srt files (one for each video clip) or one single file which will contain a joined srt file for all the video clips in the folder. One of the create buttons may be redundant. The "Select File" and "Select Folder" buttons can be used to determine the type of srt file to generate.

    Also, what is the function of "Add Remainder of Duration Time (Milliseconds) and the "Length of time ... to display each subtitle" has a maximum of 1000.

    /leepan8
    Quote Quote  
  20. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Originally Posted by leepan8 View Post

    I get it. Thanks.

    I misunderstood the interface. I thought when I selected the folder, I can either create multiple srt files (one for each video clip) or one single file which will contain a joined srt file for all the video clips in the folder. One of the create buttons may be redundant. The "Select File" and "Select Folder" buttons can be used to determine the type of srt file to generate.

    Also, what is the function of "Add Remainder of Duration Time (Milliseconds) and the "Length of time ... to display each subtitle" has a maximum of 1000.

    /leepan8
    I could probably have a single file/folder button, the logic was easier with both options seperate.
    Add remainder to duration was a feature requested by a user, they wanted the video srt to show the time at the very end which could be a number of milliseconds. Normally tbe time segments are only in the srt file for whole seconds.
    The length of time is how long that each subtitle is displayed on the screen, on the original version I used 999 milliseconds as the default, a user reported that this caused the subtitle to flash, so it was changed to 1000. Its debateable if anyone would want to change it to any other number so probably should be set as 1000 without the option to change, but its there in case someone finds it useful.

    time2innov8
    Quote Quote  
  21. Originally Posted by time2innov8 View Post
    Originally Posted by leepan8 View Post

    I get it. Thanks.

    I misunderstood the interface. I thought when I selected the folder, I can either create multiple srt files (one for each video clip) or one single file which will contain a joined srt file for all the video clips in the folder. One of the create buttons may be redundant. The "Select File" and "Select Folder" buttons can be used to determine the type of srt file to generate.

    Also, what is the function of "Add Remainder of Duration Time (Milliseconds) and the "Length of time ... to display each subtitle" has a maximum of 1000.

    /leepan8
    I could probably have a single file/folder button, the logic was easier with both options seperate.
    Add remainder to duration was a feature requested by a user, they wanted the video srt to show the time at the very end which could be a number of milliseconds. Normally tbe time segments are only in the srt file for whole seconds.
    The length of time is how long that each subtitle is displayed on the screen, on the original version I used 999 milliseconds as the default, a user reported that this caused the subtitle to flash, so it was changed to 1000. Its debateable if anyone would want to change it to any other number so probably should be set as 1000 without the option to change, but its there in case someone finds it useful.

    time2innov8
    The reason I am looking for a longer display time is to workaround the flickering of the subtitle which is caused by the one second update of the subtitle on the screen (I think). My thinking was that if I can increase the length of display time to be longer than the length of the video clip, I can get only one entry in the srt file per video clip.

    "Add remainder to duration" can do the trick for me. How does it work?

    /leepan8
    Quote Quote  
  22. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Originally Posted by leepan8 View Post

    The reason I am looking for a longer display time is to workaround the flickering of the subtitle which is caused by the one second update of the subtitle on the screen (I think). My thinking was that if I can increase the length of display time to be longer than the length of the video clip, I can get only one entry in the srt file per video clip.

    "Add remainder to duration" can do the trick for me. How does it work?

    /leepan8
    Confused by the length of files you are trying to process. If you have a video of 3 seconds 500 milliseconds, normally three entries would be in the srt file, one entry for each second. With the add remainder checked, four entries will be in the srt file. I have successfully used the srt files created by TDSC with Freemake Video Converter, with 1000mS as the display time I see no discernible flicker. With the time set at 999ms a flicker is present.

    time2innov8
    Quote Quote  
  23. Originally Posted by time2innov8 View Post
    Originally Posted by leepan8 View Post

    The reason I am looking for a longer display time is to workaround the flickering of the subtitle which is caused by the one second update of the subtitle on the screen (I think). My thinking was that if I can increase the length of display time to be longer than the length of the video clip, I can get only one entry in the srt file per video clip.

    "Add remainder to duration" can do the trick for me. How does it work?

    /leepan8
    Confused by the length of files you are trying to process. If you have a video of 3 seconds 500 milliseconds, normally three entries would be in the srt file, one entry for each second. With the add remainder checked, four entries will be in the srt file. I have successfully used the srt files created by TDSC with Freemake Video Converter, with 1000mS as the display time I see no discernible flicker. With the time set at 999ms a flicker is present.

    time2innov8
    I use a WDTV Live to view my home movies. I have all my video clips from my camera merged into one .mkv file and similarly all my .srt files joined into one. I enable the subtitle during viewing (an option on the WDTV Live) thus the subtitles can be turned on/off. Do you burn the subtitles into the video stream or keep them separate when using Freemake?

    /leepan8
    Quote Quote  
  24. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Originally Posted by leepan8 View Post

    I use a WDTV Live to view my home movies. I have all my video clips from my camera merged into one .mkv file and similarly all my .srt files joined into one. I enable the subtitle during viewing (an option on the WDTV Live) thus the subtitles can be turned on/off. Do you burn the subtitles into the video stream or keep them separate when using Freemake?

    /leepan8
    I rarely create burned media but using Freemake I create a video file that has the subtitles merged. Normally the videos are played using dlna server function on synology nas to the required device (tablet, laptop, wdtv)
    If creating a single srt file is beneficial I could add it as an option to TDSC.
    Quote Quote  
  25. Originally Posted by time2innov8 View Post
    Originally Posted by leepan8 View Post

    I use a WDTV Live to view my home movies. I have all my video clips from my camera merged into one .mkv file and similarly all my .srt files joined into one. I enable the subtitle during viewing (an option on the WDTV Live) thus the subtitles can be turned on/off. Do you burn the subtitles into the video stream or keep them separate when using Freemake?

    /leepan8
    I rarely create burned media but using Freemake I create a video file that has the subtitles merged. Normally the videos are played using dlna server function on synology nas to the required device (tablet, laptop, wdtv)
    If creating a single srt file is beneficial I could add it as an option to TDSC.
    A single srt file option will be a very good option to have. Note that when joining the srt files you will need to recalculate the time (each srt time starts at zero).

    /leepan8
    Quote Quote  
  26. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    I have updated TimeDateSRTCreator to version 1.4, which adds the option to create a single subtitle file for multiple video files. If anyone experiences a problem using the new option get in touch.

    time2innov8
    Quote Quote  
  27. Originally Posted by time2innov8 View Post
    I have updated TimeDateSRTCreator to version 1.4, which adds the option to create a single subtitle file for multiple video files. If anyone experiences a problem using the new option get in touch.

    time2innov8
    Tested. Works perfectly !!!. Good feature.

    /leepan8
    Quote Quote  
  28. Hello again! I want to report a bug with the "merge subtitles" function in version 1.4 of your program. It doesn't take into account that the clips are not exactly X seconds long, even though the "add remaining time in milliseconds" button is checked. As a result, the subtitles quickly go out of sync.

    Example: I have two clips for which I want to merge the subtitles. The first clip is 9 seconds, 120 milliseconds long. When I use your program I get the following srt (the first 7 seconds removed for clarity):

    Code:
    ...
    
    8
    00:00:07,000 --> 00:00:08,000
    lørdag 27. juni 2015 16.17.25
    
    9
    00:00:08,000 --> 00:00:09,000
    lørdag 27. juni 2015 16.17.26
    
    10
    00:00:09,000 --> 00:00:09,120
    lørdag 27. juni 2015 16.17.27
    
    11
    00:00:10,000 --> 00:00:11,000
    lørdag 27. juni 2015 17.11.58
    
    12
    00:00:11,000 --> 00:00:12,000
    lørdag 27. juni 2015 17.11.59
    
    ...
    To clarify, the error is at the start of the second clip (the line below the "11").
    This line should not be "00:00:10,000 --> 00:00:11,000" but "00:00:09,120 --> 00:00:10,120", and then continue like that.

    Please ask if you have any questions! Thanks.
    Quote Quote  
  29. Member
    Join Date
    May 2011
    Location
    Scotland
    Search PM
    Originally Posted by okv View Post
    Hello again! I want to report a bug with the "merge subtitles" function in version 1.4 of your program. It doesn't take into account that the clips are not exactly X seconds long, even though the "add remaining time in milliseconds" button is checked. As a result, the subtitles quickly go out of sync.


    To clarify, the error is at the start of the second clip (the line below the "11").
    This line should not be "00:00:10,000 --> 00:00:11,000" but "00:00:09,120 --> 00:00:10,120", and then continue like that.

    Please ask if you have any questions! Thanks.
    Application updated to version 1.5, bug reported by okv fixed (adding multiple files with various millisecond durations)

    If further issues let me know
    Quote Quote  
  30. Hey time2innov8, nice to see that you still maintain your program! The merge function works great now, much better than Subtitle Workshop which I've had to use up until now.

    However, one bug remains. In the merged srt file, the time codes are listed like this:

    Code:
    00.00.00,000 --> 00.00.01,000
    However, it should look like this (with colons instead):

    Code:
    00:00:00,000 --> 00:00:01,000

    Hopefully, this should be relatively simple to fix. Thanks again for your great software.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!