[FFmpeg-user] -b:a doesn't give me desired output bitrate
Hello. I'm trying to concatenate two OPUS audio files (from WhatsApp) into an MP3. On my first try without specifying output bitrate I found that the MP3 file is far too big (10 MB) than the sum of the input OPUS files (1 and 2 MBs). Then I figured it was because of the output bit rate not being set. But even with using -b:a to set the bitrate to the same as the input, I find that for some reason the output seems to use a higher bitrate and the output is still bigger than the sum of its inputs. Please guide me as to how I can get my desired effect of getting an output MP3 file that is comparable in size to the sum of its input OPUS files. $ ffmpeg -f concat -safe 0 -i <(printf "file '$PWD/%s'\n" *.opus) -b:a 18k -c libmp3lame output.mp3 Input #0, concat, from '/dev/fd/63': Duration: N/A, start: -0.002167, bitrate: N/A Stream #0:0: Audio: opus, 48000 Hz, mono, fltp Stream mapping: Stream #0:0 -> #0:0 (opus (native) -> mp3 (libmp3lame)) Press [q] to stop, [?] for help Output #0, mp3, to 'output.mp3': Metadata: TSSE: Lavf57.71.100 Stream #0:0: Audio: mp3 (libmp3lame), 48000 Hz, mono, fltp, 18 kb/s Metadata: encoder : Lavc57.89.100 libmp3lame size=5319kB time=00:22:41.61 bitrate= 32.0kbits/s speed= 103x video:0kB audio:5319kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.004351% $ for x in *.opus output.mp3 ; do ffprobe $x ; done Input #0, ogg, from 'AUD-20170705-WA.opus': Duration: 00:07:41.82, start: 0.002167, bitrate: 18 kb/s Stream #0:0: Audio: opus, 48000 Hz, mono, fltp Input #0, ogg, from 'AUD-20170705-WA0001.opus': Duration: 00:14:59.78, start: 0.002167, bitrate: 18 kb/s Stream #0:0: Audio: opus, 48000 Hz, mono, fltp Input #0, mp3, from 'output.mp3': Metadata: encoder : Lavf57.71.100 Duration: 00:22:41.64, start: 0.023021, bitrate: 32 kb/s Stream #0:0: Audio: mp3, 48000 Hz, mono, s16p, 32 kb/s $ ls -l *.opus output.mp3 1096672 Jul 5 06:30 AUD-20170705-WA.opus 2124414 Jul 5 06:30 AUD-20170705-WA0001.opus 5446797 Jul 5 07:01 output.mp3 -- Shriramana Sharma ஶ்ரீரமணஶர்மா श्रीरमणशर्मा ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] hls & Continuity check failed
Hello again. I have tried the option but i don't know if it has helped. The problem still exists. I have uploaded my log here https://ufile.io/8akvk If you have any questions/problems downloading please let me know! Thanks!!! On 7/4/2017 2:13 PM, Moritz Barsnick wrote: On Tue, Jul 04, 2017 at 11:55:47 +0300, tasos wrote: Would you like me to add some specific options in order to get a more detailed output? Not in the first step. Currently i'm using just -report. That's fine, although it increases the debug level. Please do try the workaround/additional flag I suggested. Thanks, Moritz ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] hls & Continuity check failed
Thank you very much. I will reply asap. On 7/4/2017 2:13 PM, Moritz Barsnick wrote: On Tue, Jul 04, 2017 at 11:55:47 +0300, tasos wrote: Would you like me to add some specific options in order to get a more detailed output? Not in the first step. Currently i'm using just -report. That's fine, although it increases the debug level. Please do try the workaround/additional flag I suggested. Thanks, Moritz ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] hls & Continuity check failed
On Tue, Jul 04, 2017 at 11:55:47 +0300, tasos wrote: > Would you like me to add some specific options in order to get a more > detailed output? Not in the first step. > Currently i'm using just -report. That's fine, although it increases the debug level. Please do try the workaround/additional flag I suggested. Thanks, Moritz ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] Create hvc1 mp4 with ffmpeg only
Hello, I have additional information... > 2017/07/03 午後10:53、桃源老師のメール: > I can not wait for this patch would be applied to ffmpeg master!! In my first post, I wrote: > I can create hvc1 mp4 using MP4Box by following the URL below: > https://stackoverflow.com/questions/32152090/encode-h265-to-hvc1-codec I have confirmed hvc1 movie which created with MP4Box is bad for next macOS. It cause unexpected shutdown of QuickTime Player when seek, first-forward, and first-rewind the movie. I also confirmed that hvc1 movie which created with patched ffmpeg does not cause above problem. Also, patched ffmpeg can fix MP4Box's problematic movie without re-encoding!! So, I think those 5 patches are required for every Mac user!! Please cut-in them sooner!! Best Regards, // Miya aka. TougenRoushi smime.p7s Description: S/MIME cryptographic signature ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] hls & Continuity check failed
Thank you very much for replying! Would you like me to add some specific options in order to get a more detailed output? Currently i'm using just -report. On 7/4/2017 11:14 AM, Moritz Barsnick wrote: On Mon, Jul 03, 2017 at 21:49:45 +0300, tasos wrote: Hello. I'm using ffmpeg to get a stream(hls) and send it to a media server. After some time i keep getting the following error and the video will never be corrected(i mean i see no video at all). I have to restart ffmpeg. [mpegts @ 0x559c3a0] Continuity check failed for pid 4095 expected 1 got 0 frame= 4314 fps=2.3 q=23.0 size= 37963kB time=00:04:56.06 bitrate=1050.4kbits/s dup=0 drop=2864 speed=0.16x [AVIOContext @ 0x7d56d00] Statistics: 144760 bytes read, 0 seeks [hls,applehttp @ 0x5575020] HLS request for url 'foo', offset 0, playlist 4 [hls,applehttp @ 0x5575020] Opening 'bar' for reading [http @ 0x7d5d700] request: GET foobar1 HTTP/1.1 User-Agent: Mozilla/5.0 (Linux; Android 5.1.1; SM-G928X Build/LMY47X) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.83 Mobile Safari/537.36 Accept: */* Connection: close Host: foobar Cookie: foofoo Icy-MetaData: 1 You are usually asked to provide the actual ffmpeg command line and the complete, uncut console output. Does ffmpeg continue to (try to) encode after the corrupt packet ("continuity check")? If I read ffmpeg's source correctly, you could try to set -fflags +discardcorrupt as an output option. ffmpeg should then drop this packet. I'm not sure you will get a better result though. Do give it a try. Regards, Moritz ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe". ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".
Re: [FFmpeg-user] hls & Continuity check failed
On Mon, Jul 03, 2017 at 21:49:45 +0300, tasos wrote: >Hello. >I'm using ffmpeg to get a stream(hls) and send it to a media server. >After some time i keep getting the following error and the video will > never be corrected(i mean i see no video at all). >I have to restart ffmpeg. > > [mpegts @ 0x559c3a0] Continuity check failed for pid 4095 expected 1 got 0 > > frame= 4314 fps=2.3 q=23.0 size= 37963kB time=00:04:56.06 > > bitrate=1050.4kbits/s dup=0 drop=2864 speed=0.16x > > [AVIOContext @ 0x7d56d00] Statistics: 144760 bytes read, 0 seeks > > [hls,applehttp @ 0x5575020] HLS request for url 'foo', offset 0, > > playlist 4 > > [hls,applehttp @ 0x5575020] Opening 'bar' for reading > > [http @ 0x7d5d700] request: GET foobar1 HTTP/1.1 > > User-Agent: Mozilla/5.0 (Linux; Android 5.1.1; SM-G928X Build/LMY47X) > > AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.83 Mobile > > Safari/537.36 > > Accept: */* > > Connection: close > > Host: foobar > > Cookie: foofoo > > Icy-MetaData: 1 You are usually asked to provide the actual ffmpeg command line and the complete, uncut console output. Does ffmpeg continue to (try to) encode after the corrupt packet ("continuity check")? If I read ffmpeg's source correctly, you could try to set -fflags +discardcorrupt as an output option. ffmpeg should then drop this packet. I'm not sure you will get a better result though. Do give it a try. Regards, Moritz ___ ffmpeg-user mailing list ffmpeg-user@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-user To unsubscribe, visit link above, or email ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".