Results 1 to 8 of 8

Thread: Identify recording type

  1. #1
    Join Date
    Oct 2008
    Location
    Leicester, UK
    Posts
    276

    Identify recording type

    I'm working on a Tizen port of this App which is needed for 2015 Samsung TV's. I have a reliable way of playing either HD or SD recordings, but the process is different. Is there a simple way in javascript of identifiyng the H.264 encoded video so that I can handle it appropriately.

    Server: Ci5 2500k, 3GB, Windows Server 2012, nPVR 3.5.7. 2xWinTV-DVB-T USB, 1xWinTV-DVB-T PCI, 2 x BlackGold DVB-T, 1xPCTV290E and 1xPCTV460E on Astra 28.2 E.
    clients: RPI2, Acer R3700, PCH-A110, NUC, 3xSamsung Smart TV

  2. #2
    Join Date
    Oct 2008
    Location
    Leicester, UK
    Posts
    276
    Further to this...

    I'm building an app for Samsung 2015 Tizen TV's to handle NEXTPVR. Its mostly based on Fred250s excellent work on the previous Samsung Smart TV's.
    If I try to stream a recording directly to the Tizen's AVPlay tool, the player locks up for a minute or two and then barfs with a message from the tizen api saying "PLAYER_ERROR_CONNECTION_FAILED". An example of the stream URL is :-
    Code:
    http://192.168.0.101:8866/stream?recording=16702&resolution=1920x1080&bitrate=4096k&mode=http&mime=video/MP2T&client=SMARTTV
    If I turn on transcoding, I get this URL:-
    Code:
    http://192.168.0.101:8866/transcode?recording=16702&resolution=1920x1080&bitrate=4096k&mode=http&mime=video/MP2T&client=SMARTTV
    and the recording plays flawlessly.

    My transcode line in config.xml is:-
    Code:
    -y -v 0 -i [SOURCE] -f mpegts -acodec ac3 -ab 96k -ar 44100 -ac 2 -vcodec libx264 -flags +loop -refs 1 -coder 0 -me_range 16 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -bt 200k -bufsize 96K -rc_eq 'blurCplx^(1-qComp)' -qcomp 0.6 -qmin 10 -qmax 51 -qdiff 4 -level 30 -aspect [ASPECT] -g 30 -async 2 [TARGET]
    and I'm using the latest version of ffmpeg.

    Whilst transcoding makes it watchable, I'm keen to get it to work with just the streaming, mainly because seeking within the recording wont work with transcode.

    I assumed it must be some corruption or incompatibility in the original recorded .ts files, so I used the same ffmpeg configuration to recode and replace the original ts file. Then I tried direct streaming it again. It still barfed, but transcoding on the fly still plays it perfectly.

    Can anyone explain what the on the fly transcode might be doing that changes the way the Tizen API sees the video.

    Incidentally, I've tried with HD content, SD content and live and recorded SD/HD. The results are all the same :-(

    Server: Ci5 2500k, 3GB, Windows Server 2012, nPVR 3.5.7. 2xWinTV-DVB-T USB, 1xWinTV-DVB-T PCI, 2 x BlackGold DVB-T, 1xPCTV290E and 1xPCTV460E on Astra 28.2 E.
    clients: RPI2, Acer R3700, PCH-A110, NUC, 3xSamsung Smart TV

  3. #3
    Join Date
    Jul 2006
    Location
    Sweden
    Posts
    444
    Quote Originally Posted by trummel View Post
    If I try to stream a recording directly to the Tizen's AVPlay tool, the player locks up for a minute or two and then barfs with a message from the tizen api saying "PLAYER_ERROR_CONNECTION_FAILED". An example of the stream URL is :-
    Code:
    http://192.168.0.101:8866/stream?recording=16702&resolution=1920x1080&bitrate=4096k&mode=http&mime=video/MP2T&client=SMARTTV
    I donít think the URL is valid. Paste it in the address field of a browser to see if it starts downloading or try playing the it in VLC.
    I canít recall /stream is able to take the property recording. Also resolution and bitrate seems odd for a non-transcoding streamer service.

    You may try using /live instead of /stream it takes a recordingID but I canít remember the correct syntax.
    There should be an example in the source code I gave you. Lock in the ďCheckActvityĒ section.
    /Stream needs a filename as far as I know. You can snatch a valid one while debugging the app in Chrome or Firefox.

    /Fred

  4. #4
    Join Date
    Jul 2006
    Location
    Sweden
    Posts
    444
    Quote Originally Posted by trummel View Post
    I'm working on a Tizen port of this App which is needed for 2015 Samsung TV's. I have a reliable way of playing either HD or SD recordings, but the process is different. Is there a simple way in javascript of identifiyng the H.264 encoded video so that I can handle it appropriately.
    Don't think so unless your Tizen player API has a method for it.

    In what way is the process different?
    Are they both .ts files?

    /Fred

  5. #5
    Join Date
    Oct 2015
    Location
    Ecuador
    Posts
    1
    Quote Originally Posted by trummel View Post
    Further to this...

    I'm building an app for Samsung 2015 Tizen TV's to handle NEXTPVR. Its mostly based on Fred250s excellent work on the previous Samsung Smart TV's.
    If I try to stream a recording directly to the Tizen's AVPlay tool, the player locks up for a minute or two and then barfs with a message from the tizen api saying "PLAYER_ERROR_CONNECTION_FAILED". An example of the stream URL is :-
    Code:
    http://192.168.0.101:8866/stream?recording=16702&resolution=1920x1080&bitrate=4096k&mode=http&mime=video/MP2T&client=SMARTTV
    ...
    I had the same error, i.e. "PLAYER_ERROR_CONNECTION_FAILED", and it turns out the culprit in my case was using
    Code:
    #EXT-X-VERSION:4
    (we use it for
    Code:
    #EXT-X-I-FRAME-STREAM-INF
    ). Lowering it to version 3 made the stream play perfectly.

    HTH
    Mathieu

  6. #6
    Join Date
    Oct 2008
    Location
    Leicester, UK
    Posts
    276
    I'm afraid my understanding of streaming doesn't stretch to how I would go about changing #EXT-X-VERSION:4 to #EXT-X-VERSION:3. I presume that gets encoded by Sub in the NextPVR engine.

    I only use Samsung TV's and NEWA on RaspBMC now. To make the videos play and time skip work consistently on all of them, I've started using a postprocess script to convert the TS files to MP4. I now have a functional version of a NextPVR Tizen player that works on the IDE emulator. Unfortunately it refuses point blank to install on the TV :-(

    Server: Ci5 2500k, 3GB, Windows Server 2012, nPVR 3.5.7. 2xWinTV-DVB-T USB, 1xWinTV-DVB-T PCI, 2 x BlackGold DVB-T, 1xPCTV290E and 1xPCTV460E on Astra 28.2 E.
    clients: RPI2, Acer R3700, PCH-A110, NUC, 3xSamsung Smart TV

  7. #7
    Join Date
    Jul 2006
    Location
    Sweden
    Posts
    444
    Trummel,

    What matb33 is referring to is a playlist file .m3u or .m3u8. Google it for details.
    NextPvr doesn't provide these types of files. Newa does but doesn't contain the parameters matb33 is talking about.

    As I mentioned earlier I'm quite certain the url you were trying to use doesn't work.
    The /stream service has no property “recording”, you need to provide an f=filename or use /live streaming service which takes the property recording.

    I know you were having trouble using the html5 <video> tag. Any change on that since postprocessing to mp4?

    With later models of Samsung (not Tizen) there were problems installing my app.
    I'm not sure why it was considered a security risk by the installer for “developer apps”, but I suspect knockout.js was to blame.
    You can always try newer versions of knockout and jquery since the ones in the project are quite old by now.

    Some googeling tells me Tizen itself seems to play nicely with both knockout and jquery, installing it onto the TV may be something else.

    /Fred

  8. #8
    Join Date
    Oct 2008
    Location
    Leicester, UK
    Posts
    276
    Unfortunately the MP4 transcode doesn’t solve the html5 playback problems. However I have managed to get to the point where I can play everything that I've transcoded in the SDK. Unfortunately, I cant test it on a Tizen TV as the latest update from Samsung seems to have destroyed the ability to load an app with the USB stick. Ironic, as this was supposed to be the 'Developer release' that should allow direct network loading, but that doesn’t work either. Even the most basic hello world app wont load. I'm waiting for someone at Samsung to get back to me.... Yawn....

    Server: Ci5 2500k, 3GB, Windows Server 2012, nPVR 3.5.7. 2xWinTV-DVB-T USB, 1xWinTV-DVB-T PCI, 2 x BlackGold DVB-T, 1xPCTV290E and 1xPCTV460E on Astra 28.2 E.
    clients: RPI2, Acer R3700, PCH-A110, NUC, 3xSamsung Smart TV

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •