mirror of
https://gitlab.freedesktop.org/wayland/wayland.git
synced 2025-11-02 09:01:39 -05:00
Clear depth buffer, but only depth buffer for gears.
This commit is contained in:
parent
8a9cda8cfb
commit
b8bf19b7a9
2 changed files with 3 additions and 0 deletions
2
gears.c
2
gears.c
|
|
@ -174,6 +174,8 @@ gears_draw(struct gears *gears, GLfloat angle)
|
||||||
{
|
{
|
||||||
GLfloat view_rotx = 20.0, view_roty = 30.0, view_rotz = 0.0;
|
GLfloat view_rotx = 20.0, view_roty = 30.0, view_rotz = 0.0;
|
||||||
|
|
||||||
|
glClear(GL_DEPTH_BUFFER_BIT);
|
||||||
|
|
||||||
glPushMatrix();
|
glPushMatrix();
|
||||||
|
|
||||||
glTranslatef(0.0, 0.0, -50);
|
glTranslatef(0.0, 0.0, -50);
|
||||||
|
|
|
||||||
1
window.c
1
window.c
|
|
@ -154,6 +154,7 @@ draw_window(struct window *window)
|
||||||
window->config, window->name,
|
window->config, window->name,
|
||||||
window->width, window->height,
|
window->width, window->height,
|
||||||
window->stride, NULL);
|
window->stride, NULL);
|
||||||
|
|
||||||
if (surface == NULL)
|
if (surface == NULL)
|
||||||
die("failed to create surface\n");
|
die("failed to create surface\n");
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue