예제 #1
0
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	jit_submatrix_init();	
	setup(&max_jit_submatrix_class, max_jit_submatrix_new, (method)max_jit_submatrix_free, (short)sizeof(t_max_jit_submatrix), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_submatrix,obex));
	q = jit_class_findbyname(gensym("jit_submatrix"));    
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_ALL & ~MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX); 		
    max_jit_classex_mop_mproc(p,q,max_jit_submatrix_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0); 	//getattributes/dumpout/maxjitclassaddmethods/etc
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  //standard mop assist fn
}
예제 #2
0
int TTCLASSWRAPPERMAX_EXPORT main(void)
{
	void *p, *q;
	
	TTFoundationInit();
	StencilClassInit();	
	setup((t_messlist**)&sMaxStencilClass, (method)MaxStencilNew, (method)MaxStencilFree, sizeof(MaxStencilObject), 0, A_GIMME, 0);
	
	p = max_jit_classex_setup(calcoffset(MaxStencilObject, obex));
	q = jit_class_findbyname(gensym("j_stencil"));    
    max_jit_classex_mop_wrap(p, q, 0);							// attrs & methods for name, type, dim, planecount, bang, outputmatrix, etc
    max_jit_classex_standard_wrap(p, q, 0);						// attrs & methods for getattributes, dumpout, maxjitclassaddmethods, etc
    addmess((method)max_jit_mop_assist, (char*)"assist", A_CANT, 0);	// standard matrix-operator (mop) assist fn
	return 0;
}
예제 #3
0
int main(void){	
	void *p,*q;
	
	jit_SDIF_buffer_init();	
	setup((t_messlist **)&max_jit_SDIF_buffer_class, (method)max_jit_SDIF_buffer_new, (method)max_jit_SDIF_buffer_free, (short)sizeof(t_max_jit_SDIF_buffer), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_SDIF_buffer,obex));
	q = jit_class_findbyname(gensym("jit_SDIF_buffer"));    
	max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX|MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX); 		
	max_jit_classex_standard_wrap(p,q,0); 	
	max_addmethod_usurp_low((method)max_jit_SDIF_buffer_outputmatrix, "outputmatrix");	
	addmess((method)max_jit_mop_assist, "assist", A_CANT,0);
	addfloat((method)max_jit_SDIF_buffer_float);
	return 0;
}
예제 #4
0
void ext_main(void* unused)
{	
	void *p,*q;
	
	union { void **v_ptr; t_messlist **m_ptr; } alias_ptr;
	alias_ptr.v_ptr = &max_cv_jit_trackpoints_class;
	cv_jit_trackpoints_init();
	setup(alias_ptr.m_ptr, (method)max_cv_jit_trackpoints_new, (method)max_cv_jit_trackpoints_free, (short)sizeof(t_max_cv_jit_trackpoints), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_cv_jit_trackpoints,obex));
	q = jit_class_findbyname(gensym("cv_jit_trackpoints"));    
    max_jit_classex_mop_wrap(p,q,0); 		//name/type/dim/planecount/bang/outputmatrix/etc
    max_jit_classex_standard_wrap(p,q,0); 	//getattributes/dumpout/maxjitclassaddmethods/etc
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  //standard mop assist fn
}
예제 #5
0
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	setup(&max_jit_la_diagproduct_class, max_jit_la_diagproduct_new, (method)max_jit_la_diagproduct_free, (short)sizeof(t_max_jit_la_diagproduct), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_la_diagproduct,obex));
	q = jit_class_findbyname(gensym("jit_la_diagproduct"));    
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_BANG|MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX); //custom bang/outputmatrix 		
    max_jit_classex_mop_mproc(p,q,max_jit_la_diagproduct_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0); 	
 	addmess((method)max_jit_la_diagproduct_assist,			"assist",			A_CANT,0);

	ps_getresult	= gensym("getresult");
}
예제 #6
0
void
main(void)
	
	{
	const long kAttrFlags = MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX
								| MAX_JIT_MOP_FLAGS_OWN_BANG;
	
	voidPtr	p,									// Have to guess about what these two do
			q;									// Not much is documented in the Jitter SDK
	
	LITTER_CHECKTIMEOUT(kClassName);
	
	PenizeJitInit();
	
	// Standard Max setup() call
	setup(	&gPenizeMaxClass,					// Pointer to our class definition
			(method) PenizeNewMaxShell,			// Instance creation function
			(method) PenizeFreeMaxShell,		// Custom deallocation function
			(short) sizeof(msobPenize),			// Class object size
			NIL,								// No menu function
			A_GIMME,							// Jitter objects always parse their own
			0);									// arguments
	
	// Jitter Magic... 
	p	= max_jit_classex_setup(
					calcoffset(msobPenize, jitObEx)
					);
	q	= jit_class_findbyname(
					gensym((char*) kMaxClassName)
					);    
    max_jit_classex_mop_wrap(p, q, kAttrFlags); 		
    max_jit_classex_mop_mproc(p, q, PenizeMaxMProc);	// Custom MProc
    max_jit_classex_standard_wrap(p, q, 0); 	
	
	// Add messages...
	LITTER_TIMEBOMB addbang	((method) PenizeBang);
	addmess	((method) PenizeTattle,	"dblclick",	A_CANT, 0);
	addmess	((method) PenizeTattle,	"tattle",	A_NOTHING);
	addmess	((method) PenizeAssist,	"assist",	A_CANT, 0);
	addmess	((method) PenizeInfo,	"info",		A_CANT, 0);
	
	// Define global symbols
	gSymGetDiffs	= gensym("getdiffs");
	
	// Initialize Litter Library
	LitterInit(kMaxClassName, 0);
	}
