VideoHelp Forum
+ Reply to Thread
Results 1 to 3 of 3
Thread
  1. Member
    Join Date
    Jan 2006
    Location
    United States
    Search Comp PM
    Trying to add Chapters in my AVS scripts for final MKV output.
    My script contains multiple clips (amalgamation of video clips, and pictures).

    I would like to put a Chapter start at beginning of each my clip.

    ShowSMPTE will Timecodes in video, but not to an external text file like chapters.txt.

    My normal route is x264 for .264 and faac/neroAacEnc for .aac or wav(vdub) to ac3 (eac3to), to using mkvmerge for MKV with chapters.

    I don't mind doing another pass on my .AVS as I am doing second pass for Audio already. This pass should create a text file compatible with mkvmerge with my specified timecodes.

    Pseudo code:

    v1 = AviSource("FirstBD.avi")
    v1t = blank(200).Subtitle("First Birthday")
    chv1 = ? # Chapter 1 timecode
    v2 = AviSource("SecondBD.avi")
    v1t = blank(200).Subtitle("Second Birthday")
    chv2 = ? # Chapter 2 timecode
    v3 = AviSource("ThirdBD.avi")
    v1t = blank(200).Subtitle("Third Birthday")
    chv3 = ? # Chapter 3 timecode

    return chv1 ++ v1 ++ v1t ++ chv2 ++ v2 ++ v2t ++ chv3 ++ v3 ++ v3t
    Quote Quote  
  2. Member AlanHK's Avatar
    Join Date
    Apr 2006
    Location
    Hong Kong
    Search Comp PM
    The title cards are easy enough:

    Code:
    AviSource("FirstBD.avi") ++\
    BlankClip(last,200).Subtitle ("First Birthday", align=8, size=36,  font="georgia") ++\
    ... etc
    See http://avisynth.org/mediawiki/Subtitle for formatting.

    As for the chapter timecodes, should be do-able with WriteFile
    http://avisynth.org/mediawiki/WriteFile
    WriteFile evaluates each expressionN, converts the result to a string and puts the concatenated results into a file, followed by a newline.
    The "run-time" variable current_frame is set so that you can use it in an expression
    Quote Quote  
  3. Member
    Join Date
    Jul 2009
    Location
    Spain
    Search Comp PM
    Perhaps something based on the techniques used in this thread will do what you want:
    http://forum.doom9.org/showthread.php?t=138229
    Quote Quote  



Similar Threads

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