VideoHelp Forum
+ Reply to Thread
Page 1 of 4
1 2 3 ... LastLast
Results 1 to 30 of 114
Thread
  1. Hi cats,

    please considering this mxf source file:

    https://www.dropbox.com/s/tveg47laoa1effa/C0044.MXF?dl=0

    I get this mp4: https://www.dropbox.com/s/cjrmenbkopqfdkf/c0044.mp4?dl=0

    using this commandline

    Code:
    ffmpeg.exe -y -i c:\c0044.mxf -c:v libx264 -profile:v high422 -level:v 4.1 -g 33 -bf 1 -crf 20 -flags +ildct+ilme -top 1 -x264opts tff=1:colorprim=bt709:transfer=bt709:colormatrix=bt709 -filter_complex crop=out_h=1080:y=0,scale=interl=1:in_range=tv:out_range=tv -pix_fmt yuv422p -c:a ac3 -b:a 256k -aspect 16:9 c:\c0044.mp4
    so the c0044.mp4 generated from ffmpeg have this mediainfo:

    Video
    ID : 1
    Format : AVC
    Format/Info : Advanced Video Codec
    Format profile : High 4:2:2@L4.1
    Format settings, CABAC : Yes
    Format settings, ReFrames : 3 frames
    Format settings, GOP : M=2, N=33
    Codec ID : avc1
    Codec ID/Info : Advanced Video Coding
    Duration : 11s 0ms
    Bit rate : 19.4 Mbps
    Width : 1 920 pixels
    Height : 1 080 pixels
    Display aspect ratio : 16:9
    Frame rate mode : Constant
    Frame rate : 25.000 fps
    Color space : YUV
    Chroma subsampling : 4:2:2
    Bit depth : 8 bits
    Scan type : MBAFF
    Bits/(Pixel*Frame) : 0.375
    Stream size : 25.5 MiB (99%)
    Writing library : x264 core 142 r2431 ac76440
    Encoding settings : cabac=1 / ref=3 / deblock=1:0:0 / analyse=0x3:0x113 / me=hex / subme=7 / psy=1 / psy_rd=1.00:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=12 / lookahead_threads=2 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=tff / bluray_compat=0 / constrained_intra=0 / bframes=1 / b_pyramid=0 / b_adapt=1 / b_bias=0 / direct=1 / weightb=1 / open_gop=0 / weightp=0 / keyint=33 / keyint_min=3 / scenecut=40 / intra_refresh=0 / rc_lookahead=33 / rc=crf / mbtree=1 / crf=20.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / ip_ratio=1.40 / aq=1:1.00
    Color primaries : BT.709
    Transfer characteristics : BT.709
    Matrix coefficients : BT.709

    Consider also this mp4 encoded with mainconcept totalcode:

    https://www.dropbox.com/s/wj2j9mzghou3l06/c0044totalcode.mp4?dl=0

    that have this mediainfo:

    Video
    ID : 2
    Format : AVC
    Format/Info : Advanced Video Codec
    Format profile : High 4:2:2@L4.1
    Format settings, CABAC : Yes
    Format settings, ReFrames : 3 frames
    Format settings, GOP : M=2, N=33
    Codec ID : avc1
    Codec ID/Info : Advanced Video Coding
    Duration : 11s 0ms
    Bit rate : 23.7 Mbps
    Width : 1 920 pixels
    Height : 1 080 pixels
    Display aspect ratio : 16:9
    Frame rate mode : Constant
    Frame rate : 25.000 fps
    Standard : PAL
    Color space : YUV
    Chroma subsampling : 4:2:2
    Bit depth : 8 bits
    Scan type : Interlaced
    Scan order : Top Field First
    Bits/(Pixel*Frame) : 0.457
    Stream size : 31.1 MiB (99%)
    Language : English
    Encoded date : UTC 2014-11-21 11:18:49
    Tagged date : UTC 2014-11-21 11:18:49
    Color primaries : BT.709
    Transfer characteristics : BT.709
    Matrix coefficients : BT.709

    I wonder: I prefer use ffmpeg but is problematic that the ffmpeg's one don't show the interlaced flag clearly. However it's internally interlaced but my decompressor don't like the MBAAF.
    So I wonder: can I get a pure interlaced mp4 with the interlaced flag as the mainconcept's one?

    thanks ^^^
    Quote Quote  
  2. This was answered a few times already

    x264, (and ffmpeg libx264) use MBAFF only, not PAFF. Use something else like mainconcept or some other compression (e.g. MPEG2) if you need need PAFF
    Quote Quote  
  3. ahm thanks,
    so is there not another way to encode interlaced PAFF with ffmpeg using mpeg4 (not libx264)? or another commandline program? thanks
    Quote Quote  
  4. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    I am trying to understand your rationale of wanting to keep an AVC delivery codec interlaced.

    Quote Quote  
  5. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    @newpball, you are wasting your time trying to understand ANY of the OP's rationales. I am NOT exaggerating nor trying to be spiteful or sarcastic - much seems to be circular reasoning. And any attempt to request frank clarity brings up mention of his pets again, so I stopped trying a while ago.

    Scott
    Quote Quote  
  6. Originally Posted by Cornucopia View Post
    @newpball, you are wasting your time trying to understand ANY of the OP's rationales. I am NOT exaggerating nor trying to be spiteful or sarcastic - much seems to be circular reasoning. And any attempt to request frank clarity brings up mention of his pets again, so I stopped trying a while ago.

    Scott
    oh, but I'm a cat
    Quote Quote  
  7. Originally Posted by newpball View Post
    I am trying to understand your rationale of wanting to keep an AVC delivery codec interlaced.

    it is simple: some time ago I delivered a .mp4 encoded with ffmpeg into the broadcats tv station and they tellme that encoding is ok but it was a mp4 that was be broadcasted directly from the airing room. Some days ago, with the same setting of ffmpeg I delivedered via ftp 9 minutes of images that need to be edited in avid from the station. Initially the quality check person tell me the file is ok, but the avid-man callme telling that seems that my images are jerky, seems that field was inverted. But I know that is not a problem if field order, but most probable that the his decoder "see" my file as progressive because of the MBAFF: it is not clearly interlaced and he wants only files that are flagged as pure interlaced and TFF. So I'm looking for an mp4 encoder that get only "pure" interlaced mp4 files.
    I have try the mainconcept, it seems works ok but I prefer ffmpeg, but ffmpeg seems don't get pure interlaced mp4
    Quote Quote  
  8. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by marcorocchini View Post
    ... I delivedered via ftp 9 minutes of images that need to be edited in avid from the station.
    The station should edit the XDCAM HD422 original.

    Out of curiosity why do you record interlaced on an XDCAM HD, that seems totally unnecessary.
    Quote Quote  
  9. Originally Posted by newpball View Post
    Originally Posted by marcorocchini View Post
    ... I delivedered via ftp 9 minutes of images that need to be edited in avid from the station.
    The station should edit the XDCAM HD422 original.

    Out of curiosity why do you record interlaced on an XDCAM HD, that seems totally unnecessary.
    usually yes, the station work the xdcamhd422 original when the journalist is present and can take the xdcam disc and bring it to the station. But in may occasions, working with the news, happens that the station demand me to transfer the footage via his radio-bridge-network (in sd) or to transcode the mxf files in mp4, or do a pre-edit where the entire footage is putted on the timeline and transcode in mp4: I use a beautiful program called Speed Razor 5.51 (for cats).

    I have do some proof and (expecially thanks to poison) I think to get a very very high quality of the mxf --> mp4 transcoding using the commandline (batched) of ffmpeg:

    Code:
    ffmpeg.exe -y -i "%CD%\%~n1.mxf" -filter_complex "[0:1] [0:2] amerge,volume=1" -c:v libx264 -profile:v high422 -level:v 4.1 -g 33 -bf 1 -crf 16 -flags +ildct+ilme -top 1 -x264opts tff=1:colorprim=bt709:transfer=bt709:colormatrix=bt709 -filter_complex crop=out_h=1080:y=0,scale=interl=1:in_range=tv:out_range=tv -pix_fmt yuv422p -c:a libvo_aacenc  -aspect 16:9 "%WorkFolder%\%~n1EncodingfromOriginalMXF".mp4
    that take a mp4 that seems almost identical to the original and it's a interlaced file but MBAFF, not clearly interlaced, however is internally interlaced. 2 days ago the station call me on the phone and tell me that my mp4 seems a little jerky, as a field-invert problem, but the file I have send was correctly interlaced and correctly TFF. The same quality check of the station confirm to me that from many proof seems my file was ok but only in the avid workstation was wrong. But the avid operator tell me he don't import directly my file: they use a intermediate transcoder that put in the avid all files that are not mxf files... so that is possible the problem was here, in this transcoder that probably don't see as interlaced a MBAFF files, meanwile see as correctly interlaced the encoding of mainconcept totalcode that in mediainfo show clearly "interlaced" and "Top Field".

    In xdcam hd I have to set the camera in interlaced because the broadcasting is interlaced, the broadcats station don't want progressive (or rarely) but obviously the progressive is better quality
    Quote Quote  
  10. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    And the station gives you MP4 because why? Probably because (let me guess...) your edit system at home cannot handle MXF. And you've already hinted you won't upgrade to a modern NLE, ALL of which can fully support XDCam in MXF. Again, you are bringing all this complexity & difficulty upon yourself when the simple answer is staring you right in the face but you won't budge.

    "But I'm a cat!" Bet that one goes over real well at the TV station.

    Scott
    Quote Quote  
  11. because you are not a cat! ^^ but me with speed razor I'm a super fast editor
    Ok at the moment it cannot import directly mxf files but with the ndjamena batch I convert all mxf in .avi mjpeg, when I have edit all I export in mjpeg or simply in uncompressed. To encode in mp4 simply I drag and drop the .avi (uncompressed) into the avi-->mp4 icon on the desktop and get the mp4 ready to be delivered. It' simply, maybe not the fastest way but works.
    THen from the .avi uncompressed I get the mxf file with totalcode, and i put in on the camera in the xdcam disc

    in the end it's all very simple

    the problem of the mp4 is that the station have multiple decoders: the quality check test the files with a type of decoder that "see" correctly as interlaced a mp4 that are flagged as MBAFF. I send some mp4 that are directly broadcasted in the main control room and they was absolutly ok. In this case the problem was in the avid station, and in a transcoder that "pass" the same mp4 to the avid.

    So I have to resolve doing mp4 that mediainfo show "interlaced" and "top field first", not mbaaf
    but possibly I would use ffmpeg, not others
    Quote Quote  
  12. That transcoder produces lossless video? Perhaps not. He could interpret footage to tff, assuming avid should have something like that ... they have their workflows and that's it ...

    if not, your footage gets transcoded 3 times ...until it gets on TV, ...,
    but anyway, I can see this kind of problems in many TV advertisements, so this could be one of those reasons that happens, I was always wondered how those field get screwed up sometimes, they must know that, but they air it anyway, because they do not have good feedback with supplier of that clip or a will to fix that, no time etc.
    Quote Quote  
  13. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by marcorocchini View Post
    In xdcam hd I have to set the camera in interlaced because the broadcasting is interlaced, the broadcats station don't want progressive (or rarely) but obviously the progressive is better quality
    I think that is not a good workflow and just because something is broadcasted interlaced does not mean everything up the chain needs to be interlaced.

    If you record progressive it is easy to go interlaced but if you record interlaced you are stuck with interlaced and even the best de-interlacers cannot make it perfect afterwards.

    “I am amazed that anybody would consider launching new services based on interlace. I have spent all of my life working on conversion from interlace to progressive. Now that I have sold my successful company, I can tell you the truth: interlace to progressive does not work!”.

    -Yves Faroudja
    Quote Quote  
  14. seems they have 3 transcoder that process all NON-mxf files, this transcoders are connected to a media-server and with the avid stations. And the media server is connected with the main control room. At the phone they tellsme that the workflow from the transcoders and the avid stations is uncompressed, and that in some cases the avid stations are called (in extreme urgency) from the main control room to send the HD stream of the editor directly to the control room for the broadcast.

    I don't have understand why they want' import directly the mp4 in the avid.

    Hoewver is possible that the transcoder used in the main control room, see as interlaced a file flagged as "MBAFF" and all is ok. But I need to solve the problem with a unique encoder so that is ok for all trascoders, so maybe I have to use the mainconcept totalcode due to the PAFF encoding.

    But it's strange that ffmpeg cannot encode PAFF, only MBAFF when using x264
    Quote Quote  
  15. Originally Posted by newpball View Post
    Originally Posted by marcorocchini View Post
    In xdcam hd I have to set the camera in interlaced because the broadcasting is interlaced, the broadcats station don't want progressive (or rarely) but obviously the progressive is better quality
    I think that is not a good workflow and just because something is broadcasted interlaced does not mean everything up the chain needs to be interlaced.

    If you record progressive it is easy to go interlaced but if you record interlaced you are stuck with interlaced and even the best de-interlacers cannot make it perfect afterwards.

    “I am amazed that anybody would consider launching new services based on interlace. I have spent all of my life working on conversion from interlace to progressive. Now that I have sold my successful company, I can tell you the truth: interlace to progressive does not work!”.

    -Yves Faroudja
    I know but if you deliver progressive to a tv, at today, this figure as an error (in italy)
    I can tell you the truth: the problem is also my camera don't do the 1080p
    Last edited by marcorocchini; 21st Nov 2014 at 15:09.
    Quote Quote  
  16. @marcorocchini

    Try to contact the FFmpeg developers (Forums) by mail or joint their IRC channels. They could give you more answers.
    - http://ffmpeg.org/contact.html#Forums
    Quote Quote  
  17. I try, thanks
    Quote Quote  
  18. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    Feel free to compile yourself a fork of ffmpeg that uses something else besides libx264 to encode to h.264...
    (It's not the developers of ffmpeg you should write to, it is the developers of x264 - VideoLan. Good luck with getting them to add PAFF. Not going to happen.)

    As far as the Rube Goldberg roundtrip compliancy machinations, we now have it straight from the horse's mouth. I rest my case.

    Scott
    Quote Quote  
  19. Member racer-x's Avatar
    Join Date
    Mar 2003
    Location
    3rd Rock from the Sun
    Search Comp PM
    But it's strange that ffmpeg cannot encode PAFF, only MBAFF when using x264
    Because x264 only supports MBAFF and not PAFF. How many time do you need to be told this?

    Use Vegas.........Done.
    Image Attached Images  
    Last edited by racer-x; 21st Nov 2014 at 16:16. Reason: add animated gif.
    Got my retirement plans all set. Looks like I only have to work another 5 years after I die........
    Quote Quote  
  20. Originally Posted by marcorocchini View Post
    But it's strange that ffmpeg cannot encode PAFF, only MBAFF when using x264
    Why? Are You aware of fact that x264 use MBAFF and doesn't support PAFF and as such ffmpeg is limited by x264 limitations.
    Use different h.264 encoder than x264.
    Quote Quote  
  21. ok but what I have to do? I don't know other h264 using ffmpeg
    Quote Quote  
  22. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by marcorocchini View Post
    ok but what I have to do? I don't know other h264 using ffmpeg
    Provide the studio with the XDCAM HD original, they should know what to do with that.

    And if it takes too long to ftp buy a $5 usb stick, copy the video and send it to them overnight.
    Quote Quote  
  23. both we have xdcam hd, but they sometimes want footage via fpt and I need to transcode in mp4.

    The problem is that seems I cannot find a mp4 encoder that encode a pure interlaced mp4, but only MBAFF
    Quote Quote  
  24. Banned
    Join Date
    Oct 2014
    Location
    Northern California
    Search PM
    Originally Posted by marcorocchini View Post
    both we have xdcam hd, but they sometimes want footage via fpt and I need to transcode in mp4.
    The studio forces you to transcode to H264 and they expect interlaced on top of that?

    Perhaps the cat believes it but not I!
    Quote Quote  
  25. not that itI'm a supporter of the interlaced and of the h264, but in every case I forced to deliver interlaced. To send a footage of 15-20 minutes I use X264 at the CRF 22 and the quality is not too low, however using CRF 15 the quality of mp4 is almost equal to that of the original: at least using FFMPEG.

    Code:
    ffmpeg.exe -y -i c:\c0044.mxf -c:v libx264 -profile:v high422 -level:v 4.1 -g 33 -bf 1 -crf 15 -flags +ildct+ilme -top 1 -x264opts tff=1:colorprim=bt709:transfer=bt709:colormatrix=bt709 -filter_complex crop=out_h=1080:y=0,scale=interl=1:in_range=tv:out_range=tv -pix_fmt yuv422p -c:a ac3 -b:a 256k -aspect 16:9 c:\c0044.mp4
    In addition: I can export directly in MP4 from the timeline of my Speed Razor 5.51 for cats (it's my modifyed version) using the x264 VFW codec or a DirectShow codec (but at the moment I cannot find a DS codec suitable) because I have do an enhancement to some files of the original Speed Razor. So that the only transcoding process is the first: from mxf to avi (mjpeg).

    Hoewver when I export in uncompressed and I mux the uncompressed file in mxf it is almost equivalent to a direct exporting as avid or edius.

    Now my only problem is that x264VFW don't support PAFF
    Quote Quote  
  26. Originally Posted by marcorocchini View Post
    ok but what I have to do? I don't know other h264 using ffmpeg
    Use any encoder that support PAFF - for example one listed by you at start of this discussion.

    Export MXF ffmpeg trough pipe or lossless file - it is up to You.
    Quote Quote  
  27. using mainconcept totalcode all is ok: paff encoding= pure interlaced mp4 and this is ok
    but this means that each time I have to export by the timeline in uncompressed, reOpen the uncompressed file in totalcode and encode in mp4


    with the x264vfw I directly export in mp4 from the timeline of the speed razor for cats 5.51 but x264 (seems) don't support paff but only mbaff

    Now I have try the mainconcept broadcast (it do 422 encoding) avc/h264 directshow codec, it works well in mbaff mode (using the "interlaced frame" option in the "frame type" menu. It works well when is necessary set "progressive" in the "frame type menu"
    and.. it don't work when I set "interlaced fields" in the frame type menu: problem is that duration is greater than the original duration in timeline

    for example: in timeline I select "export selected area" of the first 10 seconds. The mainconcept codec take a file that have duration of 15 or 20 seconds and the playback is slower

    I don't know how to solve, I have try to change the "slice count" but nothing changes

    However when the "interlaced fields" is selected the target output file is a pure paff interlaced file (scan type: interlaced/top field order) but with this problem of duration is impossible use it

    Click image for larger version

Name:	MC.jpg
Views:	648
Size:	376.7 KB
ID:	28744

    does anyone know if there is a patch or a way to get paff

    using x264vfw? thanks
    Last edited by marcorocchini; 23rd Nov 2014 at 16:36.
    Quote Quote  
  28. Member Cornucopia's Avatar
    Join Date
    Oct 2001
    Location
    Deep in the Heart of Texas
    Search PM
    No. The only way is to:
    1. Convince the x264 programmers to include PAFF (which isn't likely going to happen because they strongly do not want to)
    2. Convince someone else to create a fork of x264 that includes it (probably only likely if you $$$)
    3. Program a fork of x264 yourself

    None of those options will change anytime soon (so maybe it's time for a new workflow)...

    Scott
    Quote Quote  
  29. Originally Posted by Cornucopia View Post

    None of those options will change anytime soon
    but it's strange, for example x264vfw works well, mjpeg encoders works well, some other codec work well and don't have this kind of problem
    (duration)
    Quote Quote  
Visit our sponsor! Try DVDFab and backup Blu-rays!