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

burek burek021 at gmail.com
Wed Apr 25 02:05:45 CEST 2012


[00:22] <kami8785> quick question: can i cut .flv files without re-encoding them? approximation through file size would be good enough for me
[00:30] <burek> kami8785, try ffmpeg -i input.flv -t 10 -codec copy out.flv
[00:30] <burek> that will produce 10 seconds of original without reencoding
[00:31] <kami8785> i tried that, while the video codec remains the same, some settings still change and youtube barfs if i upload
[00:31] <kami8785> i can head -c 10M test.flv and the headers remain intact
[00:31] <kami8785> cutting from the front, no such luck apparently
[00:32] <burek> no no
[00:32] <burek> head will just cut the file off
[00:32] <burek> rendering it invalid
[00:33] <kami8785> works fine for me
[00:33] <kami8785> im getting it from rtmpdump
[00:33] <kami8785> so probably not a perfectly valid file to begin with
[00:34] <taqattack> Could someone explain to me why my output fps drops when I'm trying streaming to RTMP? http://pastebin.com/7Yd2X94e
[00:37] <taqattack> The encoded file is at 30 fps H264/MP3. Checked with Gspot.
[00:39] <burek> kami8785, I don't know, but -vcodec copy -acodec copy -scodec copy should make an identical copy of the input
[00:39] <burek> combined with -t you should get just a part of it
[00:46] <taqattack> Is librtmp being truncated in favour of native rtmp?
[00:46] <kami8785> burek, didnt know about the scodec, seems to work now, i will test on some other flvs, thanks
[00:46] <burek> :beer:
[01:05] <kami8785> burek, yup there it is again, youtube gives "Failed (unable to convert video file)" after ffmpeg -i own2.flv -ss 5 -t 20 -acodec copy -vcodec copy -scodec copy own2out.flv, it failed on 2/4 uploads
[01:07] <kami8785> ffmpeg output of one of the files http://pastebin.com/S6Titey4
[01:07] <burek> kami8785, maybe your 10 seconds contains little or no keyframes
[01:07] <burek> or something
[01:08] <burek> anyway, if you use just -vcodec copy
[01:08] <burek> there is no point placing -ss after the -i
[01:08] <burek> because you are not re-encoding your video
[01:08] <burek> so it doesn't help you if ffmpeg actually gets your position more accurate
[01:08] <burek> if it is in the middle of 2 keyframes
[01:09] <burek> it won't be able to successfully do -vcodec copy
[01:09] <kami8785> i will try again with 60 seconds and -ss before -i
[01:09] <burek> try ffmpeg -ss 5 -i own2.flv -t 60 -acodec copy ...
[01:09] <burek> yes, exactly
[01:10] <burek> also, try opening your video in a video editor to find out where are your keyframes
[01:10] <burek> so you can see where you can cut it without reencoding
[01:10] <kami8785> it needs to be automated
[01:11] <burek> good luck with that, then
[01:11] <kami8785> haha
[01:12] <kami8785> its part of a much larger app, but it simplify things a lot if i can load off video cutting to ffmpeg
[01:12] <kami8785> ive also thought about just doing the cutting in youtube, since it has a video editor
[01:12] <burek> or you can always reencode it and get it as accurate as you need :)
[01:12] <kami8785> but id have to figure out the session token and it also takes a good amt of processing time before its ready
[01:13] <kami8785> hmm with the new settings it seems to work again
[01:13] <teratorn> why would ffmpeg need to do anything other than re-encode a single key-frame, and all the inter-frames before the NEXT keyframe, where it could resume vcodec=copy ?
[01:13] <kami8785> more testing!
[01:14] <kami8785> how can i re-encode to make sure youtube accepts it?
[01:14] <kami8785> as a last-resort if copy doesnt work
[01:14] <teratorn> burek: does that sound feasible to you?
[01:15] <burek> teratorn, because you explicitly told it not to do that?
[01:15] <teratorn> burek: well that's fine, I'm just wondering if it's possible in theory
[01:16] <burek> well, I agree that's the best approach, but encoding process needs parameters for quality/speed/rate
[01:16] <burek> so, it would have to be specified somehow, or detected from input, etc
[01:16] <teratorn> yeah..
[01:17] <burek> kami8785, install mediainfo and check youtube files' properties
[01:17] <teratorn> BUT, can you actually instruct ffmpeg to follow those semantics... re-encode until first keyframe then vcodec=copy?
[01:17] <burek> and then use various params to encode your video and check with mediainfo if they match :)
[01:17] <teratorn> I assume re-encoding will always re-encode all the frames
[01:17] <burek> teratorn, I personally don't know, but you can always ask in devel channel #ffmpeg-devel
[01:18] <kami8785> burek, hmm that seems to be the most solid solution
[01:18] <burek> or you can read the source code
[01:18] <kami8785> let me see if someone has found out the params that marry yt + ffmpeg
[01:18] <burek> ok :)
[01:18] <teratorn> yeah, I'll read source :) - I have need of some editing features soon, so I'll probably have to answer this question, or implement support if it's not already there
[01:18] <teratorn> assuming we' don't end up using GStreamer Editing Services instead :/
[01:19] <burek> teratorn, that would be a great feature
[01:19] <burek> I can tell already
[01:19] <burek> a lot of people have downloaded some videos encoded with, say, -gop 250 at 25fps
[01:19] <burek> so you get a key frame every 10 seconds
[01:20] <burek> and then they come asking why doesn't -ss work properly..
[01:20] <burek> (without reencoding)
[01:20] <teratorn> heh
[01:22] <teratorn> personally I never go over 9.8 seconds/KF
[01:22] <burek> I had to do -gop 25 once
[01:22] <burek> @25fps
[01:22] <burek> :/
[01:22] <teratorn> heh
[01:22] <burek> because stupid web flv player wouldn't wanna play video immediately
[01:22] <burek> even with grey/discolored image
[01:23] <burek> it would wait until a keyframe, so people often turned it off, thinking it doesn't work
[01:23] <teratorn> in my webm-streamer, I just don't send any damn data until a keyframe comes up
[01:23] <teratorn> which is pretty quick, so it's not a problem
[01:24] <teratorn> chrome chokes like hell if you don't start it on a keyframe
[01:26] <burek> it would really be cool to have ffmpeg as a web browser plugin :)
[01:26] <burek> instead of flash and such :)
[01:34] <kami8785> yeah ffmpeg is amazing
[01:35] <kami8785> im a fabrice bellard fanboy ever since i found out he created it
[01:46] <kami8785> burek, these new settings i cant shake a stick at, everything just works :) thanks alot
[01:46] <kami8785> any way i can use -ss to get to cut to a keyframe?
[01:47] <kami8785> woops
[01:47] <kami8785> back
[02:11] <Hugo5863> I have a problem, can anyone here help?
[02:12] <Hugo5863> Start a stream with ffmpeg I get an error that says "Unrecognized option 'lag-in-frames'"
[02:13] <Hugo5863> "/usr/local/share/ffmpeg/libvpx-360p.ffpreset: Invalid option or argument: 'lag-in-frames=16', parsed as 'lag-in-frames' = '16'
[02:13] <Hugo5863> "
[02:35] <iive> Hugo5863: that file is text one, remove the line containing it.
[02:35] <iive> it is likely libvpx own option and the version you have had changed/removed it.
[02:36] <Hugo5863> Ok, I'll try but last time I tried to edit it, it tikd me I couldn't
[02:36] <Hugo5863> Told
[02:36] <iive> Hugo5863: you may try to find out if they just renamed it, and change it to the new name.
[02:37] <iive> Hugo5863: probably wants root access :)
[02:37] <Hugo5863> How do I give myself root access to something I'm modifying in the text editor?
[02:38] <Hugo5863> (I'm just going to comment the line out)
[02:39] <Hugo5863> I wouldn't know how to find out if they changed the name of the file.
[02:44] <Hugo5863> Nvm, did a search and found it
[02:45] <Hugo5863> Alt+f2 to open a seach command line then enter 'gksudo nautilus' then after type my password fot a root admin window to do my edits with
[02:49] <Hugo5863> I commented out everything that was causing an error, now it's a new error.
[02:50] <Hugo5863> Error while opening encoder for output stream #0.0 - maybe incorrect parameters such as bit_rate, rate, width or height
[02:51] <Hugo5863> I'm trying to use a quality preset for the stream. If I remove the preset the computer doesn't vomplain.
[02:51] <Hugo5863> complain
[02:54] <Hugo5863> The odd thing is I'm using the libx264 encoder, why do I have to use presets for libvpx?
[02:54] <Hugo5863> I don't see the libx264 presets
[02:58] <Hugo5863> Ok, I had the thought that I'm missing the presets instead of that being what I'm supposed to use..
[02:58] <Hugo5863> Downloading the missing presets
[02:59] <Hugo5863> Going to put them in the file it was referencing for the incorrect preset
[02:59] <phunyguy_> hello everyone, I have a specific situation I need help with.   I have a video with 24bit DTS-HD Master Audio, and I would like to convert to raw wav file to encode as 24 bit 7.1 FLAC.  Currently ffmpeg (avconv?) only sees it as 16bit DTS Core.   Is there an alternative means to make this happen?
[03:00] <phunyguy_> TrueHD works perfect, just cant get DTS-HD MA to work
[03:01] <iive> Hugo5863: hum? i guess there is more than one wrong thing in your command line ;)
[03:05] <phunyguy_> the ffmpeg -i video.mkv produces output with "Stream #0.1(eng): Audio: dca (DTS-HD MA), 48000 Hz, 5.1, s16, 1536 kb/s (default)" as input audio stream.
[03:06] <phunyguy_> should be DTS-HD MA, 48000Hz, 7.1, s32.
[03:08] <Hugo5863> It's not letting me extract the presets from the zip file
[03:09] <Hugo5863> Each onr has a lock symbol next to it in the zip file
[03:14] <Hugo5863> I'm pretty sure at this point I just need to get these files from the zip into my presets folder but ubuntu isn't letting me
[03:55] <Hugo5863> Ok, I figured it out myself. The problem WAS that ffmpeg is missing the presets for libx264.
[03:56] <Hugo5863> I had to use the iPod presets that are for libx264 to get the stream to work.
[04:38] <tlvb> is it possible to stream a prerecorded intro seamlessly followed by a realtime input (webcam, ipcam)?
[05:52] <intangir> how do i change only the container format? and not the video/audio streams (just move from mp4 to avi or something?)
[05:52] <intangir> without actually changing the video encoding
[05:54] <intangir> i think i found out, brb gonna test it on blueray ;)
[05:59] <intangir> no dice
[06:57] <aphid> trying to figure out the rtmp path to get the main feed from http://www.media.mit.edu/events/medialabtalk/ (in the source, this stuff is defined in the loadMidSD() function) so i can rip this thing tomorrow.   everything thusfar i've tried via ffmpeg has thrown "Closing connection: NetStream.Play.StreamNotFound"
[08:20] <ciao> ciao
[12:14] <mkoch> hi! how can I find out if my ffmpeg uses vda on Mac? according to the config.h vda support is on, but when I try to play a video ffplay uses 10 times more CPU then QT, so it seems that actually it doesn't use video decode acceleration
[12:16] <Mavrik> as far as I know ffplay doesn't use hardware acceleration yet
[12:16] <Mavrik> other apps that use ffmpeg libs do
[12:18] <mkoch> then what is this? http://ffmpeg.org/doxygen/trunk/vda_8h-source.html
[12:18] <mkoch> and I'm actually building an app which uses ffmpeg az a lib, so is there a way then to use hw accel?
[12:18] <Mavrik> this is a hook for those apps so they get data pre-packaged for acceleration
[12:18] <mkoch> (or should I go to the dev channel with this question?)
[12:19] <Mavrik> so they can pass it over to HW decoding APIs
[12:19] <Mavrik> probably yes
[12:19] <Mavrik> or even better - libav-users mailing list
[12:19] <mkoch> okay, thanks anyway! :)
[16:02] <praedo> i'm trying to encode a NTSC DV file and i only get sound when played in windows media
[16:02] <praedo> this is the command i use:
[16:02] <praedo> ffmpeg -i file.avi -vf yadif=0:1 -vcodec libx264 -preset veryfast -crf 22 -threads 0 -acodec libfaac -aq 100 file.mp4
[16:02] <praedo> it's a project encoded to .avi (NTSC DV profile) in premiere
[16:03] <praedo> and i want to encode the .avi into .mp4
[16:03] <praedo> if i encode it with mpeg streamclip, it works with audio+video
[16:03] <praedo> but with ffmpeg i get blank video
[16:03] <praedo> it works with PAL and the only difference is that it's NTSC
[16:03] <praedo> do i need any extra option to that command line?
[16:15] <TimNich> praedo: can you put the complete uncut console  output somewhere?
[16:42] <b_jonas> thanks for ffmpeg!
[16:42] <b_jonas> I've just decoded a video successfully
[16:44] <praedo> TimNich, what do you mean by uncut?
[16:49] <TimNich> as  in don't be tempted to trim it down, everything from the header message to the end of the coding stats..
[16:51] <kai> hi folks
[16:53] <kai> I'm trying to stream live video from a webcam to another PC with as low a latency as possible. what would be the ideal way to do this?
[16:54] <kai> I'll have 100Mbit ethernet available, and a dual-core centrino system connected to the web cam
[17:32] <ckb> hey guys, is there a way I can encode a video with adobe's h264 codec? I'm trying to add DRM to some video files, but apparently it doesn't support libx264
[17:45] <iive> ckb: drm to video files?
[17:46] <ckb> iive: yes, I'm trying to use DRM with my video& but EzDRM doesn't support libx264, only FLV..
[17:46] <iive> flv is container, x264 is encoder...
[17:47] <ckb> yeah, I'm aware
[17:47] <ckb> I have a fly file encoded with libx264 and libfaac
[17:48] <ckb> but when I try to pack the file for DRM, it tells me the video format isn't supported
[17:48] <ckb> flv***
[17:55] <barhom> anyone that uses ffserver, please check ticket: https://ffmpeg.org/trac/ffmpeg/ticket/1249 - have you ever noticed this problem?
[18:04] <ckb> Apparently, I have to use Adobe to encode my videos.. so I can't use ffmpeg to encode ;(
[18:06] <Rik316> I'm curious. What's the opaque member in libavformat?
[18:27] <ckb> APPARENTLY& I can only use Adobe's codecs with what I'm trying to do
[18:31] <barhom> does anyone know any web server that can accept ffmpeg output "-f flv http://webserver/somefile.flv"
[18:31] <barhom> and then stream that live stream via HTTP GET standard port 80 (wget http://webserver/somefile.flv)
[18:34] <aphid> ...adobe has codecs?
[18:34] <ckb> aphid: that's what I don't understand about this
[18:34] <ckb> aphid: you think you could help me wrap my head around this?
[18:35] <ckb> EzDRM says that the files need to be in a f4v container h264/aac
[18:35] <ckb> in order to put the DRM header content in there
[18:36] <ckb> everything is great and dandy, as I can encode videos into f4v& but the problem lies with me needing 5 or 6 different outputs for the video (bitrates/resolutions)
[18:36] <aphid> the time I spend working with flv is usually spent trying to get into open formats.  wouldn't even know where to start trying to get it into it.
[18:36] <ckb> sigh
[18:37] <aphid> like all this public domain gov't produced video they're using rtmp to stream cruddy flvs...   i guess i should be relieved only a few of them are still doing RealVideo
[18:39] <ckb> why can't ffmpeg output to f4v?
[18:39] <aphid> ckb - http://en.wikibooks.org/wiki/FFMPEG_An_Intermediate_Guide/h.264 mentions f4v as a valid output
[18:40] <ckb> but...
[18:40] <aphid> "h.264 is arguably the cutting edge of video compression codecs. Unfortunately it is copyright protected." just hurt my brain.
[18:41] <ckb> Unable to find a suitable output format for 'output.f4v'
[18:41] <ckb> yep
[18:42] <aphid> copyrights, patents, whatever
[18:47] <ckb> just don't understand any of this
[18:47] <ckb> DRM is the worst idea ever
[18:47] <aphid> why are you trying to use it?
[18:47] <phunyguy_> that is an opinion.
[20:02] <taqattack> I have a question. How do I add timestamp to ffmpeg. IT says -timestamp now has been deprecated
[22:27] <praedo> TimNich, still here?
[22:35] <praedo> [15:02] <praedo> i'm trying to encode a NTSC DV file and i only get sound when played in windows media
[22:35] <praedo> [15:02] <praedo> this is the command i use:
[22:35] <praedo> [15:02] <praedo> ffmpeg -i file.avi -vf yadif=0:1 -vcodec libx264 -preset veryfast -crf 22 -threads 0 -acodec libfaac -aq 100 file.mp4
[22:35] <praedo> [15:03] <praedo> it's a project encoded to .avi (NTSC DV profile) in premiere
[22:35] <praedo> [15:03] <praedo> and i want to encode the .avi into .mp4
[22:35] <praedo> [15:03] <praedo> if i encode it with mpeg streamclip, it works with audio+video
[22:35] <praedo> [15:03] <praedo> but with ffmpeg i get blank video
[22:35] <praedo> [15:04] <praedo> it works with PAL and the only difference is that it's NTSC
[22:35] <praedo> [15:04] <praedo> do i need any extra option to that command line?
[22:35] <praedo> ...
[22:35] <praedo> can i give you a chunk of the dv file for you to test please?
[22:39] <praedo> i see it can be played in vlc but not in windows media
[22:39] <praedo> i don't think it's an encoding problem
[22:39] <praedo> maybe something related to ntsc playback in windows media...
[00:00] --- Wed Apr 25 2012


More information about the Ffmpeg-devel-irc mailing list