[Interest] .rcc files and modules
Thiago Macieira
thiago.macieira at intel.com
Tue Jun 30 00:51:25 CEST 2015
On Monday 29 June 2015 17:48:29 Jérôme Godbout wrote:
> "It's automatic when you load the plugin." I assume it would if you compile
> in the resources with the plugin library altogether into the same binary it
> would be that way?
If the resource is compiled into a binary (.so, .dylib, .exe, .dll, final
application, etc.), the resource is registered when the binary is loaded.
You only need to use QResource if the resource is found on a regular file on
disk. In that sense, the regular file is like a .zip file.
> We don't use .pro file, we are inside Visual Studio. How do you generate
> the qrc_application.cpp or any equivalent outside of .pro file? Any command
> line that generate this?
rcc.
> we probably could integrate that command inside
> MSBuild. That would make the plugin and it's resources altogether. Or use
> Keith suggestion to load the .rcc file associated to the plugin when the
> plugin register.
>
> I was mostly looking into the *rcc -binary* and load only wanted resources
> with *QResource::registerResource()*.
The output of rcc is a .cpp file that, when linked into a binary, causes the
resource contents to be loaded when the binary is loaded.
> Sorry I was not clear about the release, it wasn't meant to be about
> freeing the resource memory but more on the deploy the Qml to have dynamic
> part (multiple .rcc files for different application part) to it with the
> resources binary. I want to load an .rcc only if needed, cause we have many
> modules/plugins and not all of them are used for a particular main script.
It's all or nothing: if the plugin is loaded, the resources are loaded and
registered.
--
Thiago Macieira - thiago.macieira (AT) intel.com
Software Architect - Intel Open Source Technology Center
More information about the Interest
mailing list