VideoHelp Forum
+ Reply to Thread
Page 1 of 2
1 2 LastLast
Results 1 to 30 of 41
Thread
  1. Hi cats

    please consider this 2 interlaced source

    one HD (xdcamhd422): https://www.dropbox.com/s/bewed3s3zxhouzk/HD.MXF?dl=0

    one IMX(SD)(imx50): https://www.dropbox.com/s/5jd9run51moczxh/imx.mxf?dl=0

    for example I try to convert the HD.MXF into a IMX-SD .MXF file but with this commandline pipe with ffmpeg/ffmbc:
    Code:
    ffmpeg -i v:\ffmpeg\HD.MXF -vf scale=720:576,interlace -f rawvideo -vcodec rawvideo -an - | ffmbc -y -f rawvideo -s 720x576 -r 25 -tff -i - -i v:\ffmpeg\HD.MXF -target imx50 outputIMX.mxf
    but I get errors

    Click image for larger version

Name:	ERR34.jpg
Views:	482
Size:	372.5 KB
ID:	30496

    How can I resolve?

    Can I use ffmpeg/ffmbc also to convert the IMX one into HD?

    audio channels/maps are different for the 2 files

    thanks
    Quote Quote  
  2. 1) It looks like you have 2 -i in the piped output commandline.

    2) Interlaced scaling flag is interl=1, not "interlaced"
    -vf scale=720:576:interl=1

    3) You need to specify -pix_fmt yuv422p for both pre and post pipe

    This commandline was already posted in your a few of your other threads. I thought cats have good memory?
    Last edited by poisondeathray; 28th Feb 2015 at 11:03.
    Quote Quote  
  3. because cats have 4MB or ram ^^


    Code:
    ffmpeg -i v:\ffmpeg\HD.MXF -vf scale=720:576:interl=1 -f rawvideo -pix_fmt yuv422p -an - | ffmbc -y -f rawvideo -pix_fmt yuv422p -s 720x576 -r 25 -tff -i - -target imx50 outputIMX.mxf
    this work but outputIMX.mxf don't have audio, is there a way to pick audio directly from the HD.mxf?
    Quote Quote  
  4. why are you piping ?

    ffmbc's IMX50 D/10 muxer only supports 1 audio track, so you might be able to combine them all to a single 8ch
    Quote Quote  
  5. because seems that ffmpeg don't take file playable in Sony cameras/deck. MXF files outputted by ffmpeg seems regular, but is not playable. Only ffmbc generate mxf playable on Sony PDW-700, PDW-F800 and PDW-HD1500
    Quote Quote  
  6. Why don't you use ffmbc directly? Why pipe ffmpeg to ffmbc ?



    IMX50 specs only support 16bit audio when in 8ch configuration.

    There is no need to pipe for what you are doing, you can use ffmbc directly (interlaced downscale, 8 mono to single 8ch, IMX50 encoding)

    Code:
    ffmbc -i hd.MXF -vf scale=720:576:interl=1 -acodec pcm_s16le -ar 48000 -map_audio_channel 0:1:0:0:1:0 -map_audio_channel 0:2:0:0:1:1 -map_audio_channel 0:3:0:0:1:2 -map_audio_channel 0:4:0:0:1:3 -map_audio_channel 0:5:0:0:1:4 -map_audio_channel 0:6:0:0:1:5 -map_audio_channel 0:7:0:0:1:6 -map_audio_channel 0:8:0:0:1:7 -target imx50 outputIMX.mxf
    Quote Quote  
  7. I forgot - you should use colormatrix 709 to 601 too , when downscaling. This was already covered in your other thread(s)
    Quote Quote  
  8. Originally Posted by poisondeathray View Post
    Why don't you use ffmbc directly? Why pipe ffmpeg to ffmbc ?


    [/code]
    if I don't mistake, because ffmbc don't "concatenate"
    Quote Quote  
  9. I don't understand, you have 1 file - what is there to concatenate?

    If you want to concatenate multiple files, use ffmpeg, then use that output as a single input into ffmbc in a 2nd step. You can't concatenate and pipe at the same time anyways
    Quote Quote  
  10. Ahn sorry, think I'm a confused cat :=)

    Name:  confusedcat.jpg
