diff options
| author | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-10-20 20:54:01 -0400 |
|---|---|---|
| committer | Luke Pulverenti <luke.pulverenti@gmail.com> | 2014-10-20 20:54:01 -0400 |
| commit | df509dedb71c35d6503a46d0e87a40790d2401e6 (patch) | |
| tree | 4a7eac236b6e03e5d4d02fc690ca0910af985ce5 | |
| parent | 1292eccfb57d82110d197d7fa2f1f6bbf01a7e18 (diff) | |
update dlna profiles
27 files changed, 174 insertions, 66 deletions
diff --git a/MediaBrowser.Dlna/DlnaManager.cs b/MediaBrowser.Dlna/DlnaManager.cs index 1a5269b9d..b4519d02d 100644 --- a/MediaBrowser.Dlna/DlnaManager.cs +++ b/MediaBrowser.Dlna/DlnaManager.cs @@ -3,6 +3,7 @@ using MediaBrowser.Common.Extensions; using MediaBrowser.Common.IO; using MediaBrowser.Controller.Dlna; using MediaBrowser.Controller.Drawing; +using MediaBrowser.Controller.Plugins; using MediaBrowser.Dlna.Profiles; using MediaBrowser.Dlna.Server; using MediaBrowser.Model.Dlna; @@ -37,8 +38,6 @@ namespace MediaBrowser.Dlna _appPaths = appPaths; _logger = logger; _jsonSerializer = jsonSerializer; - - //DumpProfiles(); } public IEnumerable<DeviceProfile> GetProfiles() @@ -55,44 +54,6 @@ namespace MediaBrowser.Dlna return list; } - private void DumpProfiles() - { - var list = new List<DeviceProfile> - { - new SamsungSmartTvProfile(), - new Xbox360Profile(), - new XboxOneProfile(), - new SonyPs3Profile(), - new SonyBravia2010Profile(), - new SonyBravia2011Profile(), - new SonyBravia2012Profile(), - new SonyBravia2013Profile(), - new SonyBlurayPlayer2013Profile(), - new SonyBlurayPlayerProfile(), - new PanasonicVieraProfile(), - new WdtvLiveProfile(), - new DenonAvrProfile(), - new LinksysDMA2100Profile(), - new LgTvProfile(), - new Foobar2000Profile(), - new MediaMonkeyProfile(), - new Windows81Profile(), - //new WindowsMediaCenterProfile(), - new WindowsPhoneProfile(), - new AndroidProfile(true, true, new[]{"baseline", "constrained baseline"}), - new DirectTvProfile(), - new DishHopperJoeyProfile(), - new DefaultProfile() - }; - - foreach (var item in list) - { - var path = Path.Combine(_appPaths.ProgramDataPath, _fileSystem.GetValidFilename(item.Name) + ".xml"); - - _xmlSerializer.SerializeToFile(item, path); - } - } - private bool _extracted; private readonly object _syncLock = new object(); private void ExtractProfilesIfNeeded() @@ -521,4 +482,66 @@ namespace MediaBrowser.Dlna }; } } + + class DlnaProfileEntryPoint : IServerEntryPoint + { + private readonly IApplicationPaths _appPaths; + private readonly IXmlSerializer _xmlSerializer; + private readonly IFileSystem _fileSystem; + + public DlnaProfileEntryPoint(IApplicationPaths appPaths, IXmlSerializer xmlSerializer, IFileSystem fileSystem) + { + _appPaths = appPaths; + _xmlSerializer = xmlSerializer; + _fileSystem = fileSystem; + } + + public void Run() + { + //DumpProfiles(); + } + + private void DumpProfiles() + { + var list = new List<DeviceProfile> + { + new SamsungSmartTvProfile(), + new Xbox360Profile(), + new XboxOneProfile(), + new SonyPs3Profile(), + new SonyBravia2010Profile(), + new SonyBravia2011Profile(), + new SonyBravia2012Profile(), + new SonyBravia2013Profile(), + new SonyBlurayPlayer2013Profile(), + new SonyBlurayPlayerProfile(), + new PanasonicVieraProfile(), + new WdtvLiveProfile(), + new DenonAvrProfile(), + new LinksysDMA2100Profile(), + new LgTvProfile(), + new Foobar2000Profile(), + new MediaMonkeyProfile(), + new Windows81Profile(), + //new WindowsMediaCenterProfile(), + new WindowsPhoneProfile(), + new AndroidProfile(), + new DirectTvProfile(), + new DishHopperJoeyProfile(), + new DefaultProfile() + }; + + foreach (var item in list) + { + var path = Path.Combine(_appPaths.ProgramDataPath, _fileSystem.GetValidFilename(item.Name) + ".xml"); + + _xmlSerializer.SerializeToFile(item, path); + } + } + + public void Dispose() + { + throw new NotImplementedException(); + } + } }
\ No newline at end of file diff --git a/MediaBrowser.Dlna/Profiles/XboxOneProfile.cs b/MediaBrowser.Dlna/Profiles/XboxOneProfile.cs index 292ee82c6..f95d1b37e 100644 --- a/MediaBrowser.Dlna/Profiles/XboxOneProfile.cs +++ b/MediaBrowser.Dlna/Profiles/XboxOneProfile.cs @@ -10,8 +10,18 @@ namespace MediaBrowser.Dlna.Profiles public XboxOneProfile() { Name = "Xbox One"; + + ModelName = "Windows Media Player Sharing"; + ModelNumber = "12.0"; + ModelUrl = "http://www.microsoft.com/"; + Manufacturer = "Microsoft Corporation"; + ManufacturerUrl = "http://www.microsoft.com/"; XDlnaDoc = "DMS-1.50"; + TimelineOffsetSeconds = 40; + RequiresPlainFolders = true; + RequiresPlainVideoItems = true; + Identification = new DeviceIdentification { ModelName = "Xbox One", diff --git a/MediaBrowser.Dlna/Profiles/Xml/Android.xml b/MediaBrowser.Dlna/Profiles/Xml/Android.xml index 642f93c14..85f3c73a7 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Android.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Android.xml @@ -25,6 +25,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp4" audioCodec="aac" videoCodec="h264,mpeg4" type="Video" /> @@ -36,33 +38,42 @@ </DirectPlayProfiles> <TranscodingProfiles> <TranscodingProfile container="mp3" type="Audio" audioCodec="mp3" estimateContentLength="false" enableMpegtsM2TsMode="false" transcodeSeekInfo="Auto" context="Streaming" /> - <TranscodingProfile container="ts" type="Video" videoCodec="h264" audioCodec="aac" protocol="hls" estimateContentLength="false" enableMpegtsM2TsMode="false" transcodeSeekInfo="Auto" videoProfile="Baseline" context="Streaming" /> - <TranscodingProfile container="mp4" type="Video" videoCodec="h264" audioCodec="aac" estimateContentLength="false" enableMpegtsM2TsMode="false" transcodeSeekInfo="Auto" videoProfile="Baseline" context="Static" /> + <TranscodingProfile container="ts" type="Video" videoCodec="h264" audioCodec="aac" protocol="hls" estimateContentLength="false" enableMpegtsM2TsMode="false" transcodeSeekInfo="Auto" videoProfile="baseline" context="Streaming" /> + <TranscodingProfile container="mp4" type="Video" videoCodec="h264" audioCodec="aac" estimateContentLength="false" enableMpegtsM2TsMode="false" transcodeSeekInfo="Auto" videoProfile="baseline" context="Static" /> </TranscodingProfiles> <ContainerProfiles /> <CodecProfiles> - <CodecProfile type="Video"> + <CodecProfile type="Video" codec="h264"> <Conditions> - <ProfileCondition condition="LessThanEqual" property="Width" value="1920" isRequired="true" /> - <ProfileCondition condition="LessThanEqual" property="Height" value="1080" isRequired="true" /> + <ProfileCondition condition="EqualsAny" property="VideoProfile" value="baseline|constrained baseline" isRequired="false" /> + <ProfileCondition condition="LessThanEqual" property="Width" value="1920" isRequired="false" /> + <ProfileCondition condition="LessThanEqual" property="Height" value="1080" isRequired="false" /> + <ProfileCondition condition="LessThanEqual" property="VideoBitDepth" value="8" isRequired="false" /> <ProfileCondition condition="NotEquals" property="IsAnamorphic" value="true" isRequired="false" /> + </Conditions> + </CodecProfile> + <CodecProfile type="Video"> + <Conditions> + <ProfileCondition condition="LessThanEqual" property="Width" value="1920" isRequired="false" /> + <ProfileCondition condition="LessThanEqual" property="Height" value="1080" isRequired="false" /> <ProfileCondition condition="LessThanEqual" property="VideoBitDepth" value="8" isRequired="false" /> + <ProfileCondition condition="NotEquals" property="IsAnamorphic" value="true" isRequired="false" /> </Conditions> </CodecProfile> <CodecProfile type="VideoAudio" codec="aac"> <Conditions> - <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="true" /> + <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="false" /> </Conditions> </CodecProfile> <CodecProfile type="Audio" codec="aac"> <Conditions> - <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="true" /> + <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="false" /> </Conditions> </CodecProfile> <CodecProfile type="Audio" codec="mp3"> <Conditions> - <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="true" /> - <ProfileCondition condition="LessThanEqual" property="AudioBitrate" value="320000" isRequired="true" /> + <ProfileCondition condition="LessThanEqual" property="AudioChannels" value="2" isRequired="false" /> + <ProfileCondition condition="LessThanEqual" property="AudioBitrate" value="320000" isRequired="false" /> </Conditions> </CodecProfile> </CodecProfiles> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Default.xml b/MediaBrowser.Dlna/Profiles/Xml/Default.xml index cc1481ee3..468bd13d6 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Default.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Default.xml @@ -25,6 +25,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3,wma" type="Audio" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Denon AVR.xml b/MediaBrowser.Dlna/Profiles/Xml/Denon AVR.xml index ffcdcf9fc..1636f7202 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Denon AVR.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Denon AVR.xml @@ -30,6 +30,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3,flac,m4a,wma" type="Audio" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/DirecTV HD-DVR.xml b/MediaBrowser.Dlna/Profiles/Xml/DirecTV HD-DVR.xml index c6ca13e04..b5563e9e6 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/DirecTV HD-DVR.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/DirecTV HD-DVR.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>10</TimelineOffsetSeconds> <RequiresPlainVideoItems>true</RequiresPlainVideoItems> <RequiresPlainFolders>true</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mpeg" audioCodec="mp2" videoCodec="mpeg2video" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Dish Hopper-Joey.xml b/MediaBrowser.Dlna/Profiles/Xml/Dish Hopper-Joey.xml index 98ab66408..ebd887670 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Dish Hopper-Joey.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Dish Hopper-Joey.xml @@ -32,6 +32,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp4,mkv,mpeg,ts" audioCodec="mp3,ac3,aac,he-aac,pcm" videoCodec="h264,mpeg2video" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/LG Smart TV.xml b/MediaBrowser.Dlna/Profiles/Xml/LG Smart TV.xml index fd5363529..8073e3ff0 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/LG Smart TV.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/LG Smart TV.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>10</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="ts" audioCodec="aac,ac3,mp3" videoCodec="h264" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Linksys DMA2100.xml b/MediaBrowser.Dlna/Profiles/Xml/Linksys DMA2100.xml index 7d0f416e9..d18501200 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Linksys DMA2100.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Linksys DMA2100.xml @@ -29,6 +29,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3,flac,m4a,wma" type="Audio" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/MediaMonkey.xml b/MediaBrowser.Dlna/Profiles/Xml/MediaMonkey.xml index eb85e5877..f62f02034 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/MediaMonkey.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/MediaMonkey.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3" audioCodec="mp2,mp3" type="Audio" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Panasonic Viera.xml b/MediaBrowser.Dlna/Profiles/Xml/Panasonic Viera.xml index de767b932..7960acf3d 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Panasonic Viera.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Panasonic Viera.xml @@ -32,6 +32,8 @@ <TimelineOffsetSeconds>10</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:pv" value="http://www.pv.com/pvns/" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Samsung Smart TV.xml b/MediaBrowser.Dlna/Profiles/Xml/Samsung Smart TV.xml index 25dac2f84..4ef0ec79b 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Samsung Smart TV.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Samsung Smart TV.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:sec" value="http://www.sec.co.kr/" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player 2013.xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player 2013.xml index 65f3393ff..107896ca2 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player 2013.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player 2013.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player.xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player.xml index c47e5045e..10fdccb7b 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Blu-ray Player.xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2010).xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2010).xml index c0164ae53..3adcc0a34 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2010).xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2010).xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2011).xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2011).xml index 454c7b794..ad3f7f9e6 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2011).xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2011).xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2012).xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2012).xml index f9e20531a..b179b2154 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2012).xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2012).xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2013).xml b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2013).xml index 68e35184c..7c9806929 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2013).xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony Bravia (2013).xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes> <XmlAttribute name="xmlns:av" value="urn:schemas-sony-com:av" /> </XmlRootAttributes> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Sony PlayStation 3.xml b/MediaBrowser.Dlna/Profiles/Xml/Sony PlayStation 3.xml index 103c8ad27..f4d5beb07 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Sony PlayStation 3.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Sony PlayStation 3.xml @@ -33,6 +33,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3,wma" type="Audio" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/WDTV Live.xml b/MediaBrowser.Dlna/Profiles/Xml/WDTV Live.xml index 3717b07c4..b1fdd7f71 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/WDTV Live.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/WDTV Live.xml @@ -32,6 +32,8 @@ <TimelineOffsetSeconds>5</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="avi" audioCodec="ac3,dca,mp2,mp3,pcm" videoCodec="mpeg1video,mpeg2video,mpeg4,h264,vc1" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Windows 8 RT.xml b/MediaBrowser.Dlna/Profiles/Xml/Windows 8 RT.xml index 3ed3c14d9..154e7e8fc 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Windows 8 RT.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Windows 8 RT.xml @@ -29,6 +29,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp4,mov" audioCodec="aac,ac3,eac3,mp3,pcm" videoCodec="h264,mpeg4" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Windows Phone.xml b/MediaBrowser.Dlna/Profiles/Xml/Windows Phone.xml index d1f415291..1331f2f8e 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Windows Phone.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Windows Phone.xml @@ -25,6 +25,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp4,mov" audioCodec="aac,mp3" videoCodec="h264" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Xbox 360.xml b/MediaBrowser.Dlna/Profiles/Xml/Xbox 360.xml index 3a7eddc1f..fc9b13ead 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Xbox 360.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Xbox 360.xml @@ -32,6 +32,8 @@ <TimelineOffsetSeconds>40</TimelineOffsetSeconds> <RequiresPlainVideoItems>true</RequiresPlainVideoItems> <RequiresPlainFolders>true</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="avi" audioCodec="ac3,mp3" videoCodec="mpeg4" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/Xbox One.xml b/MediaBrowser.Dlna/Profiles/Xml/Xbox One.xml index 13c368328..ed0119b60 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/Xbox One.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/Xbox One.xml @@ -7,12 +7,12 @@ <Headers /> </Identification> <FriendlyName>Media Browser</FriendlyName> - <Manufacturer>Media Browser</Manufacturer> - <ManufacturerUrl>http://mediabrowser.tv/</ManufacturerUrl> - <ModelName>Media Browser</ModelName> + <Manufacturer>Microsoft Corporation</Manufacturer> + <ManufacturerUrl>http://www.microsoft.com/</ManufacturerUrl> + <ModelName>Windows Media Player Sharing</ModelName> <ModelDescription>Media Browser</ModelDescription> - <ModelNumber>Media Browser</ModelNumber> - <ModelUrl>http://mediabrowser.tv/</ModelUrl> + <ModelNumber>12.0</ModelNumber> + <ModelUrl>http://www.microsoft.com/</ModelUrl> <IgnoreTranscodeByteRangeRequests>false</IgnoreTranscodeByteRangeRequests> <EnableAlbumArtInDidl>false</EnableAlbumArtInDidl> <SupportedMediaTypes>Audio,Photo,Video</SupportedMediaTypes> @@ -27,9 +27,11 @@ <MusicSyncBitrate>128000</MusicSyncBitrate> <XDlnaDoc>DMS-1.50</XDlnaDoc> <ProtocolInfo>http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_AC3_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_HD_50_AC3_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/mpeg:DLNA.ORG_PN=MP3;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/L16;rate=44100;channels=1:DLNA.ORG_PN=LPCM;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/L16;rate=44100;channels=2:DLNA.ORG_PN=LPCM;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/L16;rate=48000;channels=1:DLNA.ORG_PN=LPCM;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/L16;rate=48000;channels=2:DLNA.ORG_PN=LPCM;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMA_BASE;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:audio/x-ms-wma:DLNA.ORG_PN=WMA_FULL;DLNA.ORG_OP=01;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_SM;DLNA.ORG_OP=00;DLNA.ORG_FLAGS=00D00000000000000000000000000000,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_MED;DLNA.ORG_OP=00;DLNA.ORG_FLAGS=00D00000000000000000000000000000,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_LRG;DLNA.ORG_OP=00;DLNA.ORG_FLAGS=00D00000000000000000000000000000,http-get:*:image/jpeg:DLNA.ORG_PN=JPEG_TN;DLNA.ORG_OP=00;DLNA.ORG_FLAGS=00D00000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG1;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_PAL;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_PS_NTSC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_EU_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_EU_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_NA_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_NA_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_KO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=MPEG_TS_SD_KO_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=MPEG_TS_SD_KO_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-msvideo:DLNA.ORG_PN=AVI;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-matroska:DLNA.ORG_PN=MATROSKA;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AAC_MULT5;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_MPEG1_L3;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_SD_AC3;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_720p_AAC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_MP_HD_1080i_AAC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_HP_HD_AAC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=AVC_MP4_LPCM;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_ASP_AAC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_SP_L6_AAC;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mp4:DLNA.ORG_PN=MPEG4_P2_MP4_NDSD;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_AAC_MULT5_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_SD_MPEG1_L3_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_AAC_MULT5_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/mpeg:DLNA.ORG_PN=AVC_TS_MP_HD_MPEG1_L3_ISO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/vnd.dlna.mpeg-tts:DLNA.ORG_PN=AVC_TS_HD_50_LPCM_T;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_BASE;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_FULL;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_FULL;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVMED_PRO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-wmv:DLNA.ORG_PN=WMVHIGH_PRO;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-asf:DLNA.ORG_PN=VC1_ASF_AP_L1_WMA;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-asf:DLNA.ORG_PN=VC1_ASF_AP_L2_WMA;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000,http-get:*:video/x-ms-asf:DLNA.ORG_PN=VC1_ASF_AP_L3_WMA;DLNA.ORG_OP=11;DLNA.ORG_FLAGS=01500000000000000000000000000000</ProtocolInfo> - <TimelineOffsetSeconds>0</TimelineOffsetSeconds> - <RequiresPlainVideoItems>false</RequiresPlainVideoItems> - <RequiresPlainFolders>false</RequiresPlainFolders> + <TimelineOffsetSeconds>40</TimelineOffsetSeconds> + <RequiresPlainVideoItems>true</RequiresPlainVideoItems> + <RequiresPlainFolders>true</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="ts" audioCodec="ac3" videoCodec="h264" type="Video" /> diff --git a/MediaBrowser.Dlna/Profiles/Xml/foobar2000.xml b/MediaBrowser.Dlna/Profiles/Xml/foobar2000.xml index 81347accc..8f341dc4b 100644 --- a/MediaBrowser.Dlna/Profiles/Xml/foobar2000.xml +++ b/MediaBrowser.Dlna/Profiles/Xml/foobar2000.xml @@ -31,6 +31,8 @@ <TimelineOffsetSeconds>0</TimelineOffsetSeconds> <RequiresPlainVideoItems>false</RequiresPlainVideoItems> <RequiresPlainFolders>false</RequiresPlainFolders> + <SupportsDirectRemoteContent>false</SupportsDirectRemoteContent> + <SupportsCustomHttpHeaders>false</SupportsCustomHttpHeaders> <XmlRootAttributes /> <DirectPlayProfiles> <DirectPlayProfile container="mp3" audioCodec="mp2,mp3" type="Audio" /> diff --git a/MediaBrowser.Model/Dlna/Profiles/AndroidProfile.cs b/MediaBrowser.Model/Dlna/Profiles/AndroidProfile.cs index 0d060cda8..1f27e5991 100644 --- a/MediaBrowser.Model/Dlna/Profiles/AndroidProfile.cs +++ b/MediaBrowser.Model/Dlna/Profiles/AndroidProfile.cs @@ -6,8 +6,14 @@ namespace MediaBrowser.Model.Dlna.Profiles [XmlRoot("Profile")] public class AndroidProfile : DefaultProfile { - public AndroidProfile(bool supportsHls, - bool supportsMpegDash, + public AndroidProfile() + : this(true, true, new[] { "baseline", "constrained baseline" }) + { + + } + + public AndroidProfile(bool supportsHls, + bool supportsMpegDash, string[] supportedH264Profiles) { Name = "Android"; diff --git a/MediaBrowser.WebDashboard/Api/DashboardService.cs b/MediaBrowser.WebDashboard/Api/DashboardService.cs index 7f58a63bb..85a388847 100644 --- a/MediaBrowser.WebDashboard/Api/DashboardService.cs +++ b/MediaBrowser.WebDashboard/Api/DashboardService.cs @@ -286,8 +286,14 @@ namespace MediaBrowser.WebDashboard.Api var culture = "en-US"; - await DumpHtml(creator.DashboardUIPath, path, culture, _appHost.ApplicationVersion.ToString()); + var appVersion = _appHost.ApplicationVersion.ToString(); + await DumpHtml(creator.DashboardUIPath, path, culture, appVersion); + await DumpJs(creator.DashboardUIPath, path, culture, appVersion); + + await DumpFile("scripts/all.js", Path.Combine(path, "scripts", "all.js"), culture, appVersion).ConfigureAwait(false); + await DumpFile("css/all.css", Path.Combine(path, "css", "all.css"), culture, appVersion).ConfigureAwait(false); + return ""; } @@ -295,19 +301,27 @@ namespace MediaBrowser.WebDashboard.Api { foreach (var file in Directory.GetFiles(source, "*.html", SearchOption.TopDirectoryOnly)) { - await DumpHtmlFile(file, destination, culture, appVersion).ConfigureAwait(false); + var filename = Path.GetFileName(file); + + await DumpFile(filename, Path.Combine(destination, filename), culture, appVersion).ConfigureAwait(false); } } - private async Task DumpHtmlFile(string file, string destination, string culture, string appVersion) + private async Task DumpJs(string source, string destination, string culture, string appVersion) { - var filename = Path.GetFileName(file); + foreach (var file in Directory.GetFiles(source, "*.js", SearchOption.TopDirectoryOnly)) + { + var filename = Path.GetFileName(file); - var targetPath = Path.Combine(destination, filename); + await DumpFile("scripts/" + filename, Path.Combine(destination, "scripts", filename), culture, appVersion).ConfigureAwait(false); + } + } - using (var stream = await GetPackageCreator().GetResource(filename, culture, appVersion).ConfigureAwait(false)) + private async Task DumpFile(string resourceVirtualPath, string destinationFilePath, string culture, string appVersion) + { + using (var stream = await GetPackageCreator().GetResource(resourceVirtualPath, culture, appVersion).ConfigureAwait(false)) { - using (var fs = _fileSystem.GetFileStream(targetPath, FileMode.Create, FileAccess.Write, FileShare.Read)) + using (var fs = _fileSystem.GetFileStream(destinationFilePath, FileMode.Create, FileAccess.Write, FileShare.Read)) { stream.CopyTo(fs); } |
