Re: [FFmpeg-user] Get RFC6381 codecs representation using ffmpeg/ffprobe

2016-10-24 Thread Claudiu Rad


On 10/24/2016 4:33 PM, Carl Eugen Hoyos wrote:

2016-10-24 15:26 GMT+02:00 Claudiu Rad <jazz...@misalpina.net>:

Hello all,

So I have whatever video and I need to obtain the RFC6381
representation  of its codecs: https://tools.ietf.org/html/rfc6381

For example:
"avc1.640028" means: H.264/AVC video, High Profile, Level 40
"mp4a.40.2" means: AAC-LC

(It isn't clear to me what is provided and what you need - left or right?)


I can get right by parsing the commands output, but I need left.




I assume ffmpeg knows very well about those things but I've run both
ffmpeg/ffprobe on the video but can't find any trace of those things in
the output. Or am I missing something?

Please provide the ffmpeg command line you have tested and the
complete, uncut console output.


Ok, sorry. Where can I find for example a representation like 
"avc1.64??29" (High profile means 100=0x64, level 41=0x29) for the video 
stream in the below outputs?


ffmpeg -i bunny1080p.mp4
ffmpeg version N-82092-g89ec4ad-static http://johnvansickle.com/ffmpeg/  
Copyright (c) 2000-2016 the FFmpeg developers

  built with gcc 5.4.1 (Debian 5.4.1-2) 20160904
  configuration: --enable-gpl --enable-version3 --enable-static 
--disable-debug --disable-ffplay --disable-indev=sndio 
--disable-outdev=sndio --cc=gcc-5 --enable-fontconfig --enable-frei0r 
--enable-gnutls --enable-gray --enable-libass --enable-libebur128 
--enable-libfreetype --enable-libfribidi --enable-libmp3lame 
--enable-libopencore-amrnb --enable-libopencore-amrwb 
--enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsoxr 
--enable-libspeex --enable-libtheora --enable-libvidstab 
--enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx 
--enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid 
--enable-libzimg

  libavutil  55. 33.100 / 55. 33.100
  libavcodec 57. 63.103 / 57. 63.103
  libavformat57. 53.100 / 57. 53.100
  libavdevice57.  0.103 / 57.  0.103
  libavfilter 6. 64.100 /  6. 64.100
  libswscale  4.  1.100 /  4.  1.100
  libswresample   2.  2.100 /  2.  2.100
  libpostproc54.  0.100 / 54.  0.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'bunny1080p.mp4':
  Metadata:
major_brand : isom
minor_version   : 1
compatible_brands: isomavc1
creation_time   : 2013-12-16T17:44:39.00Z
title   : Big Buck Bunny, Sunflower version
artist  : Blender Foundation 2008, Janus Bager Kristensen 2013
comment : Creative Commons Attribution 3.0 - 
http://bbb3d.renderfarming.net

genre   : Animation
composer: Sacha Goedegebure
  Duration: 00:10:34.53, start: 0.00, bitrate: 3481 kb/s
Stream #0:0(und): Video: h264 (High) (avc1 / 0x31637661), yuv420p, 
1920x1080 [SAR 1:1 DAR 16:9], 2998 kb/s, 30 fps, 30 tbr, 30k tbn, 60 tbc 
(default)

Metadata:
  creation_time   : 2013-12-16T17:44:39.00Z
  handler_name: GPAC ISO Video Handler
Stream #0:1(und): Audio: mp3 (mp4a / 0x6134706D), 48000 Hz, stereo, 
s16p, 160 kb/s (default)

Metadata:
  creation_time   : 2013-12-16T17:44:42.00Z
  handler_name: GPAC ISO Audio Handler
Stream #0:2(und): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 
5.1(side), fltp, 320 kb/s (default)

Metadata:
  creation_time   : 2013-12-16T17:44:42.00Z
  handler_name: GPAC ISO Audio Handler
Side data:
  audio service type: main
At least one output file must be specified

ffprobe -print_format json -show_format -show_streams -show_programs 
-show_chapters bunny1080p.mp4
ffprobe version N-82092-g89ec4ad-static 
http://johnvansickle.com/ffmpeg/  Copyright (c) 2007-2016 the FFmpeg 
developers

  built with gcc 5.4.1 (Debian 5.4.1-2) 20160904
  configuration: --enable-gpl --enable-version3 --enable-static 
--disable-debug --disable-ffplay --disable-indev=sndio 
--disable-outdev=sndio --cc=gcc-5 --enable-fontconfig --enable-frei0r 
--enable-gnutls --enable-gray --enable-libass --enable-libebur128 
--enable-libfreetype --enable-libfribidi --enable-libmp3lame 
--enable-libopencore-amrnb --enable-libopencore-amrwb 
--enable-libopenjpeg --enable-libopus --enable-librtmp --enable-libsoxr 
--enable-libspeex --enable-libtheora --enable-libvidstab 
--enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx 
--enable-libwebp --enable-libx264 --enable-libx265 --enable-libxvid 
--enable-libzimg

  libavutil  55. 33.100 / 55. 33.100
  libavcodec 57. 63.103 / 57. 63.103
  libavformat57. 53.100 / 57. 53.100
  libavdevice57.  0.103 / 57.  0.103
  libavfilter 6. 64.100 /  6. 64.100
  libswscale  4.  1.100 /  4.  1.100
  libswresample   2.  2.100 /  2.  2.100
  libpostproc54.  0.100 / 54.  0.100
{
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'bunny1080p.mp4':
  Metadata:
major_brand : isom
minor_version   : 1
compatible_brands: isomavc1
creation_time   : 2013-12-16T17:44:39.00Z
title   : Big Buck

[FFmpeg-user] Get RFC6381 codecs representation using ffmpeg/ffprobe

2016-10-24 Thread Claudiu Rad

Hello all,

So I have whatever video and I need to obtain the RFC6381 representation 
of its codecs: https://tools.ietf.org/html/rfc6381


For example:
"avc1.640028" means: H.264/AVC video, High Profile, Level 40
"mp4a.40.2" means: AAC-LC

I assume ffmpeg knows very well about those things but I've run both 
ffmpeg/ffprobe on the video but can't find any trace of those things in 
the output. Or am I missing something?


--
Claudiu

___
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] Blackmagic card issue capturing

2016-03-01 Thread Claudiu Rad


On 3/1/2016 5:13 PM, Christian Bianchini wrote:

I just tried without that parameter and

frame=2 fps=0.6 q=0.0 size=   0kB time=00:00:00.00 bitrate=N/A
dup=0 dro
frame=2 fps=0.5 q=0.0 size=   0kB time=00:00:00.00 bitrate=N/A
dup=0 dro
frame=2 fps=0.4 q=0.0 size=   0kB time=00:00:00.00 bitrate=N/A
dup=0 dro
[dshow @ 00898217b420] real-time buffer [Decklink Video Capture] [video
inpu
t] too full or near too full (136% of size: 3041280 [rtbufsize parameter])!
fram
e dropped!


well, just try to set it larger like the error suggests, for example 10 
times the default:


-rtbufsize 30412800

still, i don't know if this is your problem.

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] gracefully restart an ffmpeg stream?

