TsBufferExtractor plugin for TvServer (8 Viewers)

Wbunaarf

Portal Pro
December 9, 2005
534
103
Sweden
Home Country
Sweden Sweden
Your setting is to save buffer from beginning of the show if available. If not, it saves buffer from the last channel change. According to your logs the timeshifting was not started when the show stated (minus your pre-record time) so the buffer was saved from last channel changing.

OK, a new trial. I have pre/post set to 1/3. This time I started timeshifting ~14:25. The program I recorded aired between 14:45 and 14:55, I manually started the recording 14:54 (and selected yes to save the buffer) and the recording stopped at 14:58 as expected. However, just as with the last trial the complete buffer was saved.

In this case the buffer wasn't saved (not completely unexpected since I didn't actually confirm, but not ideal).
It is ok because it is the design.

It's not a great issue but wouldn't it be more logical to default to 'yes'?

For some reason the buffer recording is shown with length 0 in MP
I is a bug. I need to check it.

This time MP reports both as 3 minutes while the explorer seems confused about the non-buffer recording... I don't know if there can be a connection, but when I check previous (before enabling this plugin) recordings in explorer all durations seem to be correct.

15-05-37.png 2015-07-26 15_13_22-Remote Desktop Manager [TV].png


//W
 

Attachments

  • tv-server_26_07_15__15_00.zip
    22.3 KB

