Re: [FFmpeg-user] Replace part of the audio

2023-01-22 Thread Reino Wijnsma
Hello Michael,

On 2023-01-22T18:50:20+0100, Michael Koch  wrote:
> This command line works with asendcmd and astreamselect:
>
> ffmpeg -i audio1.wav -i audio2.wav -lavfi asendcmd="4 astreamselect map 
> 1",asendcmd="6 astreamselect map 0",astreamselect=map=0 -y out.wav
>
>
> However with amix filter I have no idea what's the syntax for the string 
> inside the string. It doesn't work.
>
> ffmpeg -i audio1.wav -i audio2.wav -lavfi asendcmd="4 amix weights '0 
> 1'",amix=weights='1 0' -y out.wav

You've got your quotes all wrong. Always surround the complete filter-chain 
with double quotes and use single quotes for the individual filters.

ffmpeg -i audio1.wav -i audio2.wav -lavfi "asendcmd='4 astreamselect map 
1',asendcmd='6 astreamselect map 0',astreamselect=map=0" -y out.wav

ffmpeg -i audio1.wav -i audio2.wav -lavfi "asendcmd='4 amix weights '\\\'0 
1\\\',amix=weights='1 0'" -y out.wav

See: http://ffmpeg.org/ffmpeg-all.html#Quoting-and-escaping and 
http://ffmpeg.org/ffmpeg-all.html#Notes-on-filtergraph-escaping.

On 2023-01-22T19:21:53+0100, Paul B Mahol  wrote:
> there is way to escape stuff

Can't you for once make a useful post?!

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Piping from FFmpeg to FFplay

2022-11-13 Thread Reino Wijnsma
On 2022-11-13T20:45:42+0100, Michael Koch  wrote:
> ffmpeg -f lavfi -i testsrc2 -f nut | ffplay -

Btw, I hope you know that ffplay can do this too:

ffplay -f lavfi testsrc2

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Piping from FFmpeg to FFplay

2022-11-13 Thread Reino Wijnsma
On 2022-11-13T22:18:15+0100, Michael Koch  wrote:
> Is the "-" at the end an (undocumented) option of FFplay, or is it a batch 
> file operator?

The first, I guess.
I've found 'opusenc' (Opus command-line encoder) to print:

   Usage: opusenc [options] input_file output_file.opus

   [...]

   input_file can be:
 filename.wav  file
 - stdin

   output_file can be:
 filename.opus compressed file
 - stdout

   [...]

But I also have lots of other binaries where the help-section doesn't mention 
the dash or stdin.
So I guess the developers assume it's common knowledge.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Piping from FFmpeg to FFplay

2022-11-13 Thread Reino Wijnsma
Hello Michael,

On 2022-11-13T20:45:42+0100, Michael Koch  wrote:
> ffmpeg -f lavfi -i testsrc2 -f nut | ffplay -
>
> This command line works fine and I have used it many times.

It shouldn't, because you forgot a "-" after "-f nut".

> But I don't know what's the meaning of the - character after ffplay.

Input or output. An url or a file-path. And in this case; stdout and stdin. 
FFmpeg's stdout is piped to FFplay's stdin.
I'm surprised you didn't know.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] combining audio and video

2022-11-06 Thread Reino Wijnsma
On 2022-11-06T12:50:16+0100, owen s  wrote:
> Is it possible to have two urls, one streaming audio and one for video;
> using ffmpeg to combine these streams and just playing them as one without
> saving a file?
Sure.

ffmpeg -i "" -i "" -c copy -f nut - | ffplay -autoexit -
ffmpeg -i "" -i "" -c copy -f nut - | mpc-hc - /close

or of course:

mpc-hc "" /dub "" /close

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] ffmpeg MP4/x264 output colours change when input source is different resolution (bug?)

2022-09-25 Thread Reino Wijnsma
On 2022-09-21T17:10:21+0200, Dan  wrote:
> Thanks for both of those ffmpeg CLI lines! They do actually work for me (in 
> MPC and Chrome).
> Would you consider both of the lines safe to use?
These commands, after careful observation, are the ones that work for me to 
closely match the original colours.
I'm no expert, nor am I an FFmpeg-developer, so someone else would have to 
answer whether it's "safe" to use.
I guess it is though.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] ffmpeg MP4/x264 output colours change when input source is different resolution (bug?)

2022-09-18 Thread Reino Wijnsma
On 2022-09-14T11:21:58+0200, Dan  wrote:
> The double height version is darker than it should be. I've checked the 
> resulting video in both Media Player Classic and Chrome.
>
> If you check the dark green colour on the original PNG images, using an eye 
> dropper tool, they're both R=25,G=74,B=15. However, if you check the same 
> colour on the output MP4s, the colour matches on the original PNG, but not 
> the doubleHeight version, which is R=22,G=66,B=12.
Long time ago since I last dealt with this 
. It's all about BT.601 
(≤576p) v.s BT.709 (>576p), so for this conversion from RGB to YUV you'll also 
need a colourmatrix conversion.
I'm no expert, but these are my observations:

ffplay -f lavfi "color=0x194a0f:s=400x576,format=rgb24"   --> 
R=25,G=74,B=15 (0x194a0f)
ffplay -f lavfi "color=0x194a0f:s=400x576[,format=yuv420p]"   --> 
R=25,G=74,B=14 (0x194a0e)
ffplay -f lavfi "color=0x194a0f:s=400x576,format=yuv444p" --> 
R=25,G=74,B=14 (0x194a0e)

ffplay -f lavfi "color=0x19be0f:s=400x576,format=rgb24"   --> 
R=25,G=190,B=15 (0x19be0f)
ffplay -f lavfi "color=0x19be0f:s=400x576[,format=yuv420p]"   --> 
R=25,G=190,B=16 (0x19be10)
ffplay -f lavfi "color=0x19be0f:s=400x576,format=yuv444p" --> 
R=25,G=190,B=16 (0x19be10)

I know too little about this for an explanation on why Blue is off by 1.

ffplay -f lavfi "color=0x194a0f:s=400x578,format=rgb24" 
   --> R=25,G=74,B=15 (0x194a0f)
ffplay -f lavfi "color=0x194a0f:s=400x578[,format=yuv420p]" 
   --> R=22,G=65,B=12 (0x16410c)
ffplay -f lavfi "color=0x194a0f:s=400x578,format=yuv444p"   
   --> R=22,G=65,B=12 (0x16410c)
ffplay -f lavfi 
"color=0x194a0f:s=400x578[,format=yuv420p],scale=out_color_matrix=bt709"   --> 
R=23,G=72,B=11 (0x17480b)
ffplay -f lavfi 
"color=0x194a0f:s=400x578,format=yuv444p,scale=out_color_matrix=bt709" --> 
R=25,G=74,B=15 (0x194a0f)

ffplay -f lavfi "color=0x19be0f:s=400x578,format=rgb24" 
   --> R=25,G=190,B=15 (0x19be0f)
ffplay -f lavfi "color=0x19be0f:s=400x578[,format=yuv420p]" 
   --> R=14,G=164,B=11 (0x0ea40b)
ffplay -f lavfi "color=0x19be0f:s=400x578,format=yuv444p"   
   --> R=14,G=164,B=11 (0x0ea40b)
ffplay -f lavfi 
"color=0x19be0f:s=400x578[,format=yuv420p],scale=out_color_matrix=bt709"   --> 
R=23,G=189,B=14 (0x17bd0e)
ffplay -f lavfi 
"color=0x19be0f:s=400x578,format=yuv444p,scale=out_color_matrix=bt709" --> 
R=26,G=189,B=15 (0x1abd0f)

It's not exactly the same colour, but it's the closest you'll get.
I've also tried zscale, but with ffplay it fails with the following 
error-message:

ffplay -f lavfi "color=0x194a0f:s=400x578,format=yuv444p,zscale=m=709"
[Parsed_zscale_2 @ 0359d6c0] code 3074: no path between colorspaces

With FFmpeg, creating a temp-file, zscale does work:

ffmpeg -i PLdsb.png -t 5 -vf "zscale=m=709" -c:v libx264 -crf 0 
PLdsb_zscale-bt709.mp4
ffplay PLdsb_zscale-bt709.mp4   --> R=24,G=74,B=14 (0x184a0e) | R=25,G=190,B=14 
(0x19be0e)

Again, not exactly the same colour, but very close.

On 2022-09-15T13:07:08+0200, Michael Koch  wrote:
> Please try this, for me it works with VLC player, the color is exactly the 
> same:
>
> ffmpeg -f lavfi -i color=0x19be0f:s=400x576 -colorspace bt709 
> -color_primaries bt709 -color_trc bt709 -crf 0 -vcodec libx264 -t 5 -y 
> out1.mp4
> ffmpeg -f lavfi -i color=0x19be0f:s=400x720 -colorspace bt709 
> -color_primaries bt709 -color_trc bt709 -crf 0 -vcodec libx264 -t 5 -y 
> out2.mp4
These are all VUI (Video Usability Information) options and, unlike the 
colourmatrix conversions above, don't have a direct impact on the video-image 
itself.
It's kind of like meta-data. Your media player needs to support it to display 
the correct colours. MediaInfo can show you this, like for instance:

Color range: Full
Matrix coefficients: BT.709

ffmpeg -i PLdsb.png -t 5 -color_range tv -colorspace bt470bg -c:v libx264 -crf 
0 PLdsb_vui-tv601.mp4
ffplay PLdsb_vui-tv601.mp4   --> R=22,G=65,B=12 (0x16410c) | R=14,G=164,B=11 
(0x0ea40b)
mpc-hc PLdsb_vui-tv601.mp4   --> R=25,G=74,B=14 (0x194a0e) | R=25,G=190,B=16 
(0x19be10)

If you insist on using these VUI options, then in contrast to what you might 
expect (PC,BT.709) it's actually TV,BT.601 that has the expected result.
Welcome to the wonderful world of video conversions.

On 2022-09-15T11:40:10+0200, Paul B Mahol  wrote:
> Looks like your knowledge is very limited, incorrect and completely full of 
> nonsense. 
On 2022-09-16T15:38:51+0200, Paul B Mahol  wrote:
> It is evident that your knowledge is exactly 0. 
On 2022-09-14T17:01:39+0200, Paul B Mahol  wrote:
> Next time be more constructive and try it before pointlesly commenting here 
> in so bold and arrogant fashion. 
Do you have any idea how rude and condescending your posts are? Disgraceful! 
Especially 

Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-18 Thread Reino Wijnsma
On 2022-04-17T00:45:14+0200, Bo Berglund  wrote:
> One can see an item 'exp=1650232874', where the number seems to be seconds 
> since
> 1970. That is the base of timekeeping on Linux, right?

That's right. See https://en.wikipedia.org/wiki/Unix_time.

$ date -d @1650232874 -u '+%FT%T%:z'
2022-04-17T22:01:14+00:00

$ xidel -se '1650232874 * duration("PT1S") + dateTime("1970-01-01T00:00:00Z")'
2022-04-17T22:01:14Z

On 2022-04-18T07:28:23+0200, Bo Berglund  wrote:
> 2) Whenever it fails and I read the email *I manually start FireFox and visit 
> the
> page with F12 so I can find the new m3u8 URL*. It is then saved to a file 
> used to
> read the URL from the download script.
>
> [...]
>
> But it would be much better if the Firefox procedure could be replaced by an
> automatic extractor like I have for other sites than this:
>
> http://www.freeintertv.com/view/id-2308
>
> So far no luck in using curl or xidel or the like to find the currently active
> m3u8 URL for this site.

Did you totally miss my latest e-mail? Why do I even bother.

On 2022-04-18T12:53:19+0200, stefano roveda  wrote:
> Dear reino, i found the thread very interesting i don see any reason fir
> your comment in that case
> Anyway thank you for taking care.

I'm sorry, but I don't understand what you're trying to say.
What comment in what case? Taking care of what?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-16 Thread Reino Wijnsma
On 2022-04-13T01:42:39+0200, Reino Wijnsma  wrote:
> ...and I don't understand how something like 
> "http://188.17.143.39/hls/CH_R04_DOMASHNY/variant.m3u8?version=2; would 
> translate to...
>
> On 2022-04-12T17:54:32+0200, Bo Berglund  wrote:
>> https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/hdntl=exp=1649865178~acl=%2f*~data=hdntl~hmac=5480897632ddf98d23bf870098333af5055752c54d28764b8c894711086d1266/VIDEO_1_4596000.m3u8

Well,...

On 2022-04-13T23:49:26+0200, Reino Wijnsma  wrote:
> Alternatively I could have a look on a much newer system of one of my family 
> members

...I've found out that 
"http://188.17.143.39/hls/CH_R04_DOMASHNY/variant.m3u8?version=2; (from the 
iframe's HTML-source) has nothing to do with the akamaized-url. Very strange.

In the network-traffic I've found 2 different JSON api endpoints that house the 
bare m3u8-url:

$ xidel -s 
"https://api-leap.nbcsports.com/feeds/assets/2007524?application=NBCNews=nbc-player=desktop;
 \
  -e '$json/(videoSources)()/cdnSources/(primary)()/sourceUrl'
https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/master.m3u8

$ xidel -s "https://stream.nbcnews.com/data/live_sources_2007524.json; \
  -e '$json/(videoSources)()/sourceUrl' \
  -e '$json/(videoSources)()/cdnSources/(primary)()/url'
https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/master.m3u8
https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/master.m3u8

I have no idea where the identifier 2007524 is coming from though! It's not in 
the HTML-source of "http://www.freeintertv.com/view/id-2308; or its iframe. I 
couldn't find it anywhere else. It must be the program-id of the NBC livestream.

This HLS manifest doesn't work just yet:

$ xidel -s "https://stream.nbcnews.com/data/live_sources_2007524.json; \
  -f '{"url":$json/(videoSources)()/sourceUrl,"error-handling":"xxx=accept"}' \
  -e '$headers[1]'
HTTP/1.1 403 Forbidden

The m3u8-url needs to be sent to "https://tokens.playmakerservices.com; in a 
POST-request:

$ xidel -s "https://stream.nbcnews.com/data/live_sources_2007524.json; -e 
'$json/(videoSources)()/{"requestorId":"nbcnews","pid":pid,"application":"NBCSports","version":"v1","platform":"desktop","token":"","resourceId":"","inPath":"false","authenticationType":"unauth","cdn":"akamai","url":sourceUrl}'
{
  "requestorId": "nbcnews",
  "pid": "2007524",
  "application": "NBCSports",
  "version": "v1",
  "platform": "desktop",
  "token": "",
  "resourceId": "",
  "inPath": "false",
  "authenticationType": "unauth",
  "cdn": "akamai",
  "url": 
"https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/master.m3u8;
}

$ xidel -s "https://stream.nbcnews.com/data/live_sources_2007524.json; -e 
'serialize($json/(videoSources)()/{"requestorId":"nbcnews","pid":pid,"application":"NBCSports","version":"v1","platform":"desktop","token":"","resourceId":"","inPath":"false","authenticationType":"unauth","cdn":"akamai","url":sourceUrl},{"method":"json"})'
{"requestorId":"nbcnews","pid":"2007524","application":"NBCSports","version":"v1","platform":"desktop","token":"","resourceId":"","inPath":"false","authenticationType":"unauth","cdn":"akamai","url":"https:\/\/nbcnews3.akamaized.net\/hls\/live\/723429\/NBCNewsNowa418c506\/clear\/master.m3u8"}

$ xidel -s "https://stream.nbcnews.com/data/live_sources_2007524.json; -e 
'x:request({"post":serialize($json/(videoSources)()/{"requestorId":"nbcnews","pid":pid,"application":"NBCSports","version":"v1","platform":"desktop","token":"","resourceId":"","inPath":"false","authenticationType":"unauth","cdn":"akamai","url":sourceUrl},{"method":"json"}),"url":"https://tokens.playmakerservices.com"})/json'
{
  &quo

Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-13 Thread Reino Wijnsma
On 2022-04-13T23:49:26+0200, Reino Wijnsma  wrote:
> Or minified:
>
> $ xidel -s "http://www.freeintertv.com/view/id-2565; -e 
> 'x:request({"post":request-combine((),{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/substring(url,2),"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/"})/extract(raw,"http.+m3u8")'
Alternatively, instead of using x:request() in-query, you could use the 
command-line option --post / -d, which I guess more resembles curl:

$ xidel -s -d 
'{request-combine((),{"chname":string-to-base64Binary(doc("http://www.freeintertv.com/view/id-2565;)//meta[@property="og:image"]/extract(@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/substring(url,2)}'
 "http://www.freeintertv.com/myAjax/get_item_m3u8/; -e 
'extract($raw,"http.+m3u8")'

$ xidel -s \
  -d '{
request-combine(
  (),
  {
"chname":string-to-base64Binary(
  
doc("http://www.freeintertv.com/view/id-2565;)//meta[@property="og:image"]/
  extract(@content,"([a-z_]+)\.jpg",1)
),

"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
"html5":"11"
  }
)/substring(url,2)
  }' \
  "http://www.freeintertv.com/myAjax/get_item_m3u8/; \
  -e 'extract($raw,"http.+m3u8")'

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-13 Thread Reino Wijnsma
On 2022-04-13T21:34:32+0200, Bo Berglund  wrote:
> For me it works on both Firefox and Chrome...
> What browser are you using?

I'm using "New Moon 
<https://msfn.org/board/topic/182647-my-browser-builds-part-3>", a derivative 
of Pale Moon which in turn is based on Firefox.
Why? Believe it or not, but at the moment I'm still using an AMD Athlon XP 
3200+ and it's one of the very few browsers that still works on my cpu. It does 
mean however that websites that utilize the latest Javascript for instance 
won't work for me.
I do know I'm in desperate need of a new system and that'll probably be an AMD 
"Rembrandt" desktop APU or otherwise an AMD ZEN 4 cpu. Both scheduled for 
release later this year. The transition will be a shock I'm sure.

If you can share any useful hits you see in the network-traffic when you visit 
http://www.freeintertv.com/view/id-2308, then I could have a look. 
Alternatively I could have a look on a much newer system of one of my family 
members, which I will visit in a couple of days.

> On Wed, 13 Apr 2022 01:42:39 +0200, Reino Wijnsma  wrote:
>> That command was for Xidel 0.9.8, which you're not using anymore if I 
>> understand correctly.
> What would it be for the most recent xidel?

The final query in my initial post:

On 2022-04-09T13:14:18+0200, Reino Wijnsma  wrote:
> $ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
>   x:request({
> "post":request-combine(
>   (),
>   {
> "chname":string-to-base64Binary(
>   extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
> ),
> 
> "ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
> "html5":"11"
>   }
> )/substring(url,2),
> "url":"http://www.freeintertv.com/myAjax/get_item_m3u8/;
>   })/extract(raw,"http.+m3u8")
> '
> http://1128480543.rsc.cdn77.org/SlTNwu1CSVEq9yA3i_J9Zg==,1649504141/1128480543/index.m3u8

Or minified:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e 
'x:request({"post":request-combine((),{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/substring(url,2),"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/"})/extract(raw,"http.+m3u8")'

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-12 Thread Reino Wijnsma
On 2022-04-12T14:35:39+0200, Bo Berglund  wrote:
> I don't know from where this URL in the command came from (you say you can see
> it...):
> http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online
>
> But it is for the 2565 video...
> Maybe another is needed for 2308?

Apparently. Like I said, the videostream doesn't work in my browser, so I 
couldn't tell whether it was the same videostream.
Then I guess each channel / videostream need it's own approach in trying to 
recover the video-url.

I can only see...

$ xidel -s "http://www.freeintertv.com/view/id-2308; -e '(//iframe)[1]' 
--output-node-format=html
http://www.freeintertv.com/modules/View/screen.php?nametv=NBC+%28USA%29idtv=2308TVSESS=cko6m4au4uea7vh5aqmoi0ec35;
 scrolling="no" frameborder="0">

$ xidel -s "http://www.freeintertv.com/view/id-2308; -f '(//iframe)[1]' -e 
'(//script)[position() = (1,2)]' --output-node-format=html
var 
$config={"add":"http://188.17.143.39","go":"TRB2UWBSCQMNUG","stream":"s1","add_1":"http://85.94.1.9:8802"};

var videoid=3813;
var url_tv=true;
var outreg=/umain\('(http:\/\/[^']+)'/i;
var 
playlist=[{'file':$config['add']+'/hls/CH_R04_DOMASHNY/variant.m3u8?version=2'},{'file':'http://'+window.location.hostname+'/externals/tv-russia/smotret-tv3-online'},{'file':$config['add']+'hls/CH_R02_DOMASHNY/variant.m3u8?version=2'}];
var 
$params={top:"-80",left:"0",width:"500",height:"350",widthFr:"500",heightFr:"1500",timeout:1000,backgroundColor:"#000",backgroundPosition:"50%
 60%"};


...and I don't understand how something like 
"http://188.17.143.39/hls/CH_R04_DOMASHNY/variant.m3u8?version=2; would 
translate to...

On 2022-04-12T17:54:32+0200, Bo Berglund  wrote:
> https://nbcnews3.akamaized.net/hls/live/723429/NBCNewsNowa418c506/clear/hdntl=exp=1649865178~acl=%2f*~data=hdntl~hmac=5480897632ddf98d23bf870098333af5055752c54d28764b8c894711086d1266/VIDEO_1_4596000.m3u8

As the videostream doesn't work here, you're on your own on this one.

On 2022-04-12T17:54:32+0200, Bo Berglund  wrote:
> Anyway, the command above used with the latest xidel yields an erroneous URL 
> for
> the 2565 video:
> http://livedoc.cgtn.com/500d/prog_index.m3u8

That command was for Xidel 0.9.8, which you're not using anymore if I 
understand correctly.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-11 Thread Reino Wijnsma
On 2022-04-11T12:25:17+0200, Bo Berglund  wrote:
> $ xidel --version
> Xidel 0.9.8
> (20180421.6162.1f357eaaf5f3)

A couple of months ago I already stated to use the latest binary from the 
development branch:

On 2022-01-09T23:07:55+0100, Reino Wijnsma  wrote:
> I'm not sure why you're trying to compile Xidel from (the wrong) source when 
> you can easily grab binaries from 
> https://sourceforge.net/projects/videlibri/files/Xidel/ (binaries from the 
> development map are recommended).

On 2022-04-11T12:25:17+0200, Bo Berglund  wrote:
> There seems to be a lot of line wraps either by the news reader I use (Free
> Agent) or the commands are not meant to be entered in a terminal...

You, as a developer, don't know the difference between a minified and 
prettified command?
I don't know what a "news reader" is, but 
https://ffmpeg.org/pipermail/ffmpeg-user/2022-April/054565.html shows my mail 
as intended.
And of course prettified commands can be entered in a terminal.

> So it prints the word "msnbc_live" as a single word and nothing gets stored on
> the disk either...

All Xidel commands in my previous post just print the output to stdout. I don't 
understand why you'd expect anything to be saved to disk.

> I tried this after making it unwrapped into a single command line, but got an
> error:
>
> xidel -s "http://www.freeintertv.com/view/id-2565; -e
> '{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"}'{"chname":
> "bXNuYmNfbGl2ZQ==","ch":
> "http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":
> "11"}
> Error:
> err:XPST0003: Unknown or unexpected operator: { (possible missing comma , or
> closing parentheses)}] )

On 2022-04-09T13:14:18+0200, Reino Wijnsma  wrote:
> $ xidel -s "http://www.freeintertv.com/view/id-2565; -e '   *opening quote of 
> extraction-query*
>   {
> "chname":string-to-base64Binary(
>   extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
> ),
> "ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
> "html5":"11"
>   }
> '   *closing quote of 
> extraction-query*
> {
>   "chname": "bXNuYmNfbGl2ZQ==",
>   "ch": "http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
>   "html5": "11"
> }

So, the JSON is not part of the command, but it's the *output*!

> So next I tried this last big command again after trying to get it onto a 
> single
> line (which the newsreader has wrapped...):
>
> $ xidel -s "http://www.freeintertv.com/view/id-2565; -e
> 'x:request({"post":request-combine((),{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/substring(url,2),"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/"})/extract(raw,"http.+m3u8")
>
> Now there is only a single > output and no command prompt until I hit Ctrl-C

You forgot to copy-paste the extraction-query closing quote.

If you insist on using Xidel 0.9.8, then use:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e 
'x:request({"post":request-combine({"url":()},{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/url,"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/"})/extract(raw,"http.+m3u8")'

I think this is enough off-topic for this mailinglist. If you have any more 
questions about Xidel, I suggest you go to:
StackOverflow - https://stackoverflow.com/questions/tagged/xidel
Mailinglist - https://sourceforge.net/p/videlibri/mailman/
(not so active) Forum - https://sourceforge.net/p/xidel/discussion

On 2022-04-11T17:46:52+0200, Robert Jeffares  wrote:
> A script using curl to download the site to a file then grep m3u8 will give
> you a list which you can then sort to select the_one_you_want then ffmpeg
> -I the_one_you_want etc

No it will not, because a POST request is required to get the video-url in this 
particular case. There's no mention of "m3u8" in the site its HTML-source.
And in addition, it's really bad practise to parse HTML with grep/sed/awk etc.

P.s. Please do not top-post on this mailinglist!

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How can I extract m3u8 URL for use with ffmpeg on this site?

2022-04-09 Thread Reino Wijnsma
Hello Bo,

On 2022-04-07T18:48:06+0200, Bo Berglund  wrote:
> I want to get hold of the m3u8 URL on this site

You do realize this is the FFmpeg mailinglist, right? This question has nothing 
to do with FFmpeg.
If you want more answers, then this is the wrong place to ask.

> Another example page on the same site going through the same procedure:
> http://www.freeintertv.com/view/id-2565

By looking at the network-traffic you can see (or at least I can) this POST 
request:

$ curl --data-raw 
"chname=bXNuYmNfbGl2ZQ%3D%3D=http%3A%2F%2Fwww.freeintertv.com%2Fexternals%2Ftv-russia%2Fsmotret-tv3-online=11"
 \
"http://www.freeintertv.com/myAjax/get_item_m3u8/;

This can be replicated/automated with the HTML/XML/JSON parser Xidel, which 
I've showed you earlier.

The value to be used for "chname":

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e 
'extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)'
msnbc_live

"chname" base64 encoded:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
  string-to-base64Binary(
extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
  )
'
bXNuYmNfbGl2ZQ==

The string to POST:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
  {
"chname":string-to-base64Binary(
  extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
),
"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
"html5":"11"
  }
'
{
  "chname": "bXNuYmNfbGl2ZQ==",
  "ch": "http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
  "html5": "11"
}

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
  request-combine(
(),
{
  "chname":string-to-base64Binary(
extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
  ),
  "ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
  "html5":"11"
}
  )/substring(url,2)
'
chname=bXNuYmNfbGl2ZQ%3D%3D=http%3A%2F%2Fwww.freeintertv.com%2Fexternals%2Ftv-russia%2Fsmotret-tv3-online=11

And the actual POST-request:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
  x:request({
"post":request-combine(
  (),
  {
"chname":string-to-base64Binary(
  extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
),

"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
"html5":"11"
  }
)/substring(url,2),
"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/;
  })/raw
'
playlist[0]['file']='http://1128480543.rsc.cdn77.org/SlTNwu1CSVEq9yA3i_J9Zg==,1649504141/1128480543/index.m3u8';
 get_item.showPlayer();

Extract the m3u8-url:

$ xidel -s "http://www.freeintertv.com/view/id-2565; -e '
  x:request({
"post":request-combine(
  (),
  {
"chname":string-to-base64Binary(
  extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)
),

"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online;,
"html5":"11"
  }
)/substring(url,2),
"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/;
  })/extract(raw,"http.+m3u8")
'
http://1128480543.rsc.cdn77.org/SlTNwu1CSVEq9yA3i_J9Zg==,1649504141/1128480543/index.m3u8

> http://www.freeintertv.com/view/id-2308

This one doesn't work in my browser, but appears to work the same way:

$ xidel -s "http://www.freeintertv.com/view/id-2308; -e 
'x:request({"post":request-combine((),{"chname":string-to-base64Binary(extract(//meta[@property="og:image"]/@content,"([a-z_]+)\.jpg",1)),"ch":"http://www.freeintertv.com/externals/tv-russia/smotret-tv3-online","html5":"11"})/substring(url,2),"url":"http://www.freeintertv.com/myAjax/get_item_m3u8/"})/extract(raw,"http.+m3u8")'
http://livedoc.cgtn.com/500d/prog_index.m3u8

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Matroska Muxer Options documentation

2022-03-19 Thread Reino Wijnsma
On 2022-03-18T09:59:55+0100, Christoph Gerstbauer 
 wrote:
> the ffmpeg MKV documentation at
>
> "https://ffmpeg.org/ffmpeg-all.html#matroska;
> is quite short and focussed on stereoscopic content.
>
> Is there a more detailed documentation variant for the Matroska muxer that 
> can be used to fully utilize the current options for MKV muxing?
> At matroska.org there is the specification to read but no ffmpeg syntax 
> examples how to generate such MKVs (or I did not find it yet there).
>
> Could someone give me a tip here?

ffmpeg -h muxer=matroska

This reveals a bit more options than outlined on the url you mentioned.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2022-03-13 Thread Reino Wijnsma
On 2022-03-11T18:24:46+0100, Bo Berglund  wrote:
> Right now I could not find mention of "youtube" or even "yo" on the "view
> source" page...
> And using F12 to show the streaming data gives me the URL:
>
> https://hbzpjnctrztwpucm.wzcdn134.net:8443/hls/cshr1ujg6u-32171144940.ts
>
> But that is not an m3u8 URL I can use with ffmpeg...
Now I'm seeing...

https://wigistream.to/embed/cshr1ujg6u; width="888" height="498"  
scrolling="no" frameborder="0" allowfullscreen="true">

...but this "STREAM IS OFFLINE" I'm being shown.

Do we see different content depending on our location? I don't see any 
livestreams that work.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Convert MP3 with art cover adding to OGG file

2022-03-13 Thread Reino Wijnsma
On 2022-03-09T10:56:49+0100, CMG DiGiTaL  wrote:
> I'm trying to convert some mp3 to ogg add mp3 cover art on ogg, but I can't
> do it. When I use the standard command, the mp3 art is transformed into
> video on ogg and that's not what I want

It's because it's not supported. See https://trac.ffmpeg.org/ticket/4448.
You could probably use vorbiscomment. I have no experience with the tool 
however.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-03-13 Thread Reino Wijnsma
Hello Clamarc,

On 2022-03-07T03:53:10+0100, CMG DiGiTaL  wrote:
> [...]
> ffmpeg -hide_banner -i "%file% -filter_complex 
> "[0:a]loudnorm=print_format=summary" -f null NUL 2>1.txt

You forgot a closing double-quote after %file%. And btw, -af instead of 
-filter_complex would do as well.

> [...]
> FOR /F "tokens=1,2 delims=," %%b IN ('ffprobe -v 0 -show_entries 
> stream^=bit_rate^,sample_rate -of csv^=p^=0 "%file%"') DO ( ffmpeg -vsync vfr 
> -hide_banner -i "%file%" -af 
> loudnorm=linear=true:I=%vLUF%:LRA=11:tp=%vPEAK%:measured_I=%II%:measured_LRA=%ILRA%:measured_tp=%ITP%:measured_thresh=%IT%:offset=%TO%:print_format=summary
>  -c:v copy -id3v2_version 3 -c:a libmp3lame -b:a %%c -ar:a %%b 
> "C:\Users\%username%\Desktop\Converting_lufs\%file%")

Now I understand why you posted 2 logs. FFprobe is trying to print the bit_rate 
and sample_rate of *both* streams (the audiostream as well as the coverart). So 
it would print for instance...

44100,192000
N/A

...and then FFmpeg is called twice. First with 44100 and 192000, and a second 
time only with "N/A". You'd have to restrict ffprobe to only process the 
audiostream:

ffprobe -v 0 *-select_streams a* -show_entries [...]

Btw, there's no need for escape-characters if you use double-quotes:

ffprobe -v 0 -select_streams a -show_entries "stream=bit_rate,sample_rate" -of 
"csv=p=0" "%file%"

And please do the same for the ffmpeg command. I'm actually surprised it worked 
without:

-af 
"loudnorm=linear=true:I=%vLUF%:LRA=11:tp=%vPEAK%:measured_I=%II%:measured_LRA=%ILRA%:measured_tp=%ITP%:measured_thresh=%IT%:offset=%TO%:print_format=summary"

And do you really need -vsync vfr ? I'm no expert, but I think it's totally 
useless in this situation.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2022-03-06 Thread Reino Wijnsma
On 2022-03-04T18:47:26+0100, Bo Berglund  wrote:
> https://msnbcdailyshows.com/
>
> and the m3u8 URL I find if I use F12 in the browser when it plays:
>
> https://cdn.plt.one/cdn/premium327/chunks.m3u8

I don't see that url anywhere. Instead I'm seeing...

https://www.youtube.com/embed/9CLF18wQpag*; title="YouTube video player" 
frameborder="0" allow="accelerometer; autoplay; clipboard-write; 
encrypted-media; gyroscope; picture-in-picture" allowfullscreen>

...in the html-source. And that Youtube-video works just fine for me.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-03-06 Thread Reino Wijnsma
On 2022-03-06T18:35:11+0100, CMG DiGiTaL  wrote:
> what is happening [...]
Only one way to find out and that is to have a look at your Batch code.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-03-06 Thread Reino Wijnsma
On 2022-03-01T03:23:25+0100, CMG DiGiTaL  wrote:
> sorry I sent the wrong log, follow the right log:
>
> [...]
> *-c:v copy -acodec mp3 -b:a 32 -ar:a 44100*
>
> [...]
> *-c:v copy -acodec mp3 -b:a -ar:a N/A* 

I don't know why you're posting 2 logs.
The first one is obviously correctly being executed.
For the second one your Batch code doesn't appear to work correctly for the 
bitrate and samplerate.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-02-28 Thread Reino Wijnsma
On 2022-03-01T01:17:12+0100, CMG DiGiTaL  wrote:
> I removed the -map 0:0
> [...]
>
> log:
>
> [...]
> -c:v copy -map 0:0 -acodec mp3 -b:a -ar:a N/A
Apparently you did not.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-02-28 Thread Reino Wijnsma
On 2022-02-28T19:05:18+0100, CMG DiGiTaL  wrote:
> -c:v copy -map 0:0 -acodec mp3 -b:a %%c -ar:a %%b
> [...]
> [NULL @ 02c4fdb37740] *Unable to find a suitable* *output format for
> 'N/A'*

With -map 0:0 you tell FFmpeg to process only the audio-stream. Remove it.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] mp3 audio output recording error message when he has Cover

2022-02-27 Thread Reino Wijnsma
On 2022-02-26T09:14:05+0100, CMG DiGiTaL  wrote:
> Is there a way to check if the file has a cover and if so, record the cover
> along with it?

Simply add -c:v copy.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Fwd: Get sample rate in mp3 files

2022-02-23 Thread Reino Wijnsma
Hello Clamarc,

On 2022-02-23T01:49:41+0100, CMG DiGiTaL  wrote:
> but what did i do wrong?...

You top-posted. If you don't know what it is, then please have a look at:
- http://www.idallen.com/topposting.html
- https://www.caliburn.nl/topposting.html
or use you favorite search-engine to look it up.