2016-01-10 Thread Claudiu Rad



On 1/10/2016 10:54 PM, chovy wrote:

On 01/10/2016 01:07 PM, Reindl Harald wrote:


Am 10.01.2016 um 21:05 schrieb jd1008:

On 01/10/2016 01:00 PM, Reindl Harald wrote:


Am 10.01.2016 um 20:48 schrieb chovy:

What's the least intrusive way to restart an ffmpeg stream?

I don't mind if the stream flickers or jumps ahead...but right now
when I kill the pid and restart it, the player completely stops
playing it.

that's nothing you can solve on the server side
the client needs to graceful hand short interruptions

Seems like if the server kills the video streamer, then the client's
connection is broken. So when server restarts the streamer, then
the client should still be able to re-connect to server and start
playing the stream. No?

surely, that connection is broken
yes, the *client* should be able to reconnect

if the client don't re-connect just blame the client
you can't solve that on the server side

exactly what i said

Since the client is not able to reconnect, it seems that it may be possible
that the very server PROCESS which invokes ffmpeg to start the stream
needs to be restarted, not just ffmpeg - I am assuming the main server
daemon is NOT ffmpeg.



I'm using nginx to server the .ts and index.m3u8 files...I don't see why a 
restart of nginx would be required.


please first document yourself and understand how this whole process 
works, who plays what role, and so on.
then you'll find the role of EXT-X-ENDLIST and maybe figure out a 
solution to not feed it to the client at all and gracefully continue the 
ongoing playlist after restart. a playlist preprocessor could help.
and then please understand why this is not an ffmpeg issue and shouldn't 
be its responsibility to have flags to create intermediary incomplete 
outputs. and this is for the simple fact the ffmpeg *is not* a streaming 
server. look to other solutions for that.



___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] apple-friendly timestamps with -c copy

2015-12-21 Thread Claudiu Rad



On 12/21/2015 3:19 PM, Claudiu Rad wrote:



On 12/20/2015 2:55 AM, Laine Lee wrote:
On 12/18/15, 12:41 PM, "ffmpeg-user on behalf of Claudiu Rad" 
<ffmpeg-user-boun...@ffmpeg.org on behalf of jazz...@misalpina.net> 
wrote:



anyone? i really need to find a solution without re-encoding the whole


I worked around this issue by using Remux 1.3.1 in OS X, available 
from MacUpdate. When I saw a similar issue in Mencoder output, I 
discovered that "-lavfopts format=mp4” appeared to solve it, but even 
with an ffmpeg equivalent, it would mean re-encoding, of course.


so just remuxing without reencoding? this would confirm that the issue 
is fixable by only fiddling around with the timestamps as i suspected.
ffmpeg by default also automatically fixes this if i just reencode, 
probably because it knows to properly decode the input and then 
regenerates timestamps.
it's a pity though that timestamps / frame order in ffmpeg cannot be 
easily controlled without reencoding. after all, this is not actual 
media content, just metadata (although mandatory for playback).

maybe a bitstream filter would to the trick?


i also filled a bug at apple in the meantime and got back an interesting 
answer:

/
/
/"Please know that our engineering team has determined that this issue 
behaves as intended based on the information provided./

/
/
/The movie clearly has b-frames and requires frame reordering, but it 
lacks a ‘ctts’ (also known as the Composition Offsets table) in the 
header.  So, we play back the frames in the order which they were decoded./

/
/
/This is clearly a malformed mp4, since it lacks the required 
Composition Offset table.  Other players may play back the movie without 
regard for this movie header information, but we strictly adhere to the 
timing information they provide - not doing so will cause us to 
disregard what may be intentional updates to this header data./

/
/
/If you can, you have authored this content with your own tools you 
should update your tools to correctly add this composition offset 
information.  Otherwise, if you know what tools were used to author the 
media, you should report this issue so that they can cease creating 
invalid content."/


so this gets interesting as due to the lack of CTTS, they strictly 
adhere to decoding order, unlike ffmpeg and others, thus, the playback 
issue.
why isn't ffmpeg regenerating this table when transcoding if it doesn't 
exist?


in this case i see two possible ways of going further:
- somehow regenerate CTTS (anyone has any ideas? maybe converting to 
some other container formats?)
- somehow force frame reordering, although not very sure this would fix 
the issue in this particular case. still, i do believe it's possible 
because my current setup takes input from the same encoder and without 
reencoding the output has nice monotonically increasing timestamps. i 
still have to figure out who does this in the processing chain


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] apple-friendly timestamps with -c copy

2015-12-21 Thread Claudiu Rad



On 12/20/2015 2:55 AM, Laine Lee wrote:

On 12/18/15, 12:41 PM, "ffmpeg-user on behalf of Claudiu Rad" 
<ffmpeg-user-boun...@ffmpeg.org on behalf of jazz...@misalpina.net> wrote:


anyone? i really need to find a solution without re-encoding the whole


I worked around this issue by using Remux 1.3.1 in OS X, available from MacUpdate. 
When I saw a similar issue in Mencoder output, I discovered that "-lavfopts 
format=mp4” appeared to solve it, but even with an ffmpeg equivalent, it would mean 
re-encoding, of course.


so just remuxing without reencoding? this would confirm that the issue 
is fixable by only fiddling around with the timestamps as i suspected.
ffmpeg by default also automatically fixes this if i just reencode, 
probably because it knows to properly decode the input and then 
regenerates timestamps.
it's a pity though that timestamps / frame order in ffmpeg cannot be 
easily controlled without reencoding. after all, this is not actual 
media content, just metadata (although mandatory for playback).

maybe a bitstream filter would to the trick?

thanks for the info. i'll try playing a bit with the tools you mentioned.

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] apple-friendly timestamps with -c copy

2015-12-18 Thread Claudiu Rad



On 11/25/2015 10:10 PM, Claudiu Rad wrote:



On 11/24/2015 3:21 PM, Claudiu Rad wrote:

hello warriors,

so maybe this is obvious for some but not for me.

i have some recordings produced by adobe's flash media server 
technologies, encoding originally done by their flash media live 
encoder in h264 + mp3/aac.
only some of them exhibit a bad playback behavior when trying to -c 
copy them to mp4/HLS.


it seems that issues only exist with recordings made with h264 main 
profile. baseline works properly.


