[Mesa-dev] [RFC PATCH 03/56] mesa/main: Add tessellation shader structs

Matt Turner mattst88 at gmail.com
Sat Sep 20 19:42:53 PDT 2014


On Sat, Sep 20, 2014 at 6:40 PM, Chris Forbes <chrisf at ijw.co.nz> wrote:
> From: Fabian Bieler <fabianbieler at fastmail.fm>
>
> ---
>  src/mesa/main/mtypes.h | 121 +++++++++++++++++++++++++++++++++++++++++++++++++
>  1 file changed, 121 insertions(+)
>
> diff --git a/src/mesa/main/mtypes.h b/src/mesa/main/mtypes.h
> index 59e6eeb..7a8f5f3 100644
> --- a/src/mesa/main/mtypes.h
> +++ b/src/mesa/main/mtypes.h
> @@ -2274,6 +2274,30 @@ struct gl_vertex_program
>  };
>
>
> +/** Tessellation control program object */
> +struct gl_tess_ctrl_program
> +{
> +   struct gl_program Base;   /**< base class */
> +
> +   /* output layout */
> +   GLint VerticesOut;
> +};
> +
> +
> +/** Tessellation evaluation program object */
> +struct gl_tess_eval_program
> +{
> +   struct gl_program Base;   /**< base class */
> +
> +   /* input layout */
> +   GLenum PrimitiveMode; /* GL_TRIANGLES, GL_QUADS or GL_ISOLINES */
> +   GLenum Spacing;       /* GL_EQUAL, GL_FRACTIONAL_EVEN or
> +                            GL_FRACTIONAL_ODD */
> +   GLenum VertexOrder;   /* GL_CW or GL_CCW */
> +   GLboolean PointMode;
> +};
> +
> +
>  /** Geometry program object */
>  struct gl_geometry_program
>  {
> @@ -2376,6 +2400,39 @@ struct gl_vertex_program_state
>     GLboolean _Overriden;
>  };
>
> +/**
> + * Context state for tessellation control programs.
> + */
> +struct gl_tess_ctrl_program_state
> +{
> +   GLboolean Enabled;               /**< GL_ARB_TESSELLATION_SHADER */
> +   GLboolean _Enabled;              /**< Enabled and valid program? */
> +   struct gl_tess_ctrl_program *Current;  /**< user-bound tessellation control program */
> +
> +   /** Currently enabled and valid program (including internal programs

Start the comment on the next line.

> +    * and compiled shader programs).
> +    */
> +   struct gl_tess_ctrl_program *_Current;
> +
> +   GLint patch_vertices;
> +   GLfloat patch_default_outer_level[4];
> +   GLfloat patch_default_inner_level[2];
> +};
> +
> +/**
> + * Context state for tessellation evaluation programs.
> + */
> +struct gl_tess_eval_program_state
> +{
> +   GLboolean Enabled;               /**< GL_ARB_TESSELLATION_SHADER */
> +   GLboolean _Enabled;              /**< Enabled and valid program? */
> +   struct gl_tess_eval_program *Current;  /**< user-bound tessellation control program */
> +
> +   /** Currently enabled and valid program (including internal programs

Start the comment on the next line.

> +    * and compiled shader programs).
> +    */
> +   struct gl_tess_eval_program *_Current;
> +};
>
>  /**
>   * Context state for geometry programs.


More information about the mesa-dev mailing list