summaryrefslogtreecommitdiff
path: root/plugins/shotwell-transitions/CircleEffect.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins/shotwell-transitions/CircleEffect.c')
-rw-r--r--plugins/shotwell-transitions/CircleEffect.c367
1 files changed, 187 insertions, 180 deletions
diff --git a/plugins/shotwell-transitions/CircleEffect.c b/plugins/shotwell-transitions/CircleEffect.c
index 97680cb..cb2b660 100644
--- a/plugins/shotwell-transitions/CircleEffect.c
+++ b/plugins/shotwell-transitions/CircleEffect.c
@@ -1,4 +1,4 @@
-/* CircleEffect.c generated by valac 0.36.6, the Vala compiler
+/* CircleEffect.c generated by valac 0.40.4, the Vala compiler
* generated from CircleEffect.vala, do not modify */
/* Copyright 2013 Jens Bav
@@ -8,6 +8,7 @@
* (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>
@@ -42,6 +43,11 @@ typedef struct _ShotwellTransitionDescriptorPrivate ShotwellTransitionDescriptor
typedef struct _CircleEffectDescriptor CircleEffectDescriptor;
typedef struct _CircleEffectDescriptorClass CircleEffectDescriptorClass;
typedef struct _CircleEffectDescriptorPrivate CircleEffectDescriptorPrivate;
+enum {
+ CIRCLE_EFFECT_DESCRIPTOR_0_PROPERTY,
+ CIRCLE_EFFECT_DESCRIPTOR_NUM_PROPERTIES
+};
+static GParamSpec* circle_effect_descriptor_properties[CIRCLE_EFFECT_DESCRIPTOR_NUM_PROPERTIES];
#define TYPE_CIRCLE_EFFECT (circle_effect_get_type ())
#define CIRCLE_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_CIRCLE_EFFECT, CircleEffect))
@@ -53,6 +59,11 @@ typedef struct _CircleEffectDescriptorPrivate CircleEffectDescriptorPrivate;
typedef struct _CircleEffect CircleEffect;
typedef struct _CircleEffectClass CircleEffectClass;
typedef struct _CircleEffectPrivate CircleEffectPrivate;
+enum {
+ CIRCLE_EFFECT_0_PROPERTY,
+ CIRCLE_EFFECT_NUM_PROPERTIES
+};
+static GParamSpec* circle_effect_properties[CIRCLE_EFFECT_NUM_PROPERTIES];
struct _ShotwellTransitionDescriptor {
GObject parent_instance;
@@ -91,54 +102,68 @@ static SpitTransitionsEffectIface * circle_effect_spit_transitions_effect_parent
GType shotwell_transition_descriptor_get_type (void) G_GNUC_CONST;
GType circle_effect_descriptor_get_type (void) G_GNUC_CONST;
-enum {
- CIRCLE_EFFECT_DESCRIPTOR_DUMMY_PROPERTY
-};
CircleEffectDescriptor* circle_effect_descriptor_new (GFile* resource_directory);
-CircleEffectDescriptor* circle_effect_descriptor_construct (GType object_type, GFile* resource_directory);
-ShotwellTransitionDescriptor* shotwell_transition_descriptor_construct (GType object_type, GFile* resource_directory);
+CircleEffectDescriptor* circle_effect_descriptor_construct (GType object_type,
+ GFile* resource_directory);
+ShotwellTransitionDescriptor* shotwell_transition_descriptor_construct (GType object_type,
+ GFile* resource_directory);
static const gchar* circle_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base);
static const gchar* circle_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base);
-static SpitTransitionsEffect* circle_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host);
+static SpitTransitionsEffect* circle_effect_descriptor_real_create (ShotwellTransitionDescriptor* base,
+ SpitHostInterface* host);
CircleEffect* circle_effect_new (void);
CircleEffect* circle_effect_construct (GType object_type);
GType circle_effect_get_type (void) G_GNUC_CONST;
-enum {
- CIRCLE_EFFECT_DUMMY_PROPERTY
-};
#define CIRCLE_EFFECT_DESIRED_FPS 25
#define CIRCLE_EFFECT_MIN_FPS 15
-static void circle_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps);
-static void circle_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion);
+static void circle_effect_real_get_fps (SpitTransitionsEffect* base,
+ gint* desired_fps,
+ gint* min_fps);
+static void circle_effect_real_start (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion);
static gboolean circle_effect_real_needs_clear_background (SpitTransitionsEffect* base);
-static void circle_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number);
-static void circle_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number);
+static void circle_effect_real_paint (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion,
+ cairo_t* ctx,
+ gint width,
+ gint height,
+ gint frame_number);
+static void circle_effect_real_advance (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion,
+ gint frame_number);
static void circle_effect_real_cancel (SpitTransitionsEffect* base);
-CircleEffectDescriptor* circle_effect_descriptor_construct (GType object_type, GFile* resource_directory) {
+CircleEffectDescriptor*
+circle_effect_descriptor_construct (GType object_type,
+ GFile* resource_directory)
+{
CircleEffectDescriptor * self = NULL;
- GFile* _tmp0_;
#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
g_return_val_if_fail (G_IS_FILE (resource_directory), NULL);
#line 12 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp0_ = resource_directory;
-#line 12 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- self = (CircleEffectDescriptor*) shotwell_transition_descriptor_construct (object_type, _tmp0_);
+ self = (CircleEffectDescriptor*) shotwell_transition_descriptor_construct (object_type, resource_directory);
#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return self;
-#line 131 "CircleEffect.c"
+#line 152 "CircleEffect.c"
}
-CircleEffectDescriptor* circle_effect_descriptor_new (GFile* resource_directory) {
+CircleEffectDescriptor*
+circle_effect_descriptor_new (GFile* resource_directory)
+{
#line 11 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return circle_effect_descriptor_construct (TYPE_CIRCLE_EFFECT_DESCRIPTOR, resource_directory);
-#line 138 "CircleEffect.c"
+#line 161 "CircleEffect.c"
}
-static const gchar* circle_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base) {
+static const gchar*
+circle_effect_descriptor_real_get_id (ShotwellTransitionDescriptor* base)
+{
CircleEffectDescriptor * self;
const gchar* result = NULL;
#line 15 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -147,11 +172,13 @@ static const gchar* circle_effect_descriptor_real_get_id (ShotwellTransitionDesc
result = "org.yorba.shotwell.transitions.circle";
#line 16 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return result;
-#line 151 "CircleEffect.c"
+#line 176 "CircleEffect.c"
}
-static const gchar* circle_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base) {
+static const gchar*
+circle_effect_descriptor_real_get_pluggable_name (ShotwellTransitionDescriptor* base)
+{
CircleEffectDescriptor * self;
const gchar* result = NULL;
#line 19 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -160,11 +187,14 @@ static const gchar* circle_effect_descriptor_real_get_pluggable_name (ShotwellTr
result = _ ("Circle");
#line 20 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return result;
-#line 164 "CircleEffect.c"
+#line 191 "CircleEffect.c"
}
-static SpitTransitionsEffect* circle_effect_descriptor_real_create (ShotwellTransitionDescriptor* base, SpitHostInterface* host) {
+static SpitTransitionsEffect*
+circle_effect_descriptor_real_create (ShotwellTransitionDescriptor* base,
+ SpitHostInterface* host)
+{
CircleEffectDescriptor * self;
SpitTransitionsEffect* result = NULL;
CircleEffect* _tmp0_;
@@ -178,11 +208,13 @@ static SpitTransitionsEffect* circle_effect_descriptor_real_create (ShotwellTran
result = G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, SPIT_TRANSITIONS_TYPE_EFFECT, SpitTransitionsEffect);
#line 24 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return result;
-#line 182 "CircleEffect.c"
+#line 212 "CircleEffect.c"
}
-static void circle_effect_descriptor_class_init (CircleEffectDescriptorClass * klass) {
+static void
+circle_effect_descriptor_class_init (CircleEffectDescriptorClass * klass)
+{
#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
circle_effect_descriptor_parent_class = g_type_class_peek_parent (klass);
#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -191,15 +223,19 @@ static void circle_effect_descriptor_class_init (CircleEffectDescriptorClass * k
((ShotwellTransitionDescriptorClass *) klass)->get_pluggable_name = (const gchar* (*) (ShotwellTransitionDescriptor *)) circle_effect_descriptor_real_get_pluggable_name;
#line 10 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
((ShotwellTransitionDescriptorClass *) klass)->create = (SpitTransitionsEffect* (*) (ShotwellTransitionDescriptor *, SpitHostInterface*)) circle_effect_descriptor_real_create;
-#line 195 "CircleEffect.c"
+#line 227 "CircleEffect.c"
}
-static void circle_effect_descriptor_instance_init (CircleEffectDescriptor * self) {
+static void
+circle_effect_descriptor_instance_init (CircleEffectDescriptor * self)
+{
}
-GType circle_effect_descriptor_get_type (void) {
+GType
+circle_effect_descriptor_get_type (void)
+{
static volatile gsize circle_effect_descriptor_type_id__volatile = 0;
if (g_once_init_enter (&circle_effect_descriptor_type_id__volatile)) {
static const GTypeInfo g_define_type_info = { sizeof (CircleEffectDescriptorClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) circle_effect_descriptor_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (CircleEffectDescriptor), 0, (GInstanceInitFunc) circle_effect_descriptor_instance_init, NULL };
@@ -211,24 +247,32 @@ GType circle_effect_descriptor_get_type (void) {
}
-CircleEffect* circle_effect_construct (GType object_type) {
+CircleEffect*
+circle_effect_construct (GType object_type)
+{
CircleEffect * self = NULL;
#line 32 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
self = (CircleEffect*) g_object_new (object_type, NULL);
#line 32 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return self;
-#line 221 "CircleEffect.c"
+#line 259 "CircleEffect.c"
}
-CircleEffect* circle_effect_new (void) {
+CircleEffect*
+circle_effect_new (void)
+{
#line 32 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return circle_effect_construct (TYPE_CIRCLE_EFFECT);
-#line 228 "CircleEffect.c"
+#line 268 "CircleEffect.c"
}
-static void circle_effect_real_get_fps (SpitTransitionsEffect* base, gint* desired_fps, gint* min_fps) {
+static void
+circle_effect_real_get_fps (SpitTransitionsEffect* base,
+ gint* desired_fps,
+ gint* min_fps)
+{
CircleEffect * self;
gint _vala_desired_fps = 0;
gint _vala_min_fps = 0;
@@ -242,18 +286,22 @@ static void circle_effect_real_get_fps (SpitTransitionsEffect* base, gint* desir
if (desired_fps) {
#line 35 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
*desired_fps = _vala_desired_fps;
-#line 246 "CircleEffect.c"
+#line 290 "CircleEffect.c"
}
#line 35 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
if (min_fps) {
#line 35 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
*min_fps = _vala_min_fps;
-#line 252 "CircleEffect.c"
+#line 296 "CircleEffect.c"
}
}
-static void circle_effect_real_start (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion) {
+static void
+circle_effect_real_start (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion)
+{
CircleEffect * self;
#line 40 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLE_EFFECT, CircleEffect);
@@ -261,11 +309,13 @@ static void circle_effect_real_start (SpitTransitionsEffect* base, SpitTransitio
g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals));
#line 40 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion));
-#line 265 "CircleEffect.c"
+#line 313 "CircleEffect.c"
}
-static gboolean circle_effect_real_needs_clear_background (SpitTransitionsEffect* base) {
+static gboolean
+circle_effect_real_needs_clear_background (SpitTransitionsEffect* base)
+{
CircleEffect * self;
gboolean result = FALSE;
#line 43 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -274,27 +324,27 @@ static gboolean circle_effect_real_needs_clear_background (SpitTransitionsEffect
result = TRUE;
#line 44 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
return result;
-#line 278 "CircleEffect.c"
+#line 328 "CircleEffect.c"
}
-static void circle_effect_real_paint (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, cairo_t* ctx, gint width, gint height, gint frame_number) {
+static void
+circle_effect_real_paint (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion,
+ cairo_t* ctx,
+ gint width,
+ gint height,
+ gint frame_number)
+{
CircleEffect * self;
gdouble alpha = 0.0;
- SpitTransitionsMotion* _tmp0_;
- gint _tmp1_;
- gdouble _tmp2_;
gint radius = 0;
- gdouble _tmp3_;
- gint _tmp4_;
- gint _tmp5_;
- gdouble _tmp6_;
- SpitTransitionsVisuals* _tmp7_;
- GdkPixbuf* _tmp8_;
- GdkPixbuf* _tmp9_;
- SpitTransitionsVisuals* _tmp24_;
- GdkPixbuf* _tmp25_;
- GdkPixbuf* _tmp26_;
+ gdouble _tmp0_;
+ GdkPixbuf* _tmp1_;
+ GdkPixbuf* _tmp2_;
+ GdkPixbuf* _tmp12_;
+ GdkPixbuf* _tmp13_;
#line 47 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLE_EFFECT, CircleEffect);
#line 47 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -304,157 +354,104 @@ static void circle_effect_real_paint (SpitTransitionsEffect* base, SpitTransitio
#line 47 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
g_return_if_fail (ctx != NULL);
#line 49 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp0_ = motion;
-#line 49 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp1_ = frame_number;
-#line 49 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp2_ = spit_transitions_motion_get_alpha (_tmp0_, _tmp1_);
-#line 49 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- alpha = _tmp2_;
-#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp3_ = alpha;
-#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp4_ = width;
-#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp5_ = height;
+ alpha = spit_transitions_motion_get_alpha (motion, frame_number);
#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp6_ = fmax ((gdouble) _tmp4_, (gdouble) _tmp5_);
+ _tmp0_ = alpha;
#line 50 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- radius = (gint) (_tmp3_ * _tmp6_);
+ radius = (gint) (_tmp0_ * fmax ((gdouble) width, (gdouble) height));
#line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp7_ = visuals;
+ _tmp1_ = spit_transitions_visuals_get_from_pixbuf (visuals);
#line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp8_ = spit_transitions_visuals_get_from_pixbuf (_tmp7_);
+ _tmp2_ = _tmp1_;
#line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp9_ = _tmp8_;
-#line 52 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- if (_tmp9_ != NULL) {
-#line 333 "CircleEffect.c"
- cairo_t* _tmp10_;
- SpitTransitionsVisuals* _tmp11_;
- GdkPixbuf* _tmp12_;
- GdkPixbuf* _tmp13_;
- SpitTransitionsVisuals* _tmp14_;
- GdkRectangle _tmp15_ = {0};
- GdkRectangle _tmp16_;
- gint _tmp17_;
- SpitTransitionsVisuals* _tmp18_;
- GdkRectangle _tmp19_ = {0};
- GdkRectangle _tmp20_;
- gint _tmp21_;
- cairo_t* _tmp22_;
- gdouble _tmp23_;
-#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp10_ = ctx;
+ if (_tmp2_ != NULL) {
+#line 369 "CircleEffect.c"
+ GdkPixbuf* _tmp3_;
+ GdkPixbuf* _tmp4_;
+ GdkRectangle _tmp5_ = {0};
+ GdkRectangle _tmp6_;
+ gint _tmp7_;
+ GdkRectangle _tmp8_ = {0};
+ GdkRectangle _tmp9_;
+ gint _tmp10_;
+ gdouble _tmp11_;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp11_ = visuals;
+ _tmp3_ = spit_transitions_visuals_get_from_pixbuf (visuals);
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp12_ = spit_transitions_visuals_get_from_pixbuf (_tmp11_);
+ _tmp4_ = _tmp3_;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp13_ = _tmp12_;
+ spit_transitions_visuals_get_from_pos (visuals, &_tmp5_);
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp14_ = visuals;
+ _tmp6_ = _tmp5_;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- spit_transitions_visuals_get_from_pos (_tmp14_, &_tmp15_);
+ _tmp7_ = _tmp6_.x;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp16_ = _tmp15_;
+ spit_transitions_visuals_get_from_pos (visuals, &_tmp8_);
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp17_ = _tmp16_.x;
+ _tmp9_ = _tmp8_;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp18_ = visuals;
+ _tmp10_ = _tmp9_.y;
#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- spit_transitions_visuals_get_from_pos (_tmp18_, &_tmp19_);
-#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp20_ = _tmp19_;
-#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp21_ = _tmp20_.y;
-#line 53 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- gdk_cairo_set_source_pixbuf (_tmp10_, _tmp13_, (gdouble) _tmp17_, (gdouble) _tmp21_);
-#line 55 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp22_ = ctx;
+ gdk_cairo_set_source_pixbuf (ctx, _tmp4_, (gdouble) _tmp7_, (gdouble) _tmp10_);
#line 55 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp23_ = alpha;
+ _tmp11_ = alpha;
#line 55 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- cairo_paint_with_alpha (_tmp22_, 1 - _tmp23_);
-#line 380 "CircleEffect.c"
+ cairo_paint_with_alpha (ctx, 1 - _tmp11_);
+#line 401 "CircleEffect.c"
}
#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp24_ = visuals;
+ _tmp12_ = spit_transitions_visuals_get_to_pixbuf (visuals);
#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp25_ = spit_transitions_visuals_get_to_pixbuf (_tmp24_);
+ _tmp13_ = _tmp12_;
#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp26_ = _tmp25_;
-#line 58 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- if (_tmp26_ != NULL) {
-#line 390 "CircleEffect.c"
- cairo_t* _tmp27_;
- SpitTransitionsVisuals* _tmp28_;
- GdkPixbuf* _tmp29_;
- GdkPixbuf* _tmp30_;
- SpitTransitionsVisuals* _tmp31_;
- GdkRectangle _tmp32_ = {0};
- GdkRectangle _tmp33_;
- gint _tmp34_;
- SpitTransitionsVisuals* _tmp35_;
- GdkRectangle _tmp36_ = {0};
- GdkRectangle _tmp37_;
- gint _tmp38_;
- cairo_t* _tmp39_;
- gint _tmp40_;
- gint _tmp41_;
- gint _tmp42_;
- cairo_t* _tmp43_;
- cairo_t* _tmp44_;
-#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp27_ = ctx;
-#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp28_ = visuals;
-#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp29_ = spit_transitions_visuals_get_to_pixbuf (_tmp28_);
-#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp30_ = _tmp29_;
+ if (_tmp13_ != NULL) {
+#line 409 "CircleEffect.c"
+ GdkPixbuf* _tmp14_;
+ GdkPixbuf* _tmp15_;
+ GdkRectangle _tmp16_ = {0};
+ GdkRectangle _tmp17_;
+ gint _tmp18_;
+ GdkRectangle _tmp19_ = {0};
+ GdkRectangle _tmp20_;
+ gint _tmp21_;
+ gint _tmp22_;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp31_ = visuals;
+ _tmp14_ = spit_transitions_visuals_get_to_pixbuf (visuals);
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- spit_transitions_visuals_get_to_pos (_tmp31_, &_tmp32_);
+ _tmp15_ = _tmp14_;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp33_ = _tmp32_;
+ spit_transitions_visuals_get_to_pos (visuals, &_tmp16_);
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp34_ = _tmp33_.x;
+ _tmp17_ = _tmp16_;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp35_ = visuals;
+ _tmp18_ = _tmp17_.x;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- spit_transitions_visuals_get_to_pos (_tmp35_, &_tmp36_);
+ spit_transitions_visuals_get_to_pos (visuals, &_tmp19_);
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp37_ = _tmp36_;
+ _tmp20_ = _tmp19_;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp38_ = _tmp37_.y;
+ _tmp21_ = _tmp20_.y;
#line 59 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- gdk_cairo_set_source_pixbuf (_tmp27_, _tmp30_, (gdouble) _tmp34_, (gdouble) _tmp38_);
+ gdk_cairo_set_source_pixbuf (ctx, _tmp15_, (gdouble) _tmp18_, (gdouble) _tmp21_);
#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp39_ = ctx;
+ _tmp22_ = radius;
#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp40_ = width;
-#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp41_ = height;
-#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp42_ = radius;
-#line 60 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- cairo_arc (_tmp39_, (gdouble) (((gint) _tmp40_) / 2), (gdouble) (((gint) _tmp41_) / 2), (gdouble) _tmp42_, (gdouble) 0, 2 * G_PI);
+ cairo_arc (ctx, (gdouble) (((gint) width) / 2), (gdouble) (((gint) height) / 2), (gdouble) _tmp22_, (gdouble) 0, 2 * G_PI);
#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp43_ = ctx;
-#line 61 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- cairo_clip (_tmp43_);
-#line 62 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- _tmp44_ = ctx;
+ cairo_clip (ctx);
#line 62 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
- cairo_paint (_tmp44_);
-#line 453 "CircleEffect.c"
+ cairo_paint (ctx);
+#line 445 "CircleEffect.c"
}
}
-static void circle_effect_real_advance (SpitTransitionsEffect* base, SpitTransitionsVisuals* visuals, SpitTransitionsMotion* motion, gint frame_number) {
+static void
+circle_effect_real_advance (SpitTransitionsEffect* base,
+ SpitTransitionsVisuals* visuals,
+ SpitTransitionsMotion* motion,
+ gint frame_number)
+{
CircleEffect * self;
#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLE_EFFECT, CircleEffect);
@@ -462,26 +459,32 @@ static void circle_effect_real_advance (SpitTransitionsEffect* base, SpitTransit
g_return_if_fail (SPIT_TRANSITIONS_IS_VISUALS (visuals));
#line 66 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
g_return_if_fail (SPIT_TRANSITIONS_IS_MOTION (motion));
-#line 466 "CircleEffect.c"
+#line 463 "CircleEffect.c"
}
-static void circle_effect_real_cancel (SpitTransitionsEffect* base) {
+static void
+circle_effect_real_cancel (SpitTransitionsEffect* base)
+{
CircleEffect * self;
#line 69 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_CIRCLE_EFFECT, CircleEffect);
-#line 474 "CircleEffect.c"
+#line 473 "CircleEffect.c"
}
-static void circle_effect_class_init (CircleEffectClass * klass) {
+static void
+circle_effect_class_init (CircleEffectClass * klass)
+{
#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
circle_effect_parent_class = g_type_class_peek_parent (klass);
-#line 481 "CircleEffect.c"
+#line 482 "CircleEffect.c"
}
-static void circle_effect_spit_transitions_effect_interface_init (SpitTransitionsEffectIface * iface) {
+static void
+circle_effect_spit_transitions_effect_interface_init (SpitTransitionsEffectIface * iface)
+{
#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
circle_effect_spit_transitions_effect_parent_iface = g_type_interface_peek_parent (iface);
#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
@@ -496,15 +499,19 @@ static void circle_effect_spit_transitions_effect_interface_init (SpitTransition
iface->advance = (void (*) (SpitTransitionsEffect *, SpitTransitionsVisuals*, SpitTransitionsMotion*, gint)) circle_effect_real_advance;
#line 28 "/home/jens/Source/shotwell/plugins/shotwell-transitions/CircleEffect.vala"
iface->cancel = (void (*) (SpitTransitionsEffect *)) circle_effect_real_cancel;
-#line 500 "CircleEffect.c"
+#line 503 "CircleEffect.c"
}
-static void circle_effect_instance_init (CircleEffect * self) {
+static void
+circle_effect_instance_init (CircleEffect * self)
+{
}
-GType circle_effect_get_type (void) {
+GType
+circle_effect_get_type (void)
+{
static volatile gsize circle_effect_type_id__volatile = 0;
if (g_once_init_enter (&circle_effect_type_id__volatile)) {
static const GTypeInfo g_define_type_info = { sizeof (CircleEffectClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) circle_effect_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (CircleEffect), 0, (GInstanceInitFunc) circle_effect_instance_init, NULL };