0

I'm trying to stream using ffmpeg to a STB, with no success. From the STB software support i got this answer:

4.1.5.1 Random_access_indicator For H.264/AVC Bitstreams, the following applies: Encoding: The random_access_indicator bit shall be set whenever an H.264/AVC RAP occurs in video streams (see H.264/AVC RAP definition in Clauses 3.1 and 5.5.5). Decoding: The random_access_indicator bit may be ignored by the IRD. It can be beneficially utilized together with the elementary_stream_priority indicator to identify RAP.

3.1 H.264/AVC RAP: access unit with AU delimiter in an H.264/AVC Bitstream at which an IRD can begin decoding video successfully. This access unit shall include exactly one Sequence Parameter Set (that is active) with VUI and the Picture Parameter Set that is required for decoding the associated picture. The SPS shall also precede any SEI NAL units in this access unit. This access unit must contain an IDR picture or an I picture

I cant't figure out how to set that bit up! With working streams my STB shows:

dec[2][base] :: set_video_track() : -1 -> 0 [H264]

dec[2][base] :: set_audio_track() : -1 -> 0 [AAC] [eng]

But with my stream

dec[1][base] :: set_video_track() : -1 -> -1 []

dec[1][base] :: set_audio_track() : -1 -> 0 [AAC] [spa]

My Ffmpeg command

ffmpeg -nostdin -loglevel info -ss 10 -hwaccel_device 0 -hwaccel cuvid -c:v h264_cuvid -deint 2 -y -re -i udp://X.X.X.X:XXXX?pkt_size=1316\&buffer_size=409600\&fifo_size=1000000\&overrun_nonfatal=1 -movflags isml+frag_keyframe -f ismv -threads 0 -c:a libfdk_aac -ac 2 -b:a 64k -map 0:v -filter:v:0 scale_npp=w=1024:h=576 -c:v:0 h264_nvenc -preset llhq -g 150 -keyint_min 150 -forced-idr 1 -aud 1 -strict_gop 1 -bf 2 -flags:v +global_header -pcr_period 5 -b:v:0 1200k -bsf:v h264_mp4toannexb -map 0:v -filter:v:1 scale_npp=w=1920:h=1080 -c:v:1 h264_nvenc -preset llhq -g 150 -keyint_min 150 -forced-idr 1 -aud 1 -strict_gop 1 -bf 2 -flags:v +global_header -pcr_period 5 -b:v:1 2000k -bsf:v h264_mp4toannexb -map 0:v -filter:v:2 scale_npp=w=640:h=368 -c:v:2 h264_nvenc -preset llhq -g 150 -keyint_min 150 -forced-idr 1 -aud 1 -strict_gop 1 -bf 2 -flags:v +global_header -pcr_period 5 -b:v:2 1200k -bsf:v h264_mp4toannexb -map 0:a:0 http://XXX/X/X

I'm using last version of ffmpeg and nvidia.

Any ideas?

Thanks.

  • The STB documentation you posted only applies to transport streams. But your ffmpeg command has moovflags which implies MP4, but also has mp4toannexb which is wrong for MP4. Then you output to http. It's not clear what you are attempting to do exactly. – szatmary Aug 30 '17 at 15:38
  • I'm creating an iptv channel from a coaxial cable. It works on mobile devices without any issue, but on STB it fails. Maybe, i forgot to tell that i'm using unified streaming also. – Facundo Aug 30 '17 at 17:49
  • I think the RAI bit is a red herring. – szatmary Aug 30 '17 at 17:56
  • Maybe, but for some reason is not working. I tried every flag on ffmpeg with no success. – Facundo Aug 31 '17 at 13:16

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Browse other questions tagged or ask your own question.