void ext_main(void *r)
{
	void *classex, *jitclass;

	jit_gl_videoplane_init();
	setup((t_messlist **)&max_jit_gl_videoplane_class, (method)max_jit_gl_videoplane_new, (method)max_jit_gl_videoplane_free, (short)sizeof(t_max_jit_gl_videoplane),
		  0L, A_GIMME, 0);

	classex = max_jit_classex_setup(calcoffset(t_max_jit_gl_videoplane, obex));
	jitclass = jit_class_findbyname(gensym("jit_gl_videoplane"));
	max_jit_classex_standard_wrap(classex, jitclass, 0); 				// getattributes/dumpout/maxjitclassaddmethods/etc
	addmess((method)max_jit_ob3d_assist, "assist", A_CANT,0);

	// add methods for 3d drawing
	max_ob3d_setup();

}
예제 #8
0
void main(void)
{	
	void *p,*q;
	
	jit_str_op_init();	
	setup(&max_jit_str_op_class, max_jit_str_op_new, (method)max_jit_str_op_free, (short)sizeof(t_max_jit_str_op), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_str_op,obex));
	q = jit_class_findbyname(gensym("jit_str_op"));    
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX);
    max_jit_classex_mop_mproc(p,q,max_jit_str_op_mproc);
    max_jit_classex_standard_wrap(p,q,0); 	

	addmess((method)max_jit_str_op_jit_matrix, "jit_matrix", A_GIMME,0);	
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  
}
예제 #9
0
int main(void)
{	
	void *p,*q;
	
	union { void **v_ptr; t_messlist **m_ptr; } alias_ptr;
	alias_ptr.v_ptr = &max_cv_jit_hough_class;
	cv_jit_hough_init();
	setup(alias_ptr.m_ptr, (method)max_cv_jit_hough_new, (method)max_cv_jit_hough_free, (short)sizeof(t_max_cv_jit_hough), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_cv_jit_hough,obex));
	q = jit_class_findbyname(gensym("cv_jit_hough"));    
    max_jit_classex_mop_wrap(p,q,0); 		
    max_jit_classex_standard_wrap(p,q,0); 	
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  
	
	return 0;
}
예제 #10
0
void main(void)
{	
	void *p,*q;
	
	jit_findbounds_init();
	setup(&max_jit_findbounds_class, max_jit_findbounds_new, (method)max_jit_findbounds_free, (short)sizeof(t_max_jit_findbounds), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_findbounds,obex));
	q = jit_class_findbyname(gensym("jit_findbounds"));    
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_BANG|MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX); //custom bang/outputmatrix 		
    max_jit_classex_mop_mproc(p,q,max_jit_findbounds_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0); 	
 	addmess((method)max_jit_findbounds_assist,			"assist",			A_CANT,0);

	ps_getboundmin	= gensym("getboundmin");
	ps_getboundmax	= gensym("getboundmax");
}
예제 #11
0
void ext_main(void *r)
{
	long attrflags;
	void *p,*attr;

	setup((t_messlist **)&max_jit_peek_class, (method)max_jit_peek_new, (method)max_jit_peek_free, (short)sizeof(t_max_jit_peek),
		  0L, A_GIMME, 0);

	addmess((method)max_jit_peek_dsp, "dsp", A_CANT, 0);
	addmess((method)max_jit_peek_dsp64, "dsp64", A_CANT, 0);
	dsp_initclass();

	p = max_jit_classex_setup(calcoffset(t_max_jit_peek,obex));

	attrflags = JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW ;
	attr = jit_object_new(_jit_sym_jit_attr_offset,"matrix_name",_jit_sym_symbol,attrflags,
						  (method)0L,(method)max_jit_peek_matrix_name,calcoffset(t_max_jit_peek,matrix_name));
	max_jit_classex_addattr(p,attr);
	object_addattr_parse(attr,"label",_jit_sym_symbol,0,"\"Matrix Name\"");
	
	attr = jit_object_new(_jit_sym_jit_attr_offset,"plane",_jit_sym_long,attrflags,
						  (method)0L,(method)0L,calcoffset(t_max_jit_peek,plane));
	max_jit_classex_addattr(p,attr);
	object_addattr_parse(attr,"label",_jit_sym_symbol,0,"Plane");
	
	attr = jit_object_new(_jit_sym_jit_attr_offset,"interp",_jit_sym_long,attrflags,
						  (method)0L,(method)0L,calcoffset(t_max_jit_peek,interp));
	max_jit_classex_addattr(p,attr);
	object_addattr_parse(attr,"label",_jit_sym_symbol,0,"Interp");
	
	attr = jit_object_new(_jit_sym_jit_attr_offset,"normalize",_jit_sym_long,attrflags,
						  (method)0L,(method)0L,calcoffset(t_max_jit_peek,normalize));
	max_jit_classex_addattr(p,attr);
	object_addattr_parse(attr,"label",_jit_sym_symbol,0,"Normalize");

	// because it is not safe to call jitter methods inside the perform routine,
	// we need notify message to find out when our matrix data is changing
	addmess((method)max_jit_peek_notify, "notify", A_CANT,0);

	max_jit_classex_standard_wrap(p,NULL,0);
	addmess((method)max_jit_peek_assist, "assist", A_CANT,0);
	return 0;
}
예제 #12
0
void ext_main(void *r)
{
	void *p, *q;

	jit_scissors_init();
	setup(&max_jit_scissors_class, max_jit_scissors_new, (method)max_jit_scissors_free, (short)sizeof(t_max_jit_scissors),
		  0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_scissors, obex));
	q = jit_class_findbyname(gensym("jit_scissors"));
	max_jit_classex_mop_wrap(p, q, MAX_JIT_MOP_FLAGS_OWN_BANG|MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX); //no bang/outputmatrix...doesn't make sense for this object
	max_jit_classex_standard_wrap(p, q, 0);
	addmess((method)max_jit_scissors_assist, "assist", A_CANT, 0);
	addmess((method)max_jit_mop_variable_anything, "anything", A_GIMME, 0);

	ps_rows 	= gensym("rows");
	ps_columns	= gensym("columns");

}
예제 #13
0
void main(void)
{	
	void *classex, *jitclass;
	
	// standard Max stuff
	jit_gl_cube_init();	
	setup((t_messlist **)&max_jit_gl_cube_class, (method)max_jit_gl_cube_new, (method)max_jit_gl_cube_free, (short)sizeof(t_max_jit_gl_cube), 
		0L, A_GIMME, 0);
	classex = max_jit_classex_setup(calcoffset(t_max_jit_gl_cube, obex));
	jitclass = jit_class_findbyname(gensym("jit_gl_cube"));	
	
	// add getattributes/dumpout/maxjitclassaddmethods/etc to class extension.
    max_jit_classex_standard_wrap(classex, jitclass, 0); 	
    			   
   	// use standard ob3d assist method.
    addmess((method)max_jit_ob3d_assist, "assist", A_CANT,0);  

	// add methods for 3d drawing
    max_ob3d_setup();
}
예제 #14
0
파일: max.jit.3m.c 프로젝트: CICM/max6-sdk
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	jit_3m_init();	
	setup((t_messlist **)&max_jit_3m_class, (method)max_jit_3m_new, (method)max_jit_3m_free, (short)sizeof(t_max_jit_3m), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_3m,obex));
	q = jit_class_findbyname(gensym("jit_3m"));    
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_BANG|MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX); //custom bang/outputmatrix 		
    max_jit_classex_mop_mproc(p,q,max_jit_3m_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0); 	
 	addmess((method)max_jit_3m_assist,			"assist",			A_CANT,0);
 	addbang((method)max_jit_3m_bang);

	ps_getmin	= gensym("getmin");
	ps_getmean	= gensym("getmean");
	ps_getmax	= gensym("getmax");
}
예제 #15
0
void main(void)
{	
	long attrflags;
	void *p,*attr;
	
	setup(&max_jit_turtle_class, max_jit_turtle_new, (method)max_jit_turtle_free, (short)sizeof(t_max_jit_turtle), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_turtle,obex));
	
 	attrflags = JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW ;

	// origin -- where to start drawing from (or reset to with a 'reset' message)
	attr = jit_object_new(_jit_sym_jit_attr_offset_array,"origin",_jit_sym_long,2,attrflags,
		(method)0,(method)0,calcoffset(t_max_jit_turtle,origincount),calcoffset(t_max_jit_turtle,origin));
	max_jit_classex_addattr(p,attr);

	// angle -- angle factor for turning the turtle
	attr = jit_object_new(_jit_sym_jit_attr_offset,"angle",_jit_sym_long,attrflags,
		(method)0,(method)0,calcoffset(t_max_jit_turtle,angle));
	max_jit_classex_addattr(p,attr);

	// scale -- stepsize for moving the turtle
	attr = jit_object_new(_jit_sym_jit_attr_offset,"scale",_jit_sym_long,attrflags,
		(method)0,(method)0,calcoffset(t_max_jit_turtle,scale));
	max_jit_classex_addattr(p,attr);

	// clearmode -- send a clear on reset or not
	attr = jit_object_new(_jit_sym_jit_attr_offset,"clearmode",_jit_sym_long,attrflags,
		(method)0,(method)0,calcoffset(t_max_jit_turtle,clearmode));
	max_jit_classex_addattr(p,attr);
	
	addmess((method)max_jit_turtle_reset,			"reset",			A_GIMME,0);
	
	max_jit_classex_standard_wrap(p,NULL,0);	
	addmess((method)max_jit_turtle_assist,			"assist",			A_CANT,0);
