[PATCH 3/3] Implement animated transitions for zoom in/out.

Scott Moreau oreaus at gmail.com
Mon Jun 11 10:59:20 PDT 2012


> > +static void
> > +weston_zoom_frame_z(struct weston_animation *animation,
> > +             struct weston_output *output, uint32_t msecs)
> > +{
> > +     if (animation->frame_counter == 0)
> > +             /* We need to discard the first frame since the
> > +              * animation was started from a binding. In this
> > +              * case, the first timestamp will always be greater
> > +              * than msecs, which will cause an infinite loop
> > +              * in weston_spring_update(). */
> > +             return;
>
> We need to initialize the spring timestamp in the frame_counter == 0
> case here.
>
>
> > +static void
> > +weston_zoom_transition(struct weston_output *output)
> > +{
> > +     if (wl_list_empty(&output->zoom.animation_z.link)) {
> > +             output->zoom.spring_z.target = output->zoom.level;
> > +             output->zoom.spring_z.timestamp =
> weston_compositor_get_time();
>
> ... and not initialize it here (weston_compositor_get_time() is going
> away).
>
>

Right. A new patch is on the way.


Scott
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20120611/4ce3b0fa/attachment.html>


More information about the wayland-devel mailing list