Views: 764
Size:  21.9 KB
    Quote Quote  
  11. Originally Posted by poisondeathray View Post

    Code:
    ffmbc -i hd.MXF -vf scale=720:576:interl=1 -acodec pcm_s16le -ar 48000 -map_audio_channel 0:1:0:0:1:0 -map_audio_channel 0:2:0:0:1:1 -map_audio_channel 0:3:0:0:1:2 -map_audio_channel 0:4:0:0:1:3 -map_audio_channel 0:5:0:0:1:4 -map_audio_channel 0:6:0:0:1:5 -map_audio_channel 0:7:0:0:1:6 -map_audio_channel 0:8:0:0:1:7 -target imx50 outputIMX.mxf
    nice line, for kindness poison is there a way to have image a little less "soft", a little more detailed? maybe is only question to set the lanczos as resizer alghoritmh? but I don't know how to say to ffmbc use lanczos
    Quote Quote  
  12. It's posted in your other thread, flags=lanczos

    -vf scale=720:576:interl=1:flags=lanczos
    Quote Quote  
  13. I have try over another HD file (C0094.mxf) but it is the same, strangely I get an error using
    Code:
    ffmbc -y -i C0094.MXF -vf scale=720:576:interl=1:flags=lanczos -acodec pcm_s16le -ar 48000 -map_audio_channel 0:1:0:0:1:0 -map_audio_channel 0:2:0:0:1:1 -map_audio_channel 0:3:0:0:1:2 -map_audio_channel 0:4:0:0:1:3 -map_audio_channel 0:5:0:0:1:4 -map_audio_channel 0:6:0:0:1:5 -map_audio_channel 0:7:0:0:1:6 -map_audio_channel 0:8:0:0:1:7 -target imx50 C0094outputIMX.mxf
    Click image for larger version

