aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
diff options
context:
space:
mode:
authorLuke Pulverenti <luke.pulverenti@gmail.com>2017-11-14 02:41:21 -0500
committerLuke Pulverenti <luke.pulverenti@gmail.com>2017-11-14 02:41:21 -0500
commit2f758676d0908f07dafc3ec5434bbaf4cf82529c (patch)
tree0e595cfe51829827a1bcd6f6dc20392ee3816794 /Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
parent2c6cbb33eead0236cbf89fb4afab486aa8510647 (diff)
support sharing m3u tuner streams
Diffstat (limited to 'Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs')
-rw-r--r--Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs13
1 files changed, 11 insertions, 2 deletions
diff --git a/Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs b/Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
index cead1def03..bec92716bb 100644
--- a/Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
+++ b/Emby.Server.Implementations/LiveTv/TunerHosts/LiveStream.cs
@@ -29,8 +29,9 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
public List<string> SharedStreamIds { get; private set; }
protected readonly IEnvironmentInfo Environment;
protected readonly IFileSystem FileSystem;
+ protected readonly IServerApplicationPaths AppPaths;
- protected readonly string TempFilePath;
+ protected string TempFilePath;
protected readonly ILogger Logger;
protected readonly CancellationTokenSource LiveStreamCancellationTokenSource = new CancellationTokenSource();
@@ -44,7 +45,15 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
EnableStreamSharing = true;
SharedStreamIds = new List<string>();
UniqueId = Guid.NewGuid().ToString("N");
- TempFilePath = Path.Combine(appPaths.GetTranscodingTempPath(), UniqueId + ".ts");
+
+ AppPaths = appPaths;
+
+ SetTempFilePath("ts");
+ }
+
+ protected void SetTempFilePath(string extension)
+ {
+ TempFilePath = Path.Combine(AppPaths.GetTranscodingTempPath(), UniqueId + "." + extension);
}
public virtual Task Open(CancellationToken openCancellationToken)