bad playback means stuttering in some players like the fps went down, 
but on apple playing runtimes i really don't know the term or how to 
describe it, it's like the image jumps forward/backward a few frames 
a couple of times per second while the audio runs fine.


after searching a bit, i think what i am seeing is somewhat the same 
as described here: https://trac.ffmpeg.org/ticket/502 - jumping 
frames, frames not played in the right order


apple playing runtimes means: quicktime or safari on os x or iOS 
playing MP4 or HLS generated with ffmpeg.


from my initial investigations, the difference between a well 
behaving adobe recording and a badly behaving one is related to 
PTS/DTS values, visually i guess its like apple plays back based on 
DTS not PTS, please observe how the frames are constantly interlaced:

frame,pkt_pts_time,best_effort_timestamp_time,pkt_dts_time,pict_type
*frame,0.00,0.04,0.00,I*
frame,0.08,0.08,0.08,B
frame,0.12,0.12,0.12,B
frame,0.16,0.16,0.16,B
*frame,0.04,0.20,0.20,P*
frame,0.24,0.24,0.24,B
frame,0.28,0.28,0.28,B
frame,0.32,0.32,0.32,B
*frame,0.20,0.36,0.36,P*
frame,0.40,0.40,0.40,B
...


BTW, what does 'best_effort_timestamp_time' mean?



VLC plays both the original recording and ffmpeg outputs just fine.
if i reencode with ffmpeg everything is then perfect, PTS/DTS are 
aligned, but i want to avoid that.


what ideas do you have? how can i work on timestamps with ffmpeg and 
correct them via -c copy?
basically a reorganizing / re-timestamping so that we have 
monotonically increasing PTS i assume should be enough. is this 
possible?


anyone? i really need to find a solution without re-encoding the whole 
data. please, we are speaking about TB..

why is this correctly played by flash player or VLC?



to put it in another way: can ffmpeg reorder frames in the video 
stream based on some criteria, in my case based on PTS?
or does anybody know other tools that could do that? i would really 
try this to see if anything changes or re-timestamping is really 
necessary.




a bad recording sample is here: http://www.datafilehost.com/d/6a22a099


i realized that even i don't know how to download that. re-posted the 
sample input here:

http://88.198.6.138/tsissue/in.f4f
and the output of running the below command here:
http://88.198.6.138/tsissue/out.mp4



ffmpeg output:

ffmpeg -y -i in.f4f -c copy out.mp4
ffmpeg version N-76816-g188a1a1-static Copyright (c) 2000-2015 the 
FFmpeg developers

  built with gcc 4.7 (Debian 4.7.2-5)
  configuration: --prefix=/root/ffmpeg_build 
--extra-cflags='-I/root/ffmpeg_build/include -static' 
--extra-ldflags='-L/root/ffmpeg_build/lib -lm -static' 
--pkg-config-flags=--static --bindir=/root/bin --enable-gpl 
--enable-libfdk-aac --enable-libfreetype --enable-libmp3lame 
--enable-libopus --enable-libtheora --enable-libvorbis 
--enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid 
--enable-nonfree --extra-version=static --disable-debug 
--disable-shared --enable-static --extra-cflags=--static 
--disable-doc --enable-pthreads --enable-postproc 
--enable-runtime-cpudetect --enable-version3 --disable-devices

  libavutil  55.  9.100 / 55.  9.100
  libavcodec 57. 16.100 / 57. 16.100
  libavformat57. 19.100 / 57. 19.100
  libavdevice57.  0.100 / 57.  0.100
  libavfilter 6. 15.100 /  6. 15.100
  libswscale  4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc54.  0.100 / 54.  0.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x335fa40] multiple edit list entries, a/v 
desync might occur, patch welcome

Last message repeated 3 times
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'in.f4f':
  Metadata:
major_brand : f4v
minor_version   : 1
compatible_brands: isommp42m4v
creation_time   : 2015-01-04 18:02:32
  Duration: 00:05:24.98, start: 0.00, bitrate: 368 kb/s
Stream #0:0(eng): Data: none (amf0 / 0x30666D61), 0 kb/s (default)
Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: MainConcept
Stream #0:1(eng): Video: h264 (Main) (avc1 / 0x31637661), 
yuv420p(tv), 426x240 [SAR 1:1 DAR 71:40], 200 kb/s, 25 fps, 25 tbr, 
1k tbn, 50 tbc (default)

Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: MainConcept
  encoder : AVC Coding
Stream #0:2(eng): Audio: mp3 (.mp3 / 0x33706D2E

Re: [FFmpeg-user] apple-friendly timestamps with -c copy

2015-11-25 Thread Claudiu Rad



On 11/24/2015 3:21 PM, Claudiu Rad wrote:

hello warriors,

so maybe this is obvious for some but not for me.

i have some recordings produced by adobe's flash media server 
technologies, encoding originally done by their flash media live 
encoder in h264 + mp3/aac.
only some of them exhibit a bad playback behavior when trying to -c 
copy them to mp4/HLS.
bad playback means stuttering in some players like the fps went down, 
but on apple playing runtimes i really don't know the term or how to 
describe it, it's like the image jumps forward/backward a few frames a 
couple of times per second while the audio runs fine.


after searching a bit, i think what i am seeing is somewhat the same as 
described here: https://trac.ffmpeg.org/ticket/502 - jumping frames, 
frames not played in the right order


apple playing runtimes means: quicktime or safari on os x or iOS 
playing MP4 or HLS generated with ffmpeg.


from my initial investigations, the difference between a well behaving 
adobe recording and a badly behaving one is related to PTS/DTS values, 
visually i guess its like apple plays back based on DTS not PTS, 
please observe how the frames are constantly interlaced:

frame,pkt_pts_time,best_effort_timestamp_time,pkt_dts_time,pict_type
*frame,0.00,0.04,0.00,I*
frame,0.08,0.08,0.08,B
frame,0.12,0.12,0.12,B
frame,0.16,0.16,0.16,B
*frame,0.04,0.20,0.20,P*
frame,0.24,0.24,0.24,B
frame,0.28,0.28,0.28,B
frame,0.32,0.32,0.32,B
*frame,0.20,0.36,0.36,P*
frame,0.40,0.40,0.40,B
...


BTW, what does 'best_effort_timestamp_time' mean?



VLC plays both the original recording and ffmpeg outputs just fine.
if i reencode with ffmpeg everything is then perfect, PTS/DTS are 
aligned, but i want to avoid that.


what ideas do you have? how can i work on timestamps with ffmpeg and 
correct them via -c copy?
basically a reorganizing / re-timestamping so that we have 
monotonically increasing PTS i assume should be enough. is this possible?


to put it in another way: can ffmpeg reorder frames in the video stream 
based on some criteria, in my case based on PTS?
or does anybody know other tools that could do that? i would really try 
this to see if anything changes or re-timestamping is really necessary.




