[Piglit] [PATCH 16/17] fbo-depth-sample-compare: Eliminate dependency on gluSphere

Matt Turner mattst88 at gmail.com
Tue Sep 22 09:52:35 PDT 2015


On Tue, Sep 22, 2015 at 8:36 AM, Ian Romanick <idr at freedesktop.org> wrote:
> From: Ian Romanick <ian.d.romanick at intel.com>
>
> Signed-off-by: Ian Romanick <ian.d.romanick at intel.com>
> ---
>  tests/fbo/CMakeLists.gl.txt          |   1 -
>  tests/fbo/fbo-depth-sample-compare.c | 141 +++++++++++++++++++++++++++++++----
>  2 files changed, 125 insertions(+), 17 deletions(-)
>
> diff --git a/tests/fbo/CMakeLists.gl.txt b/tests/fbo/CMakeLists.gl.txt
> index d5c8778..0476b10 100644
> --- a/tests/fbo/CMakeLists.gl.txt
> +++ b/tests/fbo/CMakeLists.gl.txt
> @@ -8,7 +8,6 @@ include_directories(
>  link_libraries (
>         piglitutil_${piglit_target_api}
>         ${OPENGL_gl_LIBRARY}
> -       ${OPENGL_glu_LIBRARY}
>  )
>
>  piglit_add_executable (fbo-1d fbo-1d.c)
> diff --git a/tests/fbo/fbo-depth-sample-compare.c b/tests/fbo/fbo-depth-sample-compare.c
> index 7d78913..6de07d8 100644
> --- a/tests/fbo/fbo-depth-sample-compare.c
> +++ b/tests/fbo/fbo-depth-sample-compare.c
> @@ -1,5 +1,6 @@
>  /*
>   * Copyright (c) 2011 VMware, Inc.
> + * Copyright © 2015 Intel Corporation
>   *
>   * Permission is hereby granted, free of charge, to any person obtaining a
>   * copy of this software and associated documentation files (the "Software"),
> @@ -39,13 +40,6 @@
>  #include <assert.h>
>  #include "piglit-util-gl.h"
>
> -#if defined(__APPLE__)
> -#  include <OpenGL/glu.h>
> -#else
> -#  include <GL/glu.h>
> -#endif
> -
> -
>  /** Set DEBUG to 1 to enable extra output when trying to debug failures */
>  #define DEBUG 0
>
> @@ -66,7 +60,6 @@ static GLuint ColorTex, DepthTex, FBO;
>  static GLuint ShaderProg;
>  static GLint Zbits;
>  static GLenum TexTarget = GL_TEXTURE_2D;
> -static GLUquadricObj *sphereObj = NULL;
>
>
>  static void
> @@ -237,13 +230,131 @@ find_uint_min_max_center(const GLuint *buf, GLuint n,
>  static void
>  draw_sphere(void)
>  {
> -   GLdouble radius = 0.95;
> -   GLint slices = 40;
> -   GLint stacks = 20;
> +   /* Without this enum hack, GCC complains about variable length arrays
> +    * below... even if you make the varaibles const.

typo: variables


More information about the Piglit mailing list