Light weight application In QT
I am peter. I am new to Qt framework. I have worked lots and lots of framework in this computer world but i didnt see this kind of rapid developement application tool as well as code independent future. Such a robust application. I love to work with this framework.
Right now I am trying to develop a live multimedia streaming application using this framework. One of the main challenge facing is to built a light weight application. What ever i load a developed prorgam it takes time to load. So the application should work on the minimum processor speed(eg: Google Chrome). I tried to miniminze the code but i failed.
Is there any other documentation is avaiable to build such kind of application? and also Can any body assist me to build a light weight appplication in Qt?.
Please help me regarding the same.
A . Peter Jerald
[quote author="Peter Jerald" date="1290272191"]live multimedia streaming application[/quote]
I think that in such kind of application the main CPU load should be the multimedia streaming, not the framework.
If you want just to speed-up application load then maybe the following will be helpful:
- can you pre-load some part of your application (for example, server on start-up) and just connect to it with a small client? The client may be non-Qt application that "pings" the server, and server displays it's window
- if application uses many dynamic libraries make sure that the libraries are not relocated on load from base address (rebase utility on Windows, do not know the name for Linux). This also saves memory
- try static linkage, this may reduce time to search library files
k i will try. Thanks for your valuable answer. Let me check.
Sounds like a very interesting project.
bq. I tried to miniminze the code but i failed.
Just remember that less code does not mean that it's faster. Qt should be plenty fast enough if you just keep it simple. "VLC":http://www.videolan.org/vlc/ was written in Qt, and it's pretty fast.
bq. Is there any other documentation is avaiable to build such kind of application?
As a matter of "fact!":http://doc.qt.nokia.com/4.7/multimedia-videowidget.html
What exactly is taking long?
Is the loading of the libraries the cause of the delay? If so you could consider to reduce dependencies, try different compiler options (e.g. hiding symbols not needed, etc.) for you Qt and your application or even try static linking of some libraries. That will make it impossible to share most memory pages of the libraries, thus increasing the memory use (if several applications are using the same libraries).
Is the initialization of your code taking too long? If that is the case then you could try to go multithreading or simply delay some of your initialization code by putting it into a slot triggered by a QTimer (singleshot with a 200ms or so delay). If that is possible the UI can get displayed before you are done with all of your initialization, which makes the application seem to start up faster.