如何添加使用Qt的Andr​​oid扩展文件 [英] How to add android expansion files using Qt

查看:252
本文介绍了如何添加使用Qt的Andr​​oid扩展文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我目前正在开发使用Qt / QML和我的应用程序将超过50 MB谷歌Play商店限制大了很多Android应用,由于是被捆绑的媒体文件,所以我必须使用扩展名的文件。经过一番搜索我一个页上行说,Qt的资源系统可以帮助.obb扩展名的文件:

I am currently developing an Android app using Qt / QML and my app will be a lot larger than the 50 MB Google Play Store limit due to media files that are to be bundled, so I have to use extension files. After some searching I found on a page a line saying that Qt resource system can help make .obb extension files:

对于不适合入谷歌Play商店50 MB的限制,QRC可以生成放在OBB文件RCC大资源

"For large resources that do not fit into the Google Play store 50 MB limit, qrc can generate rcc files that can be put in obb"

但我无法找到如何做到这一点的任何信息或如何从我的code访问这些文件。

but I can not find any information on how to do this or how to access those files from my code.

编辑:
我已经使用Qt做出了.rcc文件。试图将其转换现在.obb。此人使用JOBB工具来完成?

I have made an .rcc file using Qt. Trying to convert it to .obb now. Anyone done this using the jobb tool?

我也在想,我可以上传文件.rcc直接作为谷歌播放接受扩展文件的文件格式,但后来我将无法得到它加密的..但我怎么能访问.rcc文件?我必须写一些Java code或我能得到它从Qt的C ++ / QML工作?

I was also thinking that I could just upload the .rcc file directly as Google Play accepts any file format for expansion files, but then I would not be able to get it encrypted.. but how could I access the .rcc file? Do I have to write some Java code or could I get it to work from Qt C++/QML?

编辑:
我想到了。我使用Qt的命令提示符下可用的RCC工具创建一个外部二进制资源文件。使用QResource类我可以加载外部的二进制资源文件和访问它,因为它是一个正常的QRC资源文件。

I figured it out. I created an external binary resource file using the rcc tool available in Qt command prompt. Using QResource class I can load the external binary resource file and access it as it was a normal qrc resource file.

推荐答案

我面临着扩展文件类似的问题并解决它。虽然我没有覆盖任何加密的问题。

I was facing a similar issue with expansion files and solved it. Although I did not cover any encryption issues.

请咨询以下答案:
<一href=\"http://stackoverflow.com/a/31911151/3155461\">http://stackoverflow.com/a/31911151/3155461

这篇关于如何添加使用Qt的Andr​​oid扩展文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