7204N/ARename "quad" argument to avoid clash with "quad" typedef in <sys/types.h> on
7204N/ASolaris. While the C compiler has no problem this, gobject-introspection
7204N/Afreaks out, resulting in errors of:
7204N/A
7204N/Agnome-shell-3.18.3/src/shell-glsl-quad.h:58: syntax error,
7204N/A unexpected typedef-name, expecting ')' or ',' in
7204N/A 'void shell_glsl_quad_add_glsl_snippet (ShellGLSLQuad *quad,' at 'quad'
7204N/A
7204N/Agnome-shell-3.18.3/src/shell-glsl-quad.h:64: syntax error,
7204N/A unexpected typedef-name, expecting ')' or ',' in
7204N/A 'int shell_glsl_quad_get_uniform_location (ShellGLSLQuad *quad,' at 'quad'
7204N/A
7204N/Agnome-shell-3.18.3/src/shell-glsl-quad.h:66: syntax error,
7204N/A unexpected typedef-name, expecting ')' or ',' in
7204N/A 'void shell_glsl_quad_set_uniform_float (ShellGLSLQuad *quad,' at 'quad'
7204N/A
7204N/Aand these functions missing from the generated Shell-0.1.gir file and thus
7204N/Abreaking calls to them from the Javascript files elsewhere in gnome-shell.
7204N/A
7204N/ANeed to consult with upstream on best way to fix there.
7204N/A
7204N/A--- gnome-shell-3.18.3/src/shell-glsl-quad.h 2015-11-17 13:11:17.000000000 -0800
7204N/A+++ gnome-shell-3.18.3/src/shell-glsl-quad.h 2016-10-13 18:25:09.637995723 -0700
7204N/A@@ -55,15 +55,15 @@
7204N/A
7204N/A GType shell_glsl_quad_get_type (void) G_GNUC_CONST;
7204N/A
7204N/A-void shell_glsl_quad_add_glsl_snippet (ShellGLSLQuad *quad,
7204N/A+void shell_glsl_quad_add_glsl_snippet (ShellGLSLQuad *gquad,
7204N/A ShellSnippetHook hook,
7204N/A const char *declarations,
7204N/A const char *code,
7204N/A gboolean is_replace);
7204N/A
7204N/A-int shell_glsl_quad_get_uniform_location (ShellGLSLQuad *quad,
7204N/A+int shell_glsl_quad_get_uniform_location (ShellGLSLQuad *gquad,
7204N/A const char *name);
7204N/A-void shell_glsl_quad_set_uniform_float (ShellGLSLQuad *quad,
7204N/A+void shell_glsl_quad_set_uniform_float (ShellGLSLQuad *gquad,
7204N/A int uniform,
7204N/A int n_components,
7204N/A int total_count,
7204N/A--- gnome-shell-3.18.3/src/shell-glsl-quad.c 2015-11-17 13:11:17.000000000 -0800
7204N/A+++ gnome-shell-3.18.3/src/shell-glsl-quad.c 2016-10-13 18:31:55.812183369 -0700
7204N/A@@ -57,7 +57,7 @@
7204N/A
7204N/A /**
7204N/A * shell_glsl_quad_add_glsl_snippet:
7204N/A- * @quad: a #ShellGLSLQuad
7204N/A+ * @gquad: a #ShellGLSLQuad
7204N/A * @hook: where to insert the code
7204N/A * @declarations: GLSL declarations
7204N/A * @code: GLSL code
7204N/A@@ -70,13 +70,13 @@
7204N/A * function.
7204N/A */
7204N/A void
7204N/A-shell_glsl_quad_add_glsl_snippet (ShellGLSLQuad *quad,
7204N/A+shell_glsl_quad_add_glsl_snippet (ShellGLSLQuad *gquad,
7204N/A ShellSnippetHook hook,
7204N/A const char *declarations,
7204N/A const char *code,
7204N/A gboolean is_replace)
7204N/A {
7204N/A- ShellGLSLQuadClass *klass = SHELL_GLSL_QUAD_GET_CLASS (quad);
7204N/A+ ShellGLSLQuadClass *klass = SHELL_GLSL_QUAD_GET_CLASS (gquad);
7204N/A CoglSnippet *snippet;
7204N/A
7204N/A g_return_if_fail (klass->base_pipeline != NULL);
7204N/A@@ -167,7 +167,7 @@
7204N/A
7204N/A /**
7204N/A * shell_glsl_quad_get_uniform_location:
7204N/A- * @quad: a #ShellGLSLQuad
7204N/A+ * @gquad: a #ShellGLSLQuad
7204N/A * @name: the uniform name
7204N/A *
7204N/A * Returns: the location of the uniform named @name, that can be
7204N/A@@ -174,15 +174,15 @@
7204N/A * passed to shell_glsl_quad_set_uniform_float().
7204N/A */
7204N/A int
7204N/A-shell_glsl_quad_get_uniform_location (ShellGLSLQuad *quad,
7204N/A+shell_glsl_quad_get_uniform_location (ShellGLSLQuad *gquad,
7204N/A const char *name)
7204N/A {
7204N/A- return cogl_pipeline_get_uniform_location (quad->priv->pipeline, name);
7204N/A+ return cogl_pipeline_get_uniform_location (gquad->priv->pipeline, name);
7204N/A }
7204N/A
7204N/A /**
7204N/A * shell_glsl_quad_set_uniform_float:
7204N/A- * @quad: a #ShellGLSLQuad
7204N/A+ * @gquad: a #ShellGLSLQuad
7204N/A * @uniform: the uniform location (as returned by shell_glsl_quad_get_uniform_location())
7204N/A * @n_components: the number of components in the uniform (eg. 3 for a vec3)
7204N/A * @total_count: the total number of floats in @value
7204N/A@@ -189,13 +189,13 @@
7204N/A * @value: (array length=total_count): the array of floats to set @uniform
7204N/A */
7204N/A void
7204N/A-shell_glsl_quad_set_uniform_float (ShellGLSLQuad *quad,
7204N/A+shell_glsl_quad_set_uniform_float (ShellGLSLQuad *gquad,
7204N/A int uniform,
7204N/A int n_components,
7204N/A int total_count,
7204N/A const float *value)
7204N/A {
7204N/A- cogl_pipeline_set_uniform_float (quad->priv->pipeline, uniform,
7204N/A+ cogl_pipeline_set_uniform_float (gquad->priv->pipeline, uniform,
7204N/A n_components, total_count / n_components,
7204N/A value);
7204N/A }