SageTV Community

SageTV Community (http://forums.sagetv.com/forums/index.php)
-   The SageTV Community (http://forums.sagetv.com/forums/forumdisplay.php?f=14)
-   -   Help with ffmpeg (http://forums.sagetv.com/forums/showthread.php?t=65504)

davidb 04-25-2018 09:32 AM

Help with ffmpeg
 
I am using ffmpeg in my client for IOS. All media for IOS has to sent using HLS. I am creating this using ffmpeg like this:
""c:\SageRemote\ffmpeg\ffmpeg.exe" -ss 00:00:00 -i "H:\hdvpr1video\60006_292_1214_1753-0.ts" -profile:v high -level 4.2 -b:v 1500K -preset superfast -c:v libx264 -strict -2 -ac: 2 -codec:a aac -b:a 128k -f hls -hls_list_size 0 -hls_time 10 "c:\SageRemote\EncodedMedia\5055417\5055417.m3u8""

I have been using this format for over 2 years now and it works fine this way. The problem is Apple has a requirement that I must also provide a 192 kbs or lower stream when used over cellular. For my app this is an absurd requirement as you can't provide video at such a low rate. I can do an audio only stream to meet this data rate. I know how to make a audio only stream but don't know how to generate both at the same time. In real use you wouldn't use the app if you can't view video! But I must do it to get it on the app store! I actually have hired two different people on the web site freelancer but haven't got a solution yet. I know ffmpeg can do it I just don't know how to ask it to do it! Anybody used ffmpeg that might know how?

trk2 04-25-2018 01:42 PM

FFmpeg novice here... perhaps I'm misunderstanding your question but is this what you're looking for?

davidb 04-25-2018 01:45 PM

Yes I have seen that and tried to get it to work. I am able to use that to generate an audio only rendition in addition to the video/audio rendition but can't get ffmpeg to generate the master playlist for both streams. I know it can do it though!

Quote:

Originally Posted by trk2 (Post 615434)
FFmpeg novice here... perhaps I'm misunderstanding your question but is this what you're looking for?


davidb 04-27-2018 06:57 AM

In case anyone is lurking and needs the same thing I think I figured it out. I think this does it:
""c:\SageRemote\ffmpeg1\ffmpeg.exe" -ss 00:00:00 -i "H:\hdvpr1video\60006_292_1214_1753-0.ts" -i "H:\hdvpr1video\60006_292_1214_1753-0.ts" -map 0:v -map 0:a -map 1:a -var_stream_map "v:0,a:0,agroup:audio_video_high a:1,agroup:aud_medium" -profile:v high -level 4.2 -b:v 1500K -preset ultrafast -c:v libx264 -strict -2 -ac: 2 -codec:a aac -b:a 128k -y -fflags +genpts+discardcorrupt -f hls -g 10 -master_pl_name 5055417.m3u8 -hls_time 10 -hls_list_size 0 -hls_wrap 10 "c:\SageRemote\EncodedMedia\5055417\5055417%%v.m3u8""
Quote:

Originally Posted by davidb (Post 615432)
I am using ffmpeg in my client for IOS. All media for IOS has to sent using HLS. I am creating this using ffmpeg like this:
""c:\SageRemote\ffmpeg\ffmpeg.exe" -ss 00:00:00 -i "H:\hdvpr1video\60006_292_1214_1753-0.ts" -profile:v high -level 4.2 -b:v 1500K -preset superfast -c:v libx264 -strict -2 -ac: 2 -codec:a aac -b:a 128k -f hls -hls_list_size 0 -hls_time 10 "c:\SageRemote\EncodedMedia\5055417\5055417.m3u8""

I have been using this format for over 2 years now and it works fine this way. The problem is Apple has a requirement that I must also provide a 192 kbs or lower stream when used over cellular. For my app this is an absurd requirement as you can't provide video at such a low rate. I can do an audio only stream to meet this data rate. I know how to make a audio only stream but don't know how to generate both at the same time. In real use you wouldn't use the app if you can't view video! But I must do it to get it on the app store! I actually have hired two different people on the web site freelancer but haven't got a solution yet. I know ffmpeg can do it I just don't know how to ask it to do it! Anybody used ffmpeg that might know how?



All times are GMT -6. The time now is 05:00 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2020, vBulletin Solutions Inc.
Copyright 2003-2005 SageTV, LLC. All rights reserved.