VideoHelp Forum
+ Reply to Thread
Results 1 to 12 of 12
Thread
  1. A number of years ago I captured all my Hi8mm to AVI where it has sat on my PC mostly unwatched. I want to encode it to MPEG so I can easily stream it from my PC to the TV. So I am looking closely at it for the first time and just need a little advice.

    The AVIs are all 720x480i. But they have an effective 704 width because of the black bars and there is a stripe of noise a few pixels high on the bottom of the video. I know all this was purposely put there by my Sony camcorder and the Canopus capture deck I used. So a couple of questions:

    1. Re: the black bars. Should I crop the video and square the pixels to 640 width? With today's LCD/LED TVs is this the preferred format? 640x480i?
    2. Re: the stripe of noise on the bottom. So in the days of analog and overscan this noise strip was never visible. But with 1:1 pixel mapping, my assumption is maybe I should crop to 472i? Or would it be better to mask with a black bar and keep 480i?

    I also plan to put this video on DVD for archiving purposes and gifts to family members. I assume just leave it as is for DVD?

    Thanks in advance!
    Last edited by SameSelf; 31st Oct 2014 at 08:33.
    Quote Quote  
  2. Member hech54's Avatar
    Join Date
    Jul 2001
    Location
    Yank in Europe
    Search PM
    Originally Posted by SameSelf View Post
    A number of years ago I captured all my Hi8mm to AVI
    What kind of "AVI"?
    AVI is a container that can "contain" everything from crappy Divx/Xvid to high quality, uncompressed video.
    Quote Quote  
  3. Originally Posted by hech54 View Post
    What kind of "AVI"?
    AVI is a container that can "contain" everything from crappy Divx/Xvid to high quality, uncompressed video.
    The video is all DV at about 12 GB per hour (bit rate?) so not lossless but lightly compressed. Also in a 4:1:1 colorspace.
    Quote Quote  
  4. Member
    Join Date
    May 2014
    Location
    Memphis TN, US
    Search PM
    Full-size DVD frames are either 720x480 or 704x480. Mmm, therefore.....

    Originally Posted by SameSelf View Post
    1. Re: the black bars. Should I crop the video and square the pixels to 640 width? With today's LCD/LED TVs is this the preferred format? 640x480i?
    Nope. It's never 640x480 for DVD.

    Originally Posted by SameSelf View Post
    2. Re: the stripe of noise on the bottom. So in the days of analog and overscan this noise strip was never visible. But with 1:1 pixel mapping, my assumption is maybe I should crop to 472i?
    Nope. The bottom strip is head-switching noise. Almost always found to some degree on analog tape. BTW, DVD isn't 1:1 pixel mapping. The actual pixel aspect ratio depends on whether you're dealing with 4:3 or 16:9 display aspect ratio.

    Originally Posted by SameSelf View Post
    Or would it be better to mask with a black bar and keep 480i?
    Better to mask. There are even better ways. See below for suggestions.

    Originally Posted by SameSelf View Post
    I also plan to put this video on DVD for archiving purposes and gifts to family members. I assume just leave it as is for DVD?
    DVD is the better choice, since it's playable on just about any player. But you don't have to leave it entirely as-is.

    I fix those borders and switching noise all the time in Avisynth. There are undoubtedly many ways to do it. The temptation is to resize the image to fill the frame. But that would change the displayed proportions of the original image. It would look either slightly too high or slightly too wide.

    Let's say you have 8 spare border pixels on each side of the image. You can remove those pixels in Avisynth (or many other editors) and have a 704x480 image. If there aren't exactly 4 pixels on each side (say there are 6 on one side and 10 on the other), you can crop each side as required and leave the 704 width intact, centering the image. Head-switching noise at the bottom varies -- it could be 4 pixels, 8, 12, etc. Remember that if your AVI is a YUV colorspace you'll have to crop interlaced video top or bottom vertically in groups of 4 pixels. So if you have 8 pixels of bottom noise, crop off 8 pixels from the bottom and then add 4 border pixels at the top and 4 at the bottom to center the image. If you have 6 pixels, you're stuck with that 4-pixel limit unless you change the colorspace to something like YUY2. That way, you can crop off in pixel groups of 2. Cropping interlaced YUV video with an odd number of pixels will produce some really odd results by screwing up the way your pixel info is mapped in YUV.

    So here's how I'd do it in Avisynth:

    Code:
    Crop(8,0,-8,-8).AddBorders(0,4,0,4)
    That gives you a 704x480 video with 4 border pixels at top and bottom which would be masked during playback anyway by overscan and blend in with other borders on a 16x9 display, and the image will retain its original proportions. Encode it at 704x480 DVD with a 4:3 display aspect ratio.

    EDF: Note that DV-AVI is not a lossless fomat. If you do any of this cropping and try to save that cropped DV-AVI as a new copy of your video, it will be lossy re-encoded again. So crop and then encode directly to DVD rather than make an even lossier copy. Don't know what you're using for edit or encoding software, so that procedure will differ.
    Last edited by LMotlow; 31st Oct 2014 at 09:04.
    - My sister Ann's brother
    Quote Quote  
  5. DVD needs 480 vertical lines, so mask that bottom noise using script, as above explained, to get 480 vertical lines again

    for standalone stream:
    - you can even choose H.264 stream, instead of mpeg2, you can crop sides and mask bottom getting 704x480i , Crop(8,0,-8,-8).AddBorders(0,4,0,4) , where you can flag it with SAR 10:11,

    - or getting H.264 stream again and getting progressive 59.94p resizing to square pixel 640x472p, Crop(8,0,-8,-8).Spline36Resize(640,472)
    -and if you find it weird to not have 4:3 square pixel, then you can add borders again (as above) to get 480 vertical lines
    -you can have SAR flag inserted even for H.264 progressive stream but that is kind of weird

    DVD aspect rations flags should be honored, but some players might not follow aspect ratio flags in some standalone streams, so they might render 704x480 square pixel on screen ...
    Last edited by _Al_; 31st Oct 2014 at 09:36.
    Quote Quote  
  6. Lmotlow, all very insightful and helpful. Thank you.

    I use Adobe Production Studio. I am not real worried about re-encoding a second time because I am planning to do all this in AE along with some mild color correction and sharpen masks.

    While a hear what you are saying about best to put the video on DVD, I really want to be able to stream as an MPEG. I might even put some up on YouTube in which case I will need to deinterlace as well. But I just want to get it in MPEG format first. Authoring DVDs is just an additional step right now.
    Quote Quote  
  7. Member hech54's Avatar
    Join Date
    Jul 2001
    Location
    Yank in Europe
    Search PM
    Originally Posted by LMotlow View Post
    Note that DV-AVI is not a lossless fomat.
    He never said it was.........but now we know it's not divx/Xvid.

    Encoding to high bitrate MPEG2 should do the trick.....DVD is MPEG2 anyway. Just don't go too crazy with the bitrate, there is a limit in case you want to author to DVD later.
    Quote Quote  
  8. ^^_Al_, hmm, mpeg2 vs H.264. That is an interesting suggestion. I will need to experiment it looks like. Thanks guys.
    Quote Quote  
  9. Member
    Join Date
    May 2014
    Location
    Memphis TN, US
    Search PM
    Originally Posted by SameSelf View Post
    I use Adobe Production Studio. I am not real worried about re-encoding a second time because I am planning to do all this in AE along with some mild color correction and sharpen masks.
    You're getting the right idea, but be mindful of what happens with lossy re-encodes. You lose clarity and accumulate noise and compression artifacts. On typically noisy analog tape, that won't look so good on your 47" TV (it won't look too great on a 29" either). If you re-encode to another DV-AVi copy, and then encode that again to lossy MPEG, you've actually gone through 3 lossy encodes. Lossy means exactly what it says -- which is one reason why it's often recommended not to capture to lossy codecs to begin with. Lossy means that each re-encode loses more and more of the original signal. It's cummulative. What gets lost never comes back.
    - My sister Ann's brother
    Quote Quote  
  10. Actually my TV is 70", but in our HD world that is quickly moving to 2K and up, it does feel funny talking about 480i video. As it is, the video takes up 600+ GB on my computer so I can't imagine how much lossless would have been, 6 TB?

    AE defaults to a lossless render so I can at least avoid one generation loss. But if I could stream the DV-AVI we wouldn't even be talking about this, but that is another problem.
    Quote Quote  
  11. Member hech54's Avatar
    Join Date
    Jul 2001
    Location
    Yank in Europe
    Search PM
    H264 is awesome, but grandma is not going to know what to do with an H264 video file. My son's grandma gets DVDs.
    Quote Quote  
  12. lossless SD could be something about 50Mbit (utcodec), I kind of tested clean DV avi, not sure about VHS source, might be even higher, so in my case just 2x more than DVavi originals, I was surprised by that actually

    60p suppose to work on Youtube now, using Chrome browser, so you can upload it in 60p for family, it has to be upscaled as well to HD, which in YouTube land gives better result on screen anyway:
    Code:
    Avisource("your_lossless_avi_from AE_or DV.avi")
    Crop(8,0,-8,-8)
    Assumebff()
    QTGMC()
    nnedi3_rpow2(2, cshift="Spline36Resize", fwidth=976 fheight=720)
    addborders(152,0,152,0) #to get 1280x720
    numbers are kind of off a bit, because of that 8pixel botom crop, otherwise it would resize to 960x720 and adding 160 pixel on each side to get 1280x720
    Quote Quote  
Visit our sponsor! Try DVDFab and backup Blu-rays!