a bad recording sample is here: http://www.datafilehost.com/d/6a22a099

ffmpeg output:

ffmpeg -y -i in.f4f -c copy out.mp4
ffmpeg version N-76816-g188a1a1-static Copyright (c) 2000-2015 the 
FFmpeg developers

  built with gcc 4.7 (Debian 4.7.2-5)
  configuration: --prefix=/root/ffmpeg_build 
--extra-cflags='-I/root/ffmpeg_build/include -static' 
--extra-ldflags='-L/root/ffmpeg_build/lib -lm -static' 
--pkg-config-flags=--static --bindir=/root/bin --enable-gpl 
--enable-libfdk-aac --enable-libfreetype --enable-libmp3lame 
--enable-libopus --enable-libtheora --enable-libvorbis --enable-libvpx 
--enable-libx264 --enable-libx265 --enable-libxvid --enable-nonfree 
--extra-version=static --disable-debug --disable-shared 
--enable-static --extra-cflags=--static --disable-doc 
--enable-pthreads --enable-postproc --enable-runtime-cpudetect 
--enable-version3 --disable-devices

  libavutil  55.  9.100 / 55.  9.100
  libavcodec 57. 16.100 / 57. 16.100
  libavformat57. 19.100 / 57. 19.100
  libavdevice57.  0.100 / 57.  0.100
  libavfilter 6. 15.100 /  6. 15.100
  libswscale  4.  0.100 /  4.  0.100
  libswresample   2.  0.101 /  2.  0.101
  libpostproc54.  0.100 / 54.  0.100
[mov,mp4,m4a,3gp,3g2,mj2 @ 0x335fa40] multiple edit list entries, a/v 
desync might occur, patch welcome

Last message repeated 3 times
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'in.f4f':
  Metadata:
major_brand : f4v
minor_version   : 1
compatible_brands: isommp42m4v
creation_time   : 2015-01-04 18:02:32
  Duration: 00:05:24.98, start: 0.00, bitrate: 368 kb/s
Stream #0:0(eng): Data: none (amf0 / 0x30666D61), 0 kb/s (default)
Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: MainConcept
Stream #0:1(eng): Video: h264 (Main) (avc1 / 0x31637661), 
yuv420p(tv), 426x240 [SAR 1:1 DAR 71:40], 200 kb/s, 25 fps, 25 tbr, 1k 
tbn, 50 tbc (default)

Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: MainConcept
  encoder : AVC Coding
Stream #0:2(eng): Audio: mp3 (.mp3 / 0x33706D2E), 44100 Hz, 
stereo, s16p, 127 kb/s (default)

Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: MainConcept
Stream #0:3(eng): Data: none (rtmp / 0x706D7472), 338 kb/s
Metadata:
  creation_time   : 2015-01-04 18:02:32
  handler_name: Adobe Systems Inc. Hint Handler
[mp4 @ 0x34103e0] Codec for stream 0 does not use global headers but 
container format requires global headers
[mp4 @ 0x34103e0] Codec for stream 1 does not use global headers but 
container format requires global headers

Re: [FFmpeg-user] artefact when upload to youtube

2015-11-15 Thread Claudiu Rad



On 11/15/2015 10:22 PM, philippe.tor...@laposte.net wrote:

Hi,

I've used ffmpeg to make a movie from a sequence of png
But, even with x264 lossless ffmpeg, i get a video on youtube with noticable 
artefact (the ugly square of cos discrete)

(the .mp4 is clean before uploading : no artefact at all with quicktime or vlc)

I guess it's not a ffmpeg problem but may be someone will lead me to the 
solution.



seriously: what would you expect after youtube's lossy encoding?
solution: encode videos the way you want and host/publish them on the 
internet yourself.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] ffmpeg CL translation from Linux to Windows

2015-11-13 Thread Claudiu Rad


On 11/8/2015 8:25 PM, MrNice wrote:

Hi,

I need to compare ffmpeg behaviour between Linux and Windows.
I installed Virtualbox on my Fedora host and Win 8.1 as guest.
Now I need to translate the Linux CL
./ffmpeg -debug 1 -xerror -f pulse -ar 44100 -ac 2 -channel_layout
stereo -thread_queue_size 512 -i
alsa_input.pci-_00_14.2.analog-stereo -f v4l2 -ts mono2abs -channel
1 -video_size 720x576 -pix_fmt yuyv422 -thread_queue_size 512 -i
/dev/video0 -c:v libx264 -vf setfield=tff -preset slow -qp 0 -x264opts
tff=1 -aspect 4:3 -pix_fmt yuv422p -c:a pcm_s16le -channel_layout stereo
/Store3/Test/t_`date +%Y%m%d_%H%M`.mkv -aspect 4:3 -f sdl "Dazzle output".


so you are trying to compare the capture from a USB device but want to 
run windows inside a VM?
i surely wouldn't recommend that, there are many many things that may go 
wrong.
it's way better to install windows side-by-side with linux on a 
different drive/partition, make all updates, install all drivers and let 
him do his job without linux/VM layers.


and please.. when investigating and posting things, resume to simplest 
command line possible that reproduces the issue.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] ffmpeg CL translation from Linux to Windows

2015-11-13 Thread Claudiu Rad-Lohanel



On 11/13/2015 8:37 PM, MrNice wrote:


On 13/11/15 15:35, Claudiu Rad wrote:

On 11/8/2015 8:25 PM, MrNice wrote:

Hi,

I need to compare ffmpeg behaviour between Linux and Windows.
I installed Virtualbox on my Fedora host and Win 8.1 as guest.
Now I need to translate the Linux CL
./ffmpeg -debug 1 -xerror -f pulse -ar 44100 -ac 2 -channel_layout
stereo -thread_queue_size 512 -i
alsa_input.pci-_00_14.2.analog-stereo -f v4l2 -ts mono2abs -channel
1 -video_size 720x576 -pix_fmt yuyv422 -thread_queue_size 512 -i
/dev/video0 -c:v libx264 -vf setfield=tff -preset slow -qp 0 -x264opts
tff=1 -aspect 4:3 -pix_fmt yuv422p -c:a pcm_s16le -channel_layout stereo
/Store3/Test/t_`date +%Y%m%d_%H%M`.mkv -aspect 4:3 -f sdl "Dazzle
output".

so you are trying to compare the capture from a USB device but want to
run windows inside a VM?
i surely wouldn't recommend that, there are many many things that may go
wrong.
it's way better to install windows side-by-side with linux on a
different drive/partition, make all updates, install all drivers and let
him do his job without linux/VM layers.

and please.. when investigating and posting things, resume to simplest
command line possible that reproduces the issue.


[...]

Back to the point; Windows is only to check if the bug occurs as well. I
don't want as much as possible to use Win. Last time I used it was
NT/2000... and I don't have an available computer for it and don't want
to damage my running config. Anyway, first is to know if it's working,
so I need to test.


i don't know much about this and sorry for not following your entire 
topic and issue due to time constraints, but i still have some remarks 
that may help:


- your errors contain negative timestamps which is weird. did you try 
all timestamp related ffmpeg options like vsync, copyts, start_at_zero, 
etc. to check their effects?


- frankly if issue reproduces with basic command line, considering the 
fact you are an isolated case, i would judge that the issue is related 
to your equipment/software? that's why one of my suggestions were to try 
a completely different capture card. another option is indeed, try 
windows via directshow. as much as you don't like it, actually from my 
experience in some video/streaming areas its the best option available. 
make sure however you use latest windows OS and try first default 
drivers for your capture device and eventually then explicitly install 
latest one if applicable. i wouldn't be surprised if your issue is 
hardware+driver+OS. in my experience i've seen situations where for 
example: mac + os x + blackmagic card + latest os x drivers + streaming 
tool osx version => periodic crashes . mac + windows + blackmagic card + 
latest windows drivers + streaming tool windows versions => complete success


- if you try windows, please don't do it inside a VM. the data path from 
and to your capture device has much more failure points. to rule out 
windows, i strongly recommend you to try as i've said, clean, latest one 
(windows 10 now), completely updated


--
jazzman

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Transcoding Infrastructure of Youtube

2015-10-16 Thread Claudiu Rad



On 10/16/2015 5:10 PM, Israel Junior wrote:

Hi, guys

But this is valid until today? Both articles are 2011 and 2012.


why don't you ask them? how would we know?
as you saw in the original post, actually it was *observed* by behavior 
that they use FFMPEG code. there was no "Hey, I'm Google and I use 
FFMPEG to happily convert videos" anywhere.
reverse engineer their video outputs and figure it out like mike did it 
back in the days.


personally I expect them to have a mix of FFMPEG, other open source, 
proprietary, etc. code in their recipe that is probably constantly changing.


why does it matter?



Best regards
Israel

On Fri, Oct 16, 2015 at 8:45 AM, Carl Eugen Hoyos  wrote:


s00b4u .  gmail.com> writes:


I recently came to know that Youtube uses FFMPEG

But it is known for some time:
http://multimedia.cx/eggs/googles-youtube-uses-ffmpeg/

Carl Eugen

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] DVB subtitles there but not viewable

2015-10-14 Thread Claudiu Rad



On 9/26/2015 3:56 PM, Moritz Barsnick wrote:

On Sat, Sep 26, 2015 at 12:45:12 +, Carl Eugen Hoyos wrote:

Moritz Barsnick  gmx.net> writes:

My PVR (or call it STB) likes neither AC-3 nor
dvb_subtitles when muxed by ffmpeg into an MPEG-TS

That is because FFmpeg writes a (general) transport stream
while your stb expects a dvb stream (different standards).

There used to be a patch (I am not sure on which mailing
list, could have been avconv-devel or ffmpeg-devel) but
it was never applied iirc.

Thank you so much, Carl Eugen! Probably the most valuable hint I have
gotten in a long time.

The VU+ forums aren't of much help. Everybody seems to use "media
player" applications on the PVR anyway, but its MPEG-TS player is just
the best (except for subs supports). It also handles ffmpeg's MPEG-TS
just fine except for the named restrictions.

I'm off looking for this patch...


did you find it?

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Application provided invalid, non monotonically increasing dts to muxer in stream

2015-10-14 Thread Claudiu Rad



On 9/27/2015 1:00 PM, MrNice wrote:

./ffmpeg -debug 1 -xerror -f pulse -ar 44100 -ac 2 -channel_layout
stereo -thread_queue_size 512 -itsoffset -0.20 -i
alsa_input.pci-_00_14.2.analog-stereo -f v4l2 -ts mono2abs -channel
1 -video_size 720x576 -pix_fmt yuyv422 -thread_queue_size 512 -i
/dev/video0 -vf
drawbox=0:0:3:576:black@1:t=max,drawbox=718:0:3:576:black@1:t=max,drawbox=0:0:720:3:black@1:t=max,drawbox=0:564:720:12:black@1:t=max
-c:v ffv1 -level 3 -g 1 -aspect 4:3 -pix_fmt yuv422p -c:a pcm_s16le
/Store3/Test/t_`date +%Y%m%d_%H%M`.mkv -aspect 4:3 -f sdl "Dazzle output"

I get errors, ie: 8133 input video packets (around 5 minutes) and drop=4

[matroska @ 0x3910d80] Writing block at offset 2449025254, size 53920,
pts 325664, dts 325664, duration 306, keyframe 1
[matroska @ 0x3910d80] end duration = 325970
[matroska @ 0x3910d80] stream 0 end duration = 325600
[matroska @ 0x3910d80] stream 1 end duration = 325970
frame= 8129 fps= 25 q=-0.0 Lq=-0.0 size= 2391845kB time=00:05:25.76
bitrate=60146.9kbits/s dup=0 drop=4
video:8923049kB audio:56154kB subtitle:0kB other streams:0kB global
headers:0kB muxing overhead: unknown
Input file #0 (alsa_input.pci-_00_14.2.analog-stereo):
   Input stream #0:0 (audio): 1173 packets read (57501184 bytes); 1173
frames decoded (14375296 samples);
   Total: 1173 packets (57501184 bytes) demuxed
Input file #1 (/dev/video0):
   Input stream #1:0 (video): 8133 packets read (6745835520 bytes); 8133
frames decoded;
   Total: 8133 packets (6745835520 bytes) demuxed
Output file #0 (/Store3/Test/t_20150927_0925.mkv):
   Output stream #0:0 (video): 8129 frames encoded; 8129 packets muxed
(2391366165 bytes);
   Output stream #0:1 (audio): 1173 frames encoded (14375296 samples);
1173 packets muxed (57501184 bytes);
   Total: 9302 packets (2448867349 bytes) muxed
Output file #1 (Dazzle output):
   Output stream #1:0 (video): 8133 frames encoded; 8133 packets muxed
(6745835520 bytes);
   Total: 8133 packets (6745835520 bytes) muxed
9306 frames successfully decoded, 0 decoding errors
[AVIOContext @ 0x391da40] Statistics: 48794 seeks, 111065 writeouts
Conversion failed!


what's your CPU? how's the CPU usage during encoding?
did you try another capture card?

not very familiar with capturing with capture cards under linux, but for 
sure if you need help you should try reproduce with a minimal amount of 
parameters. ./ffmpeg -debug 1 -xerror -f pulse -ar 44100 -ac 2 
-channel_layout stereo -thread_queue_size 512 -itsoffset -0.20 ... and I 
am already lost.


