Menu

Bug report on, ver hbencoder_v1.4b_11272007

peterbre
2007-11-29
2013-04-19
  • peterbre

    peterbre - 2007-11-29

    Using tee to capture the output of the script I get:

     -- Save Location -- 
    Enter the directory where you wish to save the encoded video file.
    [Default: /home/pete]: 
    [ OK ]  Saving file to /home/pete

     -- Video File Name -- 
    Enter the file name you wish to use.
    Example = my_movie: 
    [ OK ]  Setting file name to test1.avi.

     -- Video File Extension -- 
    Enter the file extension that you wish to use.
    [1] m4v
    [2] avi
    [3] ogm
    [4] mkv

    Please enter your choice [1-4, default = 1]: 
    [ OK ]  Setting file extension to avi.

     -- Width & Height -- 
    Enter the width and height of the video file.
    The aspect ration of the DVD is Height will be automatically set based on width
    and video aspect ratio.

    [ ERROR ]  The width you entered was invalid.

    [ ERROR ]  The width you entered was invalid.

    [ ERROR ]  The width you entered was invalid.

    [ ERROR ]  The width you entered was invalid.

    I was not prompted for any aspect ratio information.

    In the terminal session I get:

    [ ERROR ]  The width you entered was invalid.
    ./hbencoder: line 1109: [: =: unary operator expected
    ./hbencoder: line 1117: [: =: unary operator expected

    [ ERROR ]  The width you entered was invalid.
    ./hbencoder: line 1109: [: =: unary operator expected
    ./hbencoder: line 1117: [: =: unary operator expected

    [ ERROR ]  The width you entered was invalid.
    ./hbencoder: line 1109: [: =: unary operator expected
    ./hbencoder: line 1117: [: =: unary operator expected

    [ ERROR ]  The width you entered was invalid.
    ./hbencoder: line 1109: [: =: unary operator expected
    ./hbencoder: line 1117: [: =: unary operator expected

    until the script ends with a segfault error.

    This is on Fedora Core 6, x86_64

    Pete

     
    • ed

      ed - 2007-11-29

      This error generally occurs when the script can't read anything from the output file that's created by parsing the DVD.  A few questions:

      1. Was the location entered for the DVD-ROM correct? 
      This would prevent the script from grabbing a data dump from the DVD, and creating the output file.  This file is required to fill in specific information later in the question/answer process.

      2. When the script searched the DVD, was there activity on the DVD-ROM?
      Same issue as #1.  If the DVD isn't read, the data dump will not occur and the output file will not be created.

      3. Was the script executed in a read-only directory? 
      The script needs to be executed in a directory that can be written to by the user who executes it.  If the directory is read-only, the files the script creates can't be written.

      Let me know if any of these suggestions fixes the problem, otherwise I'll have to investigate further.

      Also ... the next revision of the script will have the following to help prevent these kinds of issues:

      1. An auto search feature that will find the DVD-ROM automatically or allow you to enter a location manually if it doesn't find anything.

      2. Verification that the disc in the ROM is a true DVD.  If not, it will prompt you to put in a DVD.

      3. The script will create the directory ~/.hbencoder in the user's home folder, where it will save the configuration files that it creates.  This will prevent the read-only problems mentioned above.

       
    • peterbre

      peterbre - 2007-11-30

      All good questions, here we go...

      1. Was the location entered for the DVD-ROM correct? 
      This would prevent the script from grabbing a data dump from the DVD, and creating the output file. This file is required to fill in specific information later in the question/answer process.

      I did enter the path to the DVD content. On Fedora 6, (as well as, I believe, some other distributions that are implementing udev) the media is mounted on /media/volume_label In my case it meant that the music video DVD I was trying to extract mounted at /media/MORRISSEY_SPECIAL_EDITION so this is what was entered. Fedora no longer mounts on the expected mount points for optical media like /dev/hdc or /dev/cdrom. I can access and traverse the contents of the DVD via the shell with no special requirements. Everything is accessable at  /media/MORRISSEY_SPECIAL_EDITION/VIDEO_TS

      2. When the script searched the DVD, was there activity on the DVD-ROM?
      Same issue as #1. If the DVD isn't read, the data dump will not occur and the output file will not be created.

      I did not observe any access lights indicating drive activity when the script requested the location of the DVD mount point. If I follow the script through to the point where it errors out, there are no indications that it's been accessed.

      3. Was the script executed in a read-only directory? 
      The script needs to be executed in a directory that can be written to by the user who executes it. If the directory is read-only, the files the script creates can't be written.

      The directory has full read write and execute for my user.

      Your planned features look like nice improvements to the program.

      I'll look at the script and see if I can see anything that looks odd.

      Thanks,

      Pete 

       
    • ed

      ed - 2007-11-30

      >> I did enter the path to the DVD content. On Fedora 6,
      >> (as well as, I believe, some other distributions that
      >> are implementing udev) the media is mounted on
      >> /media/volume_label

      Good info to know.  I'll install Fedora on the laptop this weekend and play around with this a bit. 

      >> Everything is accessable at
      >> /media/MORRISSEY_SPECIAL_EDITION/VIDEO_TS

      That seems correct.  The video_ts should be in the root of the DVD.  What happens when you manually run the HandBrakeCLI and enter /media/MORRISSEY_SPECIAL_EDITION as the default input device?  Is there any output when running the CLI manually without hbencoder?  What errors, if any, do you get?

      >> I did not observe any access lights indicating drive
      >> activity when the script requested the location of the
      >> DVD mount point.

      That would definitely indicate that no data is being read from the DVD-ROM.  If the HandBrakeCLI can't read the input device, then it can't encode, so using the hbencoder script is a moot point.  I'm definitely interested to see what output you get when running the CLI manually at this point.

      >> The directory has full read write and execute for my
      >> user.

      I figured as such, but it's one of those questions ya gotta ask.  :)

      >> Your planned features look like nice improvements to
      >> the program.

      Thanks ... just trying to make it more useful.  I still want to implement the rest of the features of the HandBrakeCLI binary, but I want to make sure that I understand them 100% before attempting to code something for them.

      >> I'll look at the script and see if I can see anything
      >> that looks odd.

      Thanks for your continued assistance with this meager little project.  I appreciate your help with the bug tracking and feedback.

       
    • peterbre

      peterbre - 2007-12-01

      A totally vanilla handbrake run goes like this:

      [pete@localhost handbrake]$ ./HandBrakeCLI -i /media/MORRISSEY_SPECIAL_EDITION/ -o /home/pete/test.avi
      HandBrake 0.9.1 (2007100800) - http://handbrake.m0k.org/
      2 CPUs detected
      Opening /media/MORRISSEY_SPECIAL_EDITION/...
      Scanning title 1...
      Scanning title 1...
      Scanning title 1...
      Scanning title 1...
      + title 1:
        + vts 1, ttn 1, cells 0->1 (86944 blocks)
        + duration: 00:02:46
        + size: 720x480, aspect: 1.33, 29.970 fps
        + autocrop: 0/0/0/0
        + chapters:
          + 1: cells 0->1, 86944 blocks, duration 00:02:46
        + audio tracks:
          + 1, Unknown (AC3) (2.0 ch), 48000Hz, 448000bps
        + subtitle tracks:
      [mpeg4 @ 0x8514738]removing common factors from framerate
      No accelerated IMDCT transform found

      And encoding seems to run through just fine.

      Pete

       
    • ed

      ed - 2007-12-01

      I think I found the bug.  In your output above, you have the following:

      >> Opening /media/MORRISSEY_SPECIAL_EDITION/...

      The current version of the script doesn't put the / at the end when it selects the input device.  I will make the appropriate adjustments and upload version 1.4c tonight.  Download and try the updated version and let me know if it works.

      --Ed

       
    • ed

      ed - 2007-12-01

      Correction ... I was right about the DVD input portion being the bug, but I think I was wrong about the trailing slash.  I discovered the following in the code on line 620:

      $hb_binary --input /media/cdrom0 --title 0 2> $output_file

      Apparently I overlooked the fact that I had hard coded the input device when dumping the DVD data.  I have made the corrections to the script and will be uploading it shortly.  Please try it again and let me know if it works.

       
    • peterbre

      peterbre - 2007-12-01

      Latest version seems to have done it. Everything seems to be working in both Quick and Advanced mode.

      Pete

       
    • ed

      ed - 2007-12-01

      Excellent!  Thanks for your assistance with troubleshooting the bug.

       

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.