Gdk.Pixbuf.ScaleSimple Method
Scales a Pixbuf

Syntax

public Pixbuf ScaleSimple (int dest_width, int dest_height, InterpType interp_type)

Parameters

dest_width
The width of destination image
dest_height
The height of destination image
interp_type
The interpolation type for the transformation

Returns

A new Pixbuf object, or null if no memory is available for the transformation.

Remarks

Create a new GdkPixbuf containing a copy of src scaled to dest_width x dest_height. It leaves the current Pixbuf unaffected. interp_type should be InterpType.Nearest if you want maximum speed (but when scaling down InterpType.Nearest is usually unusably ugly). The default interp_type should be InterpType.Bilinear which offers reasonable quality and speed.

You can scale a sub-portion of the Pixbuf by creating a sub-pixbuf using a Pixbuf constructor.

For more complicated scale/compositions see Pixbuf.Scale and Pixbuf.Composite

Requirements

Namespace: Gdk
Assembly: gdk-sharp (in gdk-sharp.dll)