Thread
:
mobile application optimization - share your tips
View Single Post
pycage
2009-05-29 , 11:02
Posts: 3,404 | Thanked: 4,474 times | Joined on Oct 2005 @ Germany
#
13
Since this thread was intended for sharing tips, I'll contribute a bit.
Understanding the client-server architecture of the X server is a key to better graphics performance. The X server renders on screen, while the applications are the client. The communication between clients and server is tranditionally a network connection, or through a Unix socket. You should be aware that this is a very narrow bottleneck. Be careful and decide well when to send graphics data from client to server. You can also use shared memory for sending data from client to server, but this is more complicated and only works if client and server run on the same host (OK for Maemo).
You can render and compose graphics directly on the server side and quickly render them on screen.
When using GTK, you shoud know that:
- GtkDrawingArea is server-side
- GdkPixmap and other GdkDrawable objects are server-side
- GdkPixbuf is client-side
GdkPixmaps can be used as server-side offscreen buffers for composing stuff before rendering on screen. The Pixmap can then be rendered into a GtkDrawingArea, for instance. But you should only update the areas that have changed. There is no hardware rendering acceleration on the current tablets, so you should minimize the amount of rendering down to what's necessary.
Quote & Reply
|
The Following User Says Thank You to pycage For This Useful Post:
qwerty12
pycage
View Public Profile
Send a private message to pycage
Find all posts by pycage