简体   繁体   English

尝试在系统上存储XBOX UWP的音乐

[英]Try to store music for XBOX UWP on System

I'm writing a UWP Music player, that syncs Music stored in your OneDrive to the local machine to play it. 我正在编写一个UWP音乐播放器,它将存储在您OneDrive中的音乐同步到本地计算机上以进行播放。 The User can Store it in the App folder, or his Music Folder. 用户可以将其存储在App文件夹或其音乐文件夹中。

I also would like that this app runs on the XBoxOne. 我也希望该应用程序可以在XBoxOne上运行。 Unfortunately Storing Data on the System will quickly throw Not Enough Disk Space Exception. 不幸的是,在系统上存储数据将很快引发“磁盘空间不足”异常。

According to an MSDN Answer an app can have a maximum of 3GB and there seems to be ways to get it up to 16GB if no other UWP app takes up that space. 根据MSDN Answer,一个应用程序最多可以有3GB的空间,如果没有其他UWP应用程序占用该空间,似乎有办法将其提高到16GB。

A dedicated Music folder is not available on Xbox. Xbox上没有专用的“音乐”文件夹。 (The method to get the StorageFolder returns null) (获取StorageFolder的方法返回null)

Is there any way to store more data on the Xbox? 有什么办法可以在Xbox上存储更多数据吗? Some music library's exceed easily 50GB. 一些音乐库轻松超过50GB。

No, there is no support for apps to get additional space on the internal drive (there can be a user music folder, but space here is limited). 不可以,不支持应用程序在内部驱动器上获取更多空间(可以有用户音乐文件夹,但此处的空间有限)。 The reason why you got a failure getting the music folder may because that you didn't declare the capability. 无法获取音乐文件夹的原因可能是因为您没有声明该功能。 Since given the limited storage, I'd strongly discourage you from writing files there. 由于存储空间有限,因此强烈建议您不要在此处写入文件。

You can format an external USB drive to be used for media playback and plug it in, with apps being allowed to read from it if you have the capability defined in your manifest. 您可以格式化用于播放媒体的外部USB驱动器并将其插入,如果清单中定义了功能,则允许从中读取应用程序。

https://docs.microsoft.com/en-us/windows/uwp/packaging/app-capability-declarations https://docs.microsoft.com/en-us/windows/uwp/packaging/app-capability-declarations

See above for declaring access to removable storage if you want to read from an external drive formatted for media. 如果要从格式化为媒体的外部驱动器中读取数据,请参见上文,以声明对可移动存储的访问。

Thanks. 谢谢。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM