Add Transcoding option to settings
This commit is contained in:
@@ -23,6 +23,8 @@ namespace Jellyfin.Plugin.Enigma2.Configuration
|
||||
|
||||
public string RecordingPath { get; set; }
|
||||
|
||||
public bool TranscodedStream { get; set; }
|
||||
|
||||
public bool EnableDebugLogging { get; set; }
|
||||
|
||||
|
||||
@@ -44,6 +46,8 @@ namespace Jellyfin.Plugin.Enigma2.Configuration
|
||||
|
||||
RecordingPath = "";
|
||||
|
||||
TranscodedStream = false;
|
||||
|
||||
EnableDebugLogging = false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -127,6 +127,16 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="checkboxContainer checkboxContainer-withDescription">
|
||||
<label>
|
||||
<input is="emby-checkbox" type="checkbox" id="chkTranscodedStream" />
|
||||
<span>Request Transcoded Stream</span>
|
||||
</label>
|
||||
<div class="fieldDescription checkboxFieldDescription">
|
||||
Request Transcoded Stream (h264, 720p, 1Mpbs and mp4 as default)
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<label class="checkboxContainer">
|
||||
<input is="emby-checkbox" type="checkbox" id="chkDebugLogging" />
|
||||
<span>Enable Enigma2 debug logging</span>
|
||||
@@ -163,6 +173,7 @@
|
||||
document.getElementById('chkFetchPiconsFromWebInterface').checked = config.FetchPiconsFromWebInterface || false;
|
||||
document.getElementById('txtPiconsPath').value = config.PiconsPath || "";
|
||||
document.getElementById('txtRecordingPath').value = config.RecordingPath || "";
|
||||
document.getElementById('chkTranscodedStream').checked = config.TranscodedStream || false;
|
||||
document.getElementById('chkDebugLogging').checked = config.EnableDebugLogging || false;
|
||||
|
||||
Dashboard.hideLoadingMsg();
|
||||
@@ -187,6 +198,7 @@
|
||||
config.FetchPiconsFromWebInterface = document.getElementById('chkFetchPiconsFromWebInterface').checked;
|
||||
config.PiconsPath = document.getElementById('txtPiconsPath').value;
|
||||
config.RecordingPath = document.getElementById('txtRecordingPath').value;
|
||||
config.TranscodedStream = document.getElementById('chkTranscodedStream').checked;
|
||||
config.EnableDebugLogging = document.getElementById('chkDebugLogging').checked;
|
||||
|
||||
ApiClient.updatePluginConfiguration(Enigma2ConfigurationPage.pluginUniqueId, config).then(Dashboard.processPluginConfigurationUpdateResult);
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net6.0</TargetFrameworks>
|
||||
<AssemblyVersion>5.0.0.0</AssemblyVersion>
|
||||
<FileVersion>5.0.0.0</FileVersion>
|
||||
<AssemblyVersion>5.0.1.0</AssemblyVersion>
|
||||
<FileVersion>5.0.1.0</FileVersion>
|
||||
</PropertyGroup>
|
||||
|
||||
<PropertyGroup Condition="'$(Configuration)|$(TargetFramework)|$(Platform)'=='Release|net6.0|AnyCPU'">
|
||||
|
||||
@@ -552,6 +552,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
/// <returns>Task{IEnumerable{RecordingInfo}}</returns>
|
||||
public async Task<IEnumerable<RecordingInfo>> GetRecordingsAsync(CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
return new List<RecordingInfo>();
|
||||
}
|
||||
|
||||
@@ -1140,8 +1141,14 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
baseUrl = protocol + "://" + Plugin.Instance.Configuration.WebInterfaceUsername + ":" + Plugin.Instance.Configuration.WebInterfacePassword + "@" + Plugin.Instance.Configuration.HostName + ":" + Plugin.Instance.Configuration.StreamingPort;
|
||||
}
|
||||
|
||||
var trancodingUrl = "";
|
||||
if (Plugin.Instance.Configuration.TranscodedStream)
|
||||
{
|
||||
trancodingUrl = "?bitrate=1000000?width=1280?height=720?vcodec=h264?aspectratio=2?interlaced=0.mp4";
|
||||
}
|
||||
|
||||
_liveStreams++;
|
||||
var streamUrl = string.Format("{0}/{1}", baseUrl, channelOid);
|
||||
var streamUrl = string.Format("{0}/{1}{2}", baseUrl, channelOid, trancodingUrl);
|
||||
UtilsHelper.DebugInformation(_logger, string.Format("[Enigma2] GetChannelStream url: {0}", streamUrl));
|
||||
|
||||
return new MediaSourceInfo
|
||||
@@ -1258,6 +1265,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
{
|
||||
_logger.LogInformation("[Enigma2] Start GetNewTimerDefaultsAsync");
|
||||
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
var seriesTimerInfo = new SeriesTimerInfo();
|
||||
|
||||
return seriesTimerInfo;
|
||||
@@ -1553,12 +1561,14 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
|
||||
public async Task<MediaSourceInfo> GetRecordingStream(string recordingId, string mediaSourceId, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
|
||||
public async Task CloseLiveStream(string id, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
@@ -1589,7 +1599,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
public async Task<IEnumerable<SeriesTimerInfo>> GetSeriesTimersAsync(CancellationToken cancellationToken)
|
||||
{
|
||||
_logger.LogInformation("[Enigma2] Start GetSeriesTimersAsync");
|
||||
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
var seriesTimerInfo = new List<SeriesTimerInfo>();
|
||||
return seriesTimerInfo;
|
||||
}
|
||||
@@ -1603,6 +1613,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
/// <returns></returns>
|
||||
public async Task CreateSeriesTimerAsync(SeriesTimerInfo info, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
@@ -1615,6 +1626,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
/// <returns></returns>
|
||||
public async Task UpdateSeriesTimerAsync(SeriesTimerInfo info, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
@@ -1627,6 +1639,7 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
/// <returns></returns>
|
||||
public async Task UpdateTimerAsync(TimerInfo info, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
@@ -1639,27 +1652,11 @@ namespace Jellyfin.Plugin.Enigma2
|
||||
/// <returns></returns>
|
||||
public async Task CancelSeriesTimerAsync(string timerId, CancellationToken cancellationToken)
|
||||
{
|
||||
await Task.Delay(0); //to avoid await warnings
|
||||
throw new NotImplementedException();
|
||||
}
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Get the DefaultScheduleSettings
|
||||
/// </summary>
|
||||
/// <param name="cancellationToken">The CancellationToken</param>
|
||||
/// <returns></returns>
|
||||
//private async Task<ScheduleSettings> GetDefaultScheduleSettings(CancellationToken cancellationToken)
|
||||
//{
|
||||
// throw new NotImplementedException();
|
||||
//}
|
||||
|
||||
|
||||
public event EventHandler DataSourceChanged;
|
||||
|
||||
|
||||
public event EventHandler<RecordingStatusChangedEventArgs> RecordingStatusChanged;
|
||||
|
||||
|
||||
public Task ResetTuner(string id, CancellationToken cancellationToken)
|
||||
{
|
||||
throw new NotImplementedException();
|
||||
|
||||
Reference in New Issue
Block a user