remove everything possible even if it is not exactly what you want but 
first we should see if it reproduces with the simplest command like

ffmpeg -i  -i  out.mkv
of course, add parameters that are *really* required for input devices.
and then, try to add an -vf "scale=120x90" for the output to make sure 
we encode something small and we don't hit resource limits.


and if this works, work your way from there. also try another capture 
card. you should be able to isolate the problem.


and then come back for help.

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Screen-casting - RTSP - VMIX

2015-09-21 Thread Claudiu Rad



On 8/22/2015 2:36 AM, Bilarus T wrote:

Hello FFmpeg community

I'm trying over 2 months to successfully use FFmpeg to stream locally my
desktop to VMIX but without success and it is getting me insane


and why wouldn't you use their desktop capture utility who is probably 
better optimized for the job?




I'm using screen-capture-recorder to capture at 60fps in 1080p


seriously? you need huge CPU power in order to do that resolution and 
framerate.
especially if you don't select an -preset veryfast or something (like I 
see below).



I have searched the whole web and can't find anything near to my problem.

my current try is as follow :


ffmpeg -re -rtbufsize 1500M -f dshow -i

video="screen-capture-recorder":audio="
virtual-audio-capturer" -r 60 -vcodec libx264 -threads 4 -tune zerolatency
-b 35
00K -f rtsp -rtsp_transport tcp rtsp://109.68.150.212:8550/


And I'm getting this error continuously :

*[dshow @ 03020c60] real-time buffer [screen-capture-recorder]
[video inp**ut] too full or near too full (92% of size: 15
[rtbufsize parameter])! f**rame dropped!*

Could you please tell me what I'm doing wrong? Also, is it necessary to use
FFServer ? I'm really new into this but I'm starting to like it very much,
really interesting processes and open to learn from you


you should really look at your task manager from time to time.
it's a wonder how many stories can it tell.. especially during encoding.



Greetings, Bilarus
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Copy-capturing h264 input while force-rewriting the PTS

2015-08-03 Thread Claudiu Rad



On 7/25/2015 2:54 PM, Carl Eugen Hoyos wrote:

Peter Rabbitson rabbit+list at rabbit.us writes:


I am hoping that ffmpeg can somehow help me with a
workaround.

You can try the input option -r, unfortunately
it does not work for many use-cases.

FFmpeg is not very good with h264 timestamps...


who is?
just wondering if there are any recommendations in the tool-chain as i 
was also investigating various 'glitches' (not necessary ffmpeg related)..


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Capturing a frame from video and resizing it...issue.

2015-05-24 Thread Claudiu Rad

On 5/24/2015 8:40 PM, Dani A wrote:

I am using the below and it is not working:
ffmpeg -i apple.mp4 -ss 00:00:4 -vframes 1 scale=241:164 apple2.png

Error:
[NULL @ 0xc217720] Unable to find a suitable output format for 'scale=320:240'
scale=320:240: Invalid argument



you definitely have an incorrect command line syntax. the scaling 
details should be preceded by the -vf switch (as this is a video 
filter), otherwise ffmpeg would consider that argument as the output file.

the error message really gave you the hint to the problem.

ffmpeg -i apple.mp4 -ss 00:00:4 -vframes 1 *-vf* scale=241:164 apple2.png

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Increasing the decoding speed of yuv444p h.264 files

2015-05-18 Thread Claudiu Rad


On 5/18/2015 7:22 PM, Yan Li wrote:

I've done some more tests. Input file src.flv is in yuv444p with 48
fps. I use the following commands to generate two lossless test files:
1: ffmpeg -i src.flv -c:v libx264 -qp 0 -preset ultrafast -an yuv444p.mkv
2: ffmpeg -i src.flv -c:v libx264 -qp 0 -preset ultrafast -pix_fmt
yuv420p -an yuv420p.mkv

Then I test the decoding speed using:
time ffmpeg -i yuv444p.mkv -f rawvideo -an - /dev/null

  - yuv444p.mkv (496 Mb/s): decoded at 55 fps
  - yuv420p.mkv (336 Mb/s): decoded at 92 fps

(I/O is not the bottleneck here. Four threads are used.)




sorry to question, but:
are you really sure about this? those are really high bitrates and it 
appears to be a direct link between bitrate and decoding speed: 496 x 55 
~= 336 x 92 (by a 10% margin).
I don't know what's the drive access pattern in this case but if seeks 
just a bit, you have a problem.

as a test, I would encode at much smaller bitrates and then compare the fps.
of course, you can measure the disk I/O load with appropriate tools 
during decoding.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Faster way of cropping video?

2015-03-18 Thread Claudiu Rad

On 3/18/2015 6:19 PM, JP Edwards wrote:

Hi,
I've been cropping a number of mp4 videos with ffmpeg but I was just wondering 
whether there is a way of doing it that doesn't involve re-encoding.


no, this is not technically possible for obvious reasons: you need to 
decode the frame, crop and re-encode the completely new image. due to 
the very nature of video encoding, you cannot remove portions of an 
image without re-encoding the rest as pixels in an image are strongly 
related.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] RTMP output - Past duration too large

2015-02-23 Thread Claudiu Rad


On 2/23/2015 4:26 PM, Matt Conway wrote:

I'm trying to use ffmpeg to livestream to an online service such as ustream.

This is the command I am using -

ffmpeg -i rtsp://RTSPStreamUrl -an -f avi rtmp://RTMPStreamUrl


-f avi is wrong.
use -f flv.


Here is a screenshot of the output.


firstly, for any other issues, you *must* always provide full 
console/error output of your command by copy/paste here.

sending a screenshot is not very helpful.

secondly, that's *not* the output of your above command. you use a 
different command in the picture.
if you want help, please help people on this mailing list by being 
consistent.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] MPEG-2 CBR

2015-01-15 Thread Claudiu Rad-Lohanel


On 1/15/2015 1:30 PM, Janez Miklavcic wrote:

f:/ffmpeg/bin/ffmpeg.exe -f dshow -video_size 720x576 -framerate 25
-pixel_format bgr24 -i video=VidBlaster VVD -mpegts_service_id 0x002
-metadata service_name=POLANC TV INFO -metadata service_provider=SVISLAR
telekom d.o.o. -vcodec mpeg2video -b:v 2000k -minrate:v 2000k -maxrate:v
2000k -bufsize 20k -q 3 -s: 720x576 -r 25 -g 50 -f mpegts
-mpegts_pmt_start_pid 0x3E8 -mpegts_start_pid 0x3E9 -muxrate 20M udp://
232.8.8.8:55002?pkt_size=188


what's this? what would you expect it to do if you tell it to go at 20Mbit?

-muxrate 20M




Although bitrate is set to 2Mbit/s it jumps to 20 Mbit/s.

Thnaks,
Janez