So put your reply beneath the quoted text, aka bottom-posting.
In addition to that I'd like to add; please also trim the quoted text to the 
core phrase you're replying to, like I'm doing here.
That's because unfortunately we quite regularly see (even core FFmpeg 
developers) shoving their reply somewhere in the entire untrimmed quoted 
original post (incl. footer) leaving lots of noise.

On 2022-02-23T05:57:29+0100, CMG DiGiTaL  wrote:
> thanks a lot for the help, the code has now read the file with the 
> exclamation mark no problems!

I'm glad it's now working for you.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Fwd: Get sample rate in mp3 files

2022-02-22 Thread Reino Wijnsma
Hello Clamarc,

Please do not top-post. On this mailinglist it's against the rules, to which 
you agreed upon subscribing.

On 2022-02-22T07:32:05+0100, CMG DiGiTaL  wrote:
>> FOR *%G* IN (*.mp3) DO (
>it was because I took part of the sample rate command that you sent me
> to be able to use it in my batch file that I already had here, you know?...

I'm not sure you understand. I meant the strong / bold font layout, the two 
asterisks surrounding %G.

> the problem that is driving me crazy, is that as some audio files have the
> exclamation mark in the name, using the ENABLEDELAYEDEXPANSION, the batch
> cancels because it
> doesn't recognize the files with the exclamation mark

Try this:

@ECHO off
SET vluf=-10.0
SET vpeak=-0.0
FOR %%A IN (*.mp3) DO (
  SET "filename=%%~nA"
  ffmpeg -hide_banner -i "%%A" -af 
"loudnorm=I=-15:TP=-1.5:LRA=11:print_format=summary" -f null NUL 2> "%%~nA.log"
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input Integrated" "%%~nA.log"') DO 
(SET II=%%B)
  @FOR /F "tokens=4" %%B IN ('FINDSTR /C:"Input True Peak" "%%~nA.log"') DO 
(SET ITP=%%B)
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input LRA" "%%~nA.log"') DO (SET 
ILRA=%%B)
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input Threshold" "%%~nA.log"') DO 
(SET IT=%%B)
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Target Offset" "%%~nA.log"') DO (SET 
TO=%%B)
  DEL "%%~nA.log"
  SETLOCAL ENABLEDELAYEDEXPANSION
  ECHO !II! is the Input Integrated
  ECHO !ITP! is the Input True Peak
  ECHO !ILRA! is the Input LRA
  ECHO !IT! is the Input Threshold
  ECHO !TO! is the Target Offset
  FOR /F "delims=" %%B IN ('ffprobe -v 0 -show_entries stream^=bit_rate -of 
default^=nk^=1:nw^=1 "!filename!.mp3"') DO ffmpeg -hide_banner -i 
"!filename!.mp3" -af 
"loudnorm=linear=true:I=!vluf!:LRA=11:tp=!vpeak!:measured_I=!II!:measured_LRA=!ILRA!:measured_tp=!ITP!:measured_thresh=!IT!:offset=!TO!:print_format=summary"
 -c:a libmp3lame -b:a %%B "..\Áudios LUFS ORI\!filename!_LUFS_CONVERTED.mp3"
  ENDLOCAL
)

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Fwd: Get sample rate in mp3 files

2022-02-21 Thread Reino Wijnsma
On 2022-02-21T08:52:44+0100, CMG DiGiTaL  wrote:
> I did these commands below

This has nothing to with your initial question "Get sample rate in mp3 files", 
or even FFmpeg. This is in fact a question about CMD and Batch.
I will respond to this now, but I don't believe questions like these are for 
the ffmpeg-user mailinglist.

I know CMD / Batch, but to be honest I don't know enough about FFmpeg's 
features to know what LUFS is/does. So I can't comment on whether this is a 
useful approach or not.
I can see you're trying to parse a loudnorm log and use these values in another 
FFmpeg call. A rather inefficient process, calling the txt-file multiple times 
with FINDSTR, if you ask me. Especially because you can enter print_format=json 
for the loudnorm-filter.

> - Can I use a command of this size directly in cmd?

Sure. The amount of characters doesn't come near CMD's commandline buffer of 
8192 bytes.
But you're gonna need delayed expansion for this, so I'd say you're better off 
creating a bat-file.

> FOR *%G* IN (*.mp3) DO (

Please don't do this. I understand you're trying to emphasize parts of code, 
but in this particular case it's not bold printed, which raises the question if 
it's part of the code or not.

>   set vluf=-10.0
>   set vpeak=-0.0

If these are always the same value for each mp3-file, then I would've declared 
them before the FOR-loop.

>   @for /f "delims=" *%A* IN ('ffprobe -v 0 -show_entries *stream^=bit_rate*
> -of csv^=p^=0 "*%G*"')

This FFprobe call shouldn't be here. It should be right before the final FFmpeg 
call.

>   *ffmpeg* -i "%G" -filter_complex
> "[0:a]loudnorm=I=-15:TP=-1.5:LRA=11:print_format=summary" -f null x 2>%1.txt

On Linux the convention is -f null /dev/null, but on Windows it's -f null NUL.
I would recommend naming a file "%1". Could cause lots of problems.

>   echo "%II" is the Input Integrated

You forgot the closing % --> %II%. Only FOR-loop variables work without a 
closing %.

>   @for /f "tokens=3" %B in ('findstr /C:"Output Integrated" %1.txt') do
> (set *OI*=%B)
>   echo %OI is the Output Integrated
>   @for /f "tokens=4" %B in ('findstr /C:"Output True Peak" %1.txt') do (set
> *OTP*=%B)
>   echo %OTP is the Output True Peak
>   @for /f "tokens=3" %B in ('findstr /C:"Output LRA" %1.txt') do (set *OLRA*
> =%B)
>   echo %OLRA is the Output LRA
>   @for /f "tokens=3" %B in ('findstr /C:"Output Threshold" %1.txt') do (set
> *OT*=%B)

You don't seem to be using these variables in the final FFmpeg call, so why 
extract them?

I'd recommend this for a Batch-file:

@ECHO off
SET vluf=-10.0
SET vpeak=-0.0
SETLOCAL ENABLEDELAYEDEXPANSION
FOR %%A IN (*.mp3) DO (
  ffmpeg -hide_banner -i "%%A" -af 
"loudnorm=I=-15:TP=-1.5:LRA=11:print_format=summary" -f null NUL 2> "%%~nA.log"
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input Integrated" "%%~nA.log"') DO 
(SET II=%%B)
  ECHO !II! is the Input Integrated
  @FOR /F "tokens=4" %%B IN ('FINDSTR /C:"Input True Peak" "%%~nA.log"') DO 
(SET ITP=%%B)
  ECHO !ITP! is the Input True Peak
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input LRA" "%%~nA.log"') DO (SET 
ILRA=%%B)
  ECHO !ILRA! is the Input LRA
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Input Threshold" "%%~nA.log"') DO 
(SET IT=%%B)
  ECHO !IT! is the Input Threshold
  @FOR /F "tokens=3" %%B IN ('FINDSTR /C:"Target Offset" "%%~nA.log"') DO (SET 
TO=%%B)
  ECHO !TO! is the Target Offset
  FOR /F "delims=" %%B IN ('ffprobe -v 0 -show_entries stream^=bit_rate -of 
default^=nk^=1:nw^=1 "%%A"') DO ffmpeg -hide_banner -i "%%A" -af 
"loudnorm=linear=true:I=!vluf!:LRA=11:tp=!vpeak!:measured_I=!II!:measured_LRA=!ILRA!:measured_tp=!ITP!:measured_thresh=!IT!:offset=!TO!:print_format=summary"
 -c:a libmp3lame -b:a %%B "..\Áudios LUFS ORI\%%~nA_LUFS_CONVERTED.mp3"
)
ENDLOCAL

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Get sample rate in mp3 files

2022-02-20 Thread Reino Wijnsma
On 2022-02-21T01:38:30+0100, CMG DiGiTaL  wrote:
> OK, I would also need, along with the sample rate, to get the bitrate of
> the file, because I realized that in the conversion, because I'm using
> --acodec -b:a 320k, it's passing all the aidios to 320 kbps... until even
> 192 kbps audio!. is there a way in the conversion I can get the correct
> bitrate of each file?
You could do...

ffprobe -v 0 -show_entries stream=bit_rate,sample_rate -of csv=p=0 "input.mp3"

...which would return for instance:

48000,128000

Then within the FOR-loop set the delimiter to the comma:

FOR %A IN (*.mp3) DO @FOR /F "tokens=1,2 delims=," %B IN ('ffprobe -v 0 
-show_entries stream^=bit_rate^,sample_rate -of csv^=p^=0 "%A"') DO @IF %B EQU 
48000 ffmpeg -hide_banner -i "%A" -c:a libmp3lame -b:a %C -ar 44100 "..\48000 
sample rates Audio\%A"

...or prettified:

FOR %A IN (*.mp3) DO @(
  FOR /F "tokens=1,2 delims=," %B IN ('ffprobe -v 0 -show_entries 
stream^=bit_rate^,sample_rate -of csv^=p^=0 "%A"') DO @(
IF %B EQU 48000 ffmpeg -hide_banner -i "%A" -c:a libmp3lame -b:a %C -ar 
44100 "..\48000 sample rates Audio\%A"
  )
)

- Notice the -b:a %C.
- Initially I had %~nA_converted.mp3 for the output, but if you want the 
original filename (seeing they're being dumped into a separate directory 
anyway), then you can just as well enter %A.

Note: lossy to lossy conversions are NOT recommended quality wise. Especially 
with a low bitrate. Always try to use the lossless source as much as possible!

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Get sample rate in mp3 files

2022-02-20 Thread Reino Wijnsma
On 2022-02-21T01:07:12+0100, CMG DiGiTaL  wrote:
> do i need to create the 48000 sample rates folder before running your
> command, or will it create the folder automatically?

Yes. No it won't. In your previous e-mail...

On 2022-02-07T22:47:29+0100, CMG DiGiTaL  wrote:
> md "C:\Users\%username%\Desktop\48000 sample rates Audio"---> created
> folder
...you said you've already done that.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Get sample rate in mp3 files

2022-02-20 Thread Reino Wijnsma
Hello Clamarc,

(late reply as I'm a bit behind with cleaning up e-mails)

On 2022-02-07T22:47:29+0100, CMG DiGiTaL  wrote:
> I have a folder "General Audios" and I created another one called "Audios
> 48000 sample rate"
>
> I'm running the ffprobe command that returns the sample rate value of each
> song.. but when I try to save the value in a string to be able to use the
> IF and copy only the ones with 48000 hz, I get a message that the command
> is a command input? what is wrong?... I just want to be able to take
> advantage of the if sulted the ffprobe command and you can do the if!...
> that's all!
>
> md "C:\Users\%username%\Desktop\48000 sample rates Audio"---> created
> folder
>
> cd\Users\%username%\Desktop\General Audios
>  ---> original folder
>
> ffprobe command that separates only the
> sample rate of the songs in the folder:
> set varif var
>  Generate files in folder
> for %%F IN (*) do (ffprobe -i "%%F" -v error -show_entries
> stream=sample_rate -of default=noprint_wrappers=1:nokey=1 *set* *%%S
> if %%S*==48000
> ("C:\Users\%username%\Desktop\48000 sample rates Audio\%%F")
>   )
> pause

No need for a Batch-file. Just navigate to the appropriate dir...

cd "Users\%username%\Desktop\General Audios"

...and enter the following one-liner:

FOR %A IN (*.mp3) DO @FOR /F "delims=" %B IN ('ffprobe -v 0 -show_entries 
stream^=sample_rate -of default^=nk^=1:nw^=1 "%A"') DO @IF %B EQU 48000 ffmpeg 
-hide_banner -i "%A" -c:a libmp3lame -b:a 320k -ar 44100 "..\48000 sample rates 
Audio\%~nA_converted.mp3"

...or the same FOR-loops a bit more readable (prettified):

FOR %A IN (*.mp3) DO @(
  FOR /F "delims=" %B IN ('ffprobe -v 0 -show_entries stream^=sample_rate -of 
default^=nk^=1:nw^=1 "%A"') DO @(
IF %B EQU 48000 ffmpeg -hide_banner -i "%A" -c:a libmp3lame -b:a 320k -ar 
44100 "..\48000 sample rates Audio\%~nA_converted.mp3"
  )
)

- Don't forget to escape the equals signs in the ffprobe command, or the 
FOR-loop will execute the ffprobe command without them.
- In the process you'll only see ffmpeg converting the 48kHz mp3-files. If you 
want more verbosity, just remove one or both of the "@" signs.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to get video duration in a script using ffmpeg?

2022-01-19 Thread Reino Wijnsma
On 2022-01-19T12:23:07+0100, Bo Berglund  wrote:
> ffprobe -hide_banner -i input.mp4 | grep Duration
ffprobe -hide_banner input.mp4 2>&1 | grep Duration

- 2>&1, because ffprobe (as well as ffmpeg) send the information to stderr.
- Unlike ffmpeg, -i isn't needed for ffprobe and ffplay.

On 2022-01-19T13:56:41+0100, Bo Berglund  wrote:
> On Wed, 19 Jan 2022 12:59:45 +0100, Bo Berglund  wrote:
>> Thanks, this returns the following output:
>> 0:43:26.384000
> [...]
>
> Results in this output:
> 0:43:26
>
> Exactly what is needed...

Is it? What if ffprobe returned 0:43:26.584000 (or 2606.584000 without 
-sexagesimal) instead? I'd figure you'd then want to end up with 00:43:27, 
right?

$ ffprobe -hide_banner -v 0 -show_entries format=duration -of compact=p=0:nk=1 
input.mp4
2606.584000

$ ffprobe -hide_banner -v 0 -show_entries format=duration -of compact=p=0:nk=1 
input.mp4 | awk '{print int($1 + 0.5)}'
2607

$ date -d@$(ffprobe -hide_banner -v 0 -show_entries format=duration -of 
compact=p=0:nk=1 input.mp4 | awk '{print int($1 + 0.5)}') -u '+%H:%M:%S'
00:43:27

Alternatively you can also use Xidel for this.

$ ffprobe -hide_banner -v 0 -show_entries format=duration -of compact=p=0:nk=1 
input.mp4 | \
  xidel -se 'format-time($raw * duration("PT1S") + 
duration("PT0.5S"),"[H01]:[m01]:[s01]")'
00:43:27

$ ffprobe -hide_banner -v 0 -show_entries format=duration -of compact=p=0:nk=1 
input.mp4 | \
  xidel -se 'format-time(($raw + 0.5) * duration("PT1S"),"[H01]:[m01]:[s01]")'
00:43:27

>From the JSON:

$ ffprobe -hide_banner -v 0 -show_format -of json input.mp4 | \
  xidel -se 'format-time(($json/format/duration + 0.5) * 
duration("PT1S"),"[H01]:[m01]:[s01]")'
00:43:27

Or from the initial log:

$ ffprobe -hide_banner input.mp4 2>&1 | \
  xidel -se 'format-time(time(extract($raw,"Duration: (.+?),",1)) + 
duration("PT0.5S"),"[H01]:[m01]:[s01]")'
00:43:27

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to extract m3u8 stream URL from webpage with 2 players?

2022-01-10 Thread Reino Wijnsma
On 2022-01-10T10:14:10+0100, Bo Berglund  wrote:
> Anyway from another thread about xidel I replied in:
> 
> After trying to fix this I decided to search for binaries and found them here:
> https://sourceforge.net/projects/videlibri/files/Xidel/Xidel%200.9.8/
> These I believe are all for PC style CPU:s

What other thread?

Again, I recommend you download binaries from the development branch.

I don't know what you mean by "PC style CPU:s". As you're on Ubuntu and 
assuming you're using modern hardware you're probably looking for the linux64 
binary. But come on, do I really have to tell you this?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to extract m3u8 stream URL from webpage with 2 players?

2022-01-09 Thread Reino Wijnsma
On 2022-01-09T17:39:05+0100, Bo Berglund  wrote:
> But I found its GitHub home so I could check out the sources after seeing that
> it as FreePascal/Lazarus to use as dev tools and that is exactly what I use
> daily. :)
> https://github.com/benibela/xidel
>
> But I came to a halt anyway since the sources has layer after layer of
> dependencies, which are not explained in the readme file.
>
> The first dependency on "internettools" could be resolved since the same 
> author
> had this also on his GitHub:
> https://github.com/benibela/internettools
>
> But then a bunch of other dependencies appeared which I decided were too much 
> to
> hunt down.
> So I had to give up
> Too bad.

I'm not sure why you're trying to compile Xidel from (the wrong) source when 
you can easily grab binaries from 
https://sourceforge.net/projects/videlibri/files/Xidel/ (binaries from the 
development map are recommended).

But if you insist...

http://videlibri.sourceforge.net/xidel.html:
> The source history is stored in a mercurial repository 
>  together with the 
> VideLibri source and dependencies, licensed as GPLv3+. There are mirrors on 
> GitHub  and GitLab 
> . _These mirrors have the Xidel source 
> only_, in order to compile it you need to download the dependencies from 
> their own repositories first. Or use the above source tarball, which also 
> contains dependencies.

tarball --> programs/internet/xidel/README.md 
:
> You can compile it by calling build.sh

$ curl -OL 
"https://sourceforge.net/projects/videlibri/files/Xidel/Xidel%20development/xidel-0.9.9.20211225.8285.b90e197a0a24.src.tar.gz;

$ tar -xf xidel-0.9.9.20211225.8285.b90e197a0a24.src.tar.gz

$ xidel-0.9.9.20211225.8285.b90e197a0a24-src/programs/internet/xidel/build.sh -s

This should be enough.
However, r8285 is not the latest dev-build. r8308 is, but... it's missing a 
dependency . :D

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to extract m3u8 stream URL from webpage with 2 players?

2022-01-08 Thread Reino Wijnsma
On 2022-01-08T18:34:34+0100, Bo Berglund  wrote:
> and the other working much better had the stream url:
> https://296894.rsc.cdn77.org/LS-ATL-54548-10/tracks-v1a1/mono.m3u8
>
> [...]
>
> This 2:nd URL I could only find by using Firefox in F12 mode when playing, so 
> it
> was completely manual. Not good when it changes often..
If that url starts working again, then there are 3 places to find it in the 
HTML-source, which you can extract with the HTML- and JSON-parser Xidel:

$ xidel -s "https://msnbcdailyshows.com/; -f "(//iframe)[2]/@src" -e '
  //meta[@property="og:description"]/normalize-space(@content),  (: #1 
:)
  normalize-space(//div[@class="post-body entry-content"]),  (: #2 
:)
  parse-json((: #3 
:)
replace(
  //script/extract(.,"_WidgetManager._SetDataContext\((.+)\);",1),
  "\\\x","\\\u00"
),
{"liberal":true()}
  )()[name="view"]/data/normalize-space(description)
'
https://296894.rsc.cdn77.org/LS-ATL-54548-10/playlist.m3u8
https://296894.rsc.cdn77.org/LS-ATL-54548-10/playlist.m3u8
https://296894.rsc.cdn77.org/LS-ATL-54548-10/playlist.m3u8

On 2022-01-08T20:10:29+0100, Bo Berglund  wrote:
> This tool xidel you use, from where is that?
> How can it be installed?
https://www.videlibri.de/xidel.html

I'm using the Windows binary in a Bash environment, but last I heared quite 
some Linux packagemanagers also have it, though most likely not the latest 
build 
<https://sourceforge.net/projects/videlibri/files/Xidel/Xidel%20development/>.

-- 
Reino Wijnsma

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to extract m3u8 stream URL from webpage with 2 players?

2022-01-08 Thread Reino Wijnsma
On 2022-01-08T10:25:48+0100, Bo Berglund  wrote:
> On Fri, 07 Jan 2022 14:05:02 +0100, Bo Berglund  wrote:
>> If I open the source page and use the F12 function key to activate browser 
>> debug
>> mode I can see the stream URL for both players.
>> Right now they are:
>> #1 = https://hlss.goodgame.ru/hls/188429.m3u8
>> #2 = https://296894.rsc.cdn77.org/LS-ATL-54548-10/tracks-v1a1/mono.m3u8
>>
>> What I would like to have is a way to extract the xxx/mono.m3u8 URL #2
>> automatically in a script.
>>
>> The URL:s seem to change irregularly so I will use any method found to 
>> extract
>> the URL minutes before the download starts by launching the extractor script 
>> via
>> cron.
> It turns out that shortly after I posted my question the second player stopped
> working altogether on the webpage, so there is nothing to test anymore...
> :(
Both work for me. They're actually one and the same.

$ xidel -s "https://msnbcdailyshows.com/; -e '//iframe' 
--output-node-format=html
https://goodgame.ru/player?188429; width="800" height="480" 
frameborder="0" allowfullscreen>


The second url refers to the exact same "goodgame.ru"-url:

$ xidel -s "https://msnbcdailyshows.com/; -f '(//iframe)[2]' -e 
'//div[@class="post-body entry-content"]/iframe' --ignore-namespaces 
--output-node-format=html
https://goodgame.ru/player?188429; width="600" height="400" 
frameborder="0" allowfullscreen>

The HLS-manifest-url:

$ xidel -s "https://msnbcdailyshows.com/; -e 
'x"https://hls.goodgame.ru/manifest/{substring-after((//iframe)[1]/@src,"?")}_master.m3u8"'
#or
$ xidel -s "https://msnbcdailyshows.com/; -f '(//iframe)[2]' -e 
'x"https://hls.goodgame.ru/manifest/{//div[@class="post-body 
entry-content"]/substring-after(iframe/@src,"?")}_master.m3u8"'
https://hls.goodgame.ru/manifest/188429_master.m3u8

$ ffmpeg -hide_banner -user_agent "Mozilla Firefox" -i "$(xidel -s 
"https://msnbcdailyshows.com/; -e 
'x"https://hls.goodgame.ru/manifest/{substring-after((//iframe)[1]/@src,"?")}_master.m3u8"')"
[hls @ 03105100] Skip ('#EXT-X-VERSION:3')
[hls @ 03105100] Opening 'https://hls.goodgame.ru/hls/188429.m3u8' for reading
[hls @ 03105100] Skip ('#EXT-X-VERSION:3')
[hls @ 03105100] Opening 'https://hls.goodgame.ru/hls/188429-279700.ts' for 
reading
[hls @ 03105100] Opening 'https://hls.goodgame.ru/hls/188429-279701.ts' for 
reading
Input #0, hls, from 'https://hls.goodgame.ru/manifest/188429_master.m3u8':
  Duration: N/A, start: 436.194944, bitrate: N/A
  Program 0
Metadata:
  variant_bitrate : 233
  Stream #0:0: Video: h264 (High) ([27][0][0][0] / 0x001B), yuv420p, 1280x720, 
30 tbr, 90k tbn
Metadata:
  variant_bitrate : 233
  Stream #0:1: Audio: aac (LC) ([15][0][0][0] / 0x000F), 44100 Hz, stereo, fltp
Metadata:
  variant_bitrate : 233
At least one output file must be specified

-user_agent is required!

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Getting m3u8 URL from SVTPlay channels?

2021-12-25 Thread Reino Wijnsma
On 2021-12-25T10:13:14+0100, Bo Berglund  wrote:
> CMD="curl -s \"${STREAMURL}\" | grep -o -e \"https://.\+m3u8\; | head -n 1"
> M3U8=$(eval $CMD)
> if [ -z $M3U8 ]; then
>   RESULT=1
>   echo "Error, no response!"
> else
>   RESULT=0
>   eval "echo ${STREAMURL} ${M3U8} > ${URLFILE}"
>   echo "Done, result in  ${URLFILE}:  ${STREAMURL} ${M3U8}"
> fi
> exit ${RESULT}
>
> [...]
>
> But on the following pages it does not work at all:
> https://www.svtplay.se/kanaler/svt1?start=auto
It's really bad practise to parse HTML with RegEx! It's as if you're using a 
sledgehammer when you should've been using a pair of tweezers for instance.

- Why it's not possible to use regex to parse HTML/XML: a formal explanation in 
layman's terms 
- RegEx match open tags except XHTML self-contained tags 

- How do I extract data from an HTML or XML file? 


Use the right tool for the job, use an HTML/XML parser, like Xidel 
! And besides, you're extremely 
lucky if this has worked for you this far, because nowadays it's pretty rare to 
find m3u8-urls that easily in the HTML-source.

It appears the video will only play if you're a Swedish citizen, so you have to 
do this yourself.

$ xidel -s "https://www.svtplay.se/kanaler/svt1?start=auto; -e 
'//div[@data-testid="videoplayer"]' --output-node-format=xml 
--output-node-indent

  
[...]
  


This div is where the magic happens. Take a good look at the browser's 
network-traffic. You're probably going to need the value of the 
"class"-attribute.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2021-11-04 Thread Reino Wijnsma
On 2021-11-04T08:54:40+0100, Bo Berglund  wrote:
> I assume you mean like this (replace [...] with actual file name):

Yes

> However both commands results in this after the usual ffmpeg (or maybe
> youtube-dl) output:
> [https @ 0x55f0277f11c0] HTTP error 403 Forbidden
> https://vsd79.mycdn.me/hls/1146644400798.m3u8/sig/2d23M3cZ2y0/expires/1636093952300/srcIp/158.123.113.142/clientType/0/srcAg/*CHROME*/mid/2125507010206/1146644400798_high/index.m3u8:
> Server returned 403 Forbidden (access denied)

Probably some piece of user-agent code in Youtube-dl that causes "CHROME" to 
appear in the video-url.
The Xidel command I posted earlier returns "UNKNOWN" instead of "CHROME" (and 
another host) and appears to work.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2021-11-03 Thread Reino Wijnsma
On 2021-11-04T01:40:07+0100, Reino Wijnsma  wrote:
> $ ffmpeg -i "$(youtube-dl -g 
> https://www.livenewsmag.com/msnbc-news-live-stream/)" -c copy [...] 

That obviously must've been:
$ ffmpeg -i "$(youtube-dl -g https://msnbcdailyshows.com/)" -c copy [...]

My mistake.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2021-11-03 Thread Reino Wijnsma
On 2021-11-04T01:00:52+0100, Bo Berglund  wrote:
> https://vsd79.mycdn.me/dash/stream_1146644400798/stream.manifest/sig/RcfEI7wlP-c/expires/1636066246262/srcIp/158.174.104.130/clientType/0/srcAg/GECKO/mid/2125507010206/frag-high-6827906.dash

I hope you realize your IP-address is now out in the open!

> youtube-dl -F https://msnbcdailyshows.com/
> After some thinking it returns:
>
> [info] Available formats for 2125507010206:
> format code extension resolution note
> hls-109 mp4 864x488 109k
> hls-175 mp4 640x360 175k
> hls-485 mp4 428x240 485k
> hls-782 mp4 1280x720 782k (best)
>
> [...]
>
> Is there any possibility to use ffmpeg itself to download from this kind of
> stream and if so what would the argument for the stream be?

$ ffmpeg -i "$(youtube-dl -g 
https://www.livenewsmag.com/msnbc-news-live-stream/)" -c copy [...]

or with xidel:

$ ffmpeg -i "$(xidel -s https://msnbcdailyshows.com/ -f '//iframe/@src' -e 
'parse-json(//@data-options)/flashvars/parse-json(metadata)/hlsMasterPlaylistUrl')"
 -map 0:p:0 -c copy [...]

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] toggle between two streams

2021-09-03 Thread Reino Wijnsma
On 2021-09-03T16:25:50+0200, Michael Koch  wrote:
> But if I write all in the FFmpeg command line, then it doesn't work:
>
> ffmpeg -loop 1 -i 1.png -loop 1 -i 2.png -lavfi sendcmd=c="0 [expr] 
> streamselect map 'gte(mod(T,2),1)'",streamselect=map=0 -t 10 -y out.mp4
>
> Unable to parse graph description...

ffmpeg -loop 1 -i 1.png -loop 1 -i 2.png -lavfi "sendcmd=c='0 [expr] 
streamselect map '\''gte(mod(T\,2)\,1)'\''',streamselect=map=0" -t 10 -y out.mp4

> ffmpeg -f lavfi -i color=yellow -vf 
> drawtext='text="1":fontcolor=red:fontsize=100:x=140:y=80' -frames 1 -y 1.png

No need to quote the "text"-parameter, but quoting the entire filter-chain 
instead I would consider good practice.

ffmpeg -f lavfi -i color=yellow -vf 
"drawtext=text='1':fontcolor=red:fontsize=100:x=140:y=80" -frames 1 -y 1.png

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2021-09-01 Thread Reino Wijnsma
On 2021-09-01T08:14:02+0200, Bo Berglund  wrote:
> Is there a command line call I can make to extract the m3u8 URL automatically 
> so
> it can be used in a script only supplied the main page URL?

On 2021-08-29T17:41:49+0200, Reino Wijnsma  wrote:
> $ ffmpeg -hide_banner -i "$(xidel -s 
> "https://www.livenewsmag.com/msnbc-news-live-stream/; -e 
> 'parse-json(//script/extract(.,"playerInstance.setup\((.+)\)",1,"s"),{"liberal":true()})/file')"

???

Instead of parsing the (pseudo) JSON, you can also try to extract the HLS 
manifest directly:

$ xidel -s "https://www.livenewsmag.com/msnbc-news-live-stream/; -e 
'extract(//script,"https.+m3u8")'
https://1420543146.rsc.cdn77.org/0YMlFFbIvOHfq9uQgKZexg==,1630548377/LS-ATL-54548-10/index.m3u8

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Can ffmpeg record video from this kind of URL?

2021-08-30 Thread Reino Wijnsma
On 2021-08-30T21:56:49+0200, Anatoly  wrote:
> You just need to set "Referer" header in your http request to url of
> page that embeds that video.
> ffmpeg -referer "https://www.livenewsmag.com/msnbc-news-live-stream; -i
> "https://1420543146.rsc.cdn77.org/J2SMCND-re6j5PPYbi2Hiw==,1630371979/LS-ATL-54548-10/index.m3u8;
> -c copy msnbc-rec-1.mp4
I can confirm that this works. Thanks.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to download video stream starting at an earlier time?

2021-08-18 Thread Reino Wijnsma
On 2021-08-17T13:44:20+0200, Bo Berglund  wrote:
> https://www.youtube.com/watch?v=DM-I6UugaFs [...] but what I need is a way to 
> record earlier video that is still accessible in the stream (as shown in a 
> browser). 

That Youtube url is a livestream (video-url: 
"https://manifest.googlevideo.com/api/manifest/hls_playlist/[...]/index.m3u8;) 
and as far as I know you can't "timeseek" a livestream.
If it is possible in browser, then the source most likely isn't the livestream.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to download video stream starting at an earlier time?

2021-08-16 Thread Reino Wijnsma
On 2021-08-16T23:29:19+0200, Bo Berglund  wrote:
> What is different about a youtube url and some other domain url?
A Youtube url is a program-url which first needs to be translated to a direct 
video-url.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to download video stream starting at an earlier time?

2021-08-16 Thread Reino Wijnsma
On 2021-08-16T23:20:27+0200, Carl Zwanzig  wrote:
> It's a reasonable assumption; if ffmpeg doesn't, just say so.

FFmpeg's documentation doesn't mention support for parsing websites like 
Youtube-dl does, so I'd disagree.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to download video stream starting at an earlier time?

2021-08-16 Thread Reino Wijnsma
On 2021-08-16T22:00:24+0200, Bo Berglund  wrote:
> $ ffmpeg -ss 3600 -i https://youtu.be/DM-I6UugaFs -preset veryfast -crf 25  
> -c:a
> copy -t 600 output.mp4

What makes you think FFmpeg supports Youtube urls?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Why FFMPEG?

2021-08-16 Thread Reino Wijnsma
On 2021-08-16T16:15:47+0200, Android PowerUser  wrote:
> For me, changing apps is quick.  If so, you would have practically nothing
> to work with.
Can you please move this off-topic discussion off-list?!

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Concatenate files

2021-08-01 Thread Reino Wijnsma
On 2021-07-30T17:56:24+0200, Valerio Pachera  wrote:
> First of all I tried using this syntax:
> https://trac.ffmpeg.org/wiki/Concatenate
>
> ffmpeg -f concat -safe 0 -i mylist.txt -c copy big.mkv
>
> I get the error
>
> [concat @ 0x56177e1a9740] Line 1: unknown keyword 'file1.mkv'
> mylist.txt: Invalid data found when processing input
>
> mylist.txt has been create by kate with utf8 encoding.
>
> 1) So this is my first question: whats wrong with this syntax?
You probably didn't prepend "file " as the wiki-url shows you.

Who is kate?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to repair iPhone photos

2021-05-15 Thread Reino Wijnsma
On 2021-05-16T01:24:23+0200, Ulf Zibis  wrote:
> So FFMPEG actually does not support HEIC format?

It's not in the list of supported image formats 
, so no.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] MP4-->JPG changes brightness?

2021-05-15 Thread Reino Wijnsma
On 2021-05-15T20:16:59+0200, Steven Kan  wrote:
> https://www.kan.org/pictures/StillsFromFFmpegVsQTPreview.gif 

You're now confusing things. From the urls in your previous e-mail it was in 
fact 'TrailDownStillQTScreenCap.jpg' that stood out, not 
'TrailDownStillQTPreview.jpg'.
I was talking about 'TrailDownStillffmpeg.jpg' and 'TrailDown.mp4'. They look 
the same (except for the jpg compression of course).
All JPGs look the same to me color and brightness wise, except for 
'TrailDownStillQTScreenCap.jpg', which indeed has its brightness turned up (and 
by the looks of it has also underwent some sharpening).

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] MP4-->JPG changes brightness?

2021-05-15 Thread Reino Wijnsma
On 2021-05-15T08:15:16+0200, Steven Kan  wrote:
> Is there a flag I need to set in ffmpeg to get a jpg that looks like what 
> Preview produces? Is this error related to my issue?

Your 'TrailDownStillffmpeg.jpg' looks exactly like what I see when I open your 
'TrailDown.mp4', so if you ask me, there's no "error" at all.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] FFplay turkey

2021-05-15 Thread Reino Wijnsma
On 2021-05-13T10:36:09+0200, Bouke  wrote:
> When I run FFplay, and scale the window to something like 320x180, AND drag 
> the top to something smaller than 150:
>
> On doubleclick, fullscreen
> Next doubleclick, window scales back, but vertical position is now at the 
> bottom of the screen.
> When the small window is lower than 150 all is as expected. If the window is 
> bigger (no clue how big it must be), it also does not happen.
>
> This does not happen when I use the fullscreen button, and doubleclick to get 
> back to ’normal’
>
> Happens on OSX / catalina, have not tested other OS’s
I can't reproduce on Windows.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] Possible to change pitch of audio in a downloaded mp4 file?

2021-05-07 Thread Reino Wijnsma
On 2021-04-28T08:51:15+0200, Bo Berglund  wrote:
> So I wonder if there is an ffmpeg command that can modify the pitch of the 
> audio
> without changing the playback speed or lipsync?
Lower pitch: -af "asetrate=22050,aresample=44100,atempo=2"
Higher pitch: -af "asetrate=88200,aresample=44100,atempo=0.5"

Bonus; 440Hz to 432Hz tuning: -af 
"asetrate=44100*432/440,aresample=44100,atempo=440/432"

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


[FFmpeg-user] Why doesn't FFplay try to guess the channel layout of wav-files?

