|
|
@ -47,6 +47,8 @@ |
|
|
|
|
|
|
|
|
|
|
|
#define MIN(x,y) (((x) < (y)) ? (x) : (y)) |
|
|
|
#define MIN(x,y) (((x) < (y)) ? (x) : (y)) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
static int option_blit; |
|
|
|
|
|
|
|
|
|
|
|
struct nested { |
|
|
|
struct nested { |
|
|
|
struct display *display; |
|
|
|
struct display *display; |
|
|
|
struct window *window; |
|
|
|
struct window *window; |
|
|
@ -142,6 +144,10 @@ struct nested_renderer { |
|
|
|
struct nested_buffer *buffer); |
|
|
|
struct nested_buffer *buffer); |
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
static const struct weston_option nested_options[] = { |
|
|
|
|
|
|
|
{ WESTON_OPTION_BOOLEAN, "blit", 'b', &option_blit }, |
|
|
|
|
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
static const struct nested_renderer nested_blit_renderer; |
|
|
|
static const struct nested_renderer nested_blit_renderer; |
|
|
|
static const struct nested_renderer nested_ss_renderer; |
|
|
|
static const struct nested_renderer nested_ss_renderer; |
|
|
|
|
|
|
|
|
|
|
@ -773,6 +779,9 @@ nested_init_compositor(struct nested *nested) |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if (option_blit) |
|
|
|
|
|
|
|
use_ss_renderer = 0; |
|
|
|
|
|
|
|
|
|
|
|
if (use_ss_renderer) { |
|
|
|
if (use_ss_renderer) { |
|
|
|
printf("Using subsurfaces to render client surfaces\n"); |
|
|
|
printf("Using subsurfaces to render client surfaces\n"); |
|
|
|
nested->renderer = &nested_ss_renderer; |
|
|
|
nested->renderer = &nested_ss_renderer; |
|
|
@ -1099,6 +1108,9 @@ main(int argc, char *argv[]) |
|
|
|
struct display *display; |
|
|
|
struct display *display; |
|
|
|
struct nested *nested; |
|
|
|
struct nested *nested; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
parse_options(nested_options, |
|
|
|
|
|
|
|
ARRAY_LENGTH(nested_options), &argc, argv); |
|
|
|
|
|
|
|
|
|
|
|
display = display_create(&argc, argv); |
|
|
|
display = display_create(&argc, argv); |
|
|
|
if (display == NULL) { |
|
|
|
if (display == NULL) { |
|
|
|
fprintf(stderr, "failed to create display: %m\n"); |
|
|
|
fprintf(stderr, "failed to create display: %m\n"); |
|
|
|