summaryrefslogtreecommitdiff
path: root/plugins/shotwell-transitions/ClockEffect.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/shotwell-transitions/ClockEffect.c')
-rw-r--r--plugins/shotwell-transitions/ClockEffect.c638
1 files changed, 638 insertions, 0 deletions
diff --git a/plugins/shotwell-transitions/ClockEffect.c b/plugins/shotwell-transitions/ClockEffect.c
new file mode 100644
index 0000000..3074f40
--- /dev/null
+++ b/plugins/shotwell-transitions/ClockEffect.c
@@ -0,0 +1,638 @@
+/* ClockEffect.c generated by valac 0.32.1, the Vala compiler
+ * generated from ClockEffect.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 <glib.h>
+#include <glib-object.h>
+#include <shotwell-plugin-dev-1.0.h>
+#include <stdlib.h>
+#include <string.h>
+#include <gio/gio.h>
+#include <glib/gi18n-lib.h>
+#include <float.h>
+#include <math.h>
+#include <cairo.h>
+#include <gdk/gdk.h>
+
+
+#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_CLOCK_EFFECT_DESCRIPTOR (clock_effect_descriptor_get_type ())
+#define CLOCK_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptor))
+#define CLOCK_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptorClass))
+#define IS_CLOCK_EFFECT_DESCRIPTOR(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CLOCK_EFFECT_DESCRIPTOR))
+#define IS_CLOCK_EFFECT_DESCRIPTOR_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CLOCK_EFFECT_DESCRIPTOR))
+#define CLOCK_EFFECT_DESCRIPTOR_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptorClass))
+
+typedef struct _ClockEffectDescriptor ClockEffectDescriptor;
+typedef struct _ClockEffectDescriptorClass ClockEffectDescriptorClass;
+typedef struct _ClockEffectDescriptorPrivate ClockEffectDescriptorPrivate;
+
+#define TYPE_CLOCK_EFFECT (clock_effect_get_type ())
+#define CLOCK_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CLOCK_EFFECT, ClockEffect))
+#define CLOCK_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_CLOCK_EFFECT, ClockEffectClass))
+#define IS_CLOCK_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_CLOCK_EFFECT))
+#define IS_CLOCK_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_CLOCK_EFFECT))
+#define CLOCK_EFFECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_CLOCK_EFFECT, ClockEffectClass))
+
+typedef struct _ClockEffect ClockEffect;
+typedef struct _ClockEffectClass ClockEffectClass;
+typedef struct _ClockEffectPrivate ClockEffectPrivate;
+
+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 _ClockEffectDescriptor {
+ ShotwellTransitionDescriptor parent_instance;
+ ClockEffectDescriptorPrivate * priv;
+};
+
+struct _ClockEffectDescriptorClass {
+ ShotwellTransitionDescriptorClass parent_class;
+};
+
+struct _ClockEffect {
+ GObject parent_instance;
+ ClockEffectPrivate * priv;
+};
+
+struct _ClockEffectClass {
+ GObjectClass parent_class;
+};
+
+
+static gpointer clock_effect_descriptor_parent_class = NULL;
+static gpointer clock_effect_parent_class = NULL;
+static SpitTransitionsEffectIface* clock_effect_spit_transitions_effect_parent_iface = NULL;
+
+GType shotwell_transition_descriptor_get_type (void) G_GNUC_CONST;
+GType clock_effect_descriptor_get_type (void) G_GNUC_CONST;
+enum {
+ CLOCK_EFFECT_DESCRIPTOR_DUMMY_PROPERTY
+};
+ClockEffectDescriptor* clock_effect_descriptor_new (GFile* resource_directory);
+ClockEffectDescriptor* clock_effect_descriptor_construct (GType object_type, GFile* resource_directory);
+ShotwellTransitionDescriptor* shotwell_transition_descriptor_construct (GType object_type, GFile* resource_directory);
+static const gchar* clock_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base);
+static const gchar* clock_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base);
+static SpitTransitionsEffect* clock_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host);
+ClockEffect* clock_effect_new (void);
+ClockEffect* clock_effect_construct (GType object_type);
+GType clock_effect_get_type (void) G_GNUC_CONST;
+enum {
+ CLOCK_EFFECT_DUMMY_PROPERTY
+};
+#define CLOCK_EFFECT_DESIRED_FPS 25
+#define CLOCK_EFFECT_MIN_FPS 15
+#define CLOCK_EFFECT_TOP_RADIANT (0.5 * G_PI)
+static void clock_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps);
+static void clock_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion);
+static gboolean clock_effect_real_needs_clear_background (SpitTransitionsEffect* base);
+static void clock_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number);
+static void clock_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number);
+static void clock_effect_real_cancel (SpitTransitionsEffect* base);
+
+
+ClockEffectDescriptor* clock_effect_descriptor_construct (GType object_type, GFile* resource_directory) {
+ ClockEffectDescriptor * self = NULL;
+ GFile* _tmp0_ = NULL;
+#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_val_if_fail (G_IS_FILE (resource_directory), NULL);
+#line 12 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp0_ = resource_directory;
+#line 12 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = (ClockEffectDescriptor*) shotwell_transition_descriptor_construct (object_type, _tmp0_);
+#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return self;
+#line 132 "ClockEffect.c"
+}
+
+
+ClockEffectDescriptor* clock_effect_descriptor_new (GFile* resource_directory) {
+#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return clock_effect_descriptor_construct (TYPE_CLOCK_EFFECT_DESCRIPTOR, resource_directory);
+#line 139 "ClockEffect.c"
+}
+
+
+static const gchar* clock_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base) {
+ ClockEffectDescriptor * self;
+ const gchar* result = NULL;
+#line 15 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptor);
+#line 16 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ result = "org.yorba.shotwell.transitions.clock";
+#line 16 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return result;
+#line 152 "ClockEffect.c"
+}
+
+
+static const gchar* clock_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base) {
+ ClockEffectDescriptor * self;
+ const gchar* result = NULL;
+ const gchar* _tmp0_ = NULL;
+#line 19 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptor);
+#line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp0_ = _ ("Clock");
+#line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ result = _tmp0_;
+#line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return result;
+#line 168 "ClockEffect.c"
+}
+
+
+static SpitTransitionsEffect* clock_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host) {
+ ClockEffectDescriptor * self;
+ SpitTransitionsEffect* result = NULL;
+ ClockEffect* _tmp0_ = NULL;
+#line 23 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT_DESCRIPTOR, ClockEffectDescriptor);
+#line 23 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_val_if_fail (SPIT_IS_HOST_INTERFACE (host), NULL);
+#line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp0_ = clock_effect_new ();
+#line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ result = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, SPIT_TRANSITIONS_TYPE_EFFECT, SpitTransitionsEffect);
+#line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return result;
+#line 186 "ClockEffect.c"
+}
+
+
+static void clock_effect_descriptor_class_init (ClockEffectDescriptorClass * klass) {
+#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ clock_effect_descriptor_parent_class = g_type_class_peek_parent (klass);
+#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ ((ShotwellTransitionDescriptorClass *) klass)->get_id = clock_effect_descriptor_real_get_id;
+#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ ((ShotwellTransitionDescriptorClass *) klass)->get_pluggable_name = clock_effect_descriptor_real_get_pluggable_name;
+#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ ((ShotwellTransitionDescriptorClass *) klass)->create = clock_effect_descriptor_real_create;
+#line 199 "ClockEffect.c"
+}
+
+
+static void clock_effect_descriptor_instance_init (ClockEffectDescriptor * self) {
+}
+
+
+GType clock_effect_descriptor_get_type (void) {
+ static volatile gsize clock_effect_descriptor_type_id__volatile = 0;
+ if (g_once_init_enter (&clock_effect_descriptor_type_id__volatile)) {
+ static const GTypeInfo g_define_type_info = { sizeof (ClockEffectDescriptorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) clock_effect_descriptor_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ClockEffectDescriptor), 0, (GInstanceInitFunc) clock_effect_descriptor_instance_init, NULL };
+ GType clock_effect_descriptor_type_id;
+ clock_effect_descriptor_type_id = g_type_register_static (TYPE_SHOTWELL_TRANSITION_DESCRIPTOR, "ClockEffectDescriptor", &g_define_type_info, 0);
+ g_once_init_leave (&clock_effect_descriptor_type_id__volatile, clock_effect_descriptor_type_id);
+ }
+ return clock_effect_descriptor_type_id__volatile;
+}
+
+
+ClockEffect* clock_effect_construct (GType object_type) {
+ ClockEffect * self = NULL;
+#line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = (ClockEffect*) g_object_new (object_type, NULL);
+#line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return self;
+#line 225 "ClockEffect.c"
+}
+
+
+ClockEffect* clock_effect_new (void) {
+#line 33 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return clock_effect_construct (TYPE_CLOCK_EFFECT);
+#line 232 "ClockEffect.c"
+}
+
+
+static void clock_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps) {
+ ClockEffect * self;
+ gint _vala_desired_fps = 0;
+ gint _vala_min_fps = 0;
+#line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 37 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _vala_desired_fps = CLOCK_EFFECT_DESIRED_FPS;
+#line 38 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _vala_min_fps = CLOCK_EFFECT_MIN_FPS;
+#line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ if (desired_fps) {
+#line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ *desired_fps = _vala_desired_fps;
+#line 250 "ClockEffect.c"
+ }
+#line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ if (min_fps) {
+#line 36 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ *min_fps = _vala_min_fps;
+#line 256 "ClockEffect.c"
+ }
+}
+
+
+static void clock_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion) {
+ ClockEffect * self;
+#line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals));
+#line 41 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion));
+#line 269 "ClockEffect.c"
+}
+
+
+static gboolean clock_effect_real_needs_clear_background (SpitTransitionsEffect* base) {
+ ClockEffect * self;
+ gboolean result = FALSE;
+#line 44 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 45 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ result = TRUE;
+#line 45 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ return result;
+#line 282 "ClockEffect.c"
+}
+
+
+static void clock_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number) {
+ ClockEffect * self;
+ gdouble alpha = 0.0;
+ SpitTransitionsMotion* _tmp0_ = NULL;
+ gint _tmp1_ = 0;
+ gdouble _tmp2_ = 0.0;
+ gdouble start_angle = 0.0;
+ gdouble stop_angle = 0.0;
+ SpitTransitionsMotion* _tmp3_ = NULL;
+ SpitTransitionsDirection _tmp4_ = 0;
+ SpitTransitionsDirection _tmp5_ = 0;
+ gint radius = 0;
+ SpitTransitionsVisuals* _tmp8_ = NULL;
+ GdkRectangle _tmp9_ = {0};
+ GdkRectangle _tmp10_ = {0};
+ gint _tmp11_ = 0;
+ SpitTransitionsVisuals* _tmp12_ = NULL;
+ GdkRectangle _tmp13_ = {0};
+ GdkRectangle _tmp14_ = {0};
+ gint _tmp15_ = 0;
+ gdouble _tmp16_ = 0.0;
+ SpitTransitionsVisuals* _tmp17_ = NULL;
+ GdkPixbuf* _tmp18_ = NULL;
+ GdkPixbuf* _tmp19_ = NULL;
+ SpitTransitionsVisuals* _tmp34_ = NULL;
+ GdkPixbuf* _tmp35_ = NULL;
+ GdkPixbuf* _tmp36_ = NULL;
+#line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals));
+#line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion));
+#line 48 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (ctx != NULL);
+#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp0_ = motion;
+#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp1_ = frame_number;
+#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp2_ = spit_transitions_motion_get_alpha (_tmp0_, _tmp1_);
+#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ alpha = _tmp2_;
+#line 51 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ start_angle = -CLOCK_EFFECT_TOP_RADIANT;
+#line 51 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ stop_angle = -CLOCK_EFFECT_TOP_RADIANT;
+#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp3_ = motion;
+#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp4_ = spit_transitions_motion_get_direction (_tmp3_);
+#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp5_ = _tmp4_;
+#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ if (_tmp5_ == SPIT_TRANSITIONS_DIRECTION_FORWARD) {
+#line 341 "ClockEffect.c"
+ gdouble _tmp6_ = 0.0;
+#line 54 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp6_ = alpha;
+#line 54 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ stop_angle = ((_tmp6_ * G_PI) * 2) - CLOCK_EFFECT_TOP_RADIANT;
+#line 347 "ClockEffect.c"
+ } else {
+ gdouble _tmp7_ = 0.0;
+#line 56 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp7_ = alpha;
+#line 56 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ start_angle = ((2 * (1 - _tmp7_)) * G_PI) - CLOCK_EFFECT_TOP_RADIANT;
+#line 354 "ClockEffect.c"
+ }
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp8_ = visuals;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp8_, &_tmp9_);
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp10_ = _tmp9_;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp11_ = _tmp10_.width;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp12_ = visuals;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp12_, &_tmp13_);
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp14_ = _tmp13_;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp15_ = _tmp14_.height;
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp16_ = fmax ((gdouble) _tmp11_, (gdouble) _tmp15_);
+#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ radius = (gint) _tmp16_;
+#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp17_ = visuals;
+#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp18_ = spit_transitions_visuals_get_from_pixbuf (_tmp17_);
+#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp19_ = _tmp18_;
+#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ if (_tmp19_ != NULL) {
+#line 384 "ClockEffect.c"
+ cairo_t* _tmp20_ = NULL;
+ SpitTransitionsVisuals* _tmp21_ = NULL;
+ GdkPixbuf* _tmp22_ = NULL;
+ GdkPixbuf* _tmp23_ = NULL;
+ SpitTransitionsVisuals* _tmp24_ = NULL;
+ GdkRectangle _tmp25_ = {0};
+ GdkRectangle _tmp26_ = {0};
+ gint _tmp27_ = 0;
+ SpitTransitionsVisuals* _tmp28_ = NULL;
+ GdkRectangle _tmp29_ = {0};
+ GdkRectangle _tmp30_ = {0};
+ gint _tmp31_ = 0;
+ cairo_t* _tmp32_ = NULL;
+ gdouble _tmp33_ = 0.0;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp20_ = ctx;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp21_ = visuals;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp22_ = spit_transitions_visuals_get_from_pixbuf (_tmp21_);
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp23_ = _tmp22_;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp24_ = visuals;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_from_pos (_tmp24_, &_tmp25_);
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp26_ = _tmp25_;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp27_ = _tmp26_.x;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp28_ = visuals;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_from_pos (_tmp28_, &_tmp29_);
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp30_ = _tmp29_;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp31_ = _tmp30_.y;
+#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ gdk_cairo_set_source_pixbuf (_tmp20_, _tmp23_, (gdouble) _tmp27_, (gdouble) _tmp31_);
+#line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp32_ = ctx;
+#line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp33_ = alpha;
+#line 63 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ cairo_paint_with_alpha (_tmp32_, 1 - _tmp33_);
+#line 431 "ClockEffect.c"
+ }
+#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp34_ = visuals;
+#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp35_ = spit_transitions_visuals_get_to_pixbuf (_tmp34_);
+#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp36_ = _tmp35_;
+#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ if (_tmp36_ != NULL) {
+#line 441 "ClockEffect.c"
+ cairo_t* _tmp37_ = NULL;
+ SpitTransitionsVisuals* _tmp38_ = NULL;
+ GdkPixbuf* _tmp39_ = NULL;
+ GdkPixbuf* _tmp40_ = NULL;
+ SpitTransitionsVisuals* _tmp41_ = NULL;
+ GdkRectangle _tmp42_ = {0};
+ GdkRectangle _tmp43_ = {0};
+ gint _tmp44_ = 0;
+ SpitTransitionsVisuals* _tmp45_ = NULL;
+ GdkRectangle _tmp46_ = {0};
+ GdkRectangle _tmp47_ = {0};
+ gint _tmp48_ = 0;
+ gint x = 0;
+ SpitTransitionsVisuals* _tmp49_ = NULL;
+ GdkRectangle _tmp50_ = {0};
+ GdkRectangle _tmp51_ = {0};
+ gint _tmp52_ = 0;
+ SpitTransitionsVisuals* _tmp53_ = NULL;
+ GdkRectangle _tmp54_ = {0};
+ GdkRectangle _tmp55_ = {0};
+ gint _tmp56_ = 0;
+ gint y = 0;
+ SpitTransitionsVisuals* _tmp57_ = NULL;
+ GdkRectangle _tmp58_ = {0};
+ GdkRectangle _tmp59_ = {0};
+ gint _tmp60_ = 0;
+ SpitTransitionsVisuals* _tmp61_ = NULL;
+ GdkRectangle _tmp62_ = {0};
+ GdkRectangle _tmp63_ = {0};
+ gint _tmp64_ = 0;
+ cairo_t* _tmp65_ = NULL;
+ gint _tmp66_ = 0;
+ gint _tmp67_ = 0;
+ cairo_t* _tmp68_ = NULL;
+ gint _tmp69_ = 0;
+ gint _tmp70_ = 0;
+ gint _tmp71_ = 0;
+ gdouble _tmp72_ = 0.0;
+ gdouble _tmp73_ = 0.0;
+ cairo_t* _tmp74_ = NULL;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp37_ = ctx;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp38_ = visuals;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp39_ = spit_transitions_visuals_get_to_pixbuf (_tmp38_);
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp40_ = _tmp39_;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp41_ = visuals;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp41_, &_tmp42_);
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp43_ = _tmp42_;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp44_ = _tmp43_.x;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp45_ = visuals;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp45_, &_tmp46_);
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp47_ = _tmp46_;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp48_ = _tmp47_.y;
+#line 67 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ gdk_cairo_set_source_pixbuf (_tmp37_, _tmp40_, (gdouble) _tmp44_, (gdouble) _tmp48_);
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp49_ = visuals;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp49_, &_tmp50_);
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp51_ = _tmp50_;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp52_ = _tmp51_.x;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp53_ = visuals;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp53_, &_tmp54_);
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp55_ = _tmp54_;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp56_ = _tmp55_.width;
+#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ x = _tmp52_ + (((gint) _tmp56_) / 2);
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp57_ = visuals;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp57_, &_tmp58_);
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp59_ = _tmp58_;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp60_ = _tmp59_.y;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp61_ = visuals;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ spit_transitions_visuals_get_to_pos (_tmp61_, &_tmp62_);
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp63_ = _tmp62_;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp64_ = _tmp63_.height;
+#line 70 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ y = _tmp60_ + (((gint) _tmp64_) / 2);
+#line 72 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp65_ = ctx;
+#line 72 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp66_ = x;
+#line 72 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp67_ = y;
+#line 72 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ cairo_move_to (_tmp65_, (gdouble) _tmp66_, (gdouble) _tmp67_);
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp68_ = ctx;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp69_ = x;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp70_ = y;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp71_ = radius;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp72_ = start_angle;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp73_ = stop_angle;
+#line 73 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ cairo_arc (_tmp68_, (gdouble) _tmp69_, (gdouble) _tmp70_, (gdouble) _tmp71_, _tmp72_, _tmp73_);
+#line 74 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ _tmp74_ = ctx;
+#line 74 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ cairo_fill_preserve (_tmp74_);
+#line 570 "ClockEffect.c"
+ }
+}
+
+
+static void clock_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number) {
+ ClockEffect * self;
+#line 78 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 78 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals));
+#line 78 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion));
+#line 583 "ClockEffect.c"
+}
+
+
+static void clock_effect_real_cancel (SpitTransitionsEffect* base) {
+ ClockEffect * self;
+#line 81 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CLOCK_EFFECT, ClockEffect);
+#line 591 "ClockEffect.c"
+}
+
+
+static void clock_effect_class_init (ClockEffectClass * klass) {
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ clock_effect_parent_class = g_type_class_peek_parent (klass);
+#line 598 "ClockEffect.c"
+}
+
+
+static void clock_effect_spit_transitions_effect_interface_init (SpitTransitionsEffectIface * iface) {
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ clock_effect_spit_transitions_effect_parent_iface = g_type_interface_peek_parent (iface);
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->get_fps = (void (*)(SpitTransitionsEffect*, gint*, gint*)) clock_effect_real_get_fps;
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->start = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*)) clock_effect_real_start;
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->needs_clear_background = (gboolean (*)(SpitTransitionsEffect*)) clock_effect_real_needs_clear_background;
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->paint = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*, cairo_t*, gint, gint, gint)) clock_effect_real_paint;
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->advance = (void (*)(SpitTransitionsEffect*, SpitTransitionsVisuals*, SpitTransitionsMotion*, gint)) clock_effect_real_advance;
+#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/ClockEffect.vala"
+ iface->cancel = (void (*)(SpitTransitionsEffect*)) clock_effect_real_cancel;
+#line 617 "ClockEffect.c"
+}
+
+
+static void clock_effect_instance_init (ClockEffect * self) {
+}
+
+
+GType clock_effect_get_type (void) {
+ static volatile gsize clock_effect_type_id__volatile = 0;
+ if (g_once_init_enter (&clock_effect_type_id__volatile)) {
+ static const GTypeInfo g_define_type_info = { sizeof (ClockEffectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) clock_effect_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (ClockEffect), 0, (GInstanceInitFunc) clock_effect_instance_init, NULL };
+ static const GInterfaceInfo spit_transitions_effect_info = { (GInterfaceInitFunc) clock_effect_spit_transitions_effect_interface_init, (GInterfaceFinalizeFunc) NULL, NULL};
+ GType clock_effect_type_id;
+ clock_effect_type_id = g_type_register_static (G_TYPE_OBJECT, "ClockEffect", &g_define_type_info, 0);
+ g_type_add_interface_static (clock_effect_type_id, SPIT_TRANSITIONS_TYPE_EFFECT, &spit_transitions_effect_info);
+ g_once_init_leave (&clock_effect_type_id__volatile, clock_effect_type_id);
+ }
+ return clock_effect_type_id__volatile;
+}
+
+
+