#endif
#include "driverfuncs.h"
+#include "tnl/tnl.h"
#include "swrast/swrast.h"
driver->NeedFlush = 0;
driver->SaveNeedFlush = 0;
+ driver->ProgramStringNotify = _tnl_program_string;
driver->FlushVertices = NULL;
driver->SaveFlushVertices = NULL;
driver->NotifySaveBegin = NULL;
#include "t_pipeline.h"
#include "t_vb_arbprogram.h"
+
#define DISASSEM 0
/*--------------------------------------------------------------------------- */
validate_vertex_program, /* validate */
run_arb_vertex_program /* run */
};
+
+
+/**
+ * Called via ctx->Driver.ProgramStringNotify() after a new vertex program
+ * string has been parsed.
+ */
+void
+_tnl_program_string(GLcontext *ctx, GLenum target, struct program *program)
+{
+ if (target == GL_VERTEX_PROGRAM_ARB) {
+ /* free any existing tnl data hanging off the program */
+ struct vertex_program *vprog = (struct vertex_program *) program;
+ if (vprog->TnlData) {
+ free_tnl_data(vprog);
+ }
+ }
+}
extern void
_tnl_allow_pixel_fog( GLcontext *ctx, GLboolean value );
+extern void
+_tnl_program_string(GLcontext *ctx, GLenum target, struct program *program);
#endif