VideoHelp Forum




+ Reply to Thread
Results 1 to 6 of 6
  1. I am very new at FFMPEG and just started learning.

    So I have an MXF file and I want to rewrap it to MOV, but do not touch audio and video settings. So the command I use is:
    ffmpeg -i input_file.mxf -acodec copy -vcodec copy -f mov output_file.mov
    However, even though audio in my input file is 2 channels stereo, FFMPEG gives me mono output. After the conversion, this information appears:
    Guessed Channel Layout for Input Stream #0.1 : mono
    Guessed Channel Layout for Input Stream #0.2 : mono
    My question is, what command should I use to force FFMPEG guesses Channel Layout as stereo?
    Quote Quote  
  2. Member
    Join Date
    Aug 2010
    Location
    San Francisco, California
    Search PM
    You can try putting -ac 2 before the -i option. If that doesn't work, you can try adding -map_channel 0.1.0 -map_channel 0.2.0 somewhere before the output filename. BTW, your -f option is optional because FFmpeg will know you want MOV format from the filename extension.
    Quote Quote  
  3. Your source has 2 audio streams, which need to be merged to create stereo.
    amerge does the job, but it requires re-encoding the audio:
    Code:
    ffmpeg -y -hide_banner ^
    -i "video+2audiostreams.mxf" ^
    -filter_complex "[0:1:a][0:2:a]amerge" ^
    -channel_layout stereo ^
    -c:v copy -c:a aac -q:a 0.35 ^
    "video+stereo.mxf"
    Without re-encoding, it might be possible to flag the 2 streams as "L" and "R", but it won't be stereo.
    Last edited by raffriff42; 21st Feb 2017 at 01:25.
    Quote Quote  
  4. Member
    Join Date
    Aug 2010
    Location
    San Francisco, California
    Search PM
    Does it really have two streams or is FFmpeg misreading the file? OP tells us it is stereo. Perhaps a MediaInfo report would clarify.
    Quote Quote  
  5. Thank you for advices. I exported it from Premiere with only one audio track, so I have no idea why it would possibly have two streams. Here is MediaFile report:

    Format : MXF
    Commercial name : XDCAM HD422
    Format version : 1.2
    Format profile : OP-1a
    Format settings : Closed / Complete
    File size : 49,3 MiB
    Duration : 8s 40 ms
    Overall bit rate : 51,4 Mb/s
    Package name : Source Package
    Encoded date : 2017-02-20 14:41:52.928
    Writing application : Adobe Systems Incorporated Premiere Pro 1.0.0.0.1
    Writing library : win32 4.5.13.0.3

    Wideo
    ID : 512
    Format : MPEG Video
    Commercial name : XDCAM HD422
    Format version : Version 2
    Format profile : 4:2:2@High
    Format settings, BVOP : Tak
    Format settings, Matrix : Własny
    Format settings, GOP : Variable
    Format settings, picture structure : Frame
    Format settings, wrapping mode : Frame
    Codec ID : 0D01030102046001-0401020201040300
    Duration : 8s 40 ms
    Bit rate mode : Stała
    Bit rate : 50,0 Mb/s
    Width : 1.920 pikseli
    Height : 1.080 pikseli
    Display aspect ratio : 16:9
    Frame rate : 25,000 kl/s
    Standard : Component
    Color space : YUV
    Chroma subsampling : 4:2:2
    Bit depth : 8 bitów
    Scan type : Z przeplotem
    Scan order : Górne pole wpierw
    Bits/(Pixel*Frame) : 0.965
    Time code of first frame : 00:00:00:00
    Time code source : Group of pictures header
    Stream size : 47,9 MiB (97%)
    Color primaries : BT.709
    Transfer characteristics : BT.709

    Audio #1
    ID : 768
    Format : PCM
    Format settings, Endianness : Little
    Format settings, wrapping mode : Frame (AES)
    Codec ID : 0D01030102060300
    Duration : 8s 40 ms
    Bit rate mode : Stała
    Bit rate : 768 kb/s
    Channel(s) : 1 kanał
    Sampling rate : 48,0 kHz
    Frame rate : 25,000 kl/s (1920 spf)
    Bit depth : 16 bitów
    Stream size : 754 KiB (1%)
    Locked : Yes

    Audio #2
    ID : 1024
    Format : PCM
    Format settings, Endianness : Little
    Format settings, wrapping mode : Frame (AES)
    Codec ID : 0D01030102060300
    Duration : 8s 40 ms
    Bit rate mode : Stała
    Bit rate : 768 kb/s
    Channel(s) : 1 kanał
    Sampling rate : 48,0 kHz
    Frame rate : 25,000 kl/s (1920 spf)
    Bit depth : 16 bitów
    Stream size : 754 KiB (1%)
    Locked : Yes

    Other #1
    ID : 0-Material
    Type : Time code
    Format : MXF TC
    Time code of first frame : 00:00:00:00
    Time code settings : Material Package
    Time code, striped : Tak

    Other #2
    ID : 0-Source
    Type : Time code
    Format : MXF TC
    Time code of first frame : 00:00:00:00
    Time code settings : Source Package
    Time code, striped : Tak

    Other #3
    Type : Time code
    Format : SMPTE TC
    Muxing mode : SDTI
    Time code of first frame : 00:00:00:00
    Quote Quote  
  6. Marsia Mariner
    Guest
    The truth is, MXF is a weird & stupid container. Different from the good ones, it uses ONE audio channel per stream. Compared to the other containers, it does not know the meaning of «multichannel audio».
    Quote Quote  



Similar Threads

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