VideoHelp Forum

Try DVDFab and download streaming video, copy, convert or make Blu-rays,DVDs! Download free trial !
+ Reply to Thread
Results 1 to 16 of 16
Thread
  1. My MTS (avchd) file is 1920x1080 50p (progressive 50 fps).

    I use this setting in ffmpeg that I found from the internet :

    Code:
    for %%a in ("*.mts") do ffmpeg -i %%a -vcodec mpeg2video -qscale 1 -qmin 1 -intra -flags +ilme+ildct -an -f mpegts %%~na.mpg
    from the indoor shooting :
    The original mts file show more "grain" but overall video quality looks crisp and sharp.
    The converted mpg file show less "grain" but overall video quality looks a little bit blurry.

    from the outdoor shooting :
    The original mts file has no "grain" and video quality looks perfect, crisp and sharp.
    The converted mpg file video quality still looks a little bit blurry.

    The same result with this command :
    Code:
    ffmpeg -i <input_file> -vcodec mpeg2video -pix_fmt yuv422p -qscale 1 -qmin 1 -intra -an output.m2v
    Would someone please telling me if maybe there is another command that I should add to make a better (crisp/sharp) HDV quality ? (I know, it won't be exactly the same like the original ).

    One reason that I am "persistent" wanting to have this HDV mpeg format is that when I drop the footage in Premiere CS3 timeline it plays smoothly, no red thin line on the timeline window and easy to edit for me.

    Any kind of respond would be greatly appreciated.
    Thank you in advanced and I'm sorry for my broken English.

    regards.
    Quote Quote  
  2. Member
    Join Date
    Sep 2007
    Location
    Europe
    Search PM
    You could try this ...

    Code:
    ffmpeg -i "input_file" -vcodec mpeg2video -pix_fmt yuv422p -q:v 1 -intra -mbd 2 -trellis 1 -flags +ilme+ildct -bufsize 20000k -maxrate 200000k -an -f mpegts "output_file.mpg"
    This should give high quality (and large file size). No guarantee CS3 will accept it. This is for interlaced source. Remove -flags +ilme+ildct for progressive source.

    Chris
    Quote Quote  
  3. Originally Posted by Chris K View Post
    You could try this ...

    Code:
    ffmpeg -i "input_file" -vcodec mpeg2video -pix_fmt yuv422p -q:v 1 -intra -mbd 2 -trellis 1 -flags +ilme+ildct -bufsize 20000k -maxrate 200000k -an -f mpegts "output_file.mpg"
    This should give high quality (and large file size). No guarantee CS3 will accept it. This is for interlaced source. Remove -flags +ilme+ildct for progressive source.

    Chris
    Hi Chris,

    Wow... I've tried your code and YES... it's much better, the video looks sharper now.
    But too bad, playback in CS3 timeline is choppy which cause my editing process go slow

    Anyway, I really appreciate your input and thank you very much for it.

    regards.
    Quote Quote  
  4. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    Use -pix_fmt yuv420p not -pix_fmt yuv422p. That better matches the input and Premiere should handle it better. Make sure to remove -flags +ilme+ildct, your source is progressive not interlaced.
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  5. After many, many attempts over literally years, I have never managed to create a perfectly compliant HDV stream with ffmpeg. I would recommend dropping your MTS file into Adobe Media Encoder, which comes with Premiere, and generate a proper HDV stream that way. (TMPGenc Video Mastering Works is also reliable.)
    Quote Quote  
  6. Originally Posted by racer-x View Post
    Use -pix_fmt yuv420p not -pix_fmt yuv422p. That better matches the input and Premiere should handle it better. Make sure to remove -flags +ilme+ildct, your source is progressive not interlaced.
    Hi racer,

    Yes, using "-pix_fmt yuv420p" plays not choppy in CS3 timeline.
    Thank you very much for the command.
    (still thank you again to Chris also).

    BUT, I wonder why the footage on the timeline is double ? (which cause the playback go slow)
    The one I created with the command in my first post (after removed the "-flags +ilme+ildct") is OK.
    My trick is interpret footage in CS3 of the clip to 50 fps, and then is not double in the timeline.

    Anyway this is the info from the command in my first post :

    Code:
    Video
    ID                                       : 256 (0x100)
    Menu ID                                  : 1 (0x1)
    Format                                   : MPEG Video
    Commercial name                          : HDV 1080p
    Format version                           : Version 2
    Format profile                           : Main@High 1440
    Format settings, BVOP                    : No
    Format settings, Matrix                  : Default
    Format settings, GOP                     : N=1
    Codec ID                                 : 2
    Duration                                 : 25s 920ms
    Bit rate mode                            : Variable
    Bit rate                                 : 26.3 Mbps
    Width                                    : 1 440 pixels
    Height                                   : 1 080 pixels
    Display aspect ratio                     : 16:9
    Frame rate                               : 50.000 fps
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.339
    Stream size                              : 81.4 MiB (95%)
    and this one is the info from your command line (combined with Chris) :
    Code:
    Video
    ID                                       : 256 (0x100)
    Menu ID                                  : 1 (0x1)
    Format                                   : MPEG Video
    Format version                           : Version 2
    Format profile                           : Main@High 1440
    Format settings, BVOP                    : No
    Format settings, Matrix                  : Default
    Format settings, GOP                     : N=1
    Codec ID                                 : 2
    Duration                                 : 25s 920ms
    Bit rate mode                            : Variable
    Bit rate                                 : 43.1 Mbps
    Maximum bit rate                         : 96.8 Mbps
    Width                                    : 1 440 pixels
    Height                                   : 1 080 pixels
    Display aspect ratio                     : 16:9
    Frame rate                               : 50.000 fps
    Color space                              : YUV
    Chroma subsampling                       : 4:2:0
    Bit depth                                : 8 bits
    Scan type                                : Progressive
    Compression mode                         : Lossy
    Bits/(Pixel*Frame)                       : 0.554
    Stream size                              : 133 MiB (95%)
    It's not a big deal actually, I just wonder why ...
    and hopefully maybe there is a solution for the command line so it won't show double in CS3 clip duration.

    I'd also like to know whether converting AVCHD to mpeg2video is a good acceptable workflow ?
    My final movie will be rendered in mpeg2 HD format and also DVD format.

    Thank you once again.

    regards.
    Quote Quote  
  7. Double duration? mediainfo reports the same 25s 920ms

    Use a 1440x1080p50 timeline, and interpret the footage as 50p (because that's what it is)

    Why is it reduced resolution 1440 width ? Shouldn't it be 1920 ? (EDIT: NM, you're using fake "HDV" intermediate)

    Another option is to use something like the free version of cineform (go pro cineform studio). Higher quality, faster editing (but larger filesizes)
    Last edited by poisondeathray; 7th Sep 2014 at 12:13.
    Quote Quote  
  8. For clarity's sake, 1440x1080 50p is not HDV. You might want to change your topic heading. In fact, though you can customize it, 1440x1080 50p mpeg2 is not a common "standard" format.
    Last edited by smrpix; 7th Sep 2014 at 12:22.
    Quote Quote  
  9. Originally Posted by smrpix View Post
    After many, many attempts over literally years, I have never managed to create a perfectly compliant HDV stream with ffmpeg. I would recommend dropping your MTS file into Adobe Media Encoder, which comes with Premiere, and generate a proper HDV stream that way. (TMPGenc Video Mastering Works is also reliable.)
    Hi smrpix,

    My CS3 can not open the MTS file, my computer freeze when I tried to import the file to CS3.
    Also I have an old slow computer, Intel E4400, 2 gig Ram, XP SP2.

    I don't face a problem if my MTS file shot in 50i mode from the camera and I think ffmpeg do compliant HDV stream for 50i mts file as CS3 don't show thin red line when I drop the ffmpeg encoded file into the HDV 1080i25 (50i) project setting timeline. CS3 accept the file "happily"

    Shooting in 50p mode is new to me, which I wonder myself is this useful to shoot in 50p ?

    regards.
    Quote Quote  
  10. Originally Posted by poisondeathray View Post
    Double duration? mediainfo reports the same 25s 920ms

    Use a 1440x1080p50 timeline, and interpret the footage as 50p (because that's what it is)

    Why is it reduced resolution 1440 width ? Shouldn't it be 1920 ? (EDIT: NM, you're using fake "HDV" intermediate)

    Another option is to use something like the free version of cineform (go pro cineform studio). Higher quality, faster editing (but larger filesizes)
    Hi poisondeathray,

    CS3 doesn't have project setting for 50p / 60p.
    They only offer DV 24P, 1440x1080 25p or 30p, 1440x1080 50i or 60i, and 720 25p or 30p

    I reduce to 1440 because CS3 doesn't have 1920x1080 (50i) project setting.
    For 50i HDV file, reducing to 1440 made CS3 doesn't show the thin red line.

    I've tried proRes from GoPro cineform studio, I've tried Huffyuv also.
    Yes the quality is higher, but because of a very large file - CS3 and my computer "suffer" and I'm unable to do the editing.

    regards.
    Quote Quote  
  11. Originally Posted by smrpix View Post
    For clarity's sake, 1440x1080 50p is not HDV. You might want to change your topic heading. In fact, though you can customize it, 1440x1080 50p mpeg2 is not a common "standard" format.
    My fault, I'm sorry about this.

    I just realize about this from you that 1440x1080 50p is not "standard" HDV.

    Shot in 50p mode from my camera is new to me.
    I'm used to shot in 50i, encode to 1440x1080 with ffmpeg and the resulting file is "standard" HDV file as CS3 don't show thin red line when I put the footage into the timeline. But I'm not so satisfied with the quality. (so I'm trying to shot in 50p mode)

    Now I wonder what's the point I shot in 50p mode from my camera ?
    Seems it's useless as I'm facing difficulties in editing stage

    regards.
    Quote Quote  
  12. Your software and computer are really too outdated and underpowered to properly handle your 50p footage. You will have to update or compromise somewhere. I personally find HDV can look pretty good and edits fairly easily -- but it's definitely a downgrade from your source.
    Quote Quote  
  13. Another option is a proxy workflow (edit at lower resolution, lower quality , then swap to full quality/full resolution on final render)
    Quote Quote  
  14. Originally Posted by poisondeathray View Post
    Another option is a proxy workflow (edit at lower resolution, lower quality , then swap to full quality/full resolution on final render)
    @pdr, I agree in principle. But according to reko's earlier post (#9) the original 50p mts will not even be recognized in CS3.
    Quote Quote  
  15. Originally Posted by smrpix View Post
    Originally Posted by poisondeathray View Post
    Another option is a proxy workflow (edit at lower resolution, lower quality , then swap to full quality/full resolution on final render)
    @pdr, I agree in principle. But according to reko's earlier post (#9) the original 50p mts will not even be recognized in CS3.
    It doesn't have to be the original; the "high quality" version can be the full resolution cineform or other intermediate
    Quote Quote  
  16. Hi smrpix and poisondeathray,

    Yes I realize my computer is outdated .

    Actually I've also tried the proxy way using huffyuv and reduce the size to 720x576 widescreen.
    Well what can I say, the computer is really really "great great grandfather" old, opening 1 hour duration video to CS3 takes forever when I replace footage to the huffyuv files.

    anyway, thank you to all of you for the input and suggestion.

    regards.
    Quote Quote