gallium: rename st_fragment_program's fs field to cso to match st_vertex_program
authorBrian <brian.paul@tungstengraphics.com>
Tue, 12 Feb 2008 23:10:11 +0000 (16:10 -0700)
committerBen Skeggs <skeggsb@gmail.com>
Fri, 15 Feb 2008 02:51:11 +0000 (13:51 +1100)
src/mesa/state_tracker/st_atom_shader.c
src/mesa/state_tracker/st_cb_clear.c
src/mesa/state_tracker/st_cb_drawpixels.c
src/mesa/state_tracker/st_cb_program.c
src/mesa/state_tracker/st_gen_mipmap.c
src/mesa/state_tracker/st_program.c
src/mesa/state_tracker/st_program.h

index 919691850938a553b9623a187f9ffa35c1bb345d..2c6ec8421b06203e5d2fbd178fa834475740b518 100644 (file)
@@ -158,7 +158,7 @@ find_translated_vp(struct st_context *st,
    /*
     * Translate fragment program if needed.
     */
-   if (!stfp->fs) {
+   if (!stfp->cso) {
       GLuint inAttr, numIn = 0;
 
       for (inAttr = 0; inAttr < FRAG_ATTRIB_MAX; inAttr++) {
@@ -179,7 +179,7 @@ find_translated_vp(struct st_context *st,
                                            stfp->input_to_slot,
                                            stfp->tokens,
                                            ST_MAX_SHADER_TOKENS);
-      assert(stfp->fs);
+      assert(stfp->cso);
    }
 
 
@@ -227,7 +227,7 @@ find_translated_vp(struct st_context *st,
             if (fpInAttrib >= 0) {
                GLuint fpInSlot = stfp->input_to_slot[fpInAttrib];
                if (fpInSlot != ~0) {
-                  GLuint vpOutSlot = stfp->fs->state.input_map[fpInSlot];
+                  GLuint vpOutSlot = stfp->cso->state.input_map[fpInSlot];
                   xvp->output_to_slot[outAttr] = vpOutSlot;
                   numVpOuts++;
                }
@@ -300,7 +300,7 @@ update_linkage( struct st_context *st )
    st->pipe->bind_vs_state(st->pipe, st->state.vs->cso->data);
 
    st->fp = stfp;
-   st->state.fs = stfp->fs;
+   st->state.fs = stfp->cso;
    st->pipe->bind_fs_state(st->pipe, st->state.fs->data);
 
    st->vertex_result_to_slot = xvp->output_to_slot;
index ab98b54bab48eba4ee7111aa989fce26354b994d..410062e1e8084395038c93b6528a4ab7f273a88a 100644 (file)
@@ -341,7 +341,7 @@ clear_with_quad(GLcontext *ctx,
       if (!stfp) {
          stfp = make_frag_shader(st);
       }
-      pipe->bind_fs_state(pipe, stfp->fs->data);
+      pipe->bind_fs_state(pipe, stfp->cso->data);
    }
 
    /* vertex shader state: color/position pass-through */
index 475e23653e8b460daacb8fb0b5613bf5c5b85605..3245a7488bce783af505bf050d237507d4593fc4 100644 (file)
@@ -665,7 +665,7 @@ draw_textured_quad(GLcontext *ctx, GLint x, GLint y, GLfloat z,
    }
 
    /* fragment shader state: TEX lookup program */
-   pipe->bind_fs_state(pipe, stfp->fs->data);
+   pipe->bind_fs_state(pipe, stfp->cso->data);
 
    /* vertex shader state: position + texcoord pass-through */
    pipe->bind_vs_state(pipe, stvp->cso->data);
index f1f33fb0dd8e2b3c7b8b1ddf47c51ecfc14af49f..af3ee655048b77edb8792d6b2e66babfa7f25fa5 100644 (file)
@@ -168,10 +168,10 @@ static void st_program_string_notify( GLcontext *ctx,
 
       stfp->serialNo++;
 
-      if (stfp->fs) {
+      if (stfp->cso) {
          /* free the TGSI code */
          // cso_delete(stfp->vs);
-         stfp->fs = NULL;
+         stfp->cso = NULL;
       }
 
       stfp->param_state = stfp->Base.Base.Parameters->StateFlags;
index b4a21fd7e27f7ec0ffbb76daf48c945f916f6df9..459941cca871180b7f6b276dd75a4ede9e1e8488 100644 (file)
@@ -253,7 +253,7 @@ st_render_mipmap(struct st_context *st,
    pipe->bind_rasterizer_state(pipe, st->gen_mipmap.rasterizer_cso);
 
    /* bind shaders */
-   pipe->bind_fs_state(pipe, st->gen_mipmap.stfp->fs->data);
+   pipe->bind_fs_state(pipe, st->gen_mipmap.stfp->cso->data);
    pipe->bind_vs_state(pipe, st->gen_mipmap.stvp->cso->data);
 
    /*
index 84a90940018fcdac915a10f75037235c5579b8b3..c8297badedd16455ce82cef471d95fe23d0c67f0 100644 (file)
@@ -420,7 +420,7 @@ st_translate_fragment_program(struct st_context *st,
    fs.tokens = tokensOut;
 
    cso = st_cached_fs_state(st, &fs);
-   stfp->fs = cso;
+   stfp->cso = cso;
 
    if (0)
       _mesa_print_program(&stfp->Base.Base);
index de02c3185fddd4a8c4ca35a97f172cd6df6c0b72..ea1dde4a7a3c530c6de8865f9e50374afce0c76a 100644 (file)
@@ -62,7 +62,7 @@ struct st_fragment_program
    struct tgsi_token tokens[ST_MAX_SHADER_TOKENS];
 
    /** Pointer to the corresponding cached shader */
-   const struct cso_fragment_shader *fs;
+   const struct cso_fragment_shader *cso;
 
    GLuint param_state;