Pixbuf.newFromStreamAtScaleAsync

Creates a new pixbuf by asynchronously loading an image from an input stream.

For more details see Pixbuf.newFromStreamAtScale, which is the synchronous version of this function.

When the operation is finished, callback will be called in the main thread. You can then call Pixbuf.newFromStreamFinish to get the result of the operation.

class Pixbuf
static
void
newFromStreamAtScaleAsync

Parameters

stream InputStream

a gio.InputStream from which to load the pixbuf

width int

the width the image should have or -1 to not constrain the width

height int

the height the image should have or -1 to not constrain the height

preserveAspectRatio bool

TRUE to preserve the image's aspect ratio

cancellable Cancellable

optional gio.Cancellable object, NULL to ignore

callback GAsyncReadyCallback

a GAsyncReadyCallback to call when the pixbuf is loaded

userData void*

the data to pass to the callback function

Meta

Since

2.24