[PD-cvs] externals/grill/flext/source flatom_pr.cpp, 1.23, 1.24 flbase.h, 1.38, 1.39 fllib.cpp, 1.38, 1.39 flproxy.cpp, 1.13, 1.14 flstdc.h, 1.38, 1.39 flthr.cpp, 1.34, 1.35

Thomas Grill xovo at users.sourceforge.net
Tue Jun 20 02:04:14 CEST 2006


Update of /cvsroot/pure-data/externals/grill/flext/source
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv23703/source

Modified Files:
	flatom_pr.cpp flbase.h fllib.cpp flproxy.cpp flstdc.h 
	flthr.cpp 
Log Message:
more robust structure pack setting for Max/MSP @ Windows
fixed bug for Max/MSP when there's no signal inlet
- Max: fixed reported bug (#67), where list elements are distributed over inlets
- preprocessor symbol FLEXT_COMPATIBLE - if defined don't implement specialities of either PD or Max/MSP
cosmetic changes to calm the compiler


Index: flproxy.cpp
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/flproxy.cpp,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -d -r1.13 -r1.14
*** flproxy.cpp	15 May 2006 23:03:52 -0000	1.13
--- flproxy.cpp	20 Jun 2006 00:04:11 -0000	1.14
***************
*** 125,131 ****
  void flext_base::cb_px_ft ## IX(flext_hdr *c,double v) { t_atom atom; SetFloat(atom,v); thisObject(c)->CbMethodHandler(IX,sym_float,1,&atom); }
  
! //void flext_base::cb_px_in ## IX(flext_hdr *c,long v) { t_atom atom; SetInt(atom,v); thisObject(c)->CbMethodHandler(IX,sym_int,1,&atom); } \
! //void flext_base::cb_px_ft ## IX(flext_hdr *c,double v) { t_atom atom; SetFloat(atom,v); thisObject(c)->CbMethodHandler(IX,sym_float,1,&atom); }
! 
  
  #define ADD_PROXYMSG(c,IX) \
--- 125,132 ----
  void flext_base::cb_px_ft ## IX(flext_hdr *c,double v) { t_atom atom; SetFloat(atom,v); thisObject(c)->CbMethodHandler(IX,sym_float,1,&atom); }
  
! /*
! void flext_base::cb_px_in ## IX(flext_hdr *c,long v) { t_atom atom; SetInt(atom,v); thisObject(c)->CbMethodHandler(IX,sym_int,1,&atom); } \
! void flext_base::cb_px_ft ## IX(flext_hdr *c,double v) { t_atom atom; SetFloat(atom,v); thisObject(c)->CbMethodHandler(IX,sym_float,1,&atom); }
! */
  
  #define ADD_PROXYMSG(c,IX) \
***************
*** 133,142 ****
  addftx((method)(cb_px_ft ## IX),IX)
  
! //add_method1(c,cb_px_in ## IX,"in" #IX,A_INT); \
! //add_method1(c,cb_px_ft ## IX,"ft" #IX,A_FLOAT)
! 
! //AddMethod(c,0,flext::MakeSymbol("in" #IX),cb_px_in ## IX); \
! //AddMethod(c,0,flext::MakeSymbol("ft" #IX),cb_px_ft ## IX) 
  
  
  #endif 
--- 134,144 ----
  addftx((method)(cb_px_ft ## IX),IX)
  
! /*
! add_method1(c,cb_px_in ## IX,"in" #IX,A_INT); \
! add_method1(c,cb_px_ft ## IX,"ft" #IX,A_FLOAT)
  
+ AddMethod(c,0,flext::MakeSymbol("in" #IX),cb_px_in ## IX); \
+ AddMethod(c,0,flext::MakeSymbol("ft" #IX),cb_px_ft ## IX) 
+ */
  
  #endif 

Index: flbase.h
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/flbase.h,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -d -r1.38 -r1.39
*** flbase.h	24 May 2006 12:20:57 -0000	1.38
--- flbase.h	20 Jun 2006 00:04:11 -0000	1.39
***************
*** 200,209 ****
      protected:    	
  
-         //! pointer to flext class definition
-         flext_class *clss;
- 
          //! backpointer to object header
          mutable flext_hdr *x_obj;        	
  
  //        static bool	process_attributes;
  
--- 200,209 ----
      protected:    	
  
          //! backpointer to object header
          mutable flext_hdr *x_obj;        	
  
+         //! pointer to flext class definition
+         flext_class *clss;
+ 
  //        static bool	process_attributes;
  

Index: fllib.cpp
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/fllib.cpp,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -d -r1.38 -r1.39
*** fllib.cpp	24 May 2006 12:20:57 -0000	1.38
--- fllib.cpp	20 Jun 2006 00:04:11 -0000	1.39
***************
*** 129,141 ****
  	flext_class(t_class *&cl,flext_obj *(*newf)(int,t_atom *),void (*freef)(flext_hdr *)); 
  	
  	flext_obj *(*newfun)(int,t_atom *);
  	void (*freefun)(flext_hdr *c);
  
- 	t_class *const &clss;
- 	flext_library *lib;
- 	bool dsp,attr,dist;
  	int argc;
  	int *argv;
  
      flext_base::ItemCont meths,attrs;
  };
--- 129,143 ----
  	flext_class(t_class *&cl,flext_obj *(*newf)(int,t_atom *),void (*freef)(flext_hdr *)); 
  	
+ 	t_class *const &clss;
+ 
  	flext_obj *(*newfun)(int,t_atom *);
  	void (*freefun)(flext_hdr *c);
  
  	int argc;
  	int *argv;
  
+ 	flext_library *lib;
+ 	bool dsp,attr,dist;
+ 
      flext_base::ItemCont meths,attrs;
  };

Index: flstdc.h
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/flstdc.h,v
retrieving revision 1.38
retrieving revision 1.39
diff -C2 -d -r1.38 -r1.39
*** flstdc.h	29 May 2006 10:19:27 -0000	1.38
--- flstdc.h	20 Jun 2006 00:04:11 -0000	1.39
***************
*** 252,260 ****
  #ifdef FLEXT_DEBUG
  #ifdef _MSC_VER
! #define FLEXT_ASSERT(b) (!(b)?_CrtDbgReport(_CRT_ASSERT,__FILE__,__LINE__,"flext",#b):1)
  #define FLEXT_WARN(str) _CrtDbgReport(_CRT_WARN,__FILE__,__LINE__,"flext",NULL)
  #define FLEXT_ERROR(str) _CrtDbgReport(_CRT_ERROR,__FILE__,__LINE__,"flext",NULL)
  #else
! #define FLEXT_ASSERT(b) (!(b)?(error("Assertion failed: " #b " - in " __FILE__ " line %i",(int)__LINE__),0):1)
  #define FLEXT_WARN(str) error("Warning: in " __FILE__ " line %i",(int)__LINE__)
  #define FLEXT_ERROR(str) error("Error: in " __FILE__ " line %i",(int)__LINE__)
--- 252,260 ----
  #ifdef FLEXT_DEBUG
  #ifdef _MSC_VER
! #define FLEXT_ASSERT(b) do { if(!(b)) _CrtDbgReport(_CRT_ASSERT,__FILE__,__LINE__,"flext",#b); } while(false)
  #define FLEXT_WARN(str) _CrtDbgReport(_CRT_WARN,__FILE__,__LINE__,"flext",NULL)
  #define FLEXT_ERROR(str) _CrtDbgReport(_CRT_ERROR,__FILE__,__LINE__,"flext",NULL)
  #else
! #define FLEXT_ASSERT(b) do { if(!(b)) error("Assertion failed: " #b " - in " __FILE__ " line %i",(int)__LINE__); } while(false)
  #define FLEXT_WARN(str) error("Warning: in " __FILE__ " line %i",(int)__LINE__)
  #define FLEXT_ERROR(str) error("Error: in " __FILE__ " line %i",(int)__LINE__)

Index: flthr.cpp
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/flthr.cpp,v
retrieving revision 1.34
retrieving revision 1.35
diff -C2 -d -r1.34 -r1.35
*** flthr.cpp	24 May 2006 12:20:57 -0000	1.34
--- flthr.cpp	20 Jun 2006 00:04:11 -0000	1.35
***************
*** 353,357 ****
      // --------------------------
  
-     bool found = false;
      while((ti = thrpending.Pop()) != NULL)
          if(ti->This() == this)
--- 353,356 ----

Index: flatom_pr.cpp
===================================================================
RCS file: /cvsroot/pure-data/externals/grill/flext/source/flatom_pr.cpp,v
retrieving revision 1.23
retrieving revision 1.24
diff -C2 -d -r1.23 -r1.24
*** flatom_pr.cpp	15 May 2006 23:03:52 -0000	1.23
--- flatom_pr.cpp	20 Jun 2006 00:04:11 -0000	1.24
***************
*** 34,49 ****
      }
      else if(IsSymbol(a)) {
!         if(!FLEXT_ASSERT(GetSymbol(a))) 
!             *buf = 0;
!         else {
!             const char *c = GetString(a);
!             size_t len = strlen(c);
!             if(len < bufsz) {
!                 memcpy(buf,c,len); buf[len] = 0;
!                 ok = true;
!             }
!             else 
!                 ok = false;
!         }
      }
  #if FLEXT_SYS == FLEXT_SYS_PD
--- 34,47 ----
      }
      else if(IsSymbol(a)) {
! 		FLEXT_ASSERT(IsSymbol(a));
! 
! 		const char *c = GetString(a);
! 		size_t len = strlen(c);
! 		if(len < bufsz) {
! 			memcpy(buf,c,len); buf[len] = 0;
! 			ok = true;
! 		}
! 		else 
! 			ok = false;
      }
  #if FLEXT_SYS == FLEXT_SYS_PD





More information about the Pd-cvs mailing list