Samsung D Series TV transcoding to mpeg2video fails to play

Issue #435 resolved
Former user created an issue

All files transcoded to mpeg2video using the Samsung C/D profile (h264L>4.1, h263, & VP6) fail to play on Series D TV's, even though BR's play correctly.

My fix is to add maxVBitrate="8192" to those transcoding rules, and to add a new transcoding rule to force reencoding of any mpeg2video.ts file to limit its bitrate to maxVBitrate="8192", using the attached C/D profile.

Comments (41)

  1. Former user Account Deleted

    Petr, any file that matches the transcoding rules that encode the video stream to mpeg2video don't play. Currently this includes all files containing h264>L4.1, h263, or VP6 codecs.

    Attached are the ffmpeg -i for my testfiles of each of these, and the ffmpeg -i for the low bitrate transcoded files that do not play when being transcoded but will play as standalone files if copied from the .stf files and renamed .mpg

    I can fix this by limiting the transcoding to 8192, but the question and bug to be addressed is why the transcoded files that are less than 8kbps do not play when being transcoded.

  2. Petr Nejedly repo owner

    Also can you try with another (latest) version of FFmpeg? That seems very weird and it would be the only device failing to play this (mandatory) codec. Max bitrate a device can play is usually in the region of 20MBit. Can you ask other D series users on the forum as well, as no one has complained so far AFAIK.

  3. Former user Account Deleted

    Good point. I will point my "Send to" ffmpeg -i at Serviio's ffmpeg. I assume that is latest.

    Note that my issue is not with the inability of the TV to play large bit rate files but the serviio failure to play transcoded low bitrate files unless the maxvbitrate parameter is specified. That looks like a serviio bug because the grabbed files will play standalone. I don't think the ffmpeg -i output will address that but I will redo them in a few minutes.

  4. Former user Account Deleted

    Just one thought. I don't know what the DLNA conversation is with the device, but it looks like serviio is telling the TV that it is sending a high bit rate stream to it even though the transcoded stream is a low bit rate, so the TV fails, but if I specify a maxbitrate, serviio sends that value and the tv will play it.

  5. Petr Nejedly repo owner

    I meant try using the latest FFmpeg with Serviio to play the file (replace the one in Serviio's lib folder).

    You can compare protocol info of the resource with/without bitrate setting in Intel tools (AV Media Controller, file's properties)

  6. Former user Account Deleted

    OK, I've gotten ffmpeg 33591 static build from http://ffmpeg.zeranoe.com/builds/ per ffmpeg.org, and it makes no difference with your C/D profile. Again if I limit the bitrate the files will play.

    I can't see that ffmpeg has anything to do with what serviio is sending to the TV. The TV is clearly not basing its rejection of the transcoded file on the streamed contents as shown by ffmpeg -i , because it will play that file raw, so serviio must be telling the TV that the bitrate is very high when its not, and the TV rejects the valid stream.

    Heres the new ffmpeg -i for the transcoded stream which doesn't add much info..

    [mpegts @ 01CD85A0] max_analyze_duration 5000000 reached at 5005000
    Input #0, mpegts, from 'D:\Azureus Active Downloads\Servio Test\transcoding-temp
    -13589-MPEG2TS.mpg':
      Duration: 00:00:33.90, start: 1.400000, bitrate: 10236 kb/s
      Program 1
        Metadata:
          service_name    : Service01
          service_provider: FFmpeg
        Stream #0:0[0x100]: Video: mpeg2video (Main) ([2][0][0][0] / 0x0002), yuv420
    p, 1280x720 [SAR 1:1 DAR 16:9], 104857 kb/s, 29.97 fps, 29.97 tbr, 90k tbn, 59.9
    4 tbc
        Stream #0:1[0x101](und): Audio: ac3 ([129][0][0][0] / 0x0081), 44100 Hz, ste
    reo, s16, 192 kb/s
    
  7. Petr Nejedly repo owner

    Serviio doesn't send any bitrate info differently for local and online files. Can you compare the file in AV Media Controller as a part of feed and local copy to see if they have the same properties and resources.

  8. Former user Account Deleted

    OK, AV Media Controller opened. Wow, didn't know this existed! Thanks for pointing me. All the other Directories open and show contents but my Servio Test directory with all my test files and transcoding captures shows empty. ??? I'm trying to figure out why......

  9. Former user Account Deleted

    Using AV Media Controller - .flv files containing H263 codec will not display in the file list - if any file in the subdirectory has an mpeg-ts container, then none of the files list.

    This makes it impossible to display the captured transcoded files.

    I also added these subdirectories to All-share. The TS format files do not display there either so it is an AV Media Center problem.

  10. Petr Nejedly repo owner

    I forgot to say you have to select the Samsung C/D profile in the console for the IP where AV Media Controller is running and then restart AV Media Controller to pick up the proper transcoding info.

    Also the tool can sometimes be quite slow, so click on the menu slowly and give the folders time to load.

  11. Former user Account Deleted

    OK, attached are 2 screen shots of the properties for transcoded file in the H264 case#1. Resource 2 and 3 are the same as #1 except they are for NA and KO. KO is the one used as shown in the log. I see nothing there that would cause the TV to refuse playback with not supported video codec. What now?

  12. Former user Account Deleted

    oops, just realized that this is the output with my revised c/d profile containing the bit rate limit parameters. Without that limit in the profile the TS files do not list!! So now we have something to work on!!

    Yup.. just verified this. Swiched back to your 1.6 profile and the TS files disappear!

    But now I'm really confused because with the Serviio limited bitrate C/D profile the TS files now show up in the All-share folder too. So how can the Serviio Profile change effect the AVM output for All-Share?

    What now?

  13. Petr Nejedly repo owner

    I'm not sure what's happening at your end, but the TS files should show as any other files in AVMC. Are you seeing the files not at all there or just missing resources?

  14. Former user Account Deleted

    Yes I know the TS files should show in AVM, but using the 1.6 profile shipped with .6 they do not show at all in AVM. If I add the maxVBitrate="8192" parameter to the C/D profile, that also lets the source files play correctly, then they do show up in AVM.

    Attached are screenshots showing the two cases.

    So I have to believe that whatever is causing them to not show in AVM is aso causing them not to be played by the TV, because when they do show in AVM using maxVbitrate they play fine.

  15. Former user Account Deleted

    MORE TESTING... I tried raising the maxvbitrate. I can raise it all the way up to "31000", and the files will all transcode and play correctly even though their bitrates are all under that level... so it seems that the lack of a bitrate is the problem and whatever you are using when no maxvbitrate is specified is causing the problem or iIf you are doing nothing in the absence of maxvbitrate then the default rate is causing the problem.

  16. Petr Nejedly repo owner

    can you upload the TS file that doesn't show somewhere for me to test here? or give a feed url?

  17. Former user Account Deleted

    For my h264.mp4 test file I have given you the ffmpeg output for the file and the ffmpeg -i output for the generated .stf that will not play while being transcoded, but will play if renamed .mpg and played as a file. I've uploaded it here: https://rapidshare.com/files/1048251578/transcoding-temp-13589-MPEG2TS.mpg This file however will not show in AVM unless I add mavVBitrate to the C/D profile.

    I've also noticed that when maxVBitrate is used that the generated .stf file contains a "Nominal Bit Rate" in the header that Mediainfo displays, whereas the file I've uploaded does not.

  18. Former user Account Deleted

    Beats me, here is mine...stock profile stops listing when it hits the mpeg-ts file (and next movie does not show either) but if I add the maxVBitrate to the C-D then both show, and the file will transcode and play.

    I am using the latest avm from the intel site. Beats me!

  19. Petr Nejedly repo owner

    You can try another thing:

    1) try DeviceSpy tool, choose Serviio and select ContentDirectory service
    2) InvokeAction on Browse method
    3) use these parameters:
    ObjectId: 0
    Browse Flag: Direct Children
    Requested count: 99 (or whatever is the max in a folder)
    .. leave the other fields 4) Click Invoke and check field Result

    That will give you list of folders (Audio, Video, Image, each with object/container ID) as an XML. Use the Video ID as Object Id for 3) and execute it again. And so on, until you get to the folder that should include your video. Then enable detailed logging in Serviio and execute the above again - it should try to get a list of videos in the folder - and should not include your video. Post serviio log after this, maybe there will be something dodgy why the video is not included in the result list.

  20. Former user Account Deleted

    OK, I found the reason the AVM did not list the files. It was my error which showed up in the log from the device spy test. I had altered a MediaFormatProfile in the standard C-d profile yesterday trying to find the transcoding problem.

    Sorry for the time I've wasted with that.

    So now I'm back to the compare your requested yesterday in change #8

    "Serviio doesn't send any bitrate info differently for local and online files. Can you compare the file in AV Media Controller as a part of feed and local copy to see if they have the same properties and resources".

    and "you have to select the Samsung C/D profile in the console for the IP where AV Media Controller is running and then restart AV Media Controller to pick up the proper transcoding info."

    Using AVM against the local copy of 13589 (copy of the .stf file) with the correct c-d standard profile, the output is the same as with the maxVBrate profile that I posted in change #13 above.

    I don't know what you mean by "as a part of feed" so I don't know what to compare it to.OK.

    I don't see anything different between the transcoded streams that play (those created with maxVb profile) and those that fail (created with the stock c-d profile). Only difference is that Mediainfo shows a nominal bit rate now.

  21. Former user Account Deleted

    OK, I think by "feed" you mean the "source file" so attached is the AVM output for the original AVC.mp4 file showing the transcoding followed by the output for the grabbed .stf file that plays as a file all using the C/D profile. The output using the C-D profile with maxVBitrate added is identical. The onlty difference between the feed and the file is the absence of "File size" with the feed which might explain why the transcoded file (which plays if maxVBitrate is specified) will not jump, and different values for Feed = DLNA.ORG_OP=01;DLNA.ORG_CI=0 and File = DLNA.ORG_OP=10;DLNA.ORG_CI=1

    So bottom line is that adding maxVBitrate to the transcoding rule allows them to play on the TV and the grabbed .stf file contains Nominal Bit rate.

    I can live with just leaving maxVBitrate=30000 in the profile, but it would be nice if you can fix the problem and make jumping work for transcoded files.

  22. Petr Nejedly repo owner

    That all looks ok.

    Can you ask at the forums if other users with the D series have got the same problem? Might be firmware related as well (not sure if you have the latest firmware for the TV).

    The thing with vMaxBitrate actually means the stream will be fixed bitrate, not max (the way FFmpeg works), so even for low res video you'll get 30MBit down the line, which is too much and would probably cause stuttering on some network setups.

  23. Former user Account Deleted

    "Might be firmware related as well (not sure if you have the latest firmware for the TV)."

    The firmware in the TV is the original 1009 released in Feb/11 and the online update says no new software. But I just looked at the Samsung site for my model and there is an update to 1018.1 for 2011 TV Models so I will update it and test my fles again.

    "The thing with vMaxBitrate actually means the stream will be fixed bitrate, not max (the way FFmpeg works), so even for low res video you'll get 30MBit down the line, which is too much and would probably cause stuttering on some network setups."

    My testing shows that that is not correct. I played my AVC.mp4 testfile using the BR and captured the whole transcoded .stf using both the stock c-d profile and the maxVBitrate=30000 profile. Both files are 126MB for a 120sec file which is ~ 6700 kbps. Media info shows the stock one at 6700 kbps and the vbr one as 6700(30000).

    I don't know enough about DLNA to figure out whats going on and the specs seem to be purchase only. Could you give me some pointers on how to educate myself? I haven't found any thing on the web. Thanks

  24. Former user Account Deleted

    I don't know how significant this is, but in playing around with the WILD MEDIA SERVER, I listed my files, including those that were transcoded to MPEG2VIDEO by Serviio, that I saved as .mpg's.

    Those that were transcoded with maxVBitrate, that played successfully when transcoded all show the Videobitrate of 8,000 or 20,000 kbps that I set, which Mediainfo also displays as the "Nominal bit rate" so something is in the file that contains this nominal value.

    Those using the standard C/D profile, which does not contain maxVBitrate, and will not play when transcoded all show an incredible Videobitrate of 104,859kbps, but Mediainfo does not show a "Nominal bit rate" for those files.

    So to determine what is actually in the files, I demuxed the mpgs and used restream to display the values.

    It confirms that the files transcoded without a maxVBitrate parameter do contain that 104mbps rate.

    I can't help but suspect that this is why the TV rejects the playback of these files, but plays those when the videobitrate field is less than 30mbps, as constrained by using the maxVbitrate parameter.

    Attached are jpgs showing those results.

  25. Former user Account Deleted

    I thought these new info posts might help address this issue. To me the presence of a Videobitrate of 104,859kbps in transcoded files unless I specify a maxVBitrate parameter represents a bug in Serviio or ffmpeg. Any plans to address that?

  26. Petr Nejedly repo owner

    Added from #470:

    The default transcoding is to mpeg but the Samsung C/D requires mpegts I added <Matches container="asf" /> <!-- jhb50 for Greek TV wmv3/wma to overide default transcode to ps --> t the existing online transcode rule in the C/D profile, which I had already altered to add the maxVBitrate=30000 and the transcoding of mp4 with mpeg4 as reported previously. My revised C/D looks like this.

    <OnlineTranscoding>
    <Video targetContainer="mpegts" targetVCodec="mpeg2video" targetACodec="ac3" aBitrate="384" maxVBitrate="30000" > <!-- jhb50  max vbr so TV will play it  -->
    <Matches container="mp4" vCodec="mpeg4" />  <!-- jhb50  for Nasa & Cleese MPEG4/AAC streams  -->
    <Matches container="asf" /> <!-- jhb50 for Greek TV wmv3/wma to overide default transcode to ps -->
    </Video>
    </OnlineTranscoding>
    
    
  27. Petr Nejedly repo owner

    does that mean I can just remove the attribute from all samsung profiles and leave the rest?

  28. Former user Account Deleted

    Yes, that's what I have done and will continue with it and let you know if any problems arise prior to 1.1.

  29. Guillaume Dumont

    Hi,

    I have a very similar issue.

    I have serviio 1.4.1.2 on Mac OS X Mavericks and a Samsung D Series TV with stock profile. If I try to play a h264 with high10 profile on my TV. The first time I try to play this file the TV sends this error message: Not Supported File Format. The next time I try to play it I get Not Supported Video Codec.

    Serviio correctly launches ffmpeg and transcodes the file to the temp folder but the file never plays on the TV. However, the transcoded file can be played by the TV once I add it to my media library and change its extension from .stf to .ts.

    I did not try to add the maxVBitrate as it seems unnecessary as of version 1.1.

    Any idea what could be wrong here?

    Could that be related to the .stf extension? Is there anyway to make the transcoded video file have a .ts extension?

  30. Log in to comment