Frage

I am loading a Gdk.Pixbuf from bytes:

_pixbuf = new Gdk.Pixbuf(bytes);

Then, I'd like to read the _pixbuf data. But, it appears that the data is actually loading in the background because the data doesn't exist for a while. If I wait, all is fine.

How can I either know when it is finished, or force the update?

War es hilfreich?

Lösung

It turns out that this code was fine... I was executing it in the graphics thread, and returning before it was done. Once I executed it so that it blocked until it was complete, then all was fine.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top