Name:	SWS1.jpg
Views:	243
Size:	248.1 KB
ID:	30518

    maybe a sintax error?
    Quote Quote  
  14. -sws_flags lanczos
    Quote Quote  
  15. Code:
    ffmbc -y -i C0104.MXF -vf scale=720:576:interl=1,colormatrix=bt709:bt601 -sws_flags lanczos -acodec pcm_s16le -ar 48000 -map_audio_channel 0:1:0:0:1:0 -map_audio_channel 0:2:0:0:1:1 -map_audio_channel 0:3:0:0:1:2 -map_audio_channel 0:4:0:0:1:3 -map_audio_channel 0:5:0:0:1:4 -map_audio_channel 0:6:0:0:1:5 -map_audio_channel 0:7:0:0:1:6 -map_audio_channel 0:8:0:0:1:7 -target imx50 C0104IMX.mxf
    I have try this on another xdcam422 file

    https://www.dropbox.com/s/689p158dm1xqetu/C0104.MXF?dl=0

    but I see alwais that image is slightly "vibrating", I don't know why but is well visible on a crt monitor
    Quote Quote  
  16. I haven't looked at it - But it's probably because it's too sharp, use a softer resize and lowpass (see your other thread(s). Again.)

    Sharp = bad for interlaced material
    Quote Quote  
  17. the problem is present also without the -sws_flags lanczos , it's difficult to see it without a crt monitor but is visible, maybe a tff/bff setting?

    I post another original xdcamhd422 file

    https://www.dropbox.com/s/utp5oe5t7sudjrj/C0016.MXF?dl=0


    I have try add

    Code:
    -tff
    but the problem remains

    also tryed using -bff but nothis, the "vibrating" remains
    Last edited by marcorocchini; 1st Mar 2015 at 16:37.
    Quote Quote  
  18. I see it.

    It's because it wasn't smart bobbed , you have field offset of even/odd fields, so up/down motion or as you describe "vibrating"

    You can use one of the avisynth methods. Other option in ffmpeg would be to yadif double rate, soft resize, low pass and resize, reinterlace

    Several variations of these methods were covered in your other thread(s)
    Quote Quote  
  19. in ffmpeg, but using ffmbc can I "deinterlace, resize, re-interlace"? in other threads was using alwais ffmpeg, seems not ffmbc :=(
    Quote Quote  
  20. You should be able to. The newer compiled version of ffmbc has a newer libavfilter version. So you have access to yadif, scale, tinterlace
    Quote Quote  
  21. where is downloadable?
    Quote Quote  
  22. el_heggunte compiled and posted it at videohelp somewhere use <search>

    Even if you can't do it with ffmbc, you could pipe ffmpeg to ffmbc, or avisynth to ffmbc, like in your other thread
    Quote Quote  
  23. ok but if I pipe ffmpeg into ffmbc, audio can be processed in one unique commanline?
    Quote Quote  
  24. Yes you can - use multiple inputs into ffmbc

    The pipe in from ffmpeg will be 1st, the native mxf video (only interested in the audio) will be 2nd . You have to adjust the map_audio_channel to reflect this, because it will be taken from 2nd input now. So if you put the pipe first, it will be "0" , and the mxf will be "1". The order matters

    So if you wanted to use -vf interlace instead of tinterlace, you could use ffmpeg to pipe to ffmbc (ffmbc doesn't have -vf interlace, only tinterlace). Recall in the other thread -vf interlace vs. -vf tinterlace and the low pass? You didn't like either method IIRC, and eventually went with avisynth
    Quote Quote  
  25. mmm


    Code:
    ffmpeg -i HD.mxf -vf crop=1440:1080:240:0,yadif=1:0,scale=720:576,colormatrix=bt709:bt601,interlace -pix_fmt yuv422p -an -f rawvideo - | ffmbc -y -f rawvideo -pix_fmt yuv422p -s 720x576 -r 25 -i - -tff -target imx50 -aspect 16:9 outputIMX.mxf
    maybe this? but this don't have any audio at the output
    Quote Quote  
  26. No, you need 2 inputs for ffmbc, 1 for the video pipe, 1 for the mxf which provides the audio. You have to change the map_audio_channel to reflect that the 2nd input is providing the audio

    Code:
    ffmpeg -i C0104.MXF -vf yadif=1:tff,scale=720:576,colormatrix=bt709:bt601,interlace -an -pix_fmt yuv422p -c:v rawvideo -f rawvideo - | ffmbc -f rawvideo -pix_fmt yuv422p -s 720x576 -r 25 -i - -i C0104.MXF -vf colormatrix=bt709:bt601 -acodec pcm_s16le -ar 48000 -map_audio_channel 1:1:0:0:1:0 -map_audio_channel 1:2:0:0:1:1 -map_audio_channel 1:3:0:0:1:2 -map_audio_channel 1:4:0:0:1:3 -map_audio_channel 1:5:0:0:1:4 -map_audio_channel 1:6:0:0:1:5 -map_audio_channel 1:7:0:0:1:6 -map_audio_channel 1:8:0:0:1:7 -target imx50 OUTPUT.mxf
    Quote Quote  
  27. Now audio appear but I see persist the vibrating problem
    and a "broken pipe" at the end of encoding

    Click image for larger version

Name:	C104.jpg
Views:	233
Size:	308.8 KB
ID:	30535

    the colormatrix line is doubled, however also with this, the problem of vibrating remains (and also the broken pipe error)
    Code:
    ffmpeg -i C0104.MXF -vf yadif=1:tff,scale=720:576,colormatrix=bt709:bt601,interlace -an -pix_fmt yuv422p -c:v rawvideo -f rawvideo - | ffmbc -f rawvideo -pix_fmt yuv422p -s 720x576 -r 25 -i - -i C0104.MXF -acodec pcm_s16le -ar 48000 -map_audio_channel 1:1:0:0:1:0 -map_audio_channel 1:2:0:0:1:1 -map_audio_channel 1:3:0:0:1:2 -map_audio_channel 1:4:0:0:1:3 -map_audio_channel 1:5:0:0:1:4 -map_audio_channel 1:6:0:0:1:5 -map_audio_channel 1:7:0:0:1:6 -map_audio_channel 1:8:0:0:1:7 -target imx50 OUTPUT.mxf

    However the ffmpeg don't vibrate, seems ok:

    Code:
    V:\brisighella>ffmpeg -i C0104.MXF -vf yadif=1:tff,scale=720:576,colormatrix=bt709:bt601,interlace -pix_fmt uyvy422 -c:v rawvideo -an outputavi.avi
    Last edited by marcorocchini; 2nd Mar 2015 at 09:09.
    Quote Quote  
  28. For some reason, the colormatrix works alone with ffmpeg, but not when piped through. I think there is a double conversion. If you leave it for ffmbc, not for ffmpeg, the colors are correct (ie. erase the 1st colormatrix instance with ffmpeg) . If you use only colormatrix ffmpeg through the pipe, colors are wrong

    The broken pipe message is a false alarm; it's because it doesn't know which video you are applying the filter to. Add -map 0:0 after the ffmbc inputs to specify that you are using the piped video and it won't complain

    I don't see the "vibrating" with this, other than the normal interlace and twittering problems. It's the same as ffmpeg pre-pipe, except with a bit more loss from MPEG2

    or you can try other methods like tinterlace, or avisynth
    Quote Quote  
  29. If you have mjpeg decompressor in my monitor this play ok:

    https://www.dropbox.com/s/3khsg3msdlm4j9r/C0104playOK.avi?dl=0

    while this play vibrating:
    https://www.dropbox.com/s/htgp2q53hcaxxsa/C0104FFMBC.avi?dl=0


    Using this I alwais see vibrating

    Code:
    ffmpeg -y -i C0104.MXF -vf yadif=1:tff,scale=720:576,colormatrix=bt709:bt601,interlace -an -pix_fmt yuv422p -c:v rawvideo -f rawvideo - | ffmbc -y -f rawvideo -pix_fmt yuv422p -s 720x576 -r 25 -i - -i C0104.MXF -vf colormatrix=bt709:bt601 -acodec pcm_s16le -ar 48000 -map_audio_channel 1:1:0:0:1:0 -map_audio_channel 1:2:0:0:1:1 -map_audio_channel 1:3:0:0:1:2 -map_audio_channel 1:4:0:0:1:3 -map_audio_channel 1:5:0:0:1:4 -map_audio_channel 1:6:0:0:1:5 -map_audio_channel 1:7:0:0:1:6 -map_audio_channel 1:8:0:0:1:7 -target imx50 OUTPUT.mxf
    Quote Quote  
  30. But you said ffmpeg alone (pre-pipe) is ok? It looks the same to me as the ffmbc output post pipe, just a bit worse from MPEG2. Even if you compare it frame by frame, it's the same.


    Originally Posted by marcorocchini View Post

    However the ffmpeg don't vibrate, seems ok:

    Code:
    V:\brisighella>ffmpeg -i C0104.MXF -vf yadif=1:tff,scale=720:576,colormatrix=bt709:bt601,interlace -pix_fmt uyvy422 -c:v rawvideo -an outputavi.avi

    In fact, if you use rawvideo instead of xdcam, you get bit for bit the same thing as pre-pipe

    This is not the same as the 1st "vibrating" problem, when yadif wan't used. I verified there was a problem with that. So you might have a configuration or playback problem?

    -vf interlace does apply a lowpass by default. So it isn't as "sharp" . This was discussed in your other thread. You can disable it but more "twittering" or ling buzzing will occur
    Quote Quote  
Visit our sponsor! Try DVDFab and backup Blu-rays!