2015-01-15 12:03 GMT+01:00 Roger Pack rogerdpa...@gmail.com:


On 1/14/15, Janez Miklavcic svisla...@gmail.com wrote:

Dear All,

I've been trying to achive constant video bitrate for mpeg-2 with

different

settings of ffmpeg (windows) but no success.
The source was dshow.
I've been testing video bitrate with TS reader.
Can you tell me if video CBR in MPEG-2 is possible or not and if yes can
you send me the settings.

uncut command line and console output of failing example please?
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


--
jazzman

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Stretch

2015-01-13 Thread Claudiu Rad


On 1/14/2015 6:47 AM, Vladimir Bilichenko wrote:

Hi. I have a question about  video stretching. I have a video(
https://www.dropbox.com/sh/5mw6hvgw170ov8b/AADABGroGqbSg_a9INZiesrQa?dl=0)
width = 840, height = 922. I need to change the size of the video to
1920x1080 it must be stretched. Output file should be .mp4. Can some one
help me with that?


 ffmpeg -i input_file -s 1920x1080 other_encoding_parameters 
output_name.mp4 ?


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user



Re: [FFmpeg-user] Stretch

2015-01-13 Thread Claudiu Rad-Lohanel


On 1/14/2015 9:25 AM, Vladimir Bilichenko wrote:

Hi. I have a question about  video stretching. I have a video(
https://www.dropbox.com/sh/5mw6hvgw170ov8b/AADABGroGqbSg_a9INZiesrQa?dl=0)
width = 840, height = 922. I need to change the size of the video to
1920x1080 it must be stretched. Output file should be .mp4. Can some one
help me with that?


Thats not working for such input resolution width = 840, height = 922.


yes, it works, but you probably also want to set SAR 1:1:

ffmpeg -i input_file -vf 'scale=1920:1080,setsar=1' 
other_encoding_parameters output_name.mp4



ffmpeg -i input_file -s 1920x1080 other_encoding_parameters 
output_name.mp4 ?


--
jazzman

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Codec same as opposed to copy?

2014-11-20 Thread Claudiu Rad


On 11/20/2014 11:47 AM, Carl Eugen Hoyos wrote:

My source's audio codec will typically be either
pcm_s16le or pcm_s24le, but ideally I don't want to care
and want to say use the same codec as the source.

This is not implemented, patch (or enhancement request)
welcome.


without trying to hijack the thread, sorry if i force it a bit but it is 
quite related:


is there a possibility (or is anything foreseen) in ffmpeg to 
*conditionally* copy the stream?
an example would be that in a batch process, i would only want to 
convert audio to aac if it is not already aac.
are there any workarounds on this other than first ffmpeg -i source, 
parse the output, try to detect what you have there and if it is not 
what you want convert, otherwise copy?
this workaround is reasonable for some sources, but for others where 
seeking is problematic or a large portion of the file must be read for 
detection it raises many problems.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] For HLS, playlist.m3u8 file skips last segment entry

2014-09-30 Thread Claudiu Rad


On 9/30/2014 4:11 PM, ajay parashar wrote:

#EXTM3U
#EXT-X-VERSION:3
#EXT-X-MEDIA-SEQUENCE:0
#EXT-X-ALLOW-CACHE:YES
#EXT-X-TARGETDURATION:17
#EXTINF:15.015000,
out000.ts
#EXTINF:8.341667,
out001.ts
#EXTINF:8.341667,
out002.ts
#EXTINF:8.341667,
out003.ts
#EXTINF:16.68,
out004.ts



You should add #EXT-X-ENDLIST for a VOD hls.

***
Should I add ENDLIST tag manually or ffmpeg should do this for user while 
generating playlist.m3u8 file.



Actually, #EXT-X-ENDLIST is not added because you have specified 
-segment_list_flags +live in your ffmpeg command.
If you want to generate a live HLS stream, use +live flag and the tag 
will not be added (like in your example), if you want to generate a VOD 
stream, remove the flag and the tag will be added.


However this won't fix the issue you are reporting that out005.ts 
isn't added to the playlist and I can't help you with that, sorry.

Just wondering: are you sure that out005.ts contains useful data?

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


[FFmpeg-user] remove mp4 edit lists

2014-09-29 Thread Claudiu Rad

hello all,

how can ffmpeg be used (or can be used?) to remove edit lists from an 
mp4 file?
even if they are there with a purpose, i just don't care about them or 
need them.


--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] AVStream.codec.time_base deprecated when using -f ssegment

2014-09-17 Thread Claudiu Rad

On 9/17/2014 10:41 AM, Carl Eugen Hoyos wrote:


i am trying to generate a HLS stream from a
standard MP4 file. the muxer generates a pair
of warnings for each output .ts file.


This is ticket #3741 iirc.


now true, but mainly the ticket wasn't about this. i didn't check it lately.

 shouldn't this be fixed?


All bugs should be fixed but imo the currently
open regressions (wrt to the output files) are
much more important than spam on the console
(but see above).


my main question here is if this can be safely ignored. i only quickly 
checked the output in a few cases and it seemed fine but how sure can i be?


this is important because i am preparing to convert a massive amount of 
data (~5TB and ~10.000hours) to HLS and i can't just check everything if 
it is ok, i will only scan the ffmpeg logs afterwards.
also the originals will be deleted in short time so you can imagine the 
harm that can be done if something is wrong and it gets discovered too late.


so, can someone confirm that this warning can really be safely ignored?


Please remember that time is the only limiting
factor in FFmpeg development and please
continue to report all issues!


sure, will do.

--
Claudiu
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] FFMPEG RTSP Streaming

2014-09-11 Thread Claudiu Rad

On 9/11/2014 10:43 AM, Imran Husain wrote:


Q-3 What can be the input for ffserver? Can we capture soundcard as an
input for ffserver?(because of feeds(2-step process for streaming ) it
increase delay).



you should have everything you need at 
https://trac.ffmpeg.org/wiki/Streaming%20media%20with%20ffserver


study that and you'll know how to combine ffmpeg with ffserver and it 
should probably do the job you need.
ffmpeg alone isn't for streaming. ffserver is the streamer with data fed 
by ffmpeg.


--
Claudiu
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] can ffmpeg stream out http video ?

2014-09-08 Thread Claudiu Rad

On 9/8/2014 11:53 AM, Ajay Parashar wrote:


My expectation is that ffmpeg should start streaming the data.
On other end if I send request from vlc or ffplay then this player should play 
the streaming data.



I don't think so. This is what ffserver is for.

--
Claudiu
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Generate .ts file parallel, resume option, offset HLS

2014-08-25 Thread Claudiu Rad

On 8/25/2014 1:30 PM, Diogo Serrano wrote:


Basicaly i want to create a single .ts giving in the arguments the range of
time, after that i need to join all .ts files and generate the m3u8
playlist.

