gallium: add set_tess_state to configure default tessellation parameters
authorIlia Mirkin <imirkin@alum.mit.edu>
Sun, 20 Jul 2014 15:36:49 +0000 (11:36 -0400)
committerMarek Olšák <marek.olsak@amd.com>
Sat, 16 May 2015 12:51:22 +0000 (14:51 +0200)
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
Signed-off-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/docs/source/context.rst
src/gallium/include/pipe/p_context.h

index 5861f46b30dabe3b7aedb7d5514cc92c7bc972f4..0908ee7e0583f1d958fe0b55e172fb53250686d9 100644 (file)
@@ -79,6 +79,11 @@ objects. They all follow simple, one-method binding calls, e.g.
   should be the same as the number of set viewports and can be up to
   PIPE_MAX_VIEWPORTS.
 * ``set_viewport_states``
+* ``set_tess_state`` configures the default tessellation parameters:
+  * ``default_outer_level`` is the default value for the outer tessellation
+    levels. This corresponds to GL's ``PATCH_DEFAULT_OUTER_LEVEL``.
+  * ``default_inner_level`` is the default value for the inner tessellation
+    levels. This corresponds to GL's ``PATCH_DEFAULT_INNER_LEVEL``.
 
 
 Sampler Views
index 67deb046e29554bf526bc35f0f13e0b825a8dffa..c25bfa638c1c358f9deec441f1f2a6a9c9f9d343 100644 (file)
@@ -231,6 +231,10 @@ struct pipe_context {
                              unsigned start_slot, unsigned num_views,
                              struct pipe_sampler_view **);
 
+   void (*set_tess_state)(struct pipe_context *,
+                          float default_outer_level[4],
+                          float default_inner_level[2]);
+
    /**
     * Bind an array of shader resources that will be used by the
     * graphics pipeline.  Any resources that were previously bound to