gml_GL_Program_Cg.h

00001 // gml_CG_CgProgram.h --
00002 //
00003 //    Define the gmlGL_TCgProgram class.
00004 //
00005 //  Copyright (c) 2006 CLIPS-IMAG
00006 //
00007 //  See the file "gml_LicenseTerms.txt" for information on usage and redistribution
00008 //  of this file, and for a DISCLAIMER OF ALL WARRANTIES.
00009 //
00010 
00011 #ifndef __GML_GL_CGPROGRAM__
00012 #define __GML_GL_CGPROGRAM__
00013 
00014 // project includes
00015 #include "gml/base/gml_Types.h"
00016 #include "gml/image/gml_Bitmap.h"
00017 #include "gml/image/gml_Geometry.h"
00018 #include "gml/gl/gml_GL_Base.h"
00019 #include "gml/gl/gml_GL_Texture.h"
00020 #include "gml/gl/gml_GL_Program.h"
00021 
00022 
00023 /**
00024  *  gmlGL_TProgram_Cg --
00025  *
00026  *    Programs stored in texture memory, on a GPU.
00027  *    Warning: all calls will change the current GL context to the super context.
00028  *
00029  */
00030 class gmlGL_TProgram_Cg : public gmlGL_TProgram
00031 {
00032 public:
00033 
00034 
00035   /// Init --
00036 
00037   gml_TError Init ();
00038   
00039 
00040   /// Dispose --
00041 
00042   void Dispose ();
00043 
00044 
00045   /// Compile --
00046 
00047   gml_TError Compile (char* program, int* loglen, char** log);
00048   
00049   
00050   /// Configure --
00051 
00052   gml_TError Configure (char* parameter, int stride, int nbdata, Float32* data);
00053   
00054   
00055   /// Run --
00056 
00057   gml_TError Run (gmlGL_TTexture* output, int nbinput, gmlGL_TTexture** inputs);
00058   
00059 
00060   virtual ~gmlGL_TProgram_Cg () {};
00061 
00062 private:
00063 
00064   void*  fProgram;
00065   
00066   static char* sLogString;
00067 };
00068 
00069 #endif /* __GML_GL_CGPROGRAM__ */
Generated on Tue Jun 12 14:03:27 2007 for gml by Doxygen 1.5.2.