regeszter

Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    OK, a new trial. I have pre/post set to 1/3. This time I started timeshifting ~14:25. The program I recorded aired between 14:45 and 14:55, I manually started the recording 14:54 (and selected yes to save the buffer) and the recording stopped at 14:58 as expected. However, just as with the last trial the complete buffer was saved.



    It's not a great issue but wouldn't it be more logical to default to 'yes'?



    This time MP reports both as 3 minutes while the explorer seems confused about the non-buffer recording... I don't know if there can be a connection, but when I check previous (before enabling this plugin) recordings in explorer all durations seem to be correct.

    View attachment 167306 View attachment 167307


    //W

    You started the record on 14:54 and the program started on 14:55. It means you saved the buffer for the next program. :)
     

    Wbunaarf

    Portal Pro
    December 9, 2005
    534
    103
    Sweden
    Home Country
    Sweden Sweden
    You started the record on 14:54 and the program started on 14:55. It means you saved the buffer for the next program. :)

    No, the airing of 'Aisopos teater' began at 14:45, I started the recording of it 14:54, the program ended 14:55 and the recording stopped 14:58 (+3). Technically I guess I was within the pre-recording interval (-1) for the upcoming program ('Farfar i fickan'), but that shouldn't matter should it?

    21-29-49.png

    Thinking that third time's the charm I started timeshift ~19:30, 'Tingeling och älvornas mästerskap' started 19:35, I started a recording at 19:43, the program ended 20:00 and the recording 20:03 (+3). I now expected a 9 minutes long buffer (19:34-19:43) and 20 minutes normal recording (19:43-20:03), but:


    20-35-57.png 2015-07-26 22_06_08-Remote Desktop Manager [TV].png

    What am I missing?

    //W
     

    Attachments

    • tv-server_26_07_15__20_05.zip
      18.4 KB

    regeszter

    Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    Thinking that third time's the charm I started timeshift ~19:30, 'Tingeling och älvornas mästerskap' started 19:35, I started a recording at 19:43, the program ended 20:00 and the recording 20:03 (+3). I now expected a 9 minutes long buffer (19:34-19:43) and 20 minutes normal recording (19:43-20:03), but:

    It is ok. The plugin collect the buffers from the starts of the first buffer file so the copy of the buffers can be longer as you expected. Try the play the show and check if all program is in the buffer+recorded file. :) And check the gap between the buffer and the recorded file. It should be not too much.
     

    Timberwolf99

    Portal Pro
    November 20, 2015
    172
    61
    52
    Home Country
    Australia Australia
    Hi,

    when you are watching the Tv and you decide to record the current program you will lose the 1st part of the program because the timeshift buffer is not included into the recorded file.

    bye,
    regeszter

    This is really a great Idea for a Server Plugin! Ist there no way to merge the files into on big Record? Then it would be also listed as one Recorded Show....

    Sorry but no way to merge because the buffer is not aligned to correctly but you can play with MePo or any other media player.

    hi,

    so i was just looking into installing this plugin in my development environment and was thinking about the above sentence, seems to me that it should be made up of one file e.g the recording.

    so i have a idea please, feedback is welcome.

    Why cant the plugin just lock the tuner for the duration of the recording. (i know there will be a hardware limit as the time shift buffer drive is a finite size. but really all that is needed is 2 hrs maybe 3 for most movies) then when the recording is finished format the files and move them appropriately. And not need to attempt to merge the two files.

    Most people also should know by now that if the time shift buffer doesn't cover the start of the program there is no getting it back and just record what you can.

    an example a=time shift buffer
    []=record button press
    b=recording

    so this is how it is at the moment i think,

    aaaaaaa[]bbbbbbbbbbbbbbbbbbbbbbbbbbb()
    [] grab buffer, plus prerecording time if possible, if not grab what is available and save ts buffer file, lock tuner and start recording
    () recording stopped, unlock tuner and save to recording folder.

    what i propose

    aaaaaaa[]aaaaaaaaaaaaaaaaaaaaaaaaaaaaa()
    [] grab buffer, plus prerecording time if possible, if not grab what is available and lock tuner
    () recording stopped, unlock tuner and format file to play in TV recordings if required and move to recording folder.

    just seem logical to me that its essentially the same information why separate it when you can post process it when the recording is finished.

    once again any feedback is more than welcome.
     
    Last edited:

    regeszter

    Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    aaaaaaa[]aaaaaaaaaaaaaaaaaaaaaaaaaaaaa()
    [] grab buffer, plus prerecording time if possible, if not grab what is available and lock tuner
    () recording stopped, unlock tuner and format file to play in TV recordings if required and move to recording folder.

    You can not do it with a plugin. You have to modify the TvServer and the TvPlugin.

    You may try to merge the TS buffer copied by my plugin with recorded file using ffmpeg.
     

    regeszter

    Retired Team Member
  • Premium Supporter
  • October 29, 2005
    5,335
    4,954
    Home Country
    Hungary Hungary
    So this should be put in as a feature request in the tv server github code page.

    Can you try this version?

    1. Replace the dll-s in c:\Program Files (x86)\Team MediaPortal\MediaPortal TV Server\Plugins\
    2. Enter TvPlugin
    3. Start timeshifting at least 5 minutes
    4. Start a manual recording, select save buffer
    5. Wait at least 5 minutes.
    6. Stop recording.
    7. Check the recording folder. You should find a ***_merge.ts next to the buffer and the recorded file. Please compare the files.
    Please upload the logs for checking.

    Thx
     

    Attachments

    • TsBufferExtractorV0.6.zip
      11 KB

    Timberwolf99

    Portal Pro
    November 20, 2015
    172
    61
    52
    Home Country
    Australia Australia
    Ok thanx for the test version, I might take me a while to test as its in a test environment at the moment and not permanently connected to our tv service but will put it on the list to test when I can.

    Is this the first stage in developing a true merged recording using the buffer. If so than you for your time, this may have been a make or break deal for me.
     

    Vasilich

    Portal Pro
    August 30, 2009
    3,394
    1,170
    Germany, Mayence
    Home Country
    Russian Federation Russian Federation
    @regeszter how and when do you merge the TS files?
    Just out of interest, as i also use your plugin and have to explain to my wife how it works, so i also interested in automated merge. Will test it tonight/tomorrow
     

    Users who are viewing this thread

    Top Bottom