restored live tv playback in the web client

This commit is contained in:
Luke Pulverenti
2014-03-30 12:49:40 -04:00
parent a90d892eca
commit f756e39b9d
31 changed files with 1373 additions and 192 deletions

View File

@@ -85,6 +85,13 @@ namespace MediaBrowser.Controller.Dto
/// <returns>ChapterInfoDto.</returns>
ChapterInfoDto GetChapterInfoDto(ChapterInfo chapterInfo, BaseItem item);
/// <summary>
/// Gets the media sources.
/// </summary>
/// <param name="item">The item.</param>
/// <returns>List{MediaSourceInfo}.</returns>
List<MediaSourceInfo> GetMediaSources(BaseItem item);
/// <summary>
/// Gets the item by name dto.
/// </summary>

View File

@@ -0,0 +1,38 @@
using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Entities.Audio;
using System.Collections.Generic;
namespace MediaBrowser.Controller.Library
{
public interface IMusicManager
{
/// <summary>
/// Gets the instant mix from song.
/// </summary>
/// <param name="item">The item.</param>
/// <param name="user">The user.</param>
/// <returns>IEnumerable{Audio}.</returns>
IEnumerable<Audio> GetInstantMixFromSong(Audio item, User user);
/// <summary>
/// Gets the instant mix from artist.
/// </summary>
/// <param name="name">The name.</param>
/// <param name="user">The user.</param>
/// <returns>IEnumerable{Audio}.</returns>
IEnumerable<Audio> GetInstantMixFromArtist(string name, User user);
/// <summary>
/// Gets the instant mix from album.
/// </summary>
/// <param name="item">The item.</param>
/// <param name="user">The user.</param>
/// <returns>IEnumerable{Audio}.</returns>
IEnumerable<Audio> GetInstantMixFromAlbum(MusicAlbum item, User user);
/// <summary>
/// Gets the instant mix from genre.
/// </summary>
/// <param name="genres">The genres.</param>
/// <param name="user">The user.</param>
/// <returns>IEnumerable{Audio}.</returns>
IEnumerable<Audio> GetInstantMixFromGenres(IEnumerable<string> genres, User user);
}
}

View File

@@ -1,8 +1,8 @@
using MediaBrowser.Controller.Entities;
using MediaBrowser.Controller.Providers;
using MediaBrowser.Model.Library;
using System.Threading;
using System.Threading.Tasks;
using MediaBrowser.Model.Library;
namespace MediaBrowser.Controller.LiveTv
{
@@ -14,6 +14,8 @@ namespace MediaBrowser.Controller.LiveTv
RecordingInfo RecordingInfo { get; set; }
long? RunTimeTicks { get; set; }
string GetClientTypeName();
string GetUserDataKey();

View File

@@ -134,6 +134,7 @@
<Compile Include="Library\DeleteOptions.cs" />
<Compile Include="Library\ILibraryPostScanTask.cs" />
<Compile Include="Library\IMetadataSaver.cs" />
<Compile Include="Library\IMusicManager.cs" />
<Compile Include="Library\ItemUpdateType.cs" />
<Compile Include="Library\IUserDataManager.cs" />
<Compile Include="Library\UserDataSaveEventArgs.cs" />
@@ -155,11 +156,14 @@
<Compile Include="LiveTv\SeriesTimerInfo.cs" />
<Compile Include="LiveTv\TimerInfo.cs" />
<Compile Include="Localization\ILocalizationManager.cs" />
<Compile Include="MediaEncoding\EncodingOptions.cs" />
<Compile Include="MediaEncoding\ChapterImageRefreshOptions.cs" />
<Compile Include="MediaEncoding\EncodingResult.cs" />
<Compile Include="MediaEncoding\IEncodingManager.cs" />
<Compile Include="MediaEncoding\ImageEncodingOptions.cs" />
<Compile Include="MediaEncoding\IMediaEncoder.cs" />
<Compile Include="MediaEncoding\InternalMediaInfoResult.cs" />
<Compile Include="MediaEncoding\VideoEncodingOptions.cs" />
<Compile Include="Net\IHasResultFactory.cs" />
<Compile Include="Net\IHttpResultFactory.cs" />
<Compile Include="Net\IHttpServer.cs" />

View File

@@ -0,0 +1,79 @@
using MediaBrowser.Controller.Dlna;
namespace MediaBrowser.Controller.MediaEncoding
{
public class EncodingOptions
{
/// <summary>
/// Gets or sets the item identifier.
/// </summary>
/// <value>The item identifier.</value>
public string ItemId { get; set; }
/// <summary>
/// Gets or sets the media source identifier.
/// </summary>
/// <value>The media source identifier.</value>
public string MediaSourceId { get; set; }
/// <summary>
/// Gets or sets the device profile.
/// </summary>
/// <value>The device profile.</value>
public DeviceProfile DeviceProfile { get; set; }
/// <summary>
/// Gets or sets the output path.
/// </summary>
/// <value>The output path.</value>
public string OutputPath { get; set; }
/// <summary>
/// Gets or sets the container.
/// </summary>
/// <value>The container.</value>
public string Container { get; set; }
/// <summary>
/// Gets or sets the audio codec.
/// </summary>
/// <value>The audio codec.</value>
public string AudioCodec { get; set; }
/// <summary>
/// Gets or sets the start time ticks.
/// </summary>
/// <value>The start time ticks.</value>
public long? StartTimeTicks { get; set; }
/// <summary>
/// Gets or sets the maximum channels.
/// </summary>
/// <value>The maximum channels.</value>
public int? MaxAudioChannels { get; set; }
/// <summary>
/// Gets or sets the channels.
/// </summary>
/// <value>The channels.</value>
public int? AudioChannels { get; set; }
/// <summary>
/// Gets or sets the sample rate.
/// </summary>
/// <value>The sample rate.</value>
public int? AudioSampleRate { get; set; }
/// <summary>
/// Gets or sets the bit rate.
/// </summary>
/// <value>The bit rate.</value>
public int? AudioBitRate { get; set; }
/// <summary>
/// Gets or sets the maximum audio bit rate.
/// </summary>
/// <value>The maximum audio bit rate.</value>
public int? MaxAudioBitRate { get; set; }
}
}

View File

@@ -0,0 +1,13 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace MediaBrowser.Controller.MediaEncoding
{
public class EncodingResult
{
public string OutputPath { get; set; }
}
}

View File

@@ -0,0 +1,26 @@

namespace MediaBrowser.Controller.MediaEncoding
{
public class VideoEncodingOptions : EncodingOptions
{
public string VideoCodec { get; set; }
public string VideoProfile { get; set; }
public double? VideoLevel { get; set; }
public int? VideoStreamIndex { get; set; }
public int? AudioStreamIndex { get; set; }
public int? SubtitleStreamIndex { get; set; }
public int? MaxWidth { get; set; }
public int? MaxHeight { get; set; }
public int? Height { get; set; }
public int? Width { get; set; }
}
}