[Cogl] [PATCH] Fixup for setting point size

Robert Bragg robert at sixbynine.org
Fri Jun 21 04:49:26 PDT 2013


Yup, looks good to me.

regards,
- Robert

On Thu, Jun 20, 2013 at 6:35 PM, Neil Roberts <neil at linux.intel.com> wrote:
> I messed up the comparison in the previous patch so that it would
> still try to call glPointSize even if the pipeline has a zero point
> size. This was causing GL errors but the conformance tests didn't pick
> it up because apparently we haven't been setting
> G_DEBUG=fatal-warnings since glib changed a year and a half ago! I'd
> like to squash in this change to the patch.
>
> ---
>  cogl/driver/gl/cogl-pipeline-vertend-fixed.c | 2 +-
>  cogl/driver/gl/cogl-pipeline-vertend-glsl.c  | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/cogl/driver/gl/cogl-pipeline-vertend-fixed.c b/cogl/driver/gl/cogl-pipeline-vertend-fixed.c
> index d6fa784..e84b816 100644
> --- a/cogl/driver/gl/cogl-pipeline-vertend-fixed.c
> +++ b/cogl/driver/gl/cogl-pipeline-vertend-fixed.c
> @@ -71,7 +71,7 @@ _cogl_pipeline_vertend_fixed_end (CoglPipeline *pipeline,
>        CoglPipeline *authority =
>          _cogl_pipeline_get_authority (pipeline, COGL_PIPELINE_STATE_POINT_SIZE);
>
> -      if (authority->big_state->point_size >= 0.0f)
> +      if (authority->big_state->point_size > 0.0f)
>          GE( ctx, glPointSize (authority->big_state->point_size) );
>      }
>
> diff --git a/cogl/driver/gl/cogl-pipeline-vertend-glsl.c b/cogl/driver/gl/cogl-pipeline-vertend-glsl.c
> index 035ad4a..5dd7aee 100644
> --- a/cogl/driver/gl/cogl-pipeline-vertend-glsl.c
> +++ b/cogl/driver/gl/cogl-pipeline-vertend-glsl.c
> @@ -517,7 +517,7 @@ _cogl_pipeline_vertend_glsl_end (CoglPipeline *pipeline,
>        CoglPipeline *authority =
>          _cogl_pipeline_get_authority (pipeline, COGL_PIPELINE_STATE_POINT_SIZE);
>
> -      if (authority->big_state->point_size >= 0.0f)
> +      if (authority->big_state->point_size > 0.0f)
>          GE( ctx, glPointSize (authority->big_state->point_size) );
>      }
>  #endif /* HAVE_COGL_GL */
> --
> 1.7.11.3.g3c3efa5
>
> _______________________________________________
> Cogl mailing list
> Cogl at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/cogl


More information about the Cogl mailing list