[Ffmpeg-devel-irc] ffmpeg.log.20120607

burek burek021 at gmail.com
Fri Jun 8 02:05:02 CEST 2012


[00:01] <pasteeater> milehigh: have you tried ffmpeg directly?
[00:01] <pasteeater> ffmpeg -i input -vcodec wmv2 -acodec wmav2 -b:a 448k -qscale:v 2 -r 24000/1001 -ar 44100 -ac 2 -f asf output
[00:01] <pasteeater> kind of similar to your mencoder command
[00:02] <pasteeater> you might have to use -ab and -qscale instead of what's in my zample
[00:09] <milehigh> pasteeater: that command works fine, though I can't force the program I use to use ffmpeg, it uses mencoder
[00:10] <milehigh> but does that indicate it's an issue with mencoder not ffmpeg? Or maybe just some of the options are different?
[00:51] <pasteeater> milehigh: you can probably blame mencoder, but i don't know
[01:25] <Mista_D> Is there a map of ffprobe's csv output?
[01:30] <Mista_D> I got it, all descriptions are there in json and xml.
[01:54] <pasteeater> Mista_D: you're doing a good job of answering your own questions today
[02:08] <adowdy> hello - i have a quick question about ffmpeg. i have a video stream that i'm recording to a file using the ffmpeg command line utility; is there a way to only write a certain specified subset of the incoming stream pixels to a file instead of the whole stream?
[02:09] <alfanetwork> I am x11grab. This works fine for recoding sound to my speakers. Was wondering what I need to change to recored my mic. ffmpeg -f alsa -i pulse -f x11grab -r 30 -s 1920x1080 -i :0.0 -vcodec libx264 -preset ultrafast -crf 0 -threads 0 out.mkv
[02:11] <alfanetwork> adowdy what do you mean a stream subset? Have a feeling you might want to map your streams.
[02:14] <adowdy> alfanetwork - thanks for taking the time to reply to me! what i mean by a subset of the stream is this; so there's a networked security camera which i can access through an http url - it comes in at a resolution of 704x480 pixels.  i am writing software that will be interested only in a section of those pixels (for example, pixels 15-300 in x, pixels 200 - 400 in y)
[02:15] <adowdy> i was seeing if the ffmpeg utility can take these pixel measurements as arguments somehow, but i am not sure
[02:17] <alfanetwork> adowdy sounds like a tall order but I would think ffmpeg might be able to do that. Unfortunately I am not 100% sure how this would be done =/
[02:18] <adowdy> haha, well thanks for taking a look
[02:19] <pasteeater> adowdy: you could try the crop filter
[02:20] <adowdy> pasteeater - thank you; im looking at that in the api spec now
[02:21] <alfanetwork> adowdy oh you mean a section of that you see. There is a built in tool you can just draw the borders of what you want. I thought you meant some signal analysis.
[02:26] <pasteeater> alfanetwork: where are you in norway? I went there last year to Trondheim.
[02:26] <alfanetwork> I am in Norway a lot but I live in Linköping
[02:26] <alfanetwork> thats in Sweden
[02:26] <alfanetwork> Same tz though.
[02:26] <pasteeater> oh, when you said norway yesterday i thought you meant you lived there
[02:27] <adowdy> alfanetwork - yeah the analysis is already built into my own software; it determines that a certain section of the footage is of interest, and i need to cut out that section into its own video file
[02:27] <alfanetwork> yeah I know thats why I said same tz. Its the national day here in Sweden so I am here with my family.
[02:28] <alfanetwork> adowdy there is/was a tool a while back called xrectsel that you could just draw a square around what you want and it will give you the coordinates.
[02:29] <alfanetwork> pasteeater Sweden and Norway are more or less the same place. We all sound like the cook on the muppets.
[02:29] <alfanetwork> men om du vill kan vi snaka svenska
[02:30] <alfanetwork> =)
[02:30] <pasteeater> Gratulerer med dagen!
[02:30] <alfanetwork> lol
[02:30] <alfanetwork> leerker!
[02:30] <alfanetwork> You from Norway?
[02:31] <pasteeater> i was there during syttende mai
[02:31] <pasteeater> no
[02:31] <pasteeater> Alaska
[02:31] <alfanetwork> Your Swedish is not that bad!
[02:32] <alfanetwork> You really do! I thought you were joking!
[02:32] <alfanetwork> Anyway you are a fast learner.
[02:33] <pasteeater> i forgot just about everything else.
[02:33] <alfanetwork> All you need to know is "ska vi knulla" and you will be fine in both Norway and Sweden.
[02:35] <pasteeater> so that's what the russ were saying
[02:35] <alfanetwork> I need to record my mic when using X11grab. Was wondering if -f alsa -i pulse what the way to do that.
[02:36] <alfanetwork> one that might have a happy ending or a black eye when you buy a person a beer.
[02:36] <pasteeater> i thought that does record the mic for most users
[02:37] <pasteeater> otherwise you can try replacing pulse with hw:0,0 or whatever the device is.
[02:38] <alfanetwork> My best Napoleon dynamite .... siiiighhhh. Why or why did I enforce SELinux on this machine.
[02:38] <pasteeater> burek knows more about this than i, but he looks idle
[02:38] <pasteeater> see your devices with 'arecord -l' or F2 in alsamixer
[02:38] <burek> :)
[02:38] <burek> :beer:
[02:38] <alfanetwork> I give him a shout when he gets back on.
[02:38] <alfanetwork> lol
[02:40] <alfanetwork> shout burek. Was the -f alsa -i pulse thing the right way to go after I rip SELinux of this machine?
[02:40] <burek> alfanetwork, http://ffmpeg.gusari.org/irclogs/2012/06/04/ffmpeg.log.20120604
[02:40] <burek> ctrl+F "arecord"
[02:41] <alfanetwork> well one thing for sure you can never go wrong with arecord. Ill give it a go.
[02:41] <burek> just to mention, I figured typing ffplay image.jpg is faster than opening gwenview
[02:42] <burek> to quickly preview an image
[02:42] <pasteeater> burek: so, what's the beer of the day?
[02:42] <burek> the cold one!
[02:42] <pasteeater> i need to hurry up and get some spruce tips for my next homebrew
[02:42] <burek> you are going to make it yourself?
[02:42] <alfanetwork> A dark stout would be nice for once.
[02:43] <pasteeater> like this but better: http://beeradvocate.com/beer/profile/429/1768
[02:43] <pasteeater> (for the spruce)
[02:43] <pasteeater> or even better: http://beeradvocate.com/beer/profile/829/29461
[02:44] <alfanetwork> lol wtf - Displayed for educational use only; do not reuse.
[02:44] <alfanetwork> don't drink that picture!
[02:44] <burek> is it freeze-free?
[02:45] <burek> Alaskan Winter :)
[02:45] <burek> I like the name :)
[02:45] <alfanetwork> at 6.40% I would think ... yeah
[02:45] <pasteeater> it's a seasonal ale
[02:45] <pasteeater> i don't think they make it at this time of the year
[02:45] <pasteeater> but the spruce tips are ready now
[02:46] <burek> we have several domestics here with 7%.. its just to strong
[02:46] <burek> I can't drink 2 of them, I'm usually done after it
[02:46] <burek> too*
[02:47] <pasteeater> where?
[02:47] <burek> here in Serbia
[02:48] <burek> we have Jelen (a deer) and Lav (a lion)
[02:48] <burek> both 7% and very strong
[02:48] <burek> there are normal ones too (5%) which I can drink :)
[02:48] <burek> who would say 2% would make such a difference :))
[02:49] <pasteeater> i'll look for those next time i'm in a city with more import beers.
[02:51] <burek> the best one is a big one :D http://www.forkparty.com/wp-content/uploads/2010/06/A-Best-Beer-Girls-Ever-Fork-Party.jpg
[02:51] <burek> I mean cold one :)
[02:53] <alfanetwork> adowdy sry the tool I was talking about was called xwininfo  if your still around
[02:54] <adowdy> alfanetwork and pasteeater - thank you guys for your help. i was able to get the crop filter working, and i think that will suit my needs
[02:55] <alfanetwork> adowdy you might like the cmd to get the right size and info for your crops
[02:57] <adowdy> alfanetwork - oh should i look at the tool you mentioned?
[02:58] <alfanetwork> well its just a cmd " xwininfo " lets you draw with your mouse a square and gives all the info needed.
[03:02] <pasteeater> adowdy: glad it worked for you
[03:02] <adowdy> me too; thanks
[04:52] <kolix> hey guys
[04:53] <kolix> I have a python script that parses out indivudla jpegs from a mjpeg stream and runs it through a computer vision sub routine
[04:53] <kolix> my question is can i transcode those jpegs back into an mjpeg stream on the fly?
[05:52] <Binbo> I have a problem where I stream over wireless network
[05:53] <Binbo> the video is h264, using rtsp
[05:53] <Binbo> at the client side
[05:53] <Binbo> I saved the stream into file
[05:54] <Binbo> using command ffmpeg -i rtsp://server:port -vcodec copy -acodec copy outputfile.mp4
[05:54] <Binbo> Then I get the video statistic via mplayer
[05:55] <Binbo> I found out the frame size of most of the frames were not the same as the source file
[05:55] <Binbo> am I doing something wrong?
[06:29] <zap0> i doubt thats the issue.   however you shoudl always aim to make frame sizes the largest multiple of 2 you can.  2,4,8,16,32,64  etc.
[07:04] <Binbo> zap0: hurm let me clarify first. if i saved the stream without transcoding and use the same container as the source video, the size of let say nth frame of the saved video should be the same as the nth frame of the source video rite?
[12:02] <Valo> what is the diff between "f_size" and "s_size" in vstats?
[12:09] <svenstaro> error: AVFormatContext has no member named mux_rate
[12:09] <svenstaro> how to fix in 0.11?
[12:16] <ahuillet> hello
[12:16] <ahuillet> I'm trying to write a piece of code in C, making use of libavcodec, do decode H.264 YUV420 video
[12:16] <ahuillet> the first implementation works, and now I'd like to make use of hardware acceleration when available
[12:17] <ahuillet> my understanding is that libavcodec can do that, but it doesn't seem to be completely automatic, and as it stands I'm stuck
[12:17] <ahuillet> my video is in PIX_FMT_YUV420P, and the only AVHWAccel that I have on my system for H.264 is h264_vaapi which requires a special pixel format
[12:18] <ahuillet> my question is: how am I supposed to input to avcodec_decode_video a video that is in PIX_FMT_VAAPI_*?
[12:18] <ahuillet> I couldn't find examples of that on the internet
[12:43] <ahuillet> OK, the answer was: I had to implement get_format() callback because it defaults to non-HW-accel.
[12:46] <ahuillet> though I'm still not sure how to talk to VAAPI - my input is YUV420P, can I feed that to libavcodec with pixfmt set to _VAAPI_VLD ?
[12:46] <burek> if you were given enough time to talk out loud, you could solve all your issues, as far as I can see :D
[12:51] <ahuillet> I've solved one, I'm hoping not to be on my own to solve the others ;)
[12:51] <ahuillet> but i suspect not many people are using avcodec with HW acceleration directly, and those who do know the API well....
[12:52] <burek> well, as long as I'm on this channel, hw acceleration was always something kinda problematic
[12:52] <burek> since*
[12:53] <ahuillet> it looks like MPlayer doesn't rely on avcodec's HW acceleration, but instead talks to the HW itself
[12:53] <ahuillet> I haven't been able to find a single code example using avcodec with VAAPI...
[12:55] <burek> did you try this http://stackoverflow.com/questions/5554933/ffmpeg-hardware-acceleration-gpu-directshow
[12:56] <ahuillet> well, it claims that ffmpeg supports various HW acceleration APIs, which I don't question
[12:56] <ahuillet> it doesn't tell me how to use them
[12:57] <burek> or this http://ffmpeg.org/pipermail/ffmpeg-devel/2010-August/082239.html
[12:57] <burek> well, I think google will tell you more, while you are waiting for an answer here :)
[15:48] <burek> if I have situation like this: ffmpeg -i input1 -i input2 -i input3 ...
[15:48] <burek> is it correct to specify first all -map options and then consecutively all the -vcodec -acodec ... or
[15:48] <burek> is it proper to write like this
[15:49] <burek> ffmpeg -i input1 -i input2 -i input3 -map 0:0 -vcodec ... -map 1:0 -vcodec ... -map 2:0 -vcodec ... output
[15:49] <burek> or is it
[15:50] <burek> ffmpeg -i input1 -i input2 -i input3 -map 0:0 -map 1:0 -map 2:0 -vcodec ... -vcodec ... -vcodec ... output
[16:12] <grepper> I've done it  -map 0:0 -map 1:0 -map 2:0  -acodec ac3 -ac 2  foo1.ac3 -acodec ac3 foo2.ac3 ...  for audio, but not lately and not sure if that is strickly correct, though it works fine
[16:23] <burek> it seems the correct way is
[16:23] <burek> ffmpeg -i input1 -i input2 -i input3 -vcodec ... -map 0:0 -vcodec ... -map 1:0 -vcodec ... -map 2:0 output
[18:27] <burek> something is wrong with mpegts muxer and I don't know what...
[18:28] <burek> when I encode libx264+aac into mpegts and just feed it via pipe to vlc for remux, then flash player (jw player) can't show video, but only audio
[18:28] <burek> if I do it all in vlc, then everything works..
[19:33] <kolix> Hi guys
[19:33] <kolix> can ffmpeg stream images generated on the fly without saving to disk?
[19:34] <kolix> and can it stream mjpeg?
[19:38] <burek> yes
[19:38] <burek> both
[19:39] <kolix> awesome. can you point me to some tutorials/refrences
[19:40] <burek> for the first task, you would need image2pipe
[19:40] <burek> for the second, just use -f mjpeg
[19:40] <burek> so, someappthatgeneratesimages | ffmpeg -f image2pipe - -vcodec mjpeg -q:v 5 -f mjpeg udp://remoteip:port
[19:41] <kolix> awesome
[19:42] <kolix> do i need a ffmpeg server?
[19:42] <kolix> I'm on ubuntu server 12
[19:42] <kolix> hopefully there's a package and i don't need to build from source
[19:44] <burek> it depends what exactly do you need
[19:48] <kolix> python test2.py | ffmpeg -f image2pipe -vcodec mjpeg -q 5 0f mjpeg udp://localhost:2007 breaks for me
[19:49] <burek> well I'm not psychic, I don't know what does test2.py do
[19:49] <kolix> "atleast one input file must be specificed"
[19:49] <burek> so you'll have to check it yourself
[19:49] <kolix> test2.py prints raw jpeg binary data
[19:49] <burek> after image2pipe there is no minus sign "-"
[19:49] <burek> which represents input from pipe
[19:50] <burek> read carefully what I wrote above
[19:50] <burek> and it's not 0f it's -f
[19:51] <relaxed> don't you need input? "-i -"
[19:51] <burek> oh, right :$
[19:51] Action: burek sets mode: +beer relaxed
[19:51] <burek> :)
[19:52] <kolix> ok i'm lost now lol
[19:53] <kolix> where do i put -i?
[19:53] <burek> python test2.py | ffmpeg -f image2pipe -i - -vcodec mjpeg -q:v 5 -f mjpeg udp://localhost:2007
[19:54] <relaxed> maybe copy the stream?
[19:55] <kolix> hmm could not find codec paramters
[19:55] <kolix> atleast I'm getting somewhere
[19:55] <relaxed> input format is what?
[19:55] <kolix> it's raw jpeg binary
[19:56] <relaxed> blah | ffmpeg -f image2pipe -vcodec mjpeg -i - ....
[19:58] <relaxed> sometimes on pipes you have to force the decoder
[19:59] <relaxed> which "-vcodec mjpeg" before the input does.
[20:05] <IchGuckLive> Hi all someone knows the format or codec "Zoran C10P"
[20:07] <burek> is there any alternative to mpegts format, to use with pipes (for libx264 + aac) ?
[20:08] <burek> ffmpeg -i bla -i bla ... -f mpegts - | vlc - ...
[20:13] <relaxed> Why are you piping through vlc?
[20:21] <alezandro> I have an AVFrame thats 640x360.. (yuv 4:2:0), i'd like to make it 640x480 with 60 pixel height bars at top and bottom.. "letterbox"
[20:21] <alezandro> is this possible with av_picture_pad() ? i'm using ffmpeg-0.8.10
[20:21] <burek> relaxed, to be able to have http stream out of it..
[20:21] <burek> still couldn't manage ffserver to do it :(
[20:27] <burek> alezandro, I don't know how to do it in the code, but the 'pad' video filter can do what you want: http://ffmpeg.org/ffmpeg.html#pad
[20:31] <alezandro> burek: ok, thx...will take a look at that
[20:33] <smjms> what is libavresample?
[20:36] <smjms> does it mix some frames to avoid jaggy motion when reducing frame rate?
[20:46] <smjms> ffmpeg supports libmodplug input? how does it work with infinitely looping tracks?
[20:57] <smjms> last time I heard Matroska was the new amazing container format
[20:58] <smjms> what are NUT's advantages?
[21:00] <JEEB> I wouldn't look at nut for much yet
[21:00] <JEEB> or well, maybe not ever
[21:01] <JEEB> but it's useful for things like raw YCbCr data with timecodes
[21:01] <JEEB> that's what most people who actually use it use it for
[21:03] <smjms> oh
[21:13] <gp5st> hello.  is there a way to add blank time to the end of a track? (a track in my case being a plain mp3 file)
[21:19] <burek> gp5st, what is blank time
[21:20] <llogan> burek: i assume no sound; silence.
[21:21] <burek> http://ffmpeg.org/ffmpeg.html#Examples-8
[21:22] <burek> btw, it's better to use audio editor
[21:22] <burek> and not a converting tool, like ffmpeg
[21:52] <relaxed> llogan: pasteeater?
[21:57] <relaxed> llogan: I updated my builds. Sorry about the delay.
[22:02] <WasserDragoon> hi there how to convert mkv to m2ts for playing on my ps3 (it's an hd video, no quality loss would be great)
[22:05] <td123> hi, I'm trying to help patch a program xmms2 for ffmpeg 0.11, and I'm wondering if anyone knows what the call to avcodec_init() was replaced with
[22:05] <gp5st> burek: i'm using ffmpeg to do conversions elsewhere so i was trying to keep the external tool count low
[22:09] <relaxed> gp5st: does it have to remain mp3?
[22:09] <td123> nvm, it seems that avcodec_init is called automatically when calling avcodec_register (found in git commits)
[22:10] <relaxed> gp5st: decode to wav -> SoX -> flac (or recode to mp3)
[22:12] <gp5st> relaxed: yes. i mean, i'm not opposed to having to re-encode it, but i was hoping there was a simpler way to just add a second of nothing to the end of the track
[22:20] <relaxed> gp5st: ffmpeg -f s16le -ar 44100 -i /dev/zero -t 60 -c:a libmp3lame -ab 128k silence.mp3; ffmpeg -i concat:song.mp3\|silence.mp3 -c:a copy done.mp3
[22:21] <relaxed> gp5st: that should give you 60 seconds of silence at the end.
[22:21] <relaxed> without any quality loss
[22:21] <gp5st> oh man
[22:21] <gp5st> thanks
[22:22] <gp5st> let me digest this
[22:24] <relaxed> The first command uses /dev/zero (zero = silence) as input and we force ffmpeg to decode it as raw pcm, then encode it to mp3. The second command concats the two into one track.
[22:25] <gp5st> it's trying to read concat:song.mp3\|silence.mp3 as a file name
[22:25] <gp5st> FFmpeg version SVN-r0.5.8-4:0.5.8-1
[22:26] <gp5st> relaxed: cool.  i get it conceptually, but i'd never been able to put that all together
[22:27] <relaxed> run, ffmpeg 2>&1 | sed q
[22:27] <gp5st> http://stackoverflow.com/a/7333453. i was going to give that a shot
[22:27] <gp5st> ok one sec
[22:27] <_Vi> How to portably enumerate streams in AVFormatContext without digging in "->nb_streams" and "->streams[..]" internals?
[22:27] <gp5st> FFmpeg version SVN-r0.5.8-4:0.5.8-1, Copyright (c) 2000-2009 Fabrice Bellard, et al.
[22:28] <relaxed> Okay, that
[22:28] <relaxed> s's too old
[22:28] <gp5st> :( it's what was in debian's repos
[22:29] <relaxed> Is this a 64bit machine?
[22:29] <gp5st> yes
[22:29] <relaxed> uname -r
[22:29] <gp5st> 3.2.0-0.bpo.1-amd64
[22:30] <gp5st> i can compile the new version, that's not a huge deal.  i just hate that the debian repos are always so old:(
[22:30] <relaxed> You can use my static builds if you like. https://sites.google.com/site/linuxencoding/builds
[22:31] <relaxed> Either way, you now have a solution :)
[22:32] <gp5st> \/\/007
[22:32] <gp5st> thanks
[22:37] <llogan> llogan: thanks. I was merely curious though. i didn't intend to have you rebuild everything because i asked.
[22:37] <llogan> i mean: relaxed
[22:37] <llogan> duh
[22:38] <gp5st> thank's perfect! thanks relaxed
[22:38] <relaxed> llogan: No problem, I have it all scripted. I've just been lazy!
[22:41] <llogan> relaxed: maybe a link to your builds would be good for the download page.
[22:41] <llogan> (if you update them regularly)
[22:42] <relaxed> I can but what download page are you talking about?
[22:44] <llogan> ffmpeg.org/download.html
[22:46] <relaxed> Ah, I'm fine with it if someone want to put it on there.
[22:46] <relaxed> wants*
[22:46] <llogan> there are some small updates for libvorbis and libvo-amrwbenc by the way (not that it really matters)
[22:46] <llogan> sure, i'll make a patch
[22:53] <relaxed> Yes, I have some static versions in my script that I need to remove. They're more than likely up-to-date.
[23:03] <llogan> relaxed: what do you want the link title to say? "Relaxed's FFmpeg Static Builds"?
[23:28] <llogan> nevermind. i just sent the patch with "Relaxed FFmpeg Static Builds"
[23:59] <teratorn> btw, what is the relationship between ffmpeg and vlc projects? I know there is some overlap/collaboration, but what's the history there?
[00:00] --- Fri Jun  8 2012


More information about the Ffmpeg-devel-irc mailing list