/* CirclesEffect.c generated by valac 0.40.4, the Vala compiler * generated from CirclesEffect.vala, do not modify */ /* Copyright 2013 Jens Bav * Copyright 2016 Software Freedom Conservancy Inc. * * This software is licensed under the GNU Lesser General Public License * (version 2.1 or later). See the COPYING file in this distribution. */ #include #include #include #include #include #include #include #include #include #include #include #define TYPE_SHOTWELL_TRANSITION_DESCRIPTOR (shotwell_transition_descriptor_get_type ()) #define SHOTWELL_TRANSITION_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_SHOTWELL_TRANSITION_DESCRIPTOR, ShotwellTransitionDescriptor)) #define SHOTWELL_TRANSITION_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_SHOTWELL_TRANSITION_DESCRIPTOR, ShotwellTransitionDescriptorClass)) #define IS_SHOTWELL_TRANSITION_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_SHOTWELL_TRANSITION_DESCRIPTOR)) #define IS_SHOTWELL_TRANSITION_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_SHOTWELL_TRANSITION_DESCRIPTOR)) #define SHOTWELL_TRANSITION_DESCRIPTOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_SHOTWELL_TRANSITION_DESCRIPTOR, ShotwellTransitionDescriptorClass)) typedef struct _ShotwellTransitionDescriptor ShotwellTransitionDescriptor; typedef struct _ShotwellTransitionDescriptorClass ShotwellTransitionDescriptorClass; typedef struct _ShotwellTransitionDescriptorPrivate ShotwellTransitionDescriptorPrivate; #define TYPE_CIRCLES_EFFECT_DESCRIPTOR (circles_effect_descriptor_get_type ()) #define CIRCLES_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptor)) #define CIRCLES_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptorClass)) #define IS_CIRCLES_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CIRCLES_EFFECT_DESCRIPTOR)) #define IS_CIRCLES_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CIRCLES_EFFECT_DESCRIPTOR)) #define CIRCLES_EFFECT_DESCRIPTOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptorClass)) typedef struct _CirclesEffectDescriptor CirclesEffectDescriptor; typedef struct _CirclesEffectDescriptorClass CirclesEffectDescriptorClass; typedef struct _CirclesEffectDescriptorPrivate CirclesEffectDescriptorPrivate; enum { CIRCLES_EFFECT_DESCRIPTOR_0_PROPERTY, CIRCLES_EFFECT_DESCRIPTOR_NUM_PROPERTIES }; static GParamSpec* circles_effect_descriptor_properties[CIRCLES_EFFECT_DESCRIPTOR_NUM_PROPERTIES]; #define TYPE_CIRCLES_EFFECT (circles_effect_get_type ()) #define CIRCLES_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CIRCLES_EFFECT, CirclesEffect)) #define CIRCLES_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CIRCLES_EFFECT, CirclesEffectClass)) #define IS_CIRCLES_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CIRCLES_EFFECT)) #define IS_CIRCLES_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CIRCLES_EFFECT)) #define CIRCLES_EFFECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CIRCLES_EFFECT, CirclesEffectClass)) typedef struct _CirclesEffect CirclesEffect; typedef struct _CirclesEffectClass CirclesEffectClass; typedef struct _CirclesEffectPrivate CirclesEffectPrivate; enum { CIRCLES_EFFECT_0_PROPERTY, CIRCLES_EFFECT_NUM_PROPERTIES }; static GParamSpec* circles_effect_properties[CIRCLES_EFFECT_NUM_PROPERTIES]; struct _ShotwellTransitionDescriptor { GObject parent_instance; ShotwellTransitionDescriptorPrivate * priv; }; struct _ShotwellTransitionDescriptorClass { GObjectClass parent_class; const gchar* (*get_id) (ShotwellTransitionDescriptor* self); const gchar* (*get_pluggable_name) (ShotwellTransitionDescriptor* self); SpitTransitionsEffect* (*create) (ShotwellTransitionDescriptor* self, SpitHostInterface* host); }; struct _CirclesEffectDescriptor { ShotwellTransitionDescriptor parent_instance; CirclesEffectDescriptorPrivate * priv; }; struct _CirclesEffectDescriptorClass { ShotwellTransitionDescriptorClass parent_class; }; struct _CirclesEffect { GObject parent_instance; CirclesEffectPrivate * priv; }; struct _CirclesEffectClass { GObjectClass parent_class; }; static gpointer circles_effect_descriptor_parent_class = NULL; static gpointer circles_effect_parent_class = NULL; static SpitTransitionsEffectIface * circles_effect_spit_transitions_effect_parent_iface = NULL; GType shotwell_transition_descriptor_get_type (void) G_GNUC_CONST; GType circles_effect_descriptor_get_type (void) G_GNUC_CONST; CirclesEffectDescriptor* circles_effect_descriptor_new (GFile* resource_directory); CirclesEffectDescriptor* circles_effect_descriptor_construct (GType object_type, GFile* resource_directory); ShotwellTransitionDescriptor* shotwell_transition_descriptor_construct (GType object_type, GFile* resource_directory); static const gchar* circles_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base); static const gchar* circles_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base); static SpitTransitionsEffect* circles_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host); CirclesEffect* circles_effect_new (void); CirclesEffect* circles_effect_construct (GType object_type); GType circles_effect_get_type (void) G_GNUC_CONST; #define CIRCLES_EFFECT_DESIRED_FPS 25 #define CIRCLES_EFFECT_MIN_FPS 15 #define CIRCLES_EFFECT_SPEED 2.5 static void circles_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps); static void circles_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion); static gboolean circles_effect_real_needs_clear_background (SpitTransitionsEffect* base); static void circles_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number); static void circles_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number); static void circles_effect_real_cancel (SpitTransitionsEffect* base); CirclesEffectDescriptor* circles_effect_descriptor_construct (GType object_type, GFile* resource_directory) { CirclesEffectDescriptor * self = NULL; #line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_val_if_fail (G_IS_FILE (resource_directory), NULL); #line 12 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = (CirclesEffectDescriptor*) shotwell_transition_descriptor_construct (object_type, resource_directory); #line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return self; #line 153 "CirclesEffect.c" } CirclesEffectDescriptor* circles_effect_descriptor_new (GFile* resource_directory) { #line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return circles_effect_descriptor_construct (TYPE_CIRCLES_EFFECT_DESCRIPTOR, resource_directory); #line 162 "CirclesEffect.c" } static const gchar* circles_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base) { CirclesEffectDescriptor * self; const gchar* result = NULL; #line 15 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptor); #line 16 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" result = "org.yorba.shotwell.transitions.circles"; #line 16 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return result; #line 177 "CirclesEffect.c" } static const gchar* circles_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base) { CirclesEffectDescriptor * self; const gchar* result = NULL; #line 19 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptor); #line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" result = _ ("Circles"); #line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return result; #line 192 "CirclesEffect.c" } static SpitTransitionsEffect* circles_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host) { CirclesEffectDescriptor * self; SpitTransitionsEffect* result = NULL; CirclesEffect* _tmp0_; #line 23 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT_DESCRIPTOR, CirclesEffectDescriptor); #line 23 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_val_if_fail (SPIT_IS_HOST_INTERFACE (host), NULL); #line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp0_ = circles_effect_new (); #line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" result = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, SPIT_TRANSITIONS_TYPE_EFFECT, SpitTransitionsEffect); #line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return result; #line 213 "CirclesEffect.c" } static void circles_effect_descriptor_class_init (CirclesEffectDescriptorClass * klass) { #line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" circles_effect_descriptor_parent_class = g_type_class_peek_parent (klass); #line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" ((ShotwellTransitionDescriptorClass *) klass)->get_id = (const gchar* (*) (ShotwellTransitionDescriptor *)) circles_effect_descriptor_real_get_id; #line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" ((ShotwellTransitionDescriptorClass *) klass)->get_pluggable_name = (const gchar* (*) (ShotwellTransitionDescriptor *)) circles_effect_descriptor_real_get_pluggable_name; #line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" ((ShotwellTransitionDescriptorClass *) klass)->create = (SpitTransitionsEffect* (*) (ShotwellTransitionDescriptor *, SpitHostInterface*)) circles_effect_descriptor_real_create; #line 228 "CirclesEffect.c" } static void circles_effect_descriptor_instance_init (CirclesEffectDescriptor * self) { } GType circles_effect_descriptor_get_type (void) { static volatile gsize circles_effect_descriptor_type_id__volatile = 0; if (g_once_init_enter (&circles_effect_descriptor_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (CirclesEffectDescriptorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) circles_effect_descriptor_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (CirclesEffectDescriptor), 0, (GInstanceInitFunc) circles_effect_descriptor_instance_init, NULL }; GType circles_effect_descriptor_type_id; circles_effect_descriptor_type_id = g_type_register_static (TYPE_SHOTWELL_TRANSITION_DESCRIPTOR, "CirclesEffectDescriptor", &g_define_type_info, 0); g_once_init_leave (&circles_effect_descriptor_type_id__volatile, circles_effect_descriptor_type_id); } return circles_effect_descriptor_type_id__volatile; } CirclesEffect* circles_effect_construct (GType object_type) { CirclesEffect * self = NULL; #line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = (CirclesEffect*) g_object_new (object_type, NULL); #line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return self; #line 260 "CirclesEffect.c" } CirclesEffect* circles_effect_new (void) { #line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return circles_effect_construct (TYPE_CIRCLES_EFFECT); #line 269 "CirclesEffect.c" } static void circles_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps) { CirclesEffect * self; gint _vala_desired_fps = 0; gint _vala_min_fps = 0; #line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 37 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _vala_desired_fps = CIRCLES_EFFECT_DESIRED_FPS; #line 38 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _vala_min_fps = CIRCLES_EFFECT_MIN_FPS; #line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (desired_fps) { #line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" *desired_fps = _vala_desired_fps; #line 291 "CirclesEffect.c" } #line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (min_fps) { #line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" *min_fps = _vala_min_fps; #line 297 "CirclesEffect.c" } } static void circles_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion) { CirclesEffect * self; #line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); #line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); #line 314 "CirclesEffect.c" } static gboolean circles_effect_real_needs_clear_background (SpitTransitionsEffect* base) { CirclesEffect * self; gboolean result = FALSE; #line 44 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 45 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" result = TRUE; #line 45 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" return result; #line 329 "CirclesEffect.c" } static void circles_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number) { CirclesEffect * self; gdouble alpha = 0.0; gint distance = 0; gint radius = 0; gint circleCountX = 0; gint _tmp0_; gint circleCountY = 0; gint _tmp1_; gdouble maxRadius = 0.0; gint _tmp2_; GdkPixbuf* _tmp3_; GdkPixbuf* _tmp4_; GdkPixbuf* _tmp14_; GdkPixbuf* _tmp15_; #line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); #line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); #line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (ctx != NULL); #line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" alpha = spit_transitions_motion_get_alpha (motion, frame_number); #line 51 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" distance = 60; #line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp0_ = distance; #line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" circleCountX = width / (2 * _tmp0_); #line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp1_ = distance; #line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" circleCountY = height / _tmp1_; #line 54 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp2_ = distance; #line 54 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" maxRadius = CIRCLES_EFFECT_SPEED * _tmp2_; #line 56 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp3_ = spit_transitions_visuals_get_from_pixbuf (visuals); #line 56 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp4_ = _tmp3_; #line 56 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (_tmp4_ != NULL) { #line 386 "CirclesEffect.c" GdkPixbuf* _tmp5_; GdkPixbuf* _tmp6_; GdkRectangle _tmp7_ = {0}; GdkRectangle _tmp8_; gint _tmp9_; GdkRectangle _tmp10_ = {0}; GdkRectangle _tmp11_; gint _tmp12_; gdouble _tmp13_; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp5_ = spit_transitions_visuals_get_from_pixbuf (visuals); #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp6_ = _tmp5_; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" spit_transitions_visuals_get_from_pos (visuals, &_tmp7_); #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp8_ = _tmp7_; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp9_ = _tmp8_.x; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" spit_transitions_visuals_get_from_pos (visuals, &_tmp10_); #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp11_ = _tmp10_; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp12_ = _tmp11_.y; #line 57 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" gdk_cairo_set_source_pixbuf (ctx, _tmp6_, (gdouble) _tmp9_, (gdouble) _tmp12_); #line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp13_ = alpha; #line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" cairo_paint_with_alpha (ctx, 1 - _tmp13_); #line 418 "CirclesEffect.c" } #line 62 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp14_ = spit_transitions_visuals_get_to_pixbuf (visuals); #line 62 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp15_ = _tmp14_; #line 62 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (_tmp15_ != NULL) { #line 426 "CirclesEffect.c" GdkPixbuf* _tmp16_; GdkPixbuf* _tmp17_; GdkRectangle _tmp18_ = {0}; GdkRectangle _tmp19_; gint _tmp20_; GdkRectangle _tmp21_ = {0}; GdkRectangle _tmp22_; gint _tmp23_; gdouble _tmp43_; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp16_ = spit_transitions_visuals_get_to_pixbuf (visuals); #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp17_ = _tmp16_; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" spit_transitions_visuals_get_to_pos (visuals, &_tmp18_); #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp19_ = _tmp18_; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp20_ = _tmp19_.x; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" spit_transitions_visuals_get_to_pos (visuals, &_tmp21_); #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp22_ = _tmp21_; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp23_ = _tmp22_.y; #line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" gdk_cairo_set_source_pixbuf (ctx, _tmp17_, (gdouble) _tmp20_, (gdouble) _tmp23_); #line 454 "CirclesEffect.c" { gint y = 0; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" y = 0; #line 459 "CirclesEffect.c" { gboolean _tmp24_ = FALSE; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp24_ = TRUE; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" while (TRUE) { #line 466 "CirclesEffect.c" gint _tmp26_; gint _tmp27_; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (!_tmp24_) { #line 471 "CirclesEffect.c" gint _tmp25_; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp25_ = y; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" y = _tmp25_ + 1; #line 477 "CirclesEffect.c" } #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp24_ = FALSE; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp26_ = y; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp27_ = circleCountY; #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (!(_tmp26_ <= _tmp27_)) { #line 65 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" break; #line 489 "CirclesEffect.c" } { gint x = 0; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" x = 0; #line 495 "CirclesEffect.c" { gboolean _tmp28_ = FALSE; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp28_ = TRUE; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" while (TRUE) { #line 502 "CirclesEffect.c" gint _tmp30_; gint _tmp31_; gdouble _tmp32_; gint _tmp33_; gint _tmp34_; gint _tmp35_; gint _tmp36_; gdouble _tmp37_; gint _tmp38_; gint _tmp39_; gint _tmp40_; gint _tmp41_; gint _tmp42_; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (!_tmp28_) { #line 518 "CirclesEffect.c" gint _tmp29_; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp29_ = x; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" x = _tmp29_ + 1; #line 524 "CirclesEffect.c" } #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp28_ = FALSE; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp30_ = x; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp31_ = circleCountX; #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" if (!(_tmp30_ <= _tmp31_)) { #line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" break; #line 536 "CirclesEffect.c" } #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp32_ = alpha; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp33_ = x; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp34_ = y; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp35_ = circleCountY; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp36_ = circleCountX; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp37_ = maxRadius; #line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" radius = (gint) (fmax ((gdouble) 0, fmin ((gdouble) 1, _tmp32_ - (((gdouble) (_tmp33_ + _tmp34_)) / ((gdouble) ((_tmp35_ + _tmp36_) * CIRCLES_EFFECT_SPEED))))) * _tmp37_); #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp38_ = distance; #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp39_ = x; #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp40_ = distance; #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp41_ = y; #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp42_ = radius; #line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" cairo_arc (ctx, (gdouble) ((2 * _tmp38_) * _tmp39_), (gdouble) ((2 * _tmp40_) * _tmp41_), (gdouble) _tmp42_, (gdouble) 0, 2 * G_PI); #line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" cairo_fill (ctx); #line 566 "CirclesEffect.c" } } } } } } #line 74 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" cairo_clip (ctx); #line 75 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" _tmp43_ = alpha; #line 75 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" cairo_paint_with_alpha (ctx, _tmp43_); #line 579 "CirclesEffect.c" } } static void circles_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number) { CirclesEffect * self; #line 81 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 81 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals)); #line 81 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion)); #line 597 "CirclesEffect.c" } static void circles_effect_real_cancel (SpitTransitionsEffect* base) { CirclesEffect * self; #line 84 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLES_EFFECT, CirclesEffect); #line 607 "CirclesEffect.c" } static void circles_effect_class_init (CirclesEffectClass * klass) { #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" circles_effect_parent_class = g_type_class_peek_parent (klass); #line 616 "CirclesEffect.c" } static void circles_effect_spit_transitions_effect_interface_init (SpitTransitionsEffectIface * iface) { #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" circles_effect_spit_transitions_effect_parent_iface = g_type_interface_peek_parent (iface); #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->get_fps = (void (*) (SpitTransitionsEffect *, gint*, gint*)) circles_effect_real_get_fps; #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->start = (void (*) (SpitTransitionsEffect *, SpitTransitionsVisuals*, SpitTransitionsMotion*)) circles_effect_real_start; #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->needs_clear_background = (gboolean (*) (SpitTransitionsEffect *)) circles_effect_real_needs_clear_background; #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->paint = (void (*) (SpitTransitionsEffect *, SpitTransitionsVisuals*, SpitTransitionsMotion*, cairo_t*, gint, gint, gint)) circles_effect_real_paint; #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->advance = (void (*) (SpitTransitionsEffect *, SpitTransitionsVisuals*, SpitTransitionsMotion*, gint)) circles_effect_real_advance; #line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CirclesEffect.vala" iface->cancel = (void (*) (SpitTransitionsEffect *)) circles_effect_real_cancel; #line 637 "CirclesEffect.c" } static void circles_effect_instance_init (CirclesEffect * self) { } GType circles_effect_get_type (void) { static volatile gsize circles_effect_type_id__volatile = 0; if (g_once_init_enter (&circles_effect_type_id__volatile)) { static const GTypeInfo g_define_type_info = { sizeof (CirclesEffectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) circles_effect_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (CirclesEffect), 0, (GInstanceInitFunc) circles_effect_instance_init, NULL }; static const GInterfaceInfo spit_transitions_effect_info = { (GInterfaceInitFunc) circles_effect_spit_transitions_effect_interface_init, (GInterfaceFinalizeFunc) NULL, NULL}; GType circles_effect_type_id; circles_effect_type_id = g_type_register_static (G_TYPE_OBJECT, "CirclesEffect", &g_define_type_info, 0); g_type_add_interface_static (circles_effect_type_id, SPIT_TRANSITIONS_TYPE_EFFECT, &spit_transitions_effect_info); g_once_init_leave (&circles_effect_type_id__volatile, circles_effect_type_id); } return circles_effect_type_id__volatile; }