Pixbuf Functions

Pixbuf Functions — Functions for GdkPixbuf

Functions

Includes

#include <retro-gtk/retro-gtk.h>

Description

Convenience functions to handle the options of a GdkPixbuf.

Functions

retro_pixbuf_get_aspect_ratio ()

gfloat
retro_pixbuf_get_aspect_ratio (GdkPixbuf *pixbuf);

Gets the aspect ratio of pixbuf by reading the 'aspect-ratio' pixbuf option.

Parameters

pixbuf

a GdkPixbuf

 

Returns

the aspect ratio, or 0 if the option is not set or its value is invalid.


retro_pixbuf_set_aspect_ratio ()

void
retro_pixbuf_set_aspect_ratio (GdkPixbuf *pixbuf,
                               gfloat aspect_ratio);

Sets the aspect ratio of pixbuf by setting the 'aspect-ratio' pixbuf option. Use retro_pixbuf_get_aspect_ratio() to retrieve it.

Parameters

pixbuf

a GdkPixbuf

 

aspect_ratio

the aspect ratio value

 

Types and Values

See Also

GdkPixbuf, RetroCoreView