}
void
+change_tape(Actor *actor, AWallpaperPlugin *desktop_plugin)
+{
+ gint x, speed = 8;
+ Actor *a;
+
+ if (!desktop_plugin->priv->rich_animation) return;
+
+ a = g_ptr_array_index(actor->child, 0);
+ x = a->x - speed;
+ if (x < -800)
+ x = 2400;
+ set_actor_position(a, x, a->y, a->z, desktop_plugin);
+ a->x = x;
+
+ a = g_ptr_array_index(actor->child, 1);
+ x = a->x - speed;
+ if (x < -800)
+ x = 2400;
+ set_actor_position(a, x, a->y, a->z, desktop_plugin);
+ a->x = x;
+
+}
+
+void
change_layer(Actor * actor, AWallpaperPlugin *desktop_plugin)
{
gint y, speed1 = 8, speed2 = 16;
void set_actor_scale(Actor *actor, double scalex, double scaley);
void set_actor_visible(Actor *actor, gboolean visible);
void change_obj(Actor * actor, AWallpaperPlugin *desktop_plugin);
+void change_tape(Actor * actor, AWallpaperPlugin *desktop_plugin);
void change_billboard(Actor * actor, AWallpaperPlugin *desktop_plugin);
void change_moon(Actor * actor, AWallpaperPlugin *desktop_plugin);
void change_sun(Actor * actor, AWallpaperPlugin *desktop_plugin);
fprintf(stderr,"init scene accel\n");
Actor *actor;
Scene *scene;
+ GPtrArray *child;
gint now = time(NULL);
scene = g_new0(Scene, 1);
scene->actors = NULL;
desktop_plugin->priv->scene = scene;
+ actor = init_object(desktop_plugin, "background", "bg.png",
+ 0, 0, 5, 800, 480,
+ TRUE, TRUE, 100, 255,
+ NULL, NULL, NULL);
+ scene->actors = g_slist_append(scene->actors, actor);
+
+ child = g_ptr_array_sized_new(2);
+ actor = init_object(desktop_plugin, "tape0", "tape1_0.png",
+ 800, 100, 5, 1600, 227,
+ TRUE, TRUE, 100, 255,
+ NULL, NULL, NULL);
+ scene->actors = g_slist_append(scene->actors, actor);
+ g_ptr_array_add(child, actor);
+
+ actor = init_object(desktop_plugin, "tape1", "tape1_1.png",
+ 2400, 100, 5, 1600, 227,
+ TRUE, TRUE, 100, 255,
+ NULL, NULL, NULL);
+ scene->actors = g_slist_append(scene->actors, actor);
+ g_ptr_array_add(child, actor);
+
+ actor = init_object(desktop_plugin, "tape1", "",
+ 0, 800, 5, 1600, 227,
+ FALSE, FALSE, 100, 255,
+ (gpointer)&change_tape, NULL, child);
+ actor->time_start_animation = now;
+ actor->duration_animation = G_MAXINT;
+ scene->actors = g_slist_append(scene->actors, actor);
+
+ /*
actor = init_object(desktop_plugin, "sky", "sky0.png",
0, 0, 1, 800, 480,
TRUE , TRUE, 100, 255,
actor->time_start_animation = now;
actor->duration_animation = G_MAXINT;
scene->actors = g_slist_append(scene->actors, actor);
-
+ */
run_long_timeout(desktop_plugin);
}