Merge branch 'text-autofit' of https://github.com/gargsms/libvips into gargsms-text-autofit
This commit is contained in:
commit
4f18027a7c
@ -16,6 +16,8 @@
|
||||
* - add @spacing
|
||||
* 29/5/17
|
||||
* - don't set "font" if unset, it breaks caching
|
||||
* 16/7/17
|
||||
* - implement auto fitting of text inside bounds
|
||||
*/
|
||||
|
||||
/*
|
||||
@ -52,6 +54,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
#include <vips/vips.h>
|
||||
|
||||
@ -68,9 +71,11 @@ typedef struct _VipsText {
|
||||
char *text;
|
||||
char *font;
|
||||
int width;
|
||||
int height;
|
||||
int spacing;
|
||||
VipsAlign align;
|
||||
int dpi;
|
||||
VipsGravity gravity;
|
||||
|
||||
FT_Bitmap bitmap;
|
||||
PangoContext *context;
|
||||
@ -80,6 +85,15 @@ typedef struct _VipsText {
|
||||
|
||||
typedef VipsCreateClass VipsTextClass;
|
||||
|
||||
typedef struct _FontSizeList FontSizeList;
|
||||
|
||||
struct _FontSizeList {
|
||||
int deviation;
|
||||
int size;
|
||||
long area;
|
||||
FontSizeList *next;
|
||||
};
|
||||
|
||||
G_DEFINE_TYPE( VipsText, vips_text, VIPS_TYPE_CREATE );
|
||||
|
||||
/* Just have one of these and reuse it.
|
||||
@ -94,6 +108,12 @@ static PangoFontMap *vips_text_fontmap = NULL;
|
||||
*/
|
||||
static GMutex *vips_text_lock = NULL;
|
||||
|
||||
/* The maximum deviation to tolerate for autofitting the text
|
||||
*
|
||||
* TODO: Should the user be able to change this?
|
||||
*/
|
||||
static int const MAX_TOLERANCE = 10;
|
||||
|
||||
static void
|
||||
vips_text_dispose( GObject *gobject )
|
||||
{
|
||||
@ -109,7 +129,7 @@ vips_text_dispose( GObject *gobject )
|
||||
static PangoLayout *
|
||||
text_layout_new( PangoContext *context,
|
||||
const char *text, const char *font, int width, int spacing,
|
||||
VipsAlign align, int dpi )
|
||||
VipsAlign align )
|
||||
{
|
||||
PangoLayout *layout;
|
||||
PangoFontDescription *font_description;
|
||||
@ -150,12 +170,139 @@ text_layout_new( PangoContext *context,
|
||||
return( layout );
|
||||
}
|
||||
|
||||
static int
|
||||
digits_in_num( int f )
|
||||
{
|
||||
int digits = 0;
|
||||
if( f == 0 )
|
||||
return 1;
|
||||
while( f ) {
|
||||
f /= 10;
|
||||
digits++;
|
||||
}
|
||||
return digits;
|
||||
}
|
||||
|
||||
static int
|
||||
determine_deviation( int width, int height, PangoRectangle rect ) {
|
||||
int rect_width = PANGO_PIXELS( rect.width );
|
||||
int rect_height = PANGO_PIXELS( rect.height );
|
||||
|
||||
int dw = (int)( 100 * (double)abs( rect_width - width ) / width );
|
||||
int dh = (int)( 100 * (double)abs( rect_height - height ) / height );
|
||||
|
||||
if( dw && dh ) {
|
||||
return dw * dh;
|
||||
}
|
||||
return dw ? dw : dh;
|
||||
}
|
||||
|
||||
static bool
|
||||
search_flist( FontSizeList *flist, int size )
|
||||
{
|
||||
FontSizeList *entry = flist;
|
||||
while( entry->next != NULL ) {
|
||||
if( entry->size == size )
|
||||
return true;
|
||||
entry = entry->next;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
static FontSizeList *
|
||||
least_deviation_flist( FontSizeList *flist )
|
||||
{
|
||||
FontSizeList *entry = flist;
|
||||
// This works for all practical purposes
|
||||
long smallest = 1999999999;
|
||||
FontSizeList *least;
|
||||
while( entry->next != NULL ) {
|
||||
if( entry->deviation < smallest ) {
|
||||
smallest = entry->deviation;
|
||||
least = entry;
|
||||
}
|
||||
entry = entry->next;
|
||||
}
|
||||
return least;
|
||||
}
|
||||
|
||||
static void
|
||||
append_to_flist( FontSizeList *flist, FontSizeList *nflist )
|
||||
{
|
||||
FontSizeList *entry = flist;
|
||||
while( entry->next != NULL ) {
|
||||
entry = entry->next;
|
||||
}
|
||||
entry->next = nflist;
|
||||
}
|
||||
|
||||
static PangoRectangle
|
||||
fit_to_bounds( VipsText *text,
|
||||
char *name, int size, PangoRectangle rect, FontSizeList *flist, bool coarse )
|
||||
{
|
||||
int buf_size = strlen( name ) + digits_in_num( size ) + 2;
|
||||
int deviation;
|
||||
char buf[ buf_size ];
|
||||
long font_area = (long)PANGO_PIXELS( rect.width ) *
|
||||
(long)PANGO_PIXELS( rect.height );
|
||||
long allowed_area = (long)text->width * (long)text->height;
|
||||
|
||||
FontSizeList *nflist = (FontSizeList *) malloc( sizeof( FontSizeList ) );
|
||||
|
||||
if( coarse ) {
|
||||
// A factor of X increase in font size causes X^2 increase in the area
|
||||
// occupied by the text
|
||||
size = (int)((double)size * sqrt( (double)allowed_area / font_area ));
|
||||
} else {
|
||||
if( allowed_area > font_area ) {
|
||||
size++;
|
||||
} else {
|
||||
size--;
|
||||
}
|
||||
}
|
||||
|
||||
snprintf( buf, buf_size, "%s %d", name, size );
|
||||
|
||||
text->layout = text_layout_new( text->context,
|
||||
text->text, buf, text->width, text->spacing, text->align );
|
||||
|
||||
pango_layout_get_extents( text->layout, NULL, &rect );
|
||||
|
||||
deviation = determine_deviation( text->width, text->height, rect );
|
||||
|
||||
nflist->size = size;
|
||||
nflist->deviation = deviation;
|
||||
nflist->area = PANGO_PIXELS( rect.width ) * PANGO_PIXELS( rect.height );
|
||||
nflist->next = NULL;
|
||||
append_to_flist( flist, nflist );
|
||||
|
||||
// If we have been through this font size before, find the one with the
|
||||
// smallest deviation and then fit in small adjustments
|
||||
if( search_flist( flist, size ) ) {
|
||||
if( coarse ) {
|
||||
return fit_to_bounds( text, name, size, rect,
|
||||
least_deviation_flist( flist ), false );
|
||||
} else {
|
||||
// We cannot do better than this because we will
|
||||
// cycle through sizes again
|
||||
return rect;
|
||||
}
|
||||
}
|
||||
|
||||
if( deviation > MAX_TOLERANCE ) {
|
||||
return fit_to_bounds( text, name, size, rect, flist, coarse );
|
||||
} else {
|
||||
return rect;
|
||||
}
|
||||
}
|
||||
|
||||
static int
|
||||
vips_text_build( VipsObject *object )
|
||||
{
|
||||
VipsObjectClass *class = VIPS_OBJECT_GET_CLASS( object );
|
||||
VipsCreate *create = VIPS_CREATE( object );
|
||||
VipsText *text = (VipsText *) object;
|
||||
FontSizeList *flist = (FontSizeList *) malloc( sizeof( FontSizeList ) );
|
||||
|
||||
PangoRectangle logical_rect;
|
||||
int left;
|
||||
@ -163,6 +310,10 @@ vips_text_build( VipsObject *object )
|
||||
int width;
|
||||
int height;
|
||||
int y;
|
||||
int deviation = 0;
|
||||
int font_size = 0;
|
||||
char *last;
|
||||
bool is_font_size_provided = true;
|
||||
|
||||
if( VIPS_OBJECT_CLASS( vips_text_parent_class )->build( object ) )
|
||||
return( -1 );
|
||||
@ -173,6 +324,26 @@ vips_text_build( VipsObject *object )
|
||||
return( -1 );
|
||||
}
|
||||
|
||||
char *font_name[ strlen( text->font ) + 1 ];
|
||||
// Extract font size from provided argument
|
||||
last = strrchr( text->font, ' ' );
|
||||
|
||||
// Happens for a single word font names
|
||||
if( last != '\0' ) {
|
||||
font_size = atol( last );
|
||||
}
|
||||
|
||||
if( font_size ) {
|
||||
strncat( font_name, text->font, last - text->font );
|
||||
} else {
|
||||
// Font was more than 1 MAX_word. "Fira Code" would have last
|
||||
// pointing to "Code", leading atol to output 0
|
||||
// Fix font_name back to the original in this case
|
||||
strcpy( font_name, text->font );
|
||||
font_size = text->height;
|
||||
is_font_size_provided = false;
|
||||
}
|
||||
|
||||
g_mutex_lock( vips_text_lock );
|
||||
|
||||
if( !vips_text_fontmap )
|
||||
@ -185,13 +356,32 @@ vips_text_build( VipsObject *object )
|
||||
|
||||
if( !(text->layout = text_layout_new( text->context,
|
||||
text->text, text->font,
|
||||
text->width, text->spacing, text->align, text->dpi )) ) {
|
||||
text->width, text->spacing, text->align )) ) {
|
||||
g_mutex_unlock( vips_text_lock );
|
||||
return( -1 );
|
||||
}
|
||||
|
||||
pango_layout_get_extents( text->layout, NULL, &logical_rect );
|
||||
|
||||
if( !is_font_size_provided ) {
|
||||
if( text->height && text->width ) {
|
||||
deviation = determine_deviation( text->width, text->height, logical_rect );
|
||||
}
|
||||
|
||||
if( deviation > MAX_TOLERANCE ) {
|
||||
flist->size = font_size;
|
||||
flist->deviation = deviation;
|
||||
flist->area = PANGO_PIXELS( logical_rect.width ) * PANGO_PIXELS( logical_rect.height );
|
||||
flist->next = NULL;
|
||||
|
||||
logical_rect = fit_to_bounds( text, font_name, font_size, logical_rect, flist, true );
|
||||
}
|
||||
|
||||
// Logical rect does not help us with exact bounds of the text
|
||||
pango_layout_get_extents( text->layout, NULL, &logical_rect );
|
||||
}
|
||||
|
||||
|
||||
#ifdef DEBUG
|
||||
printf( "logical left = %d, top = %d, width = %d, height = %d\n",
|
||||
PANGO_PIXELS( logical_rect.x ),
|
||||
@ -205,6 +395,80 @@ vips_text_build( VipsObject *object )
|
||||
width = PANGO_PIXELS( logical_rect.width );
|
||||
height = PANGO_PIXELS( logical_rect.height );
|
||||
|
||||
// Match the layout to fit the exact dimensions requested
|
||||
// We also apply gravity here
|
||||
if( !is_font_size_provided && text->width && text->height ) {
|
||||
left = 0;
|
||||
top = 0;
|
||||
width = PANGO_PIXELS( logical_rect.width );
|
||||
height = PANGO_PIXELS( logical_rect.height );
|
||||
|
||||
// Since the layout is bigger than the requested dimensions, we
|
||||
// scale the layout font description by the same scale
|
||||
// This seems like the only way to resize the layout before it
|
||||
// is rendered. We cannot reliably do resizing after rendering
|
||||
// because we lose the lock, and we need to rely on vips_resize
|
||||
if( width > text->width || height > text->height ) {
|
||||
double scale_w = (double)text->width / width;
|
||||
double scale_h = (double)text->height / height;
|
||||
double scale = scale_w > scale_h ? scale_h : scale_w;
|
||||
PangoFontDescription *temp_fd = pango_font_description_copy(
|
||||
pango_layout_get_font_description( text->layout ) );
|
||||
int fz = pango_font_description_get_size( temp_fd );
|
||||
pango_font_description_set_size( temp_fd, (int)(fz * scale) );
|
||||
pango_layout_set_font_description( text->layout, temp_fd );
|
||||
pango_font_description_free( temp_fd );
|
||||
|
||||
// Overloading logical_rect as an ink rectangle here to determine the
|
||||
// best gravity
|
||||
// For most cases, gravities with north, south components are completely
|
||||
// useless if we do positioning with logical rect
|
||||
pango_layout_get_extents( text->layout, &logical_rect, NULL );
|
||||
|
||||
width = PANGO_PIXELS( logical_rect.width );
|
||||
height = PANGO_PIXELS( logical_rect.height );
|
||||
}
|
||||
|
||||
switch( text->gravity ) {
|
||||
case VIPS_GRAVITY_CENTER:
|
||||
left = ( text->width - width ) / 2;
|
||||
break;
|
||||
case VIPS_GRAVITY_NORTH:
|
||||
top = ( height - text->height ) / 2;
|
||||
left = ( text->width - width ) / 2;
|
||||
break;
|
||||
case VIPS_GRAVITY_EAST:
|
||||
left = text->width - width;
|
||||
break;
|
||||
case VIPS_GRAVITY_SOUTH:
|
||||
top = ( text->height - height ) / 2;
|
||||
left = ( text->width - width ) / 2;
|
||||
break;
|
||||
case VIPS_GRAVITY_WEST:
|
||||
break;
|
||||
case VIPS_GRAVITY_NORTH_EAST:
|
||||
top = ( height - text->height ) / 2;
|
||||
left = text->width - width;
|
||||
break;
|
||||
case VIPS_GRAVITY_SOUTH_EAST:
|
||||
top = ( text->height - height ) / 2;
|
||||
left = text->width - width;
|
||||
break;
|
||||
case VIPS_GRAVITY_SOUTH_WEST:
|
||||
top = ( text->height - height ) / 2;
|
||||
break;
|
||||
case VIPS_GRAVITY_NORTH_WEST:
|
||||
top = ( height - text->height ) / 2;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
left = -1 * left;
|
||||
top = -1 * top;
|
||||
width = text->width;
|
||||
height = text->height;
|
||||
}
|
||||
|
||||
/* Can happen for "", for example.
|
||||
*/
|
||||
if( width == 0 || height == 0 ) {
|
||||
@ -299,27 +563,41 @@ vips_text_class_init( VipsTextClass *class )
|
||||
G_STRUCT_OFFSET( VipsText, width ),
|
||||
0, VIPS_MAX_COORD, 0 );
|
||||
|
||||
VIPS_ARG_ENUM( class, "align", 7,
|
||||
VIPS_ARG_INT( class, "height", 7,
|
||||
_( "Height" ),
|
||||
_( "Maximum image height in pixels" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsText, height ),
|
||||
0, VIPS_MAX_COORD, 0 );
|
||||
|
||||
VIPS_ARG_ENUM( class, "align", 8,
|
||||
_( "Align" ),
|
||||
_( "Align on the low, centre or high edge" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsText, align ),
|
||||
VIPS_TYPE_ALIGN, VIPS_ALIGN_LOW );
|
||||
|
||||
VIPS_ARG_INT( class, "dpi", 8,
|
||||
VIPS_ARG_INT( class, "dpi", 9,
|
||||
_( "DPI" ),
|
||||
_( "DPI to render at" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsText, dpi ),
|
||||
1, 1000000, 72 );
|
||||
|
||||
VIPS_ARG_INT( class, "spacing", 9,
|
||||
VIPS_ARG_INT( class, "spacing", 10,
|
||||
_( "Spacing" ),
|
||||
_( "Line spacing" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsText, spacing ),
|
||||
0, 1000000, 0 );
|
||||
|
||||
VIPS_ARG_ENUM( class, "gravity", 11,
|
||||
_( "Gravity" ),
|
||||
_( "Gravity to use while auto fitting text in bounds" ),
|
||||
VIPS_ARGUMENT_OPTIONAL_INPUT,
|
||||
G_STRUCT_OFFSET( VipsText, gravity ),
|
||||
VIPS_TYPE_GRAVITY, VIPS_GRAVITY_CENTER );
|
||||
|
||||
}
|
||||
|
||||
static void
|
||||
@ -343,9 +621,11 @@ vips_text_init( VipsText *text )
|
||||
*
|
||||
* * @font: %gchararray, font to render with
|
||||
* * @width: %gint, image should be no wider than this many pixels
|
||||
* * @height: %gint, image should be no higher than this many pixels
|
||||
* * @align: #VipsAlign, left/centre/right alignment
|
||||
* * @dpi: %gint, render at this resolution
|
||||
* * @spacing: %gint, space lines by this in points
|
||||
* * @gravity: #VipsGravity, gravity of text
|
||||
*
|
||||
* Draw the string @text to an image. @out is a one-band 8-bit
|
||||
* unsigned char image, with 0 for no text and 255 for text. Values inbetween
|
||||
@ -362,12 +642,21 @@ vips_text_init( VipsText *text )
|
||||
* case, @align can be used to set the alignment style for multi-line
|
||||
* text.
|
||||
*
|
||||
* @height is the maximum number of pixels high the generated text can be. This
|
||||
* only takes effect when there is no font size specified, and a width is
|
||||
* provided, making a box. If a font size is provided, we render the font size
|
||||
* without any fitting to box. Bounds might be exceeded if the font size is too
|
||||
* big to be fit or wrapped inside.
|
||||
*
|
||||
* @dpi sets the resolution to render at. "sans 12" at 72 dpi draws characters
|
||||
* approximately 12 pixels high.
|
||||
*
|
||||
* @spacing sets the line spacing, in points. It would typicallly be something
|
||||
* like font size times 1.2.
|
||||
*
|
||||
* @gravity determines the position of the text inside the bounds. This is only
|
||||
* applied opportunistically if the bounds are bigger than the text
|
||||
*
|
||||
* See also: vips_xyz(), vips_text(), vips_gaussnoise().
|
||||
*
|
||||
* Returns: 0 on success, -1 on error
|
||||
|
@ -38,6 +38,18 @@
|
||||
extern "C" {
|
||||
#endif /*__cplusplus*/
|
||||
|
||||
typedef enum {
|
||||
VIPS_GRAVITY_CENTER,
|
||||
VIPS_GRAVITY_NORTH,
|
||||
VIPS_GRAVITY_EAST,
|
||||
VIPS_GRAVITY_SOUTH,
|
||||
VIPS_GRAVITY_WEST,
|
||||
VIPS_GRAVITY_NORTH_EAST,
|
||||
VIPS_GRAVITY_SOUTH_EAST,
|
||||
VIPS_GRAVITY_SOUTH_WEST,
|
||||
VIPS_GRAVITY_NORTH_WEST
|
||||
} VipsGravity;
|
||||
|
||||
int vips_black( VipsImage **out, int width, int height, ... )
|
||||
__attribute__((sentinel));
|
||||
|
||||
|
@ -6,50 +6,14 @@
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
/* enumerations from "../../../libvips/include/vips/arithmetic.h" */
|
||||
GType vips_operation_math_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MATH (vips_operation_math_get_type())
|
||||
GType vips_operation_math2_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MATH2 (vips_operation_math2_get_type())
|
||||
GType vips_operation_round_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_ROUND (vips_operation_round_get_type())
|
||||
GType vips_operation_relational_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_RELATIONAL (vips_operation_relational_get_type())
|
||||
GType vips_operation_boolean_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_BOOLEAN (vips_operation_boolean_get_type())
|
||||
GType vips_operation_complex_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEX (vips_operation_complex_get_type())
|
||||
GType vips_operation_complex2_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEX2 (vips_operation_complex2_get_type())
|
||||
GType vips_operation_complexget_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEXGET (vips_operation_complexget_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/basic.h" */
|
||||
GType vips_precision_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_PRECISION (vips_precision_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/colour.h" */
|
||||
GType vips_intent_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_INTENT (vips_intent_get_type())
|
||||
GType vips_pcs_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_PCS (vips_pcs_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/conversion.h" */
|
||||
GType vips_extend_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_EXTEND (vips_extend_get_type())
|
||||
GType vips_direction_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_DIRECTION (vips_direction_get_type())
|
||||
GType vips_align_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ALIGN (vips_align_get_type())
|
||||
GType vips_angle_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ANGLE (vips_angle_get_type())
|
||||
GType vips_angle45_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ANGLE45 (vips_angle45_get_type())
|
||||
GType vips_interesting_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_INTERESTING (vips_interesting_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/convolution.h" */
|
||||
GType vips_combine_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_COMBINE (vips_combine_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/draw.h" */
|
||||
GType vips_combine_mode_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_COMBINE_MODE (vips_combine_mode_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/resample.h" */
|
||||
GType vips_kernel_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_KERNEL (vips_kernel_get_type())
|
||||
GType vips_size_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_SIZE (vips_size_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/create.h" */
|
||||
GType vips_gravity_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_GRAVITY (vips_gravity_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/foreign.h" */
|
||||
GType vips_foreign_flags_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_FOREIGN_FLAGS (vips_foreign_flags_get_type())
|
||||
@ -71,6 +35,39 @@ GType vips_foreign_dz_depth_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_FOREIGN_DZ_DEPTH (vips_foreign_dz_depth_get_type())
|
||||
GType vips_foreign_dz_container_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_FOREIGN_DZ_CONTAINER (vips_foreign_dz_container_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/arithmetic.h" */
|
||||
GType vips_operation_math_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MATH (vips_operation_math_get_type())
|
||||
GType vips_operation_math2_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MATH2 (vips_operation_math2_get_type())
|
||||
GType vips_operation_round_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_ROUND (vips_operation_round_get_type())
|
||||
GType vips_operation_relational_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_RELATIONAL (vips_operation_relational_get_type())
|
||||
GType vips_operation_boolean_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_BOOLEAN (vips_operation_boolean_get_type())
|
||||
GType vips_operation_complex_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEX (vips_operation_complex_get_type())
|
||||
GType vips_operation_complex2_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEX2 (vips_operation_complex2_get_type())
|
||||
GType vips_operation_complexget_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_COMPLEXGET (vips_operation_complexget_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/conversion.h" */
|
||||
GType vips_extend_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_EXTEND (vips_extend_get_type())
|
||||
GType vips_direction_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_DIRECTION (vips_direction_get_type())
|
||||
GType vips_align_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ALIGN (vips_align_get_type())
|
||||
GType vips_angle_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ANGLE (vips_angle_get_type())
|
||||
GType vips_angle45_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ANGLE45 (vips_angle45_get_type())
|
||||
GType vips_interesting_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_INTERESTING (vips_interesting_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/util.h" */
|
||||
GType vips_token_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_TOKEN (vips_token_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/image.h" */
|
||||
GType vips_demand_style_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_DEMAND_STYLE (vips_demand_style_get_type())
|
||||
@ -84,23 +81,29 @@ GType vips_coding_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_CODING (vips_coding_get_type())
|
||||
GType vips_access_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ACCESS (vips_access_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/morphology.h" */
|
||||
GType vips_operation_morphology_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MORPHOLOGY (vips_operation_morphology_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/object.h" */
|
||||
GType vips_argument_flags_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ARGUMENT_FLAGS (vips_argument_flags_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/colour.h" */
|
||||
GType vips_intent_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_INTENT (vips_intent_get_type())
|
||||
GType vips_pcs_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_PCS (vips_pcs_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/operation.h" */
|
||||
GType vips_operation_flags_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_FLAGS (vips_operation_flags_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/resample.h" */
|
||||
GType vips_kernel_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_KERNEL (vips_kernel_get_type())
|
||||
GType vips_size_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_SIZE (vips_size_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/util.h" */
|
||||
GType vips_token_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_TOKEN (vips_token_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/convolution.h" */
|
||||
GType vips_combine_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_COMBINE (vips_combine_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/morphology.h" */
|
||||
GType vips_operation_morphology_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_OPERATION_MORPHOLOGY (vips_operation_morphology_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/draw.h" */
|
||||
GType vips_combine_mode_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_COMBINE_MODE (vips_combine_mode_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/basic.h" */
|
||||
GType vips_precision_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_PRECISION (vips_precision_get_type())
|
||||
/* enumerations from "../../../libvips/include/vips/object.h" */
|
||||
GType vips_argument_flags_get_type (void) G_GNUC_CONST;
|
||||
#define VIPS_TYPE_ARGUMENT_FLAGS (vips_argument_flags_get_type())
|
||||
G_END_DECLS
|
||||
|
||||
#endif /*VIPS_ENUM_TYPES_H*/
|
||||
|
@ -4,384 +4,69 @@
|
||||
/* auto-generated enums for vips introspection */
|
||||
|
||||
#include <vips/vips.h>
|
||||
/* enumerations from "../../libvips/include/vips/arithmetic.h" */
|
||||
/* enumerations from "../../libvips/include/vips/resample.h" */
|
||||
GType
|
||||
vips_operation_math_get_type( void )
|
||||
vips_kernel_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_MATH_SIN, "VIPS_OPERATION_MATH_SIN", "sin"},
|
||||
{VIPS_OPERATION_MATH_COS, "VIPS_OPERATION_MATH_COS", "cos"},
|
||||
{VIPS_OPERATION_MATH_TAN, "VIPS_OPERATION_MATH_TAN", "tan"},
|
||||
{VIPS_OPERATION_MATH_ASIN, "VIPS_OPERATION_MATH_ASIN", "asin"},
|
||||
{VIPS_OPERATION_MATH_ACOS, "VIPS_OPERATION_MATH_ACOS", "acos"},
|
||||
{VIPS_OPERATION_MATH_ATAN, "VIPS_OPERATION_MATH_ATAN", "atan"},
|
||||
{VIPS_OPERATION_MATH_LOG, "VIPS_OPERATION_MATH_LOG", "log"},
|
||||
{VIPS_OPERATION_MATH_LOG10, "VIPS_OPERATION_MATH_LOG10", "log10"},
|
||||
{VIPS_OPERATION_MATH_EXP, "VIPS_OPERATION_MATH_EXP", "exp"},
|
||||
{VIPS_OPERATION_MATH_EXP10, "VIPS_OPERATION_MATH_EXP10", "exp10"},
|
||||
{VIPS_OPERATION_MATH_LAST, "VIPS_OPERATION_MATH_LAST", "last"},
|
||||
{VIPS_KERNEL_NEAREST, "VIPS_KERNEL_NEAREST", "nearest"},
|
||||
{VIPS_KERNEL_LINEAR, "VIPS_KERNEL_LINEAR", "linear"},
|
||||
{VIPS_KERNEL_CUBIC, "VIPS_KERNEL_CUBIC", "cubic"},
|
||||
{VIPS_KERNEL_LANCZOS2, "VIPS_KERNEL_LANCZOS2", "lanczos2"},
|
||||
{VIPS_KERNEL_LANCZOS3, "VIPS_KERNEL_LANCZOS3", "lanczos3"},
|
||||
{VIPS_KERNEL_LAST, "VIPS_KERNEL_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationMath", values );
|
||||
etype = g_enum_register_static( "VipsKernel", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_math2_get_type( void )
|
||||
vips_size_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_MATH2_POW, "VIPS_OPERATION_MATH2_POW", "pow"},
|
||||
{VIPS_OPERATION_MATH2_WOP, "VIPS_OPERATION_MATH2_WOP", "wop"},
|
||||
{VIPS_OPERATION_MATH2_LAST, "VIPS_OPERATION_MATH2_LAST", "last"},
|
||||
{VIPS_SIZE_BOTH, "VIPS_SIZE_BOTH", "both"},
|
||||
{VIPS_SIZE_UP, "VIPS_SIZE_UP", "up"},
|
||||
{VIPS_SIZE_DOWN, "VIPS_SIZE_DOWN", "down"},
|
||||
{VIPS_SIZE_FORCE, "VIPS_SIZE_FORCE", "force"},
|
||||
{VIPS_SIZE_LAST, "VIPS_SIZE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationMath2", values );
|
||||
etype = g_enum_register_static( "VipsSize", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/create.h" */
|
||||
GType
|
||||
vips_operation_round_get_type( void )
|
||||
vips_gravity_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_ROUND_RINT, "VIPS_OPERATION_ROUND_RINT", "rint"},
|
||||
{VIPS_OPERATION_ROUND_CEIL, "VIPS_OPERATION_ROUND_CEIL", "ceil"},
|
||||
{VIPS_OPERATION_ROUND_FLOOR, "VIPS_OPERATION_ROUND_FLOOR", "floor"},
|
||||
{VIPS_OPERATION_ROUND_LAST, "VIPS_OPERATION_ROUND_LAST", "last"},
|
||||
{VIPS_GRAVITY_CENTER, "VIPS_GRAVITY_CENTER", "center"},
|
||||
{VIPS_GRAVITY_NORTH, "VIPS_GRAVITY_NORTH", "north"},
|
||||
{VIPS_GRAVITY_EAST, "VIPS_GRAVITY_EAST", "east"},
|
||||
{VIPS_GRAVITY_SOUTH, "VIPS_GRAVITY_SOUTH", "south"},
|
||||
{VIPS_GRAVITY_WEST, "VIPS_GRAVITY_WEST", "west"},
|
||||
{VIPS_GRAVITY_NORTH_EAST, "VIPS_GRAVITY_NORTH_EAST", "north-east"},
|
||||
{VIPS_GRAVITY_SOUTH_EAST, "VIPS_GRAVITY_SOUTH_EAST", "south-east"},
|
||||
{VIPS_GRAVITY_SOUTH_WEST, "VIPS_GRAVITY_SOUTH_WEST", "south-west"},
|
||||
{VIPS_GRAVITY_NORTH_WEST, "VIPS_GRAVITY_NORTH_WEST", "north-west"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationRound", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_relational_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_RELATIONAL_EQUAL, "VIPS_OPERATION_RELATIONAL_EQUAL", "equal"},
|
||||
{VIPS_OPERATION_RELATIONAL_NOTEQ, "VIPS_OPERATION_RELATIONAL_NOTEQ", "noteq"},
|
||||
{VIPS_OPERATION_RELATIONAL_LESS, "VIPS_OPERATION_RELATIONAL_LESS", "less"},
|
||||
{VIPS_OPERATION_RELATIONAL_LESSEQ, "VIPS_OPERATION_RELATIONAL_LESSEQ", "lesseq"},
|
||||
{VIPS_OPERATION_RELATIONAL_MORE, "VIPS_OPERATION_RELATIONAL_MORE", "more"},
|
||||
{VIPS_OPERATION_RELATIONAL_MOREEQ, "VIPS_OPERATION_RELATIONAL_MOREEQ", "moreeq"},
|
||||
{VIPS_OPERATION_RELATIONAL_LAST, "VIPS_OPERATION_RELATIONAL_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationRelational", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_boolean_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_BOOLEAN_AND, "VIPS_OPERATION_BOOLEAN_AND", "and"},
|
||||
{VIPS_OPERATION_BOOLEAN_OR, "VIPS_OPERATION_BOOLEAN_OR", "or"},
|
||||
{VIPS_OPERATION_BOOLEAN_EOR, "VIPS_OPERATION_BOOLEAN_EOR", "eor"},
|
||||
{VIPS_OPERATION_BOOLEAN_LSHIFT, "VIPS_OPERATION_BOOLEAN_LSHIFT", "lshift"},
|
||||
{VIPS_OPERATION_BOOLEAN_RSHIFT, "VIPS_OPERATION_BOOLEAN_RSHIFT", "rshift"},
|
||||
{VIPS_OPERATION_BOOLEAN_LAST, "VIPS_OPERATION_BOOLEAN_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationBoolean", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complex_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEX_POLAR, "VIPS_OPERATION_COMPLEX_POLAR", "polar"},
|
||||
{VIPS_OPERATION_COMPLEX_RECT, "VIPS_OPERATION_COMPLEX_RECT", "rect"},
|
||||
{VIPS_OPERATION_COMPLEX_CONJ, "VIPS_OPERATION_COMPLEX_CONJ", "conj"},
|
||||
{VIPS_OPERATION_COMPLEX_LAST, "VIPS_OPERATION_COMPLEX_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplex", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complex2_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEX2_CROSS_PHASE, "VIPS_OPERATION_COMPLEX2_CROSS_PHASE", "cross-phase"},
|
||||
{VIPS_OPERATION_COMPLEX2_LAST, "VIPS_OPERATION_COMPLEX2_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplex2", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complexget_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEXGET_REAL, "VIPS_OPERATION_COMPLEXGET_REAL", "real"},
|
||||
{VIPS_OPERATION_COMPLEXGET_IMAG, "VIPS_OPERATION_COMPLEXGET_IMAG", "imag"},
|
||||
{VIPS_OPERATION_COMPLEXGET_LAST, "VIPS_OPERATION_COMPLEXGET_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplexget", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/basic.h" */
|
||||
GType
|
||||
vips_precision_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_PRECISION_INTEGER, "VIPS_PRECISION_INTEGER", "integer"},
|
||||
{VIPS_PRECISION_FLOAT, "VIPS_PRECISION_FLOAT", "float"},
|
||||
{VIPS_PRECISION_APPROXIMATE, "VIPS_PRECISION_APPROXIMATE", "approximate"},
|
||||
{VIPS_PRECISION_LAST, "VIPS_PRECISION_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsPrecision", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/colour.h" */
|
||||
GType
|
||||
vips_intent_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_INTENT_PERCEPTUAL, "VIPS_INTENT_PERCEPTUAL", "perceptual"},
|
||||
{VIPS_INTENT_RELATIVE, "VIPS_INTENT_RELATIVE", "relative"},
|
||||
{VIPS_INTENT_SATURATION, "VIPS_INTENT_SATURATION", "saturation"},
|
||||
{VIPS_INTENT_ABSOLUTE, "VIPS_INTENT_ABSOLUTE", "absolute"},
|
||||
{VIPS_INTENT_LAST, "VIPS_INTENT_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsIntent", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_pcs_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_PCS_LAB, "VIPS_PCS_LAB", "lab"},
|
||||
{VIPS_PCS_XYZ, "VIPS_PCS_XYZ", "xyz"},
|
||||
{VIPS_PCS_LAST, "VIPS_PCS_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsPCS", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/conversion.h" */
|
||||
GType
|
||||
vips_extend_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_EXTEND_BLACK, "VIPS_EXTEND_BLACK", "black"},
|
||||
{VIPS_EXTEND_COPY, "VIPS_EXTEND_COPY", "copy"},
|
||||
{VIPS_EXTEND_REPEAT, "VIPS_EXTEND_REPEAT", "repeat"},
|
||||
{VIPS_EXTEND_MIRROR, "VIPS_EXTEND_MIRROR", "mirror"},
|
||||
{VIPS_EXTEND_WHITE, "VIPS_EXTEND_WHITE", "white"},
|
||||
{VIPS_EXTEND_BACKGROUND, "VIPS_EXTEND_BACKGROUND", "background"},
|
||||
{VIPS_EXTEND_LAST, "VIPS_EXTEND_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsExtend", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_direction_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_DIRECTION_HORIZONTAL, "VIPS_DIRECTION_HORIZONTAL", "horizontal"},
|
||||
{VIPS_DIRECTION_VERTICAL, "VIPS_DIRECTION_VERTICAL", "vertical"},
|
||||
{VIPS_DIRECTION_LAST, "VIPS_DIRECTION_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsDirection", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_align_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ALIGN_LOW, "VIPS_ALIGN_LOW", "low"},
|
||||
{VIPS_ALIGN_CENTRE, "VIPS_ALIGN_CENTRE", "centre"},
|
||||
{VIPS_ALIGN_HIGH, "VIPS_ALIGN_HIGH", "high"},
|
||||
{VIPS_ALIGN_LAST, "VIPS_ALIGN_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAlign", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_angle_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ANGLE_D0, "VIPS_ANGLE_D0", "d0"},
|
||||
{VIPS_ANGLE_D90, "VIPS_ANGLE_D90", "d90"},
|
||||
{VIPS_ANGLE_D180, "VIPS_ANGLE_D180", "d180"},
|
||||
{VIPS_ANGLE_D270, "VIPS_ANGLE_D270", "d270"},
|
||||
{VIPS_ANGLE_LAST, "VIPS_ANGLE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAngle", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_angle45_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ANGLE45_D0, "VIPS_ANGLE45_D0", "d0"},
|
||||
{VIPS_ANGLE45_D45, "VIPS_ANGLE45_D45", "d45"},
|
||||
{VIPS_ANGLE45_D90, "VIPS_ANGLE45_D90", "d90"},
|
||||
{VIPS_ANGLE45_D135, "VIPS_ANGLE45_D135", "d135"},
|
||||
{VIPS_ANGLE45_D180, "VIPS_ANGLE45_D180", "d180"},
|
||||
{VIPS_ANGLE45_D225, "VIPS_ANGLE45_D225", "d225"},
|
||||
{VIPS_ANGLE45_D270, "VIPS_ANGLE45_D270", "d270"},
|
||||
{VIPS_ANGLE45_D315, "VIPS_ANGLE45_D315", "d315"},
|
||||
{VIPS_ANGLE45_LAST, "VIPS_ANGLE45_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAngle45", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_interesting_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_INTERESTING_NONE, "VIPS_INTERESTING_NONE", "none"},
|
||||
{VIPS_INTERESTING_CENTRE, "VIPS_INTERESTING_CENTRE", "centre"},
|
||||
{VIPS_INTERESTING_ENTROPY, "VIPS_INTERESTING_ENTROPY", "entropy"},
|
||||
{VIPS_INTERESTING_ATTENTION, "VIPS_INTERESTING_ATTENTION", "attention"},
|
||||
{VIPS_INTERESTING_LAST, "VIPS_INTERESTING_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsInteresting", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/convolution.h" */
|
||||
GType
|
||||
vips_combine_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_COMBINE_MAX, "VIPS_COMBINE_MAX", "max"},
|
||||
{VIPS_COMBINE_SUM, "VIPS_COMBINE_SUM", "sum"},
|
||||
{VIPS_COMBINE_LAST, "VIPS_COMBINE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsCombine", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/draw.h" */
|
||||
GType
|
||||
vips_combine_mode_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_COMBINE_MODE_SET, "VIPS_COMBINE_MODE_SET", "set"},
|
||||
{VIPS_COMBINE_MODE_ADD, "VIPS_COMBINE_MODE_ADD", "add"},
|
||||
{VIPS_COMBINE_MODE_LAST, "VIPS_COMBINE_MODE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsCombineMode", values );
|
||||
etype = g_enum_register_static( "VipsGravity", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
@ -587,6 +272,312 @@ vips_foreign_dz_container_get_type( void )
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/conversion.h" */
|
||||
GType
|
||||
vips_extend_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_EXTEND_BLACK, "VIPS_EXTEND_BLACK", "black"},
|
||||
{VIPS_EXTEND_COPY, "VIPS_EXTEND_COPY", "copy"},
|
||||
{VIPS_EXTEND_REPEAT, "VIPS_EXTEND_REPEAT", "repeat"},
|
||||
{VIPS_EXTEND_MIRROR, "VIPS_EXTEND_MIRROR", "mirror"},
|
||||
{VIPS_EXTEND_WHITE, "VIPS_EXTEND_WHITE", "white"},
|
||||
{VIPS_EXTEND_BACKGROUND, "VIPS_EXTEND_BACKGROUND", "background"},
|
||||
{VIPS_EXTEND_LAST, "VIPS_EXTEND_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsExtend", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_direction_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_DIRECTION_HORIZONTAL, "VIPS_DIRECTION_HORIZONTAL", "horizontal"},
|
||||
{VIPS_DIRECTION_VERTICAL, "VIPS_DIRECTION_VERTICAL", "vertical"},
|
||||
{VIPS_DIRECTION_LAST, "VIPS_DIRECTION_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsDirection", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_align_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ALIGN_LOW, "VIPS_ALIGN_LOW", "low"},
|
||||
{VIPS_ALIGN_CENTRE, "VIPS_ALIGN_CENTRE", "centre"},
|
||||
{VIPS_ALIGN_HIGH, "VIPS_ALIGN_HIGH", "high"},
|
||||
{VIPS_ALIGN_LAST, "VIPS_ALIGN_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAlign", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_angle_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ANGLE_D0, "VIPS_ANGLE_D0", "d0"},
|
||||
{VIPS_ANGLE_D90, "VIPS_ANGLE_D90", "d90"},
|
||||
{VIPS_ANGLE_D180, "VIPS_ANGLE_D180", "d180"},
|
||||
{VIPS_ANGLE_D270, "VIPS_ANGLE_D270", "d270"},
|
||||
{VIPS_ANGLE_LAST, "VIPS_ANGLE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAngle", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_angle45_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_ANGLE45_D0, "VIPS_ANGLE45_D0", "d0"},
|
||||
{VIPS_ANGLE45_D45, "VIPS_ANGLE45_D45", "d45"},
|
||||
{VIPS_ANGLE45_D90, "VIPS_ANGLE45_D90", "d90"},
|
||||
{VIPS_ANGLE45_D135, "VIPS_ANGLE45_D135", "d135"},
|
||||
{VIPS_ANGLE45_D180, "VIPS_ANGLE45_D180", "d180"},
|
||||
{VIPS_ANGLE45_D225, "VIPS_ANGLE45_D225", "d225"},
|
||||
{VIPS_ANGLE45_D270, "VIPS_ANGLE45_D270", "d270"},
|
||||
{VIPS_ANGLE45_D315, "VIPS_ANGLE45_D315", "d315"},
|
||||
{VIPS_ANGLE45_LAST, "VIPS_ANGLE45_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsAngle45", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_interesting_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_INTERESTING_NONE, "VIPS_INTERESTING_NONE", "none"},
|
||||
{VIPS_INTERESTING_CENTRE, "VIPS_INTERESTING_CENTRE", "centre"},
|
||||
{VIPS_INTERESTING_ENTROPY, "VIPS_INTERESTING_ENTROPY", "entropy"},
|
||||
{VIPS_INTERESTING_ATTENTION, "VIPS_INTERESTING_ATTENTION", "attention"},
|
||||
{VIPS_INTERESTING_LAST, "VIPS_INTERESTING_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsInteresting", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/arithmetic.h" */
|
||||
GType
|
||||
vips_operation_math_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_MATH_SIN, "VIPS_OPERATION_MATH_SIN", "sin"},
|
||||
{VIPS_OPERATION_MATH_COS, "VIPS_OPERATION_MATH_COS", "cos"},
|
||||
{VIPS_OPERATION_MATH_TAN, "VIPS_OPERATION_MATH_TAN", "tan"},
|
||||
{VIPS_OPERATION_MATH_ASIN, "VIPS_OPERATION_MATH_ASIN", "asin"},
|
||||
{VIPS_OPERATION_MATH_ACOS, "VIPS_OPERATION_MATH_ACOS", "acos"},
|
||||
{VIPS_OPERATION_MATH_ATAN, "VIPS_OPERATION_MATH_ATAN", "atan"},
|
||||
{VIPS_OPERATION_MATH_LOG, "VIPS_OPERATION_MATH_LOG", "log"},
|
||||
{VIPS_OPERATION_MATH_LOG10, "VIPS_OPERATION_MATH_LOG10", "log10"},
|
||||
{VIPS_OPERATION_MATH_EXP, "VIPS_OPERATION_MATH_EXP", "exp"},
|
||||
{VIPS_OPERATION_MATH_EXP10, "VIPS_OPERATION_MATH_EXP10", "exp10"},
|
||||
{VIPS_OPERATION_MATH_LAST, "VIPS_OPERATION_MATH_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationMath", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_math2_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_MATH2_POW, "VIPS_OPERATION_MATH2_POW", "pow"},
|
||||
{VIPS_OPERATION_MATH2_WOP, "VIPS_OPERATION_MATH2_WOP", "wop"},
|
||||
{VIPS_OPERATION_MATH2_LAST, "VIPS_OPERATION_MATH2_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationMath2", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_round_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_ROUND_RINT, "VIPS_OPERATION_ROUND_RINT", "rint"},
|
||||
{VIPS_OPERATION_ROUND_CEIL, "VIPS_OPERATION_ROUND_CEIL", "ceil"},
|
||||
{VIPS_OPERATION_ROUND_FLOOR, "VIPS_OPERATION_ROUND_FLOOR", "floor"},
|
||||
{VIPS_OPERATION_ROUND_LAST, "VIPS_OPERATION_ROUND_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationRound", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_relational_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_RELATIONAL_EQUAL, "VIPS_OPERATION_RELATIONAL_EQUAL", "equal"},
|
||||
{VIPS_OPERATION_RELATIONAL_NOTEQ, "VIPS_OPERATION_RELATIONAL_NOTEQ", "noteq"},
|
||||
{VIPS_OPERATION_RELATIONAL_LESS, "VIPS_OPERATION_RELATIONAL_LESS", "less"},
|
||||
{VIPS_OPERATION_RELATIONAL_LESSEQ, "VIPS_OPERATION_RELATIONAL_LESSEQ", "lesseq"},
|
||||
{VIPS_OPERATION_RELATIONAL_MORE, "VIPS_OPERATION_RELATIONAL_MORE", "more"},
|
||||
{VIPS_OPERATION_RELATIONAL_MOREEQ, "VIPS_OPERATION_RELATIONAL_MOREEQ", "moreeq"},
|
||||
{VIPS_OPERATION_RELATIONAL_LAST, "VIPS_OPERATION_RELATIONAL_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationRelational", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_boolean_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_BOOLEAN_AND, "VIPS_OPERATION_BOOLEAN_AND", "and"},
|
||||
{VIPS_OPERATION_BOOLEAN_OR, "VIPS_OPERATION_BOOLEAN_OR", "or"},
|
||||
{VIPS_OPERATION_BOOLEAN_EOR, "VIPS_OPERATION_BOOLEAN_EOR", "eor"},
|
||||
{VIPS_OPERATION_BOOLEAN_LSHIFT, "VIPS_OPERATION_BOOLEAN_LSHIFT", "lshift"},
|
||||
{VIPS_OPERATION_BOOLEAN_RSHIFT, "VIPS_OPERATION_BOOLEAN_RSHIFT", "rshift"},
|
||||
{VIPS_OPERATION_BOOLEAN_LAST, "VIPS_OPERATION_BOOLEAN_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationBoolean", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complex_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEX_POLAR, "VIPS_OPERATION_COMPLEX_POLAR", "polar"},
|
||||
{VIPS_OPERATION_COMPLEX_RECT, "VIPS_OPERATION_COMPLEX_RECT", "rect"},
|
||||
{VIPS_OPERATION_COMPLEX_CONJ, "VIPS_OPERATION_COMPLEX_CONJ", "conj"},
|
||||
{VIPS_OPERATION_COMPLEX_LAST, "VIPS_OPERATION_COMPLEX_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplex", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complex2_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEX2_CROSS_PHASE, "VIPS_OPERATION_COMPLEX2_CROSS_PHASE", "cross-phase"},
|
||||
{VIPS_OPERATION_COMPLEX2_LAST, "VIPS_OPERATION_COMPLEX2_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplex2", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_operation_complexget_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_OPERATION_COMPLEXGET_REAL, "VIPS_OPERATION_COMPLEXGET_REAL", "real"},
|
||||
{VIPS_OPERATION_COMPLEXGET_IMAG, "VIPS_OPERATION_COMPLEXGET_IMAG", "imag"},
|
||||
{VIPS_OPERATION_COMPLEXGET_LAST, "VIPS_OPERATION_COMPLEXGET_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsOperationComplexget", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/util.h" */
|
||||
GType
|
||||
vips_token_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_TOKEN_LEFT, "VIPS_TOKEN_LEFT", "left"},
|
||||
{VIPS_TOKEN_RIGHT, "VIPS_TOKEN_RIGHT", "right"},
|
||||
{VIPS_TOKEN_STRING, "VIPS_TOKEN_STRING", "string"},
|
||||
{VIPS_TOKEN_EQUALS, "VIPS_TOKEN_EQUALS", "equals"},
|
||||
{VIPS_TOKEN_COMMA, "VIPS_TOKEN_COMMA", "comma"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsToken", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/image.h" */
|
||||
GType
|
||||
vips_demand_style_get_type( void )
|
||||
@ -734,6 +725,85 @@ vips_access_get_type( void )
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/colour.h" */
|
||||
GType
|
||||
vips_intent_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_INTENT_PERCEPTUAL, "VIPS_INTENT_PERCEPTUAL", "perceptual"},
|
||||
{VIPS_INTENT_RELATIVE, "VIPS_INTENT_RELATIVE", "relative"},
|
||||
{VIPS_INTENT_SATURATION, "VIPS_INTENT_SATURATION", "saturation"},
|
||||
{VIPS_INTENT_ABSOLUTE, "VIPS_INTENT_ABSOLUTE", "absolute"},
|
||||
{VIPS_INTENT_LAST, "VIPS_INTENT_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsIntent", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_pcs_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_PCS_LAB, "VIPS_PCS_LAB", "lab"},
|
||||
{VIPS_PCS_XYZ, "VIPS_PCS_XYZ", "xyz"},
|
||||
{VIPS_PCS_LAST, "VIPS_PCS_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsPCS", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/operation.h" */
|
||||
GType
|
||||
vips_operation_flags_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GFlagsValue values[] = {
|
||||
{VIPS_OPERATION_NONE, "VIPS_OPERATION_NONE", "none"},
|
||||
{VIPS_OPERATION_SEQUENTIAL, "VIPS_OPERATION_SEQUENTIAL", "sequential"},
|
||||
{VIPS_OPERATION_SEQUENTIAL_UNBUFFERED, "VIPS_OPERATION_SEQUENTIAL_UNBUFFERED", "sequential-unbuffered"},
|
||||
{VIPS_OPERATION_NOCACHE, "VIPS_OPERATION_NOCACHE", "nocache"},
|
||||
{VIPS_OPERATION_DEPRECATED, "VIPS_OPERATION_DEPRECATED", "deprecated"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_flags_register_static( "VipsOperationFlags", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/convolution.h" */
|
||||
GType
|
||||
vips_combine_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_COMBINE_MAX, "VIPS_COMBINE_MAX", "max"},
|
||||
{VIPS_COMBINE_SUM, "VIPS_COMBINE_SUM", "sum"},
|
||||
{VIPS_COMBINE_LAST, "VIPS_COMBINE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsCombine", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/morphology.h" */
|
||||
GType
|
||||
vips_operation_morphology_get_type( void )
|
||||
@ -753,6 +823,45 @@ vips_operation_morphology_get_type( void )
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/draw.h" */
|
||||
GType
|
||||
vips_combine_mode_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_COMBINE_MODE_SET, "VIPS_COMBINE_MODE_SET", "set"},
|
||||
{VIPS_COMBINE_MODE_ADD, "VIPS_COMBINE_MODE_ADD", "add"},
|
||||
{VIPS_COMBINE_MODE_LAST, "VIPS_COMBINE_MODE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsCombineMode", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/basic.h" */
|
||||
GType
|
||||
vips_precision_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_PRECISION_INTEGER, "VIPS_PRECISION_INTEGER", "integer"},
|
||||
{VIPS_PRECISION_FLOAT, "VIPS_PRECISION_FLOAT", "float"},
|
||||
{VIPS_PRECISION_APPROXIMATE, "VIPS_PRECISION_APPROXIMATE", "approximate"},
|
||||
{VIPS_PRECISION_LAST, "VIPS_PRECISION_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsPrecision", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/object.h" */
|
||||
GType
|
||||
vips_argument_flags_get_type( void )
|
||||
@ -778,90 +887,6 @@ vips_argument_flags_get_type( void )
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/operation.h" */
|
||||
GType
|
||||
vips_operation_flags_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GFlagsValue values[] = {
|
||||
{VIPS_OPERATION_NONE, "VIPS_OPERATION_NONE", "none"},
|
||||
{VIPS_OPERATION_SEQUENTIAL, "VIPS_OPERATION_SEQUENTIAL", "sequential"},
|
||||
{VIPS_OPERATION_SEQUENTIAL_UNBUFFERED, "VIPS_OPERATION_SEQUENTIAL_UNBUFFERED", "sequential-unbuffered"},
|
||||
{VIPS_OPERATION_NOCACHE, "VIPS_OPERATION_NOCACHE", "nocache"},
|
||||
{VIPS_OPERATION_DEPRECATED, "VIPS_OPERATION_DEPRECATED", "deprecated"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_flags_register_static( "VipsOperationFlags", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/resample.h" */
|
||||
GType
|
||||
vips_kernel_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_KERNEL_NEAREST, "VIPS_KERNEL_NEAREST", "nearest"},
|
||||
{VIPS_KERNEL_LINEAR, "VIPS_KERNEL_LINEAR", "linear"},
|
||||
{VIPS_KERNEL_CUBIC, "VIPS_KERNEL_CUBIC", "cubic"},
|
||||
{VIPS_KERNEL_LANCZOS2, "VIPS_KERNEL_LANCZOS2", "lanczos2"},
|
||||
{VIPS_KERNEL_LANCZOS3, "VIPS_KERNEL_LANCZOS3", "lanczos3"},
|
||||
{VIPS_KERNEL_LAST, "VIPS_KERNEL_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsKernel", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
GType
|
||||
vips_size_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_SIZE_BOTH, "VIPS_SIZE_BOTH", "both"},
|
||||
{VIPS_SIZE_UP, "VIPS_SIZE_UP", "up"},
|
||||
{VIPS_SIZE_DOWN, "VIPS_SIZE_DOWN", "down"},
|
||||
{VIPS_SIZE_FORCE, "VIPS_SIZE_FORCE", "force"},
|
||||
{VIPS_SIZE_LAST, "VIPS_SIZE_LAST", "last"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsSize", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
/* enumerations from "../../libvips/include/vips/util.h" */
|
||||
GType
|
||||
vips_token_get_type( void )
|
||||
{
|
||||
static GType etype = 0;
|
||||
|
||||
if( etype == 0 ) {
|
||||
static const GEnumValue values[] = {
|
||||
{VIPS_TOKEN_LEFT, "VIPS_TOKEN_LEFT", "left"},
|
||||
{VIPS_TOKEN_RIGHT, "VIPS_TOKEN_RIGHT", "right"},
|
||||
{VIPS_TOKEN_STRING, "VIPS_TOKEN_STRING", "string"},
|
||||
{VIPS_TOKEN_EQUALS, "VIPS_TOKEN_EQUALS", "equals"},
|
||||
{VIPS_TOKEN_COMMA, "VIPS_TOKEN_COMMA", "comma"},
|
||||
{0, NULL, NULL}
|
||||
};
|
||||
|
||||
etype = g_enum_register_static( "VipsToken", values );
|
||||
}
|
||||
|
||||
return( etype );
|
||||
}
|
||||
|
||||
/* Generated data ends here */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user