mirror of
https://github.com/brl/mutter.git
synced 2024-12-26 04:42:14 +00:00
hello: Make sure to clear background explicitly
This test wasn't actually explicitly clearing the background to black it was simply a fluke that some drivers clear the background when allocating a new framebuffer. Reviewed-by: Neil Roberts <neil@linux.intel.com>
This commit is contained in:
parent
6d79657f76
commit
db7f087953
@ -2,6 +2,8 @@
|
||||
#include <glib.h>
|
||||
#include <stdio.h>
|
||||
|
||||
CoglColor black;
|
||||
|
||||
int
|
||||
main (int argc, char **argv)
|
||||
{
|
||||
@ -38,6 +40,7 @@ main (int argc, char **argv)
|
||||
triangle = cogl_primitive_new_p2c4 (COGL_VERTICES_MODE_TRIANGLES,
|
||||
3, triangle_vertices);
|
||||
for (;;) {
|
||||
cogl_clear (&black, COGL_BUFFER_BIT_COLOR);
|
||||
cogl_primitive_draw (triangle);
|
||||
cogl_framebuffer_swap_buffers (fb);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user