- June 13, 2006
- 979
- 178
- Home Country
- Belgium
I want to propose a new .tshift format, similar to the existing .tsbuffer format, but with one big difference: timeshifting takes place in a single .ts file instead of a list of (by default) four files.
The format of this .tshift file is the following:
The server writes to the .ts file and keeps the .tshift file up to date with the current position and wrapped-counter. When the server reaches the end of the file, the counter is incremented and the writing continues at the start of the same file.
What I'd like to upload first is the required patches to TsReader.ax and MediaPortal itself, so handle the client-side of this new format.
Note that the only reason I had to patch MP itself is to simply make sure .tshift files were recognized as live TV files and properly forwarded to tsreader. All the real logic is in tsreader itself.
Also note that there's still a small zapping issue, but we're look at that... Disaster123 is looking at the tswriter side of things, which he can add to this thread too I guess
Finally, what I uploaded does NOT work stand-alone yet. I have an internal For The Record build that writes out the new .tshift format, and disaster123 is working on tswriter...
The format of this .tshift file is the following:
- First 8 bytes: 64-bit pointer to the current live-position (where the server is writing)
- Next 4 bytes: a 32-bit integer counting the number of times the file has looped/wrapped (starting at 0)
- Rest of the file: a Unicode filepath to the .ts file used (zero terminated, any path is ignored, file is in the same directory as the .tshift file)
The server writes to the .ts file and keeps the .tshift file up to date with the current position and wrapped-counter. When the server reaches the end of the file, the counter is incremented and the writing continues at the start of the same file.
What I'd like to upload first is the required patches to TsReader.ax and MediaPortal itself, so handle the client-side of this new format.
Note that the only reason I had to patch MP itself is to simply make sure .tshift files were recognized as live TV files and properly forwarded to tsreader. All the real logic is in tsreader itself.
Also note that there's still a small zapping issue, but we're look at that... Disaster123 is looking at the tswriter side of things, which he can add to this thread too I guess
Finally, what I uploaded does NOT work stand-alone yet. I have an internal For The Record build that writes out the new .tshift format, and disaster123 is working on tswriter...