VideoHelp Forum




+ Reply to Thread
Page 2 of 3
FirstFirst 1 2 3 LastLast
Results 31 to 60 of 82
  1. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    Here is an hta that creates top menu and chapter menu

    I couldn't find a simple way to check if chapter number input is a whole number

    if textbox.value mod 1 <> 0 then
    MsgBox "You need to enter a whole number from 2 to 12"

    doesn't work
    Image Attached Files
    Quote Quote  
  2. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Got tied up with work, I'm just now getting the opportunity to look at this, preview.avs generates an error at line 13 (a value is not being assigned to to your variable chapters). After manually assigning a value and saving, the file will play in MPC.

    Encode.avs also generates an error at line 13 appease to be the same problem as preview.avs.
    Murphy's law taught me everything I know.
    Quote Quote  
  3. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    Here is an hta that creates top menu and chapter menu

    I couldn't find a simple way to check if chapter number input is a whole number
    Numbers between 0 and 1 would not be your only worry. The easiest method would to use key capturing. something like this should work.
    Code:
    function isNbr(event) {
       var key = window.event ? event.keyCode : event.which;
       if (event.keyCode == 8 ) //list the key codes of the exceptions you wish to allow using and or statement ex. event.keyCode == 8 ||  event.keyCode == 9
        {
          return true;
       }
       else if ((key >= 48 && key <= 57) || (key >= 96 && key <= 105)) 
        {
         return true;
       } else {
         return false;
       }
     }
    
      </script>
    use the function with the onKeyPress or onKeydown event of the field you wish to validate.
    Murphy's law taught me everything I know.
    Quote Quote  
  4. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    I made some changes before I saw your post re function isNbr(event) {

    changed sub chapnum, added a couple of new variables -> TMDur, blength

    if duration of menu is "0" the blankclip will be 30 frames and there will be a static menu
    Image Attached Files
    Quote Quote  
  5. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    A couple of things I've noticed, you have 3 groups of radio buttons but i'm able to select only 1 radio button on the page. Each group of radio buttons should be in a set of form tags, or use a option box. The Avisynth script is not recognizing the colors you have chosen for borders and subtitles. Do you have a plug in that allows you to use color codes other than hex and RGB? Which version of VirtualDub do i need the preview function does not work for me virtualDub crashes upon opening.
    Murphy's law taught me everything I know.
    Quote Quote  
  6. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    I've made a couple of changes to the app, I've added the function to prevent anything but numbers from being entered in to the text box for chapters. I also modified step 3 i created a java script fuction to loop through all the check boxes for the Top menu Duration to find the checked radio button , I then pass the value to the vbscript subroutine you created to write the text file. It makes for a little less code and the fuction can be re-used for each group of radio buttons.

    "Oops just realized i forgot to attach the file."
    Image Attached Files
    Last edited by dragonkeeper; 27th Jul 2012 at 06:39. Reason: For got to attach file.
    Murphy's law taught me everything I know.
    Quote Quote  
  7. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    Thanks again for your time - I appreciate it

    1. re colors - Yes, I am using an avsi file -> colors-fonts.avsi i.e. text_color=c13 and c13=$DEB887 - I should add the ability to choose the font, fontsize, textcolor, halocolor, backgroundcolor . . .

    2. re Virtual Dub version 1.9.11.0 - do you have an avs file that crashed VirtualDub?

    3. re the Radio Buttons - yeah - I am a little confused about exactly how they operate - I'm looking into this
    Image Attached Files
    Quote Quote  
  8. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    1. re colors - Yes, I am using an avsi file -> colors-fonts.avsi i.e. text_color=c13 and c13=$DEB887 - I should add the ability to choose the font, fontsize, textcolor, halocolor, backgroundcolor . . .
    I assumed that there must have been differences in our systems, be sure to included details of what app versions, addons, scripts etc you are using.. That will be the only way to ensure we are getting the same results.
    Originally Posted by wiseant View Post
    2. re Virtual Dub version 1.9.11.0 - do you have an avs file that crashed VirtualDub?
    I can easily reproduce the issue I will be able to get an avs to you late tonight once i make it home. I'm using a different version of Vdub than you are I will try to get the latestr version to see if the issue corrects its self.
    Originally Posted by wiseant View Post
    3. re the Radio Buttons - yeah - I am a little confused about exactly how they operate - I'm looking into this
    Radio buttons as well as check boxes are group togeather by the DOM (the thing with radio buttons is that you can select only one in the group) , if you have groups of either on a page the DOM assumes they belong to the same group unless they are embeded in form tags which tells the DOM that each is seperate group.
    Why not try drop boxes?
    Last edited by dragonkeeper; 27th Jul 2012 at 16:51.
    Murphy's law taught me everything I know.
    Quote Quote  
  9. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Ok, adding the script to my avisynth plugin folder corrected both problems i mentioned earlier. Another question though, why are you using VDub to preview? Why not just use a player such as MPC?
    Murphy's law taught me everything I know.
    Quote Quote  
  10. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    I'm using VirtualDub for a couple of reasons
    1. It has a smaller filesize -> 2.54 MB vs. MPlayerClassic = 4.2 MB vs. MP-HC = 11 MB
    2. I will be using ColorsFontsAVI [3 frames] and a samplechapter.avi [11 frames] - I find it is easier to use VDub for scrolling frame by frame
    3. I find that it provides more information - and allows a user if they want/need to, to do a DirectStreamCopy [uncompressed] encode or encode to other codecs with VDub

    re the Radio Buttons - I found the problem - all three groups had the same name - when I changed them to Group, Group1 and Group2 and made the corresponding changes in the subs - they are working as they should - i.e. no focus is lost - each selection for each Group remains checked - and all the values got assigned to their respective variables

    And I will get the details re file versions, addons, and scripts

    I'll upload a new hta on Saturday with the button fix - I hope it works on your end

    Something else I found - ffvideosource is better than Directshowsource re mp4 container - Directshowsource was getting the framerate wrong
    however FFVideoSource sucks with m2ts files - so I'll need to program for this
    By the way, did you use a m2ts/ts file with VDub?


    Cheers
    Last edited by wiseant; 29th Jul 2012 at 01:19. Reason: sp
    Quote Quote  
  11. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    By the way, did you use an m2ts/ts file with VDub?
    I used an MKV file.
    Murphy's law taught me everything I know.
    Quote Quote  
  12. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper

    I was concerned when you mentioned that the radiobuttons needed a form tag and some javascript - so I created a test hta - buttonTest.hta
    It works for me on WinXp and Vista32


    Versions that I am using:

    Vista32

    mshta.exe
    Microsoft (R) HTML Application host
    C:\WINDOWS\System32
    January 19, 2008, 12:33:18 AM
    7.0.6001.1800

    VirtualDub.exe
    December 23, 2011, 10:05:56 PM
    1.10.1

    DirectShowSource.dll
    Sunday, December 21, 2008, 2:46:06 PM
    2.5.8.6

    ffms2.dll
    August 26, 2011, 1:12:12 PM

    IntenetExplorer
    April 11, 2009, 12:27:46 AM
    7.06002.18005


    WinXP:

    mshta.exe
    Monday, August 13, 2007, 6:32:30 PM
    7.0.5730.13

    VirtualDub.exe
    December 23, 2011, 10:05:56 PM
    1.10.1

    DirectShowSource.dll
    Sunday, December 21, 2008, 2:46:06 PM
    2.5.8.6

    ffms2.dll
    7.64 MB (8,019,968 bytes)
    ? date

    Internet Explorer
    Friday, April 16, 2010, 4:43:26 AM
    7.0.6000.17055


    I'll upload my newest .hta later today or tomorrow
    Image Attached Files
    Quote Quote  
  13. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    dragonkeeper

    I was concerned when you mentioned that the radiobuttons needed a form tag and some javascript - so I created a test hta - buttonTest.hta
    I mis-spoke when i said they need a form tag, you are correct in your assessment that the object name controls the grouping. Radio buttons don't need javascript to get the value, but it makes for less coding which in turn is cleaner and more efficient .
    Currently you are doing the following to get your button value(s).
    Code:
    Sub RBTop
     If Group(0).Checked Then
    Group(0).value=30
    TMdur=Group(0).value
      Msgbox "You selected a duration of 30 sec"
     End If
     If Group(1).Checked Then
    Group(1).value=20
    TMdur=Group(1).value
      Msgbox "You selected a duration of 20 sec"
     End If
     If Group(2).Checked Then
    Group(2).value=10
    TMdur=Group(2).value
      Msgbox "You selected a duration of 10 sec"
     End If
     If Group(3).Checked Then
    Group(3).value=0
    TMdur=Group(3).value
      Msgbox "You selected a duration of 0 sec"
     End If
    End Sub
    You are doing the same for each group of buttons you have; since the code is specific to the button group it cant be reused.

    but by doing something like
    Code:
     function getRadioValue(frmName, btnGroup){
          {
    for (var i=0; i < document.forms[frmName][btnGroup].length; i++)
       {
       if (document.forms[frmName][btnGroup][i].checked)
          {
          return [frmName.toString(),document.forms[frmName][btnGroup][i].value.toString()]
          }
       }             
     }
    I've created a short piece of code that can be reused multiple times.
    Murphy's law taught me everything I know.
    Quote Quote  
  14. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper

    Nice. Makes sense.

    I've written way more subs than functions - I'll check some script functions out

    Also, I was going to originally use Microsoft MPlayer2 6.4.9.1125 but any current WindowsMediaPlayer will probably take it over.
    Probably the best previewer for this is AvsP - but not as common - and it had problems reloading files sometimes
    I'll look at adding the option of selecting the previewer
    One problem with VDub is no scroll

    With FFvideosource - video only gets decoded, with DirectshowSource, I need to make sure to add audio=false for vclip when a ts, m2ts, or ?mkv

    VirtualDub probably has a problem with some audio in an mkv container, or mp4, ts, and m2ts read with directshowsource
    Perhaps ffvideosource has a problem with mkv?
    With audio, I am presuming that the user can decode the bluray compliant audio with directshowsource / windows7 media decoders which does favour mplayerclassic or would one require mp-hc with windows7?
    Quote Quote  
  15. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    I don't believe Window 7 can natively decode the various HD audio formats.
    Murphy's law taught me everything I know.
    Quote Quote  
  16. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    July 31 10:41 PST - had some other things to care of - hope to post next hta later today . . .
    Quote Quote  
  17. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    .cool, wating to see what you've come up with
    Murphy's law taught me everything I know.
    Quote Quote  
  18. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    I was back at this evening - working on the next steps - but I've run into a bug that just doesn't make sense to me
    I'm sure I'll figure it out tomorrow - so no new hta right now - but I should have one for tomorrow
    Quote Quote  
  19. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    dragonkeeper:

    I was back at this evening - working on the next steps - but I've run into a bug that just doesn't make sense to me
    I'm sure I'll figure it out tomorrow - so no new hta right now - but I should have one for tomorrow
    So whats the bug you've run into. Javascript and VBscript and give some really unexpected results in certain circumstances.
    Murphy's law taught me everything I know.
    Quote Quote  
  20. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    Looks like it wasn't a bug - I added some new subs - and tried to test the last one without going through the other routines. When I started from the beginning it was OK

    When I started this project I intended not to use javascript - I have read about problems mixing vbscript and javascript

    I wasn't able to implement your getButtonValue script anyway - but I used the gist of it to rewrite some subs

    I changed the code so that all files will have the same "FileTime" suffix

    I have added another chapter thumbnail size and I have added "CreateMainTitle" and "Create Top & Chapters" subs

    I still have to process the remaining clpi files, add 90010.m2ts and 90011.m2ts, 00301.mpls, and 00601.mpls files - hope to have this done for Friday

    TSmuxer [cli] needs to be in the hta folder

    So right now the application should make a BD with folder name value of "FileTime" in hta directory but without the files for implementing the top and chapters menus

    Audio should be ok - all that is necessary is that TSMuxer can process it
    I am going to go with elementary streams - so if someone has video and audio in a ts, m2ts, mp4, or mkv - they will have to demux it first

    Re making mkv files - it is necessary to check "Disable header removal compression.." in the latest MKVToolNix
    [I don't think earlier version of mkvtoolnix could handle m2ts as input]

    By the way is there any difference between vbscript and javascript functions? I come across more javascript functions than vbscript

    To do:
    clean up file paths and use several different folders for temp files and helper applications
    add option for selecting Video Preview application
    add some more options for Chapter Menu Subtitles
    and some more options for selecting background color, background image for TopMenu
    implement 2x2, 3x3, 4x4, and possibly 5x5 chapter menu "grids"

    add AVCHD support
    add option for m2v files for top and chapter menu using HCenc or QuEnc
    Image Attached Files
    Quote Quote  
  21. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    When I started this project I intended not to use javascript - I have read about problems mixing vbscript and javascript
    I've never encountered this particular problem, i've always intermixed the two freely. Vbscript was the first scripting language i learned , buti soon found out some things that were a pita in VBscript was much easier in other scripting languages. So moved on to javascript and perl. Vbscript is only useful to me now when writing VBA, it is as close to vbscript as i get these days..
    Originally Posted by wiseant View Post
    By the way is there any difference between vbscript and javascript functions? I come across more javascript functions than vbscript
    The syntax is different and javascript has more built in functions and methods, making it easier to code. Which is part of the reason why you find more code examples available in javascript than VBscript.
    Murphy's law taught me everything I know.
    Quote Quote  
  22. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    note re Aug1.7z - only writing AC3 for audio - have to add the other types for tsmuxer

    new hta - just added "Choose Video Preview Application" - probably won't work with filename spaces e.g. Program Files\Windows Media Player - need to fix
    Image Attached Files
    Quote Quote  
  23. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Originally Posted by wiseant View Post
    note re Aug1.7z - only writing AC3 for audio - have to add the other types for tsmuxer

    new hta - just added "Choose Video Preview Application" - probably won't work with filename spaces e.g. Program Files\Windows Media Player - need to fix
    As you said the preview function did not work, try adding quotations, also remember that quotation marks that are part of the name will need to be escaped.

    the values for the following variable's are not being written to the previewchapter avs file;
    duration, blength, vheight
    Murphy's law taught me everything I know.
    Quote Quote  
  24. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    I've got some other things to attend to today - so I hope to post another hta tomorrow

    Re the Choose Video Preview Application:
    I'll look into this - but after using MP-HC, MPlayerC, AvsP, and Mplayer (didn't work) - I still think VDub is the way to go

    Re previewchapter.avs - duration, blength, vheight:
    That's odd - it is working for me
    I trust that you hit the confirm button after choosing these values . . .
    Again I'll have to see if I uploaded a different hta than the one I am using
    Quote Quote  
  25. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    Your are correct i didn't press the confirm button on each step. It's working.
    Murphy's law taught me everything I know.
    Quote Quote  
  26. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    Just a quick update

    I'm almost there - it can now author a BD - but there is a small bug re my chapter textfile - if someone does a preview/encode and decides to do another preview/encode - the chapter textfile gets appended and causes a read error - should be easy to fix
    I have added dts audio and an option to Downconvert DST-HD to DTS
    Will be uploading a new hta tomorrow [Monday]

    Cheers
    Quote Quote  
  27. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    Here is the new hta -> QuickBD.hta

    The zip also has VirtualDub, TSMuxer and ClipINf_Edit [from ClownBD]

    I have added TMP and DAT directories

    The DAT directory contain the various BD "templates"

    ClipINF_edit.exe has been renamed from CLIPINF_Editor_v0.05.exe

    I tested it with 2ch ac3, 5ch ac3, DTS and DTS-HD

    The BD plays fine in PowerDVD11 but for some reason TMT5 has a problem navigating to the scene selection [chapter menu]

    I still have to address the chapter text file
    Image Attached Files
    Quote Quote  
  28. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    been tied up testing right now.
    Murphy's law taught me everything I know.
    Quote Quote  
  29. Member dragonkeeper's Avatar
    Join Date
    Jul 2003
    Location
    United States
    Search Comp PM
    TSmuxer is crashing on windows 7
    Murphy's law taught me everything I know.
    Quote Quote  
  30. Member
    Join Date
    Jun 2007
    Location
    Canada
    Search Comp PM
    dragonkeeper:

    I wonder if tsMuxeR_1.8.4b.zip might work

    Was it an mkv file? - header compression would have to be removed

    Or, it could have been an error with my chapter text file - it might have got appended - so there might be too many chapters [this will happen if the motion menu gets encoded more than once] - I did this before and TSMuxer crashed with a read or write error
    Did you notice any error info from TSMuxer?

    So far, I have just tested this new hta on XP SP3 and XP SP2
    I'll test it on Vista32 and Vista64 tomorrow and I think I'll go ahead and install Windows7 . . .
    Quote Quote  



Similar Threads

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