2021-05-07 Thread Reino Wijnsma
Hello ffmpeg-user and devs,

FFmpeg binary used:

ffmpeg version N-102342-g5541cff-Reino Copyright (c) 2000-2021 the FFmpeg 
developers
  built with gcc 10.3.0 (GCC)
  configuration: --arch=x86 --target-os=mingw32 
--prefix=/cygdrive/[...]/cross_compilers/mingw-w64-i686/i686-w64-mingw32 
--cross-prefix=/cygdrive/[...]/cross_compilers/mingw-w64-i686/bin/i686-w64-mingw32-
 --extra-cflags='-march=pentium3 -mtune=athlon-xp -O2 -mfpmath=sse -msse' 
--pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino 
--enable-gpl --enable-gray --enable-version3 --disable-debug --disable-doc 
--disable-htmlpages --disable-manpages --disable-mediafoundation 
--disable-podpages --disable-txtpages --disable-w32threads --enable-avisynth 
--enable-frei0r --enable-filter=frei0r --enable-gmp --enable-libaom 
--enable-libass --enable-libfdk-aac --enable-libflite --enable-libfontconfig 
--enable-libfreetype --enable-libfribidi --enable-libgme --enable-libmp3lame 
--enable-libopenmpt --enable-libopus --enable-libsoxr --enable-libtwolame 
--enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp 
--enable-libx264 --enable-libx265 --enable-libxml2
--enable-libxvid --enable-libzimg --enable-mbedtls
  libavutil  57.  0.100 / 57.  0.100
  libavcodec 59.  0.100 / 59.  0.100
  libavformat59.  0.100 / 59.  0.100
  libavdevice59.  0.100 / 59.  0.100
  libavfilter 8.  0.101 /  8.  0.101
  libswscale  6.  0.100 /  6.  0.100
  libswresample   4.  0.100 /  4.  0.100
  libpostproc56.  0.100 / 56.  0.100

Input file:

ffmpeg -v 40 -i "D:\input.wav" -f null NUL
[...]
Guessed Channel Layout for Input Stream #0.0 : stereo
Input #0, wav, from 'D:\input.wav':
  Duration: 00:00:25.50, bitrate: 1411 kb/s
  Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, stereo, s16, 
1411 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (pcm_s16le (native) -> pcm_s16le (native))
Press [q] to stop, [?] for help
[graph_0_in_0_0 @ 0510f980] tb:1/44100 samplefmt:s16 samplerate:44100 
chlayout:0x3
[...]

FFmpeg sets "-channel_layout stereo" in the background, hence "[graph_0_in_0_0 
@ 0510f980] ... chlayout:-0x3-".
FFplay for some reason doesn't guess the channel layout:

ffplay -v 40 -nodisp -autoexit "D:\input.wav"
[...]
Input #0, wav, from 'D:\input.wav':
  Duration: 00:00:25.50, bitrate: 1411 kb/s
  Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, 2 channels, 
s16, 1411 kb/s
[ffplay_abuffer @ 05b1e0c0] tb:1/44100 samplefmt:s16 samplerate:44100 
chlayout:-(null)-
[...]

It plays the wav-file nontheless. Problems start to occur however when 
audiofilters are applied, like when changing the tempo and pitch for instance.
No problem for FFmpeg:

ffmpeg -v 40 [-channel_layout stereo] -i "D:\input.wav" -af "asetrate=22050" -f 
null NUL
[...]
[graph_0_in_0_0 @ 05117c80] tb:1/44100 samplefmt:s16 samplerate:44100 
chlayout:0x3
Output #0, null, to 'NUL':
  Metadata:
encoder : Lavf59.0.100
  Stream #0:0: Audio: pcm_s16le, 22050 Hz, stereo, s16, 705 kb/s
[...]

But FFplay returns:

ffplay -v 40 -nodisp -autoexit -af "asetrate=22050" "D:\input.wav"
[...]
[ffplay_abuffer @ 05ad1200] tb:1/44100 samplefmt:s16 samplerate:44100 
chlayout:(null)
[Parsed_asetrate_0 @ 05b43300] auto-inserting filter 'auto_resampler_0' between 
the filter 'ffplay_abuffer' and the filter 'Parsed_asetrate_0'
[auto_resampler_0 @ 05a2d040] Cannot select channel layout for the link between 
filters auto_resampler_0 and Parsed_asetrate_0.
[auto_resampler_0 @ 05a2d040] Unknown channel layouts not supported, try 
specifying a channel layout using 'aformat=channel_layouts=something'.

It appears that "-channel_layout" isn't a valid option for FFplay, so would...

ffplay -v 40 -nodisp -autoexit -af "aformat=cl=stereo,asetrate=22050" 
"D:\input.wav"

...be the only way to set the channel layout (to satisfy asetrate at least)?
Isn't there a "-channel_layout" like option for FFplay to properly set the 
channel layout? But more importantly, why doesn't FFplay try to guess the 
channel layout of wav-files like FFmpeg does?

---

Small side question:

-af "loudnorm,aformat=cl=stereo,aresample=44100"
-af "loudnorm,aresample=44100:ocl=stereo"

Is there a difference between the two, or is the end result the same 
quality-wise?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".


Re: [FFmpeg-user] How to get he total number of frames

2021-03-11 Thread Reino Wijnsma
On 2021-03-09T20:43:21+0100, Mark Filipak (ffmpeg)  wrote:
> On 2021-03-09 03:58, Michael Koch wrote:
>> These links might help:
>> https://stackoverflow.com/questions/2017843/fetch-frame-count-with-ffmpeg
>> https://superuser.com/questions/1512575/why-total-frame-count-is-different-in-ffmpeg-than-ffprobe
>>
>> Michael
>
> Those links are really hard to follow and it's fruitless to try to find 
> what's there that works vs. what doesn't work.
>
> From Ulf Zibis:
> can one please tell me, how I can get the total number of frames of a video?
>
> Was Ulf's question actually answered? I think not.

How can you say that? These urls do exactly that. They offer a couple of 
solutions on how to get the total number of frames.
What is so hard to follow?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] FFmpeg list footer

2021-03-11 Thread Reino Wijnsma
On 2021-03-09T21:07:52+0100, Carl Zwanzig  wrote:
> The list FAQ should also be mentioned in the the welcome message. I raised 
> this, over a year ago to a/the list owner, who replied--
>>> Could we include the entire FAQ section 6.1 into the list welcome message? 
>>> (I don't know specifically who maintains the list.) That might
>>> cut down on some of the badly-written postings.
>
>> thanks for the input and it's definitely a good idea - if it cuts down
>> bad messages, well we might hope for that at least 0:-)
>
> But AFAIK nothing happened.

I would say, section 6.1 of the FAQ is something one has to explicitly agree 
with upon registering to ffmpeg-user, together with a three-strikes-you're-out 
rule. So an extra field in the "Subscribing to ffmpeg-user" section of 
https://ffmpeg.org/mailman/listinfo/ffmpeg-user. No need to change the footer 
this way.

However, as there's no authority to uphold these rules, this whole discussion 
is pointless if you ask me.
And it's even more pointless when certain long-time members on this list, 
including developers even who i.m.o. should be an example of how to use this 
mailinglist and its etiquette, think the rules don't apply to them.

Unless the etiquette will be enforced, I doubt anything will change.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] astats to csv file

2021-02-13 Thread Reino Wijnsma
On 2021-02-11T16:39:47+0100, Benjamin Houtman  wrote:
> I ran the
>
> ffprobe -f lavfi -i amovie=X.flac,astats=metadata=1 -show_frames -of csv
>
> command, but I don't need the entire printout, just the "Parsed_astats..."
> data that appears at the end of the printout. How would I limit the results
> to just that?
You could try Xidel [1] to parse FFprobe's output.

Assuming you're on Windows:

ffprobe -f lavfi -i "amovie='X.flac',astats=metadata=1" 2>&1 | xidel - -se 
"x:lines($raw)[starts-with(.,'[Parsed_astats')] ! replace(substring(.,30),': 
',',')"

Swap the single- and double-quotes if you're on Unix.

[1]: http://videlibri.sourceforge.net/xidel.html

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] List etiquette [was: Re: alternating checkerboard]

2021-02-09 Thread Reino Wijnsma
On 2021-02-09T18:19:27+0100, Carl Eugen Hoyos  wrote:
> Am Di., 9. Feb. 2021 um 18:06 Uhr schrieb Carl Zwanzig :
>
> [...]
>
> Please stop this.
Double standards, Carl?

You're always quick to warn people to not top-post on this mailing list (and 
rightly so!), but now that it concerns a developer here it's not important that 
also he respects the rules/etiquette? I'm baffled!

I fully agree with Carl Zwanzig. The rules apply to all users.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Subtitles disappear

2021-01-05 Thread Reino Wijnsma
On 2021-01-05T12:18:34+0100, Cecil Westerhof via ffmpeg-user 
 wrote:
> I tried it. But at the moment the files generated are about 20% bigger.
libmp3lame's -q:a 9 compared to what?

By default without any additional options...

ffmpeg -i input.wav [-c:a libmp3lame] output.mp3
ffmpeg -i input.wav [-c:a aac] output.m4a

...ffmpeg uses 128kbit/s for both outputs.
See https://trac.ffmpeg.org/wiki/Encode/AAC#NativeFFmpegAACEncoder on how to 
change the bitrate.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Subtitles disappear

2021-01-04 Thread Reino Wijnsma
On 2021-01-04T02:00:19+0100, Cecil Westerhof via ffmpeg-user 
 wrote:
> I convert a video with the following statement
> ffmpeg -y -i input.mkv -nostdin -vf scale=1024:-2 -crf 23 -acodec 
> libmp3lame -qscale:a 9 -preset veryfast Temp/output.mp4
>
> The input file has subtitles, but the output file does not.
> What to change to have also subtitles in the output file?
>
> And if I can do things better, I do not mind to hear it. ;-)

On 2021-01-04T15:52:39+0100, Cecil Westerhof via ffmpeg-user 
 wrote:
> Input #0, matroska,webm, from 'input.mkv':
> [...]
> Stream #0:2(eng): Subtitle: subrip (default)

Mp4doesn't support subrip. Please use -c:s mov_text.

I wouldn't recommend muxing an mp3 audiostream in mp4 btw. Aac is more widely 
supported.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Compilation Guide / MSVC on Wiki

2020-12-02 Thread Reino Wijnsma
On 2020-12-02T22:20:25+0100, hinderanyoption81 via ffmpeg-user 
 wrote:
> Do you know where I could get pre-built .LIB etc. files old enough to be used 
> under Windows XP?
You could give https://forum.doom9.org/showthread.php?t=181802 a try.

-- 
Reino

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://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] keepalive request failed

2020-10-25 Thread Reino Wijnsma
Hello Edward,

On 2020-10-25T03:07:02+0100, Edward Park  wrote:
>>> ffmpeg -fflags +igndts -i 
>>> "https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502.m3u8;
>>>  -i "https://vod-kijk2-prod.talpatvcdn.nl/webvtt/760978E1.vtt; -c copy -c:s 
>>> srt "output.mkv"
>>> [...]
>>> [mpegts @ 0500f040] PES packet size mismatchime=00:32:30.87 
>>> bitrate=3177.6kbits/s speed=2.52x
>>> [...]
>> To answer my own question: adding the flag "discardcorrupt" (-fflags 
>> +discardcorrupt+igndts) fixes the issue and keeps the process going. 
> Glad you found a workaround, but that’s a stopgap measure at best right? The 
> “I/O error” messages are still encountered and new ssl sessions are 
> established? Maybe there is a problem with how mbedtls is used in ffmpeg?

You're actually right. It doesn't fix the issue. Having watched the resulting 
video I noticed the corrupt parts to be missing indeed. They caused small gaps 
of around 1 second in duration.
I'm not a FFmpeg developer, so I can't comment on the implementation of mbedTLS.

Earlier I have already tried different -reconnect* options, but to no avail.

-- 
Reino

___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://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] keepalive request failed

2020-10-24 Thread Reino Wijnsma
On 2020-10-24T00:12:30+0200, Reino Wijnsma  wrote:
> ffmpeg -fflags +igndts -i 
> "https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502.m3u8;
>  -i "https://vod-kijk2-prod.talpatvcdn.nl/webvtt/760978E1.vtt; -c copy -c:s 
> srt "output.mkv"
> [...]
> [mpegts @ 0500f040] PES packet size mismatchime=00:32:30.87 
> bitrate=3177.6kbits/s speed=2.52x
> [...]
To answer my own question: adding the flag "discardcorrupt" (-fflags 
+discardcorrupt+igndts) fixes the issue and keeps the process going.

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] [hls] keepalive request failed

2020-10-23 Thread Reino Wijnsma
Hello ffmpeg-user,

ffmpeg -fflags +igndts -i 
"https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502.m3u8;
 -i "https://vod-kijk2-prod.talpatvcdn.nl/webvtt/760978E1.vtt; -c copy -c:s srt 
"output.mkv"
ffmpeg version N-98939-g276d86a-Reino Copyright (c) 2000-2020 the FFmpeg 
developers
  built with gcc 10.2.0 (GCC)
  configuration: --arch=x86 --target-os=mingw32 
--prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/i686-w64-mingw32
 
--cross-prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/bin/i686-w64-mingw32-
 --extra-cflags='-march=pentium3 -mtune=athlon-xp -O2 -mfpmath=sse -msse' 
--pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino 
--enable-gpl --enable-gray --enable-version3 --disable-debug --disable-doc 
--disable-htmlpages --disable-manpages --disable-mediafoundation 
--disable-podpages --disable-txtpages --disable-w32threads --enable-avisynth 
--enable-frei0r --enable-filter=frei0r --enable-gmp --enable-libaom 
--enable-libass --enable-libfdk-aac --enable-libflite --enable-libfontconfig 
--enable-libfreetype --enable-libfribidi --enable-libgme --enable-libmp3lame 
--enable-libopenmpt --enable-libopus --enable-libsoxr --enable-libtwolame
--enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libwebp 
--enable-libx264 --enable-libx265 --enable-libxml2 --enable-libxvid 
--enable-libzimg --enable-mbedtls
  libavutil  56. 58.100 / 56. 58.100
  libavcodec 58.101.101 / 58.101.101
  libavformat58. 51.101 / 58. 51.101
  libavdevice58. 11.101 / 58. 11.101
  libavfilter 7. 87.100 /  7. 87.100
  libswscale  5.  8.100 /  5.  8.100
  libswresample   3.  8.100 /  3.  8.100
  libpostproc55.  8.100 / 55.  8.100
[...]
[tls @ 0500e240] mbedtls_ssl_read reported connection reset by 
peer=3177.6kbits/s speed=2.52x
[mpegts @ 0500f040] Invalid timestamps stream=1, pts=176367600, dts=176371200, 
size=1398
[mpegts @ 0500f040] Invalid timestamps stream=1, pts=176371200, dts=176374800, 
size=1596
[tcp @ 05678300] ffurl_read returned 0xdfb9b0bb
[https @ 05909880] Opening 
'https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502-977.ts'
 for reading
[tcp @ 05678300] ffurl_read returned 0xdfb9b0bb
[hls @ 050098c0] keepalive request failed for 
'https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502-977.ts'
 with error: 'I/O error' when opening url, retrying with new connection
[hls @ 050098c0] Opening 
'https://vod-kijk2-prod.talpatvcdn.nl/GIEBboXaKkD/3bf69d5f-da4f-7756-7e3d-ad8d1295f936/GIEBboXaKkD-index.ism/GIEBboXaKkD-index-audio=16-video=3031502-977.ts'
 for reading
[mpegts @ 0500f040] PES packet size mismatchime=00:32:30.87 
bitrate=3177.6kbits/s speed=2.52x
[mpegts @ 0500f040] Packet corrupt (stream = 0, dts = 176377320).
[mpegts @ 0500f040] Packet corrupt (stream = 1, dts = 176378400).
[mpegts @ 0500f040] Invalid timestamps stream=1, pts=176403600, dts=176407200, 
size=2256
[aac_adtstoasc @ 05a0dfc0] Error parsing ADTS frame header!
[matroska @ 05f98040] Error applying bitstream filters to an output packet for 
stream #1: Invalid data found when processing input
av_interleaved_write_frame(): Invalid data found when processing input
[mpegts @ 0500f040] Invalid timestamps stream=1, pts=176407200, dts=176410800, 
size=2126
frame=48747 fps= 63 q=-1.0 Lsize=  757780kB time=00:32:30.87 
bitrate=3182.0kbits/s speed=2.52x
video:718571kB audio:38708kB subtitle:8kB other streams:0kB global headers:0kB 
muxing overhead: 0.065088%
Conversion failed!

I've been saving videos from Kijk for some time now and never did I have any 
problems with this command and other videos, until now.
It also appears to be pretty random; here it fails at segment #977, but the 
next time it'll fail at #450 for instance.

Has anyone encountered this before? Can this be solved with a specific 
command-line option?

-- 
Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] libx265 a lot slower

2020-08-17 Thread Reino Wijnsma
On 2020-08-17T18:07:54+0200, Phil Rhodes via ffmpeg-user 
 wrote:
> The reason people are complaining is nothing to do with the logic of what 
> you're saying.
> It's because you're so incredibly impolite about it.

And you're being rude for not following this mailinglist's netiquette.
You're subscribed here long enough to know that top-posting is not allowed.
 
> To put it succinctly, you are a very good example of what is wrong with open 
> source software in general.

Was this really necessary?

-- 
Reino Wijnsma

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Fwd: Need help splitting stereo FLAC into two separate files

2020-04-05 Thread Reino Wijnsma
On 2020-04-05T20:39:02+0200, Net Net  wrote:
> I understand MS batch files in general but the %~nA would have taken
> a long time to discover and get working.
Please have a look at...

