wl_list_for_each_reverse(surface, &compositor->base.surface_list, link)
weston_surface_draw(surface, &output->base, damage);
- wl_signal_emit(&output->frame_signal, &output->frame_time);
+ wl_signal_emit(&output->base.frame_signal, output);
ret = eglSwapBuffers(compositor->base.egl_display, output->egl_surface);
if (ret == EGL_FALSE && !errored) {
wl_list_for_each_reverse(surface, &compositor->base.surface_list, link)
weston_surface_draw(surface, &output->base, damage);
- wl_signal_emit(&output->frame_signal, &output->frame_time);
+ wl_signal_emit(&output->base.frame_signal, output);
eglSwapBuffers(compositor->base.egl_display, output->egl_surface);
bo = gbm_surface_lock_front_buffer(output->surface);
wl_list_for_each_reverse(surface, &compositor->base.surface_list, link)
weston_surface_draw(surface, &output->base, damage);
- wl_signal_emit(&output->frame_signal, &output->frame_time);
+ wl_signal_emit(&output->base.frame_signal, output);
eglSwapBuffers(compositor->base.egl_display, output->egl_surface);
struct wl_listener listener;
struct wl_buffer *buffer;
struct wl_resource *resource;
- struct weston_output *output;
};
static void
struct screenshooter_frame_listener *l =
container_of(listener,
struct screenshooter_frame_listener, listener);
- struct weston_output *output = l->output;
+ struct weston_output *output = data;
int32_t stride;
uint8_t *pixels, *d, *s;
l->buffer = buffer;
l->resource = resource;
- l->output = output;
l->listener.notify = screenshooter_frame_notify;
wl_signal_add(&output->frame_signal, &l->listener);
}
struct weston_recorder {
- struct weston_output *output;
uint32_t *frame, *rect;
uint32_t total;
int fd;
{
struct weston_recorder *recorder =
container_of(listener, struct weston_recorder, frame_listener);
- struct weston_output *output = recorder->output;
- uint32_t msecs = * (uint32_t *) data;
+ struct weston_output *output = data;
+ uint32_t msecs = output->frame_time;
pixman_box32_t *r;
pixman_region32_t damage;
int i, j, k, n, width, height, run, stride;
struct iovec v[2];
pixman_region32_init(&damage);
- pixman_region32_intersect(&damage, &recorder->output->region,
- &recorder->output->previous_damage);
+ pixman_region32_intersect(&damage, &output->region,
+ &output->previous_damage);
r = pixman_region32_rectangles(&damage, &n);
if (n == 0)
struct { uint32_t magic, format, width, height; } header;
recorder = malloc(sizeof *recorder);
- recorder->output = output;
stride = output->current->width;
size = stride * 4 * output->current->height;