The ffmpeg command list bellow are a prove of concept to resolve my
problem, but when a generate the m3u8 playlist the video is not fluid,
because the cut is not very precise


fmpeg -ss 0.000 -i /home/USER/vagrant/files/rod.mp4 -t 10.000 -c:v copy

-bsf h264_mp4toannexb -flags -global_header -map 0 -f segment -segment_time
10 -segment_start_number 1 -segment_list 0001_test.m3u8 -segment_format
mpegts 1stream%05d.ts

...
.

(the list continue depending the time of the video)


i think that in order for this to work you should have keyframes in the 
input video at each 10s exactly if you use -c:v copy.

cut should be done at keyframe.

--
Claudiu
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Strange CPU usage when running multiple ffmpeg instances

2014-08-25 Thread Claudiu Rad

On 8/25/2014 1:47 PM, Tal Maoz wrote:

When running just one instance of ffmpeg, it uses about 20-25% CPU. I then
continue to run a few more simultaneous
instances doing the exact same thing. When I have 4 instances, I see that
each instance is now using 30-35% CPU.
When I get to 7 instances, each one is using 40-45% CPU. Finally, when I
get to 9 instances, each instance uses 55-60% CPU!
As you will see below, my ffmpeg is compiled with vaapi support, but I've
already tried running with -hwaccel none
and with -threads 1 and I still get the same results.

One would expect the CPU usage per instance to remain the same, right? am I
missing anything here?


well, not really.
how do you measure the cpu usage?
i mean you should consider with growing number of active processes a 
significant increase in the process/thread switching overhead.
still, i think this shouldn't make such differences, but can't be 
completely ignored.
additionally, by using the pipes, network, etc, i wonder if you don't 
trigger any system I/O that piles up.


i'm not an expert but it wouldn't make sense for ffmpeg processes to be 
somehow inter-dependent. and that's why i don't think this is an ffmpeg 
issue, but you have to search for answers in the resources ffmpeg is using.


--
Claudiu
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] Audio channel mapping of stereo channel without re-encode

2014-08-21 Thread Claudiu Rad-Lohanel


On 8/21/2014 5:30 PM, Carl Eugen Hoyos wrote:

Hanno Klamke Hanno.Klamke at streamlab.net writes:


I would like to transcode a video into several
outputs. From the source audio I would like to
take either only the left or the right channel
into my outputs. While only transcoding the
video and copy the audio.


I also confronted something similar a while ago.


This cannot work.
(And even if you know nothing about audio encoding,
you should be able to imagine why it cannot work for
codecs that actually do compress in a useful way.)


Indeed, you are right. But from what I know so far, this is because the 
level of data access that we have now is either at the stream level 
(audio, video, subtitles, etc) after demuxing, either somehow at the 
uncompressed frame level after decoding.
However, this doesn't change the fact that it would be really nice if we 
could have an intermediate access level in audio streams case (and I 
think this is the only one case where one stream actually packs multiple 
'substreams' at least in abstraction) and we could really remap channels 
as we like without reencoding.
But I assume that this would be a nightmare because it must be 
implemented at audio codec level, thus, for every codec alone..


However, it would be something nice for the future, would certainly 
optimize things.




Carl Eugen

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


--
jazzman

attachment: jazzman.vcf___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


Re: [FFmpeg-user] -threads option has no effect

2014-08-12 Thread Claudiu Rad-Lohanel


On 8/12/2014 1:56 PM, Rohit Talwar wrote:

Hi

Thanks for looking into my query. I have a main java program within which I
run ffmpeg (using exec). Often there comes a scenario wherein my program
needs to create 4+ different instances of ffmpeg program for converting
files into different formats. When this happens the cpu gets 'too busy'
running the ffmpeg instances which affects the performance of my java
program.
I think lowering the priority(using nice or start /LOW )  of the ffmpeg
process might be a possible strategy to solve this, but would be glad if
you can help me point towards a platform independent solution.



On Tue, Aug 12, 2014 at 3:39 PM, James Darnley james.darn...@gmail.com
wrote:


On 2014-08-12 11:59, Rohit Talwar wrote:

Hi

I ran the command - ffmpeg -threads number of threads -i my file.avi

Perhaps you should not be using it as an input option.


or to expand this a bit for regular people that don't understand that 
order matters:
try to put threads option AFTER the input file, because most options 
apply to the next input/output file in the command line, like this:


ffmpeg -i my file.avi -threads number of threads ... output

don't know if it would do the job for you but it should.
also, lowering process priority and letting ffmpeg use all available 
resources would be my recommendation for maximum performance in all cases.





target.mp4 hoping it would not hog my cpu and consume only one core of

my

machine. But it was still taking up all of my cpu. I ran the following
experiments to confirm my suspicion that including the -threads option

has

no effect on cpu usage.

Why do you not want it to use as much CPU as it can?  If this is a
desktop that you are using at the same time you should lower the
priority of the ffmpeg process.



___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user






--
jazzman

attachment: jazzman.vcf___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


[FFmpeg-user] live transcoding alignment

2014-07-28 Thread Claudiu Rad

hello all,

using ffmpeg i want to live transcode an input live stream into multiple 
variants and push all of them (including the original) to the client. 
everything works all right except for one thing: i want all keyframes to 
be properly aligned between streams but it seems that over time, they 
get misaligned which is probably as expected because it would make sense 
for ffmpeg to treat each output and do its keyframe generation quite 
independently. however, the first question:


1. how can i enforce keyframe alignment between output transcoded 
(reencoded) streams in ffmpeg? i don't need P/B or other frame types to 
be aligned, but I-frames should be exactly on the same frame numbers on 
all streams


to extend this even further:

2. how can i enforce keyframe alignment also with input which i would 
like to simply -c copy ? this means that reencoded outputs should have 
the exactly same keyframe placements as the input, thus, internal codec 
heuristics should be disabled on this matter.


i am talking about a h264/x264 input/output.

thanks much.

--
Claudiu

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user


[FFmpeg-user] copy input i-frames structure to output

2014-07-14 Thread Claudiu Rad-Lohanel

hello,

i need to do transcoding of an mp4 video and i want to keep the i-frame 
structure the same as in the original video.
i've searched info on this but couldn't find out if it is even possible 
with ffmpeg although my wild guess is that it should be.


furthermore, to complicate things, ffmpeg should be just a simple box in 
a processing chain and pre-scanning the input is not acceptable.
basically, i would like to somehow tell ffmpeg during encoding that for 
each video frame that it encodes, first check if it was a keyframe in 
the original video. if yes, make it also in the output, if no, don't do it.


any ideas?

thanks!

--
jazzman

attachment: jazzman.vcf___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
http://ffmpeg.org/mailman/listinfo/ffmpeg-user