FOR /?

...and especially the last couple of paragraphs.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Need help splitting stereo FLAC into two separate files

2020-04-05 Thread Reino Wijnsma
On 2020-04-05T18:45:27+0200, Net Net  wrote:
> [...] I tried map_channel and it worked great for a single file:
>
> *ffmpeg -i 1.flac -map_channel 0.0.0 1left.flac -map_channel 0.0.1 
> 1right.flac*
>
> Now, I have several hundred of these flacs to split, named 001.flac,
> 002.flac, 003.flac etc.  I want them to be split into eg. 001left.flac,
> 001right.flac etc.  A few attempts with Windows wildcards didn't work.
> Can anyone tell me how, or point me to the right documentation pack for
> figuring this out?
Use a for-loop:

FOR %A IN (*.flac) DO @ffmpeg -i %A -map_channel 0.0.0 %~nAleft%~xA 
-map_channel 0.0.1 %~nAright%~xA

This will process all flac-files sorted by filename. If you want to process 
them sorted by date for instance, then you can do:

FOR /F "delims=" %A IN ('DIR /B /O:D *.flac') DO @ffmpeg -i %A -map_channel 
0.0.0 %~nAleft%~xA -map_channel 0.0.1 %~nAright%~xA

-- Reino

P.s. Please don't top-post  here. Thank 
you.
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] Seeking programmable decomber

2020-04-03 Thread Reino Wijnsma
On 2020-04-03T17:17:07+0200, Paul B Mahol  wrote:
> On 4/3/20, Mark Filipak  wrote:
>> I have a video with P (progressive) and C (combed) frames as follows:
>> P P C P P P P C P P P P C P P P P C etc.
>> I seek a programmable decomber that decombs only frames 3, 8, 13, 18, etc.
>>
>> Do you have any ideas?
>>
> Nope.
Could you please stop this utter nonsense! Such childish behaviour is unworthy 
of this mailinglist and VERY irritating!

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] drawtext, suggestion for improvement

2020-03-27 Thread Reino Wijnsma
On 2020-03-27T23:25:09+0100, Michael Koch  wrote:
> Am 27.03.2020 um 22:58 schrieb Reino Wijnsma:
>> Your FFmpeg binary looks very recent, but what about the FontConfig library 
>> you compiled this FFmpeg binary with?
> I didn't compile it myself, it's the Windows version from Zeranoe.
Then Kyle knows what to do. If he's not subscribed to this list, then you might 
want to reach out to him.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] drawtext, suggestion for improvement

2020-03-27 Thread Reino Wijnsma
Hello Michael,

On 2020-03-26T20:28:02+0100, Michael Koch  wrote:
> How to reproduce:
> Use Windows Notepad to create a UTF-8 text file which contains only the word 
> "test".
> This is how the file looks in a hex editor:
> EF BB BF 74 65 73 74
>
> Now run this command line and have a look at the output image.
>
> C:\Users\mKoch\Desktop>c:\ffmpeg\ffmpeg -f lavfi -i color=c=white -vf 
> drawtext=textfile=test.txt -frames 1 -y out.png
> ffmpeg version git-2020-03-23-ba698a2 Copyright (c) 2000-2020 the FFmpeg 
> developers
>   built with gcc 9.2.1 (GCC) 20200122
>   [...]
Your FFmpeg binary looks very recent, but what about the FontConfig library you 
compiled this FFmpeg binary with?

I was only able to reproduce this with one of the very first FFmpeg binaries I 
compiled myself (N-86393, dated 2017-06-06 and compiled with FontConfig 2.12.1).
The next FFmpeg binary I compiled (N-86763, dated 2017-07-12 and compiled with 
FontConfig 2.12.4), and all that come after it, don't show this behaviour.

I think updating FontConfig (and recompiling FFmpeg) would most likely solve 
your problem.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] email line wrapping (was Re: How to compress .MOV file ...)

2020-03-13 Thread Reino Wijnsma
On 2020-03-12T02:49:02+0100, Mark Filipak 
 wrote:
> [...] since my own submissions are not echoed
Log in to https://ffmpeg.org/mailman/options/ffmpeg-user.
Set "Receive your own posts to the list?" to "Yes".

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to compress .MOV file compatible to Canon camera

2020-03-13 Thread Reino Wijnsma
On 2020-03-12T10:38:43+0100, Ulf Zibis  wrote:
> Am 12.03.20 um 02:24 schrieb Ted Park:
>>> ... and how can I avoid this, or which argument should I pass to
>>> -video_track_timescale ?
>> Passing the timescale to that option would work I think.
> And which value should I choose?
See https://stackoverflow.com/a/43337235.
So -video_track_timescale 60k for instance.

> (difficult to know, as "video_track_timescale" is nowhere documented)
ffmpeg -hide_banner -h muxer=mov | grep "video_track_timescale"
  -video_track_timescale E. set timescale of all video 
tracks (from 0 to INT_MAX) (default 0)


I had a look at your 'MVI_1324.MOV'.
ffmpeg -i MVI_1324.MOV -c:v libx264 -preset ultrafast -level 4.1 -g 15 
-colorspace smpte170m -color_primaries bt709 -color_trc bt709 
-video_track_timescale 60k -c:a copy -map_metadata 0 MVI_1324_test.MOV

diff -u <(ffmpeg -i MVI_1324.MOV 2>&1) <(ffmpeg -i MVI_1324_test.MOV 2>&1)
--- /dev/fd/63  2020-03-13 16:54:23.0 +0100
+++ /dev/fd/62  2020-03-13 16:54:23.0 +0100
@@ -9,17 +9,21 @@
   libswscale  5.  6.100 /  5.  6.100
   libswresample   3.  6.100 /  3.  6.100
   libpostproc55.  6.100 / 55.  6.100
-Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'MVI_1324.MOV':
+Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'MVI_1324_test.MOV':
   Metadata:
 major_brand : qt
-minor_version   : 537331968
-compatible_brands: qt  CAEP
+minor_version   : 512
+compatible_brands: qt
 creation_time   : 2020-02-05T20:17:27.00Z
-  Duration: 00:00:29.10, start: 0.00, bitrate: 23351 kb/s
-Stream #0:0(eng): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), 
yuvj420p(pc, smpte170m/bt709/bt709), 1280x720, 23228 kb/s, 29.97 fps, 29.97 
tbr, 30k tbn, 60k tbc (default)
+encoder : Lavf58.35.101
+  Duration: 00:00:29.10, start: 0.00, bitrate: 9374 kb/s
+Stream #0:0(eng): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), 
yuvj420p(pc, smpte170m/bt709/bt709), 1280x720, 9276 kb/s, 29.97 fps, 29.97 tbr, 
60k tbn, 59.94 tbc (default)
 Metadata:
   creation_time   : 2020-02-05T20:17:27.00Z
+  handler_name: VideoHandler
+  encoder : Lavc58.65.102 libx264
 Stream #0:1(eng): Audio: pcm_u8 (raw  / 0x20776172), 12000 Hz, mono, u8, 
96 kb/s (default)
 Metadata:
   creation_time   : 2020-02-05T20:17:27.00Z
+  handler_name: SoundHandler
 At least one output file must be specified

-video_track_timescale 60k changes "30k tbn" to "60k tbn". So it doesn't change 
"tbc" at all.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] What argument(s) does 'ashowinfo' take?

2020-03-02 Thread Reino Wijnsma
On 2020-03-02T15:35:11+0100, Gyan Doshi  wrote:
> On 02-03-2020 06:24 pm, Mark Filipak wrote:
>> C:\CMD & tiny apps\ffmpeg >ffprobe -f lavfi 
>> amovie=G:\\VIDEO_TS\\VTS_01_1.VOB,ashowinfo
>> --note escaped '\'s in path to 'VTS_01_1.VOB'--
>> fails; "movie=G:\\VIDEO_TS\\VTS_01_1.VOB,showinfo: No such file or 
>> directory".
>
> Double escape the : and use forward slashes
>
> movie=G\\:/path/to/file
Especially when your map/path contains spaces, your safest bet would be to use 
quotes:

ffprobe -f lavfi "amovie='G\:/VIDEO_TS/VTS_01_1.VOB',ashowinfo"

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to remove rotation of a video?

2020-03-01 Thread Reino Wijnsma
On 2020-02-27T13:23:02+0100, Ulf Zibis  wrote:
> unfortunately I now see, that there is a problem with that. Some other
> tags were completely removed, e.g. creation time, geo tags, etc
>
> What must I do to preserve all tags?
I believe the -map_metadata option is what you're looking for.

ffmpeg -i  -map_metadata 0 -metadata:s:v rotate=0 -c copy 

-- Reino

P.s. top-posting here is considered rude, so please stop it.
___
ffmpeg-user mailing list
ffmpeg-user@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-user

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] WebVTT demuxer ignores processing every 1st line of each follow-up HLS webvtt-segment

2020-02-16 Thread Reino Wijnsma
Hello ffmpeg-user,

While reading this 
 
Github-issue-comment and testing the mentioned HLS-webvtt-url I first of all 
noticed that, unlike the user claims, ffmpeg does demux all the 
webvtt-segments. Why this is not happening for this user is most likely because 
of the old ffmpeg-binary he/she uses.
Secondly, what does happen is that ffmpeg doesn't remove the 2nd line of each 
webvtt-segment (except for the 1st segment).

The first webvtt-segment, 
'https://ga.video.cdn.pbs.org/videos/frontline/8f769cee-b6d6-437d-80b5-74252ed7642d/2000150564/hd-16x9-mezzanine-1080p/3717fes-captions0.vtt':

WEBVTT
X-TIMESTAMP-MAP=MPEGTS:187507, LOCAL:00:00:00.000

00:13.400 --> 00:17.400 position:10%,start line:85% size:80%
♪ ♪

00:17.400 --> 00:20.080 position:10%,start line:85% size:80%
WAAD (speaking Arabic):

[...]

03:11.320 --> 03:13.400 position:10%,start line:85% size:80%
(explosion roars)


With [ffmpeg -i 
https://ga.video.cdn.pbs.org/videos/frontline/8f769cee-b6d6-437d-80b5-74252ed7642d/2000150564/hd-16x9-mezzanine-1080p/3717fes-captions0.vtt
 3717fes-captions0.vtt] ffmpeg converts this to...

WEBVTT

00:13.400 --> 00:17.400
♪ ♪

00:17.400 --> 00:20.080
WAAD (speaking Arabic):

[...]

03:11.320 --> 03:13.400
(explosion roars)


...which is expected.
Converting the entire stream with [ffmpeg -i 
https://ga.video.cdn.pbs.org/videos/frontline/8f769cee-b6d6-437d-80b5-74252ed7642d/2000150564/hd-16x9-mezzanine-1080p/3717fes-captions.m3u8
 3717fes-captions.vtt] ffmpeg puts out...

WEBVTT

00:13.400 --> 00:17.400
♪ ♪

00:17.400 --> 00:20.080
WAAD (speaking Arabic):

[...]

03:11.320 --> 03:13.400
(explosion roars)
WEBVTT
X-TIMESTAMP-MAP=MPEGTS:187507, LOCAL:00:00:00.000

03:11.320 --> 03:13.400
(explosion roars)

[...]

05:56.440 --> 05:59.320
WAAD:
WEBVTT
X-TIMESTAMP-MAP=MPEGTS:187507, LOCAL:00:00:00.000

06:14.720 --> 06:16.800
(numerous explosions booming)

[...]

09:09.400 --> 09:12.960
MAN:
WEBVTT
X-TIMESTAMP-MAP=MPEGTS:187507, LOCAL:00:00:00.000

09:23.400 --> 09:25.440
SOLDIER:

[...]


So the very first "WEBVTT\nX-TIMESTAMP-MAP=MPEGTS:187507, LOCAL:00:00:00.000" 
does become "WEBVTT" and all the following instances (at the beginning of each 
webvtt-segment) should've been removed, but are simply ignored/copied.
Also allowing duplicate entries ("03:11.320 --> 03:13.400\n(explosion roars)") 
is weird to say the least.

FFmpeg used:

ffmpeg version N-96249-g81172b5-Reino Copyright (c) 2000-2020 the FFmpeg 
developers
  built with gcc 9.2.0 (GCC)
  configuration: --arch=x86 --target-os=mingw32 
--cross-prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/bin/i686-w64-mingw32-
 --pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino 
--enable-gray --enable-version3 --disable-debug --disable-doc 
--disable-htmlpages --disable-manpages --disable-podpages --disable-txtpages 
--disable-w32threads --enable-avisynth --enable-frei0r --enable-filter=frei0r 
--enable-gmp --enable-gpl --enable-libaom --enable-libass --enable-libfdk-aac 
--enable-libflite --enable-libfontconfig --enable-libfreetype 
--enable-libfribidi --enable-libgme --enable-libmp3lame --enable-libopenmpt 
--enable-libopus --enable-libsoxr --enable-libvidstab --enable-libvorbis 
--enable-libvpx --enable-libwebp --enable-libx264 --enable-libx265 
--enable-libxml2 --enable-mbedtls --extra-cflags='-march=pentium3' 
--extra-cflags='-mtune=athlon-xp' --extra-cflags=-O2 
--extra-cflags='-mfpmath=sse'
--extra-cflags=-msse --enable-static --disable-shared 
--prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/i686-w64-mingw32
  libavutil  56. 38.100 / 56. 38.100
  libavcodec 58. 65.102 / 58. 65.102
  libavformat58. 35.101 / 58. 35.101
  libavdevice58.  9.102 / 58.  9.102
  libavfilter 7. 70.101 /  7. 70.101
  libswscale  5.  6.100 /  5.  6.100
  libswresample   3.  6.100 /  3.  6.100
  libpostproc55.  6.100 / 55.  6.100

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to decrypt .ts files into separate .ts files with ffmpeg without using a playlist?

2020-02-12 Thread Reino Wijnsma
On 2020-02-10T16:55:04+0100, Micael Silva  wrote:
> You can decrypt single files using "ffmpeg  -key (hex key) -iv (hex IV,
> required) -i crypto+file:/path/to/file.ts"
Hmm, never knew this was possible. Very interesting.
Thanks, Micael!

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-09 Thread Reino Wijnsma
On 2020-02-09T17:43:39+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> I finally got the right commandline. I'll provide this solution for others, 
> so they don't have to spend so much time on a simple task.
Ah, you already found out. And with practically the same commandline.
I'm glad you succeeded.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-09 Thread Reino Wijnsma
On 2020-02-09T14:41:23+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> I just made a sample as you describe. But i think it is useless as the copy 
> only contains video, sound and no dvb_teletext.

I forgot -map 0 to return ALL input streams, so: ffmpeg -ss 00:04:45 -i 'Beck_ 
_je for _je (4).ts' -to 00:05:00 *-map 0* -c copy sample.ts

BUT apparently this is not the recommended method. I wish Carl, instead of 
shouting to avoid this at all cost, would explain WHY.
I found https://ffmpeg.org/pipermail/ffmpeg-user/2019-October/045728.html.
I understand...

dd if=input.ts bs=188 skip=27888 count=55775 of=output.ts

...for instance would skip 188*27888=5242944bytes (around 5M) and extract 
188*55775=10485700 (around 10M), but I don't understand where the 188 comes 
from.

Also, I think it's very hard to find out what amount of bytes equates to 
00:04:45, or isn't it?

On 2020-02-09T15:16:30+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
>> Hey Reino.
>> Just a test as you suggestet, but it will create a new error. I correctet 
>> the channels that need to be encoded.
> ffmpeg -ss 00:04:45 -c:v h264_mmal -i 'Beck_ _je for _je (4).ts' -to 00:05:00 
> -map 0:0 -c:v h264_omx -b:v 4800k -map 0:2 -c:a copy -map 0:1 -txt_format 
> text -txt_page 599 -c:s mov_text -metadata:s:s language=dan 'Beck _je for _je 
> (4).mp4'
> [...]
> Stream mapping:
>   Stream #0:0 -> #0:0 (h264 (h264_mmal) -> h264 (h264_omx))
>   Stream #0:2 -> #0:1 (copy)
>   Stream #0:1 -> #0:2 (dvb_teletext (libzvbi_teletextdec) -> mov_text 
> (native))
> Error while opening encoder for output stream #0:2 - maybe incorrect 
> parameters such as bit_rate, rate, width or height

What I understand from this 
https://ffmpeg.org/pipermail/ffmpeg-user/2016-February/030792.html huge thread 
is that the libzvbi-options are actually input-options and that 
-fix_sub_duration is probably needed, so...

ffmpeg -ss 00:04:45 -fix_sub_duration -txt_format text -txt_page 599 -c:v 
h264_mmal -i 'Beck_ _je for _je (4).ts' -to 00:05:00 -map 0:0 -c:v h264_omx 
-b:v 4800k -map 0:2 -c:a copy -map 0:1 -c:s mov_text -metadata:s:s language=dan 
'Beck _je for _je (4).mp4'

...could be worth a try.

-- Reino

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-08 Thread Reino Wijnsma
On 2020-02-09T02:29:18+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> I dont have 15 sec sample.

ffmpeg -ss 00:04:45 -i 'Beck_ _je for _je (4).ts' -to 00:05:00 -c copy sample.ts

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-08 Thread Reino Wijnsma
On 2020-02-09T01:59:53+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> ffmpeg -txt_format text -txt_page 599 -ss 00:04:45 -i 'Beck_ _je for _je 
> (4).ts' -to 00:05:00 -map 0:s:0 -c:s:2 mov_text -metadata:s:2 language=dan 
> 'Beck _je for _je (4).srt'
> The -txt_page number i get by using VLC. So now i have the .srt file. Don't 
> know how else to get ffmpeg to pick that one subtitle.
> Then i encode my video as i always do.
> Then i combine it with:
> ffmpeg -i 'Beck _je for _je (4).mp4' -i 'Beck _je for _je (4).srt' -c:v copy 
> -c:a copy -c:s mov_text 'test.mp4'
> This seems to be working. But is a long way to go.