// 	addbang((method)max_jit_turtle_bang);
	addint((method)max_jit_turtle_int);
	
    max_jit_class_addmethods(jit_class_findbyname(gensym("jit_turtle")));	
}
예제 #16
0
void main(void)
{	
	void *p,*q;
	
	jit_notify_init();	
	setup(&max_jit_notify_class, max_jit_notify_new, (method)max_jit_notify_free, (short)sizeof(t_max_jit_notify), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_notify,obex));
	q = jit_class_findbyname(gensym("jit_notify"));    
	
	//NOTIFY EXAMPLE: WE NEED TO OVERRIDE THE DEFAULT MOP NOTIFY METHOD
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_NOTIFY); 		//name/type/dim/planecount/bang/outputmatrix/etc
    
    max_jit_classex_standard_wrap(p,q,0); 	//getattributes/dumpout/maxjitclassaddmethods/etc
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  //standard mop assist fn

	//NOTIFY EXAMPLE: HERE'S WHERE WE DECLARE OUR OWN NOTIFY METHOD
    addmess((method)max_jit_notify_notify, "notify", A_CANT,0);  

}
예제 #17
0
int main(void)
{	
	void *p, *q;
	t_jit_object	*attr;
	
	post("jit.openni %s, Copyright (c) 2011 Dale Phurrough. This program comes with ABSOLUTELY NO WARRANTY.", JIT_OPENNI_VERSION);
	post("jit.openni %s, Licensed under the GNU General Public License v3.0 (GPLv3) available at http://www.gnu.org/licenses/gpl-3.0.html", JIT_OPENNI_VERSION);

	// initialize the Jitter class by calling Jitter class's registration function
	jit_openni_init();
	
	// create the Max wrapper class
	setup((t_messlist**)&max_jit_openni_class, (method)max_jit_openni_new, (method)max_jit_openni_free, sizeof(t_max_jit_openni), 0, A_GIMME, 0);
	
	// specify a byte offset to keep additional OBEX information
	p = max_jit_classex_setup(calcoffset(t_max_jit_openni, obex));
	
	// look up the Jitter class in the class registry
	q = jit_class_findbyname(gensym("jit_openni"));    
    
	// add default methods and attributes for MOP max wrapper class, e.g. name, type, dim, planecount, bang, outputmatrix, etc
	max_jit_classex_mop_wrap(p, q, MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX|MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX|MAX_JIT_MOP_FLAGS_OWN_ADAPT);

	// add custom max wrapper attributes
	attr = jit_object_new(_jit_sym_jit_attr_offset, "skeleton_format", _jit_sym_char, JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW,
			NULL, NULL, calcoffset(t_max_jit_openni, chrSkeletonOutputFormat));
	jit_attr_addfilterset_clip(attr,0,2,TRUE,TRUE);
	max_jit_classex_addattr(p, attr);

	// wrap the Jitter class with the standard methods for Jitter objects, e.g. getattributes, dumpout, maxjitclassaddmethods, etc
	max_jit_classex_standard_wrap(p, q, 0);

    // add methods to the Max wrapper class
	max_addmethod_usurp_low((method)max_jit_openni_outputmatrix, "outputmatrix");	
	max_addmethod_usurp_low((method)max_jit_openni_XMLConfig_read, "read");

	// add an inlet/outlet assistance method; in this case the default matrix-operator (mop) assist fn 
	addmess((method)max_jit_openni_assist, "assist", A_CANT, 0);
	return 0;
}
예제 #18
0
int main(void)
{	
	void *p,*q;
	
	art_jit_simple_init();	
	setup((t_messlist **)&max_art_jit_simple_class, 
		  (method)max_art_jit_simple_new, 
		  (method)max_art_jit_simple_free, 
		  (short)sizeof(t_max_art_jit_simple), 
		  0L, 
		  A_GIMME, 
		  0);

	p = max_jit_classex_setup(calcoffset(t_max_art_jit_simple,obex));
	q = jit_class_findbyname(gensym("art_jit_simple"));    
    max_jit_classex_mop_wrap(p,q,0); 		//name/type/dim/planecount/bang/outputmatrix/etc
    max_jit_classex_standard_wrap(p,q,0); 	//getattributes/dumpout/maxjitclassaddmethods/etc
	
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  //standard mop assist fn
	
	return 0;
}
void main(void)
{	
	long attrflags;
	void *p, *q;
	
	jit_ys_pixelweightmat_init();	
	setup(&max_jit_ys_pixelweightmat_class, max_jit_ys_pixelweightmat_new, (method)max_jit_ys_pixelweightmat_free, (short)sizeof(t_max_jit_ys_pixelweightmat), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_ys_pixelweightmat,obex));
	q = jit_class_findbyname(gensym("jit_ys_pixelweightmat"));    
    	max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_BANG|MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX);
    	max_jit_classex_mop_mproc(p, q, max_jit_ys_pixelweightmat_mproc); // custom mproc
	max_jit_classex_standard_wrap(p,q,0); 	

    	addmess((method)max_jit_mop_assist, "assist", A_CANT,0);
    	
    	// bang method (accept bang)
    	addbang((method)max_jit_ys_pixelweightmat_bang);
    
    	ps_getmap = gensym("getmap");
}
예제 #20
0
int TTCLASSWRAPPERMAX_EXPORT main(void)
{
	void *p, *q;
	
	TTFoundationInit();
	
	// initialize the Jitter class
	GainClassInit();
	
	// create the Max class
	setup((t_messlist**)&sMaxGainClass, (method)MaxGainNew, (method)MaxGainFree, sizeof(MaxGainObject), 0, A_GIMME, 0);
	
	// specify a byte offset to keep additional information
	p = max_jit_classex_setup(calcoffset(MaxGainObject, obex));
	
	// look up the Jitter class in the class registry
	q = jit_class_findbyname(gensym("j_gain"));
	
    max_jit_classex_mop_wrap(p, q, 0);							// attrs & methods for name, type, dim, planecount, bang, outputmatrix, etc
    max_jit_classex_standard_wrap(p, q, 0);						// attrs & methods for getattributes, dumpout, maxjitclassaddmethods, etc
    addmess((method)max_jit_mop_assist, (char*)"assist", A_CANT, 0);	// standard matrix-operator (mop) assist fn
	return 0;
}
예제 #21
0
void ext_main(void* unused)
{	
	void *p,*q;
	union { void **v_ptr; t_messlist **m_ptr; } alias_ptr;
	alias_ptr.v_ptr = &max_cv_jit_blobs_centroids_class;
	cv_jit_blobs_centroids_init();
	setup(
			alias_ptr.m_ptr,	//A pointer to the Max class pointer
			(method)max_cv_jit_blobs_centroids_new,			//The constructor function
			(method)max_cv_jit_blobs_centroids_free,			//The destructor function
			(short)sizeof(t_max_cv_jit_blobs_centroids),		//The size of the Max class
			0L,											//Use only for GUI objects, null for standard Jitter objects
			A_GIMME,									//Pass arguments as a list of t_atoms
			0);											//End of type list

	p = max_jit_classex_setup(calcoffset(t_max_cv_jit_blobs_centroids,obex));	//Setup Max class
	q = jit_class_findbyname(gensym("cv_jit_blobs_centroids"));				//Get a pointer to the Jitter object class
    max_jit_classex_mop_wrap(p,q,0); 		
    max_jit_classex_standard_wrap(p,q,0); 	

    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);	//Add outlet assistance to object
	
	return 0;
}
/*
 * Main method
 */
int main(void)
{	
	//long attrflags;
	void *p, *q;//, *attr;
	
	//Initialize the ODE stuff
	jit_tml_DepthBG_init();
	
	setup((t_messlist**)&max_jit_tml_DepthBG_class,		//Define class type
		(method)max_jit_tml_DepthBG_new,					//Constructor
		(method)max_jit_tml_DepthBG_delete,				//Destructor
		(short)sizeof(t_max_jit_tml_DepthBG), 				//Size of data to allocate
		0L, A_GIMME, 0);									//Default get-all

	p = max_jit_classex_setup(calcoffset(t_max_jit_tml_DepthBG,obex));
	q = jit_class_findbyname(gensym(EXTERNAL_NAME));
    max_jit_classex_mop_wrap(p,q,0);
	max_jit_classex_standard_wrap(p,q,0);
	
	addmess((method)max_jit_tmp_DepthBG_assist, "assist", A_CANT,0);
	post("Initialized: jit.tml.DepthBG - XCode Build");
	
	return 0;
}