Remove remaining pipe format utility functions.
[mesa.git] / src / gallium / include / pipe / p_context.h
index 57e966ac3b04b42043da066b9125c3be2922edab..f896001eb12091d3d7035eb908731e42ca4258ab 100644 (file)
@@ -98,7 +98,7 @@ struct pipe_context {
     */
    /*@{*/
    struct pipe_query *(*create_query)( struct pipe_context *pipe,
-                                              unsigned query_type );
+                                       unsigned query_type );
 
    void (*destroy_query)(struct pipe_context *pipe,
                          struct pipe_query *q);
@@ -123,7 +123,12 @@ struct pipe_context {
 
    void * (*create_sampler_state)(struct pipe_context *,
                                   const struct pipe_sampler_state *);
-   void   (*bind_sampler_states)(struct pipe_context *, unsigned num, void **);
+   void   (*bind_fragment_sampler_states)(struct pipe_context *,
+                                          unsigned num_samplers,
+                                          void **samplers);
+   void   (*bind_vertex_sampler_states)(struct pipe_context *,
+                                        unsigned num_samplers,
+                                        void **samplers);
    void   (*delete_sampler_state)(struct pipe_context *, void *);
 
    void * (*create_rasterizer_state)(struct pipe_context *,
@@ -173,9 +178,13 @@ struct pipe_context {
    void (*set_viewport_state)( struct pipe_context *,
                                const struct pipe_viewport_state * );
 
-   void (*set_sampler_textures)( struct pipe_context *,
-                                 unsigned num_textures,
-                                 struct pipe_texture ** );
+   void (*set_fragment_sampler_textures)(struct pipe_context *,
+                                         unsigned num_textures,
+                                         struct pipe_texture **);
+
+   void (*set_vertex_sampler_textures)(struct pipe_context *,
+                                       unsigned num_textures,
+                                       struct pipe_texture **);
 
    void (*set_vertex_buffers)( struct pipe_context *,
                                unsigned num_buffers,
@@ -189,6 +198,9 @@ struct pipe_context {
 
    /**
     * Surface functions
+    *
+    * The pipe driver is allowed to set these functions to NULL, and in that
+    * case, they will not be available.
     */
    /*@{*/
 
@@ -215,10 +227,12 @@ struct pipe_context {
 
    /**
     * Clear the specified set of currently bound buffers to specified values.
+    * The entire buffers are cleared (no scissor, no colormask, etc).
     *
-    * buffers is a bitfield of PIPE_CLEAR_* values.
-    *
-    * rgba is a pointer to an array of one float for each of r, g, b, a.
+    * \param buffers  bitfield of PIPE_CLEAR_* values.
+    * \param rgba  pointer to an array of one float for each of r, g, b, a.
+    * \param depth  depth clear value in [0,1].
+    * \param stencil  stencil clear value
     */
    void (*clear)(struct pipe_context *pipe,
                  unsigned buffers,
@@ -226,7 +240,9 @@ struct pipe_context {
                  double depth,
                 unsigned stencil);
 
-   /** Flush rendering (flags = bitmask of PIPE_FLUSH_x tokens) */
+   /** Flush rendering
+    * \param flags  bitmask of PIPE_FLUSH_x tokens)
+    */
    void (*flush)( struct pipe_context *pipe,
                   unsigned flags,
                   struct pipe_fence_handle **fence );
@@ -242,10 +258,10 @@ struct pipe_context {
     * \param texture  texture to check.
     * \param face  cubemap face. Use 0 for non-cubemap texture.
     */
-
    unsigned int (*is_texture_referenced) (struct pipe_context *pipe,
                                          struct pipe_texture *texture,
                                          unsigned face, unsigned level);
+
    /**
     * Check whether a buffer is referenced by an unflushed hw command.
     * The state-tracker uses this function to optimize away unnecessary
@@ -255,7 +271,6 @@ struct pipe_context {
     *              checked.
     * \param buf  Buffer to check.
     */
-
    unsigned int (*is_buffer_referenced) (struct pipe_context *pipe,
                                         struct pipe_buffer *buf);
 };