ffmpeg -ss 00:04:45 -c:v h264_mmal -i 'Beck_ _je for _je (4).ts' -to 00:05:00 
-map 0:0 -c:v h264_omx -b:v 4800k -map 0:2 -map 0:3 -c:a copy -map 0:1 
-txt_format text -txt_page 599 -c:s mov_text -metadata:s:s language=dan 'Beck 
Øje for øje (4).mp4'

Wouldn't this work? But again, without a sample we can't verify.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-08 Thread Reino Wijnsma
On 2020-02-09T00:15:43+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
>> Now i'm trying a new approach. I actually got the dvb text out of the 
>> dvb_teletext into a seperate .srt file.
>> But now i have a new issue.
>> I do not only get the subtitle i need but all of them. So when playing the 
>> .mp4 with .srt on Kodi, my screens is filled with all 4 subtitles!
>> I do extract with this command:
>> ffmpeg -txt_format text -ss 00:04:45 -i 'Beck_ _je for _je (4).ts' -to 
>> 00:05:00 -map 0:s:0 -c:s:2 mov_text -metadata:s:s:2 language=dan 'Beck _je 
>> for _je (4).srt'
>> So how do i get only the one subtitle that i need?

Could you share your 15sec ts-file so that we can have a look? Otherwise I 
don't have any idea what you're talking about.
Also please tell us exactly what your expected output needs to be.

And btw, you put your reply in the same blockquote as your previous 
e-mail/post, which is quite confusing. So please put your reply underneath the 
blockquote, not in it.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-08 Thread Reino Wijnsma
On 2020-02-08T20:47:35+0100, Robin A. Jensen via ffmpeg-user 
 wrote:

> No one of them is getting me any closer. Just the same error:
> [...]
> Stream #0:4[0x12]: Data: epg
> Beck Øje for øje (4).mp4: Invalid or incomplete multibyte or wide character

I'm no FFmpeg expert, but from what I can find this probably means certain 
characters can't be converted to mov_text. I'm not sure though.

On 2020-02-08T20:12:32+0100, Robin A. Jensen via ffmpeg-user 
 wrote:

> ffmpeg -ss 00:04:45 -c:v h264_mmal -i 'Beck_ _je for _je (4).ts' -to 00:05:00 
> -map 0:0 -map 0:1 -map 0:2 -c:v h264_omx -b:v 4800k -c:a:0 copy -c:s:0 copy 
> -metadata:0:1:2 language=dan 'Beck Øje for øje (4).mp4

I don't have any experience with a Raspberry Pi, but I can't believe putting 
both -c:v h264_mmal and -c:v h264_omx in your commandline would work.
Except for the video-bitrate you're not changing anything else, so why not do a 
streamcopy instead?Also the order of your options matters. Could you try:

ffmpeg -ss 00:04:45 -i 'Beck_ _je for _je (4).ts' -to 00:05:00 -map 0:0 -map 
0:2 -map 0:3 -c copy -map 0:1 -c:s mov_text -metadata:s:s language=dan 'Beck 
Øje for øje (4).mp4'

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] How to get DVB-Teletxt into MP4

2020-02-08 Thread Reino Wijnsma
On 2020-02-08T20:12:32+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> Den 08-02-2020 kl. 20:06 skrev James Darnley:
>> On 2020-02-08 19:38, Robin A. Jensen via ffmpeg-user wrote:
>>> -c:s:0 copy mov_text
>> Make up your mind.  codec copy or codec mov_text?
> That command is in the wiki. Apparently it used because of the mp4.
> This is the command:
>
> *-scodec*  [/*subtitle codec*/]
> for*MP4*  containers:|*copy*|,|*mov_text

That's 
https://en.wikibooks.org/wiki/FFMPEG_An_Intermediate_Guide/subtitle_options#Set_Subtitle_Codec
 I take it?
You noticed it says "parameter example*s*"? Plural! Meaning it's either "copy", 
or "mov_text". Not both.
So it's -c:s:0 mov_text what you want.

On 2020-02-08T20:01:31+0100, Robin A. Jensen via ffmpeg-user 
 wrote:
> I don't know what you mean with top-post mailing list. I just use button 
> "Answer list, so now i m,ove answer to buttom of mail.

You could've used Google to find out of course, but posting your answer beneath 
the quoted message (or "bottom-posting") is exactly the etiquette here.
Next time please remove the footer (from "ffmpeg-user mailing list" downward) 
as well.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] ffmpeg convert mp3 to opus codec (contained in ogg format)?

2019-07-18 Thread Reino Wijnsma
First of all (again), stop top-posting here!

On 18-7-2019 15:36, Robert Keir  wrote:
> I'm trying to convert an mp3 file to ogg file to send through to a WhatApp 
> contact through their API. The Whatsapp API only accepts " audio ogg-file in 
> opus codec".

So if I understand correctly, you're pressing the paperclip and "Audio"? If so, 
then I guess Whatsapp will always convert this audiofile indeed.
Instead, simply press the paperclip and "Document" to send the mp3 file as is. 
Then you don't have to convert to opus either.

> I convert it using 
>
> ffmpeg -i audio.mp3 -c:a libopus newfilename.ogg

On 18-7-2019 15:30, Ted Park  wrote:
> ffmpeg -i audio.mp3 -c:a libopus -b 19.1k -ac 1 -r 16k newfilename.ogg

Why haven't you tried the command suggested by Ted?

-b 19.1k needs to be -b:a 19.1k btw.
Opus uses 1 samplerate: 48000Hz. So -r 16k would only needlessly hurt your 
audiofile.
But again, if above works, then you don't have to convert to opus in the first 
place.

On 18-7-2019 15:23, Robert Keir  wrote:
> Is the Writing library " Lavf58.28.102" the same as "WhatsApp"?

This 'opusvoice.ogg' file of yours was made by Whatsapp.
You used FFmpeg to create 'newfilename.ogg' which used the "Lavf58.28.102" 
library to convert the audio to opus.
That's all.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] ffmpeg convert mp3 to opus codec (contained in ogg format)?

2019-07-18 Thread Reino Wijnsma
On 18-7-2019 14:37, Robert Keir  wrote:
> I need to convert an MP3 to OGG (opus codec). I need to execute this (below)
> in PHP.
>
> ffmpeg -i filename.mp3 c:a libopus newfilename.ogg
>
> Is this correct?

Except for the dash you forgot ( -c:a libopus) this is indeed a very basic 
conversion to opus.

In general converting a lossy format to another (mp3 to opus) is frowned upon.
It's recommended to convert the original lossless format (wav, flac, etc) if 
you still have it.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] amix: Hard limit for number of inputs?

2019-07-16 Thread Reino Wijnsma
On 16-7-2019 18:56, Paul B Mahol  wrote:
> On 7/16/19, Reino Wijnsma  wrote:
>> Let me ask you this: How can I do MixAudio(clip1,clip2,1.0,1.0) with ffmpeg
>> leaving the volume completely untouched?
> There is currently no way.

Hmm, alright. That's very clear.

I'm no expert, but isn't/wasn't implementing volume renormalization in amix 
much harder than adding an option to leave the volume completely untouched?

Would creating a ticket to request this option be worthwhile.

I noticed that you're the author of adelay. Do you want me to create a ticket 
to request the single time entry for all channels?

Thanks.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] amix: Hard limit for number of inputs?

2019-07-16 Thread Reino Wijnsma
On 16-7-2019 17:45, Paul B Mahol  wrote:
> On 7/16/19, Reino Wijnsma  wrote:
>> I can't use these filters. Have a look at the Youtube video please.
>> I wish it was a simple matter of just concatenating all segments, but it
>> isn't, because the segments don't align perfectly.
>> Each segments has to start at a very specific time.
>> Then it's a matter of mixing everything at full volume(!), so there's no
>> fading involved at all.
> acrossfade can just *join* it with nofade curve, which basically disables 
> fading.

But that's the point, I need to *mix*all segments, not join/concatthem.

> On 7/16/19, Reino Wijnsma  wrote:
>> Do you happen to know why ffmpeg reports a completely wrong duration?
>>
>> Related question/suggestion:
>> It's really cumbersome to always having to specify the delay for all(!)
>> channels: [1]adelay=158792S|158792S[E2];
>> How about a default behaviour where specifying an amount of
>> milliseconds/samples once(!) applies to all channels: [1]adelay=158792S[E2];
>> And if you want a specific delay for another channel, then you can do so as
>> is already possible.
>> This would make my commandline a lot shorter!
> The thing with amix is that by *reducing volume* by mixing and adding it
> back with volume,
> you basically loose quality. It is more obvious with float sample
> format then double one.

I'm actually trying to prefend volume reduction. I only want to mix all 
segments.

(I noticed I forgot to attach the Avisynth script I used years ago. Attached 
now.)
In the Avisynth script I align all segments (with sample precision) and mix 
everything with full volume: MixAudio(clip1,clip2,1.0,1.0)

ffmpeg.exe -h filter=amix
[...]
  weights..F.A Set weight for each input. (default 
"1 1")

I figure "1 1" does the same as MixAudio(clip1,clip2,1.0,1.0), doesn't it? But 
amix still reduces the volume dramatically.

Let me ask you this: How can I do MixAudio(clip1,clip2,1.0,1.0) with ffmpeg 
leaving the volume completely untouched?

> Option could be added to amix filter to just sum samples as is.

You mean the adelay filter, right?

> Also what ffmpeg version you are using?
Please see my first post.

On 16-7-2019 18:36, Paul B Mahol  wrote:
> Actually ffmpeg is behaving correctly, your [29]adelay is missing one S.
Well I'll be darned. A typo. Thanks!
That solves that problem, but the volume issue remains.

-- Reino
Loadplugin("D:\Storage\Media\Binaries\BASS\bassAudio.dll")

###
# Siberia_Explore #
###

E1=BassAudioSource("SIBERIA\SIBERIAE1.WAV")
E2=BassAudioSource("SIBERIA\SIBERIAE2.WAV").DelayAudio(158792/44100.0)
E3=BassAudioSource("SIBERIA\SIBERIAE3.WAV").DelayAudio(291139/44100.0)
E4=BassAudioSource("SIBERIA\SIBERIAE4.WAV").DelayAudio(423476/44100.0)
E5=BassAudioSource("SIBERIA\SIBERIAE5.WAV").DelayAudio(130916/44100.0)
E6=BassAudioSource("SIBERIA\SIBERIAE6.WAV").DelayAudio(157382/44100.0)
E7=BassAudioSource("SIBERIA\SIBERIAE7.WAV").DelayAudio(157355/44100.0)
E8=BassAudioSource("SIBERIA\SIBERIAE8.WAV").DelayAudio(183812/44100.0)
E9=BassAudioSource("SIBERIA\SIBERIAE9.WAV").DelayAudio(183786/44100.0)
E10=BassAudioSource("SIBERIA\SIBERIAE10.WAV").DelayAudio(130804/44100.0)
E11=BassAudioSource("SIBERIA\SIBERIAE11.WAV").DelayAudio(130842/44100.0)
E12=BassAudioSource("SIBERIA\SIBERIAE12.WAV").DelayAudio(157365/44100.0)
E13=BassAudioSource("SIBERIA\SIBERIAE13.WAV").DelayAudio(157359/44100.0)
E14=BassAudioSource("SIBERIA\SIBERIAE14.WAV").DelayAudio(104395/44100.0)
E15=BassAudioSource("SIBERIA\SIBERIAE15.WAV").DelayAudio(184468/44100.0)
E16=BassAudioSource("SIBERIA\SIBERIAE16.WAV").DelayAudio(135333/44100.0)
E17=BassAudioSource("SIBERIA\SIBERIAE17.WAV").DelayAudio(107303/44100.0)
E18=BassAudioSource("SIBERIA\SIBERIAE18.WAV").DelayAudio(133899/44100.0)
E19=BassAudioSource("SIBERIA\SIBERIAE19.WAV").DelayAudio(85956/44100.0)
E20=BassAudioSource("SIBERIA\SIBERIAE20.WAV").DelayAudio(130086/44100.0)
E21=BassAudioSource("SIBERIA\SIBERIAE21.WAV").DelayAudio(130577/44100.0)
E22=BassAudioSource("SIBERIA\SIBERIAE22.WAV").DelayAudio(130918/44100.0)
E23=BassAudioSource("SIBERIA\SIBERIAE23.WAV").DelayAudio(86800/44100.0)
E24=BassAudioSource("SIBERIA\SIBERIAE24.WAV").DelayAudio(86463/44100.0)
E25=BassAudioSource("SIBERIA\SIBERIAE25.WAV").DelayAudio(86121/44100.0)
E26=BassAudioSource("SIBERIA\SIBERIAE26.WAV").DelayAudio(85044/44100.0)
E27=BassAudioSource("SIBERIA\SIBERIAE27.WAV").DelayAudio(82337/44100.0)
E28=BassAudioSource("SIBERIA\SIBERIAE28.WAV").DelayAudio(153075/44100.0)
E29=BassAudioSource(&

Re: [FFmpeg-user] amix: Hard limit for number of inputs?

2019-07-16 Thread Reino Wijnsma
On 16-7-2019 15:36, Paul B Mahol  wrote:
> On 7/16/19, Reino Wijnsma  wrote:
>> About 7 years ago I've used Audacity to assemble the soundtrack of the
>> videogame No One Lives Forever 2. See
>> https://www.youtube.com/watch?v=4Y3aKcQ0HK4 for example.
> Why you use adelay?
> Perhaps you want acrossfade filter instead, or even better concat filter.
I can't use these filters. Have a look at the Youtube video please.
I wish it was a simple matter of just concatenating all segments, but it isn't, 
because the segments don't align perfectly.
Each segments has to start at a very specific time.
Then it's a matter of mixing everything at full volume(!), so there's no fading 
involved at all.

Do you happen to know why ffmpeg reports a completely wrong duration?

Related question/suggestion:
It's really cumbersome to always having to specify the delay for all(!) 
channels: [1]adelay=158792S|158792S[E2];
How about a default behaviour where specifying an amount of 
milliseconds/samples once(!) applies to all channels: [1]adelay=158792S[E2];
And if you want a specific delay for another channel, then you can do so as is 
already possible.
This would make my commandline a lot shorter!

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

[FFmpeg-user] amix: Hard limit for number of inputs?

2019-07-16 Thread Reino Wijnsma
Hello ffmpeg-user,

About 7 years ago I've used Audacity to assemble the soundtrack of the 
videogame No One Lives Forever 2. See 
https://www.youtube.com/watch?v=4Y3aKcQ0HK4 for example.
The soundtrack comprised of lots of small segments that can all dynamically be 
loaded by the videogame.

A year later I've assembled the soundtrack once more, but this time with 
Avisynth. See the attached 'SIBERIA.avs' for example.

Now I wanted to see if ffmpeg is up for the task. Just for fun.

FFmpeg used:

ffmpeg version N-94137-g89b9690-Reino Copyright (c) 2000-2019 the FFmpeg 
developers
  built with gcc 8.3.0 (GCC)
  configuration: --arch=x86 --target-os=mingw32 
--cross-prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/bin/i686-w64-mingw32-
 --pkg-config=pkg-config --pkg-config-flags=--static --extra-version=Reino 
--enable-gray --enable-version3 --disable-debug --disable-doc 
--disable-htmlpages --disable-manpages --disable-podpages --disable-txtpages 
--disable-w32threads --enable-avisynth --enable-frei0r --enable-filter=frei0r 
--enable-gmp --enable-gpl --enable-libaom --enable-libass --enable-libbluray 
--enable-libbs2b --enable-libcaca --extra-cflags=-DCACA_STATIC 
--enable-libfdk-aac --enable-libflite --enable-libfontconfig 
--enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm 
--enable-libilbc --enable-libmp3lame --enable-libmysofa 
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 
--enable-libopenmpt --enable-libopus --enable-librubberband --enable-libsnappy 
--enable-libsoxr
--enable-libspeex --enable-libtheora --enable-libtwolame 
--extra-cflags=-DLIBTWOLAME_STATIC --enable-libvidstab --enable-libvmaf 
--enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwebp 
--enable-libx264 --enable-libx265 --enable-libxavs --enable-libxml2 
--enable-libxvid --enable-libzimg --enable-libzvbi --enable-mbedtls 
--extra-cflags='-march=pentium3' --extra-cflags='-mtune=athlon-xp' 
--extra-cflags=-O2 --extra-cflags='-mfpmath=sse' --extra-cflags=-msse 
--enable-static --disable-shared 
--prefix=/cygdrive/m/ffmpeg-windows-build-helpers-master/ffmpeg_local_builds/sandbox/cross_compilers/mingw-w64-i686/i686-w64-mingw32
  libavutil  56. 30.100 / 56. 30.100
  libavcodec 58. 53.100 / 58. 53.100
  libavformat58. 28.101 / 58. 28.101
  libavdevice58.  7.100 / 58.  7.100
  libavfilter 7. 55.100 /  7. 55.100
  libswscale  5.  4.101 /  5.  4.101
  libswresample   3.  4.100 /  3.  4.100
  libpostproc55.  4.100 / 55.  4.100

The soundtrack contains an "explore", "warning" and "combat" section. I'll do 
the "explore" section first, which is 'SIBERIAE{1-29}.WAV'.

ffmpeg.exe -i SIBERIAE1.WAV -i SIBERIAE2.WAV -i SIBERIAE3.WAV -i SIBERIAE4.WAV 
-i SIBERIAE5.WAV -i SIBERIAE6.WAV -i SIBERIAE7.WAV -i SIBERIAE8.WAV -i 
SIBERIAE9.WAV -i SIBERIAE10.WAV -i SIBERIAE11.WAV -i SIBERIAE12.WAV -i 
SIBERIAE13.WAV -i SIBERIAE14.WAV -i SIBERIAE15.WAV -i SIBERIAE16.WAV -i 
SIBERIAE17.WAV -i SIBERIAE18.WAV -i SIBERIAE19.WAV -i SIBERIAE20.WAV -i 
SIBERIAE21.WAV -i SIBERIAE22.WAV -i SIBERIAE23.WAV -i SIBERIAE24.WAV -i 
SIBERIAE25.WAV -i SIBERIAE26.WAV -i SIBERIAE27.WAV -i SIBERIAE28.WAV -i 
SIBERIAE29.WAV -filter_complex
"[1]adelay=158792S|158792S[E2];[2]adelay=291139S|291139S[E3];[3]adelay=423476S|423476S[E4];[4]adelay=555820S|555820S[E5];[5]adelay=714633S|714633S[E6];[6]adelay=873439S|873439S[E7];[7]adelay=1058736S|1058736S[E8];[8]adelay=1244019S|1244019S[E9];[9]adelay=1376339S|1376339S[E10];[10]adelay=1508682S|1508682S[E11];[11]adelay=1667496S|1667496S[E12];[12]adelay=1826306S|1826306S[E13];[13]adelay=1932181S|1932181S[E14];[14]adelay=2118076S|2118076S[E15];[15]adelay=2255399S|2255399S[E16];[16]adelay=2364348S|2364348S[E17];[17]adelay=2499655S|2499655S[E18];[18]adelay=2587883S|2587883S[E19];[19]adelay=2720226S|2720226S[E20];[20]adelay=2852568S|2852568S[E21];[21]adelay=2984913S|2984913S[E22];[22]adelay=3073138S|3073138S[E23];[23]adelay=3161367S|3161367S[E24];[24]adelay=3249594S|3249594S[E25];[25]adelay=3336742S|3336742S[E26];[26]adelay=3421112S|3421112S[E27];[27]adelay=3576621S|3576621S[E28];[28]adelay=3788369S|3788369S[E29];[0][E2][E3][E4][E5][E6][E7][E8][E9][E10][E11][E12][E13][E14][E15][E16][E17][E18][E19][E20][E21][E22][E23][E24][E25][E26][E27][E28][E29]amix=inputs=29"
-f null NUL
Input #0, wav, from 'SIBERIAE1.WAV':
  Duration: 00:00:09.64, bitrate: 127 kb/s
Stream #0:0: Audio: mp3 (U[0][0][0] / 0x0055), 44100 Hz, stereo, fltp, 128 
kb/s
[...]
Input #28, wav, from 'SIBERIAE29.WAV':
  Duration: 00:00:04.83, bitrate: 127 kb/s
Stream #28:0: Audio: mp3 (U[0][0][0] / 0x0055), 44100 Hz, stereo, fltp, 128 
kb/s
Stream mapping:
  Stream #0:0 (mp3float) -> amix:input0
  Stream #1:0 (mp3float) -> adelay
  [...]
  Stream #28:0 (mp3float) -> adelay
  amix -> Stream #0:0 (pcm_s16le)
Press [q] to stop, [?] for help
Output #0, null, to 'NUL':
  Metadata:
encoder : Lavf58.28.101
Stream 

Re: [FFmpeg-user] unsubscribe

2019-04-11 Thread Reino Wijnsma
On 11-4-2019 17:29, Mustafa Al Ani  wrote:
> @FFmpeg user questions , please take an action.

Then someone should also take action against you imo for constantly top-posting 
 and 
thus ignoring the netiquette described here 
.

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

To unsubscribe, visit link above, or email
ffmpeg-user-requ...@ffmpeg.org with subject "unsubscribe".

Re: [FFmpeg-user] down sampling

2018-12-29 Thread Reino Wijnsma
On 29-12-2018 20:19, Michael Koch  wrote:
> F:\Sound\Ultraschall_Konvertierung>c://ffmpeg/ffmpeg -i 699.mp4 -f nut - | 
> c://f
> fmpeg/ffplay -

Have you actually tested this at all? Forward slashes don't work on Windows!

C:\ffmpeg\ffmpeg.exe -f lavfi -i aevalsrc="sin(864*2*PI*t):c=stereo:s=131072" 
-ar 44.1k -f wav - | C:\ffmpeg\ffplay.exe -i -
or
C:\ffmpeg\ffmpeg.exe -f lavfi -i aevalsrc="sin(864*2*PI*t):c=stereo:s=131072" 
-af "aresample=resampler=soxr:osr=48000:precision=28" -f wav - | 
C:\ffmpeg\ffplay.exe -i -

-- Reino

___
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] Question about handling / unwanted changes of SAR in ffmpeg

2018-12-26 Thread Reino Wijnsma
On 25-12-2018 20:54, Uwe Freese  wrote:
> Stream #0:0: Video: h264 (High), yuv420p(progressive), 688x560 [SAR 64:45 
> DAR 2752:1575], SAR 172:121 DAR 7396:4235, 50 fps, 50 tbr, 1k tbn, 100 tbc 
> (default)
>
> What does SAR (and DAR) mean in the brackets compared to the second SAR 
> 172:121, which is slightly different?
As far as I know:

688x 64/45 = 978,49w
978,49 x 1575/2752 = 560h --> 978x560 @ bitstream level
688x 172/121 =   977,98w
977,98 x 4235/7396 = 560h --> 977x560 @ container level

-- Reino
___
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] Building ffmpeg - pkgconfig, again

2018-12-01 Thread Reino Wijnsma
On 1-12-2018 13:53, darkm...@frontier.com wrote:
> On Sat, 1 Dec 2018 12:08:36 +0100, Moritz Barsnick  wrote:
>> I can tell that the linker flag "-lm" seems to be missing.
>>
>> You information is a bit sparse. Can you show us your complete
>> configure command line as well please?
>
> ../ffmpeg/configure --enable-gpl --enable-version3 --disable-podpages 
> --enable-gnutls
> --enable-libx264 --enable-gmp --enable-libopus --enable-libmp3lame 
> --enable-libtheora
> --enable-libvorbis
>
> [...]
>> Possibly, you only built a static libopus,
>
> Yes. I built all libs static only, because I am building only the static 
> version of ffmpeg.
$ pkg-config --libs opus
-L/cygdrive/[...]/i686-w64-mingw32/lib -lopus

$ pkg-config *--static* --libs opus
-L/cygdrive/[...]/i686-w64-mingw32/lib -lopus *-lm*

That's why I would recommend:
../ffmpeg/configure *--pkg-config-flags=--static* --enable-gpl --enable-version3
--disable-podpages --enable-gnutls --enable-libx264 --enable-gmp 
--enable-libopus
--enable-libmp3lame --enable-libtheora --enable-libvorbis

-- Reino
___
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] Audio delay doesn't work as expected

2018-08-27 Thread Reino Wijnsma
On 27-8-2018 15:18, Michael Koch  wrote:
> ffmpeg -f lavfi -i sine=f=1000:d=5 -f lavfi -i sine=f=1000:d=5 
> -filter_complex "[0:a]adelay=0.0[d0],[1:a]adelay=0.5[d1],[d0][d1]amix" -y 
> test2.mp3

Since delaying audio by zero doesn't make sense, you can shorten the command 
like this:

ffmpeg -f lavfi -i sine=f=1000:d=5 -f lavfi -i sine=f=1000:d=5 -filter_complex 
"[1:a]adelay=0.5[d1];[0:a][d1]amix" -y test2.mp3

-- Reino
___
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] How to build static fontconfig with ffmpeg?

2018-08-15 Thread Reino Wijnsma
On 13-8-2018 15:02, qw  wrote:
> I use the command of 'pkg-config --static', which prints nothing.
On 9-8-2018 2:09, Reino Wijnsma  wrote:
> 8) build fontconfig-2.13.0.tar.bz2
> export PKG_CONFIG="pkg-config --static"
> ./configure --disable-shared --enable-static
> make
> unset PKG_CONFIG
You'd have to assign that command to the 'PKG_CONFIG'-variable, as quoted above.

-- Reino

P.s. Top-posting is not allowed on this mailinglist.

___
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] Is this the best method to keep audio quality when converting lossy audio to another lossy audio?

2018-06-01 Thread Reino Wijnsma
On 1-6-2018 14:11, Farhad Mohammadi Majd 
 wrote:
>> On the other hand, if you compiled FFmpeg with libopus, then you
>> don't need 'opusenc' at all.
> Does ffmpeg has the same output quality of opusenc?
They're both a wrapper for libopus if you will, so yes.

-- Reino
___
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] Is this the best method to keep audio quality when converting lossy audio to another lossy audio?

2018-06-01 Thread Reino Wijnsma
Hello Farhad,

On 1-6-2018 10:37, Farhad Mohammadi Majd 
 wrote:
> Hello, I have a large collection of audio files contains music in mp3
> format, due to need to free space of hard disk, I need to reduce their
> size.
>
> It seems opus is the best format for this purpose, in order to have the
> quality of original mp3 files, currently I use ffmpeg command to
> convert them to FLAC and then use opusenc, the official opus encoder,
> to convert FLAC files to opus.
>
> By using one standard and good quality headphone, My ears don't notice
> any difference between original mp3 files versus new opus files.
>
> 1. Is this the best method to keep audio quality when converting lossy
> audio to another lossy audio?
First of all I would never recommend a lossy to lossy conversion as you'd 
always lose audio quality in the process. If you can get a hold of the lossless 
source (the original cd's, or FLAC/WV/TAK files), then it's always recommended 
to convert those to opus!
But if you insist,... an intermediate FLAC file isn't necessary. 'opusenc' 
mentions "The input format can be Wave, AIFF, FLAC, Ogg/FLAC, or raw PCM.", so 
instead of converting the mp3 files to flac, you can also pipe the decoded mp3 
audio from 'ffmpeg' to 'opusenc':

ffmpeg -i input.mp3 -f wav - | opusenc --bitrate 64 - output.opus

On the other hand, if you compiled FFmpeg with libopus, then you don't need 
'opusenc' at all. 'ffmpeg' is then all you need:

ffmpeg -i input.mp3 -c:a libopus -ab 64k output.opus
> 2. Is there any quailty loss in this method? if yes, is it noticeable?
> how much is it?
Yes there is, as is always the case with a lossy to lossy conversion.
Not necessarily. If the bitrate of the mp3 files is high enough, then you may 
not notice it at all. If that's okay with you, then fine.

-- Reino

___
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] Reporting GCC 7.3.0 compiler-warnings on FFmpeg git (955fa23)

2018-04-19 Thread Reino Wijnsma
On 19-4-2018 12:13, Carl Eugen Hoyos  wrote:
>> libavformat/hlsenc.c: In function 'get_default_pattern_localtime_fmt':
>> libavformat/hlsenc.c:1676:63: warning: unknown conversion type character 's' 
>> in format
>> return (HAVE_LIBC_MSVCRT || !strftime(b, sizeof(b), "%s", p)
> What does "grep HAVE_LIBC_MSVCRT config.h" show for you?
#define HAVE_LIBC_MSVCRT 0

>> libavutil/hwcontext_d3d11va.c: In function 'd3d11va_transfer_data':
>> libavutil/hwcontext_d3d11va.c:413:49: warning: passing argument 3 of 
>> 'av_image_copy' from incompatible pointer type
> Does changing the third argument of av_image_copy() in libavutil/imgutils.h
> into "const uint8_t * const src_data[4]" silence anything?
I take it you meant this one?

diff --git a/libavutil/imgutils.h b/libavutil/imgutils.h
index 5b790ec..9530c6e 100644
--- a/libavutil/imgutils.h
+++ b/libavutil/imgutils.h
@@ -107,7 +107,7 @@ int av_image_alloc(uint8_t *pointers[4], int linesizes[4],
  * @param src_linesize linesize for the image plane in src
  */
 void av_image_copy_plane(uint8_t   *dst, int dst_linesize,
- const uint8_t *src, int src_linesize,
+ const uint8_t *src_data[4], int src_linesize,
  int bytewidth, int height);
 
 /**

Result: same warning messages as before.

> (Only hwcontext_d3d11va.o testing required, breaks imgutils.o compilation)
I'm still rather new to all of this and normally I would always run make on 
FFmpeg. Can you tell me how I can compile just this one file?

-- Reino

___
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] Reporting GCC 7.3.0 compiler-warnings on FFmpeg git (955fa23)

2018-04-18 Thread Reino Wijnsma
On 15-4-2018 15:16, Reino Wijnsma <rwijn...@xs4all.nl> wrote:
> Hello ffmpeg-user(/devel),
>
> I've just compiled a fresh build from git (955fa23) (on Windows using Cygwin, 
> MinGW and GCC).
> It compiled without errors, but I did get quite some warnings! I thought I'd 
> share it with you.
> See the attached 'ffmpeg_build.log'.
On 16-4-2018 0:00, Carl Eugen Hoyos <ceffm...@gmail.com> wrote 
<https://ffmpeg.org/pipermail/ffmpeg-devel/2018-April/228297.html>:
> Attached patch is supposed to silence several user-reported warnings,
> I cannot currently test here.
>
> Please review, Carl Eugen
[...]
CC  libavcodec/dxva2.o
CC  libavcodec/dxva2_h264.o
CC  libavcodec/dxva2_hevc.o
CC  libavcodec/dxva2_mpeg2.o
CC  libavcodec/dxva2_vc1.o
CC  libavcodec/dxva2_vp9.o
[...]

On 16-4-2018 0:03, Carl Eugen Hoyos <ceffm...@gmail.com> wrote 
<https://ffmpeg.org/pipermail/ffmpeg-devel/2018-April/228299.html>:
> Attached patch is supposed to silence a user-reported warning, I
> cannot currently test.
>
> libavdevice/vfwcap.c: In function 'vfw_read_header':
> libavdevice/vfwcap.c:331:35: warning: passing argument 1 of 
> 'av_parse_video_size' from incompatible pointer type 
> [-Wincompatible-pointer-types]
>  ret = av_parse_video_size(>bmiHeader.biWidth, 
> >bmiHeader.biHeight, ctx->video_size);
>^
>
> Please review, Carl Eugen
[...]
CC  libavdevice/vfwcap.o
[...]

On 16-4-2018 0:19, Carl Eugen Hoyos <ceffm...@gmail.com> wrote 
<https://ffmpeg.org/pipermail/ffmpeg-devel/2018-April/228300.html>:
> rtmpe_write() exploits knowledge about av_rc4_crypt() internals and
> passes the same
> pointer as src and dst. I assume this is intentional for performance
> reasons, the only
> way to silence the resulting warning is a cast afaict.
>
> Please comment, Carl Eugen
[...]
CC  libavformat/rtmpcrypt.o
[...]

On 16-4-2018 1:33, Carl Eugen Hoyos <ceffm...@gmail.com> wrote 
<https://ffmpeg.org/pipermail/ffmpeg-devel/2018-April/228305.html>:
> Attached patch is supposed to silence a user-reported warning when
> inet_aton() is missing but getaddrinfo() is supported.
> Untested.
>
> Please review, Carl Eugen
[...]
CC  libavformat/os_support.o
libavformat/os_support.c: In function 'ff_poll':
libavformat/os_support.c:248:23: warning: comparison of unsigned expression < 0 
is always false [-Wtype-limits]
 if (fds[i].fd < 0)
   ^
[...]

As you can see, no more warnings. Good job. Thanks. (The 'os_support.o'-warning 
above wasn't the warning that Carl fixed)

-- Reino
___
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] Can't use latest NASM with FFmpeg?

2018-03-17 Thread Reino Wijnsma
On 2-1-2018 23:17, Carl Eugen Hoyos <ceffm...@gmail.com> wrote:
> 2018-01-02 17:11 GMT+01:00 Reino Wijnsma <rwijn...@xs4all.nl>:
>> nasm: fatal: unable to open output file 
>> `/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.Zrz2Fm8R/test.o'
> Is it possible that the binary you tested cannot read Cygwin paths?
This week I had another look at this.
To cross-compile on Windows I first install Cygwin. Then I use a MinGW build 
script to compile the latest GCC using Cygwin's compilers. And it's this latest 
GCC binary I'm using to compile everything that follows, including the latest 
NASM.
It suddenly occurred to me that in order for NASM to read Cygwin paths I had to 
compile NASM with Cygwin's GCC rather than MinGW's GCC.
And after having done so my hunch proved to be correct and FFmpeg's 'configure' 
was happy again:

nasm -v
NASM version 2.13.03 compiled on Mar 15 2018
test_x86asm movbe ecx, [5]
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1movbe ecx, [5]
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -Werror -o /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
test_x86asm vmovdqa32 [eax]{k1}{z}, zmm0
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1vmovdqa32 [eax]{k1}{z}, zmm0
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -f win32 -DPREFIX -Werror -o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
test_x86asm vextracti128 xmm0, ymm0, 0
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1vextracti128 xmm0, ymm0, 0
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -f win32 -DPREFIX -Werror -o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
test_x86asm vpmacsdd xmm0, xmm1, xmm2, xmm3
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1vpmacsdd xmm0, xmm1, xmm2, xmm3
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -f win32 -DPREFIX -Werror -o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
test_x86asm vfmaddps ymm0, ymm1, ymm2, ymm3
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1vfmaddps ymm0, ymm1, ymm2, ymm3
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -f win32 -DPREFIX -Werror -o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
test_x86asm CPU amdnop
BEGIN /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
1CPU amdnop
END /cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
nasm -f win32 -DPREFIX -Werror -o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.o 
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S
/cygdrive/c/DOCUME~1/Admin/LOCALS~1/Temp/ffconf.p7gxGA9N/test.S:1: error: 
unknown 'cpu' type 'amdnop'

-- Reino
___
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".

  1   2   >