int main(void)
{	
	//long attrflags;
	void *p, *q;
	
	jit_tml_fluid2_init();	
	setup((void*)&max_jit_tml_fluid2_class,
			(method)max_jit_tml_fluid2_new,
			(method)max_jit_tml_fluid2_free, (short)sizeof(t_max_jit_tml_fluid2), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_tml_fluid2,obex));
	q = jit_class_findbyname(gensym("jit_tml_fluid2"));    
    	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_tml_fluid2_mproc); // custom mproc
	max_jit_classex_standard_wrap(p,q,0); 	

		addmess((method)max_jit_tml_fluid2_assist, "assist", A_CANT,0);
    	
    	// bang method (accept bang)
    	addbang((method)max_jit_tml_fluid2_bang);
    
    	ps_getmap = gensym("getmap");
	
	return 0;
}
Exemple #2
0
void main(void)
{	
	void *p,*q,*attr;
	long attrflags;
	
	setup(&max_jit_op_class, max_jit_op_new, (method)max_jit_op_free, (short)sizeof(t_max_jit_op), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_op,obex));
	q = jit_class_findbyname(gensym("jit_op"));    
    
    addmess((method)max_jit_op_jit_matrix, "jit_matrix", A_GIMME, 0);
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX); 		
    max_jit_classex_mop_mproc(p,q,max_jit_op_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0);
        
    attrflags = JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW ;
	attr = jit_object_new(_jit_sym_jit_attr_offset_array,"val",_jit_sym_atom,JIT_MATRIX_MAX_PLANECOUNT,attrflags,
		(method)0,(method)max_jit_op_val,calcoffset(t_max_jit_op,valcount),calcoffset(t_max_jit_op,val));
	max_jit_classex_addattr(p,attr);
 	
 	addint((method)max_jit_op_int);
 	addfloat((method)max_jit_op_float);
	addmess((method)max_jit_op_list, "list", A_GIMME, 0);
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  
}
Exemple #3
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_binedge_class;
	
	cv_jit_binedge_init();
	setup(
			//(t_messlist **)&max_cv_jit_binedge_class,	//A pointer to the Max class pointer
			alias_ptr.m_ptr,
			(method)max_cv_jit_binedge_new,				//The constructor function
			(method)max_cv_jit_binedge_free,			//The destructor function
			(short)sizeof(t_max_cv_jit_binedge),		//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_binedge,obex));	//Setup Max class
	q = jit_class_findbyname(gensym("cv_jit_binedge"));				//Get a pointer to the Jitter object class
    max_jit_classex_mop_wrap(p,q,0); 		//Add default methods and attributes to Max MOP wrapper class
    max_jit_classex_standard_wrap(p,q,0); 	//Add standard Jitter methods

    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);	//Add outlet assistance to object
	
	return 0;
}
void C74_EXPORT main(void)
{
	void *p,*q,*attr;
	long attrflags;

	xray_jit_levelsetseg_init();
	setup((t_messlist **)&max_xray_jit_levelsetseg_class, max_xray_jit_levelsetseg_new, (method)max_xray_jit_levelsetseg_free, (short)sizeof(t_max_xray_jit_levelsetseg),
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_xray_jit_levelsetseg,obex));
	q = jit_class_findbyname(gensym("xray_jit_levelsetseg"));

	addmess((method)max_xray_jit_levelsetseg_jit_matrix, "jit_matrix", A_GIMME, 0);
    max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX);
    max_jit_classex_mop_mproc(p,q,max_xray_jit_levelsetseg_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0);

    attrflags = JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW ;
	attr = jit_object_new(_jit_sym_jit_attr_offset,"val",_jit_sym_float32,attrflags,
		(method)0,(method)max_xray_jit_levelsetseg_val,calcoffset(t_max_xray_jit_levelsetseg,val),calcoffset(t_max_xray_jit_levelsetseg,val));
	max_jit_classex_addattr(p,attr);

    addfloat((method)max_xray_jit_levelsetseg_float);
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);
}
Exemple #5
0
void main(void)
{	
	void *p,*q,*attr;
	long attrflags;
	
	jit_unpack_init();	
	setup(&max_jit_unpack_class, max_jit_unpack_new, (method)max_jit_unpack_free, (short)sizeof(t_max_jit_unpack), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_unpack,obex));
	q = jit_class_findbyname(gensym("jit_unpack"));
	
	addmess((method)max_jit_unpack_jit_matrix, "jit_matrix", A_GIMME,0); //place at beginning for speed
	max_jit_classex_mop_wrap(p,q,MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX);
//	max_jit_classex_mop_wrap(p,q,0);
    max_jit_classex_standard_wrap(p,q,0);
    
    attrflags = JIT_ATTR_GET_DEFER_LOW | JIT_ATTR_SET_USURP_LOW;
	attr = jit_object_new(_jit_sym_jit_attr_offset,"type",_jit_sym_symbol,attrflags,
		(method)max_jit_mop_gettype,(method)max_jit_mop_type,0/*custom*/);
	object_addattr_parse(attr,"category",_jit_sym_symbol,0,"MOP");
	max_jit_classex_addattr(p,attr);
	attr = jit_object_new(_jit_sym_jit_attr_offset_array,"dim",_jit_sym_long,JIT_MATRIX_MAX_DIMCOUNT,attrflags,
		(method)max_jit_mop_getdim,(method)max_jit_mop_dim,0/*custom*/);
	object_addattr_parse(attr,"category",_jit_sym_symbol,0,"MOP");
	max_jit_classex_addattr(p,attr);
    
    addmess((method)max_jit_mop_assist, "assist", A_CANT,0);  
    addmess((method)max_jit_mop_variable_anything, "anything", A_GIMME, 0);  

}
void main(void)
{	
	void *p,*q;
	
	jit_human_init();	
	setup(&max_jit_human_class, max_jit_human_new, (method)max_jit_human_free, (short)sizeof(t_max_jit_human), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_human,obex));
	q = jit_class_findbyname(gensym("jit_human"));    
//    max_jit_classex_mop_wrap(p,q,0); 		
    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_human_mproc); 	//custom mproc
    max_jit_classex_standard_wrap(p,q,0); 	
    addmess((method)max_jit_human_assist, "assist", A_CANT,0);  

	ps_getstate = gensym("getstate");
	ps_getbox_coords = gensym("getbox_coords");
	ps_getarm_left = gensym("getarm_left");
	ps_getarm_right = gensym("getarm_right");
	ps_gethead = gensym("gethead");
	ps_getfoot_left = gensym("getfoot_left");
	ps_getfoot_right = gensym("getfoot_right");


	post("a-jit.human  - andrŽ sier - "__DATE__"  "__TIME__);
}
int main(void)
{	
	void *p,*q;
	
	union { void **v_ptr; t_messlist **m_ptr; } alias_ptr;
	alias_ptr.v_ptr = &max_cv_jit_canny_class;
	cv_jit_canny_init();
	setup(
			alias_ptr.m_ptr,	//A pointer to the Max class pointer
			(method)max_cv_jit_canny_new,			//The constructor function
			(method)max_cv_jit_canny_free,			//The destructor function
			(short)sizeof(t_max_cv_jit_canny),		//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_canny,obex));	//Setup Max class
	q = jit_class_findbyname(gensym("cv_jit_canny"));				//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;
}
void main(void)
{	
	void *classex, *jitclass;
	
	/*
	// Debug console window so printf works
	FILE* pCout; // should really be freed on exit 
	AllocConsole();
	freopen_s(&pCout, "CONOUT$", "w", stdout); 
	printf("jit_gl_spout_receiverSDK\n");
	*/
	post("jit_gl_spout_receiver - SDK Vers 2.001");

	// initialize our Jitter class
	jit_gl_spout_receiver_init();	
	
	// create our Max class
	setup((t_messlist **)&max_jit_gl_spout_receiver_class, 
		  (method)max_jit_gl_spout_receiver_new, 
		  (method)max_jit_gl_spout_receiver_free, 
		  (short)sizeof(t_max_jit_gl_spout_receiver), 
		  0L, A_GIMME, 0);
	
	// specify a byte offset to keep additional information about our object
	classex = max_jit_classex_setup(calcoffset(t_max_jit_gl_spout_receiver, obex));
	
	// look up our Jitter class in the class registry
	jitclass = jit_class_findbyname(gensym("jit_gl_spout_receiver"));	
	
	// wrap our Jitter class with the standard methods for Jitter objects
    max_jit_classex_standard_wrap(classex, jitclass, 0); 	
	
	// custom draw handler so we can output our texture.
	// override default ob3d bang/draw methods
	addbang((method)max_jit_gl_spout_receiver_bang);
	max_addmethod_defer_low((method)max_jit_gl_spout_receiver_draw, "draw");  
	
    #ifdef UseServers
	max_addmethod_defer_low((method)max_jit_gl_spout_receiver_getavailableservers, "getavailableservers");
	#else
	max_addmethod_defer_low((method)max_jit_gl_spout_receiver_getavailablesenders, "getavailablesenders");
	#endif
    
   	// use standard ob3d assist method
    addmess((method)max_jit_ob3d_assist, "assist", A_CANT,0);  
	
	// add methods for 3d drawing
    max_ob3d_setup();

	ps_jit_gl_texture = gensym("jit_gl_texture");
	ps_maxdraw = gensym("maxdraw");
	ps_out_name = gensym("out_name");
	ps_spoutsendername = gensym("SpoutSender");
    ps_clear = gensym("clear");

}
Exemple #9
0
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	jit_clip_init();	
	setup(&max_jit_clip_class, max_jit_clip_new, (method)max_jit_clip_free, (short)sizeof(t_max_jit_clip), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_clip,obex));
	q = jit_class_findbyname(gensym("jit_clip"));    
    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
}
void C74_EXPORT main(void)
{
	void *p,*q;

	xray_jit_keepcell_init();
	setup((t_messlist **)&max_xray_jit_keepcell_class, max_xray_jit_keepcell_new, (method)max_xray_jit_keepcell_free, (short)sizeof(t_max_xray_jit_keepcell),
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_xray_jit_keepcell,obex));
	q = jit_class_findbyname(gensym("xray_jit_keepcell"));
    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);
}
Exemple #11
0
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	jit_transpose_init();
	setup(&max_jit_transpose_class, max_jit_transpose_new, (method)max_jit_transpose_free, (short)sizeof(t_max_jit_transpose), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_transpose,obex));
	q = jit_class_findbyname(gensym("jit_transpose"));    
    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);  
}
void ext_main(void *r)
{
	void *p,*q;

	jit_split_init();
	setup(&max_jit_split_class, max_jit_split_new, (method)max_jit_split_free, (short)sizeof(t_max_jit_split),
		  0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_split,obex));
	q = jit_class_findbyname(gensym("jit_split"));
	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);
}
void C74_EXPORT main(void)
{
    void *p,*q;

    jit_alphablend_init();
    setup((t_messlist **)&max_jit_alphablend_class, (method)max_jit_alphablend_new, (method)max_jit_alphablend_free, (short)sizeof(t_max_jit_alphablend),
          0L, A_GIMME, 0);

    p = max_jit_classex_setup(calcoffset(t_max_jit_alphablend,obex));
    q = jit_class_findbyname(gensym("jit_alphablend"));
    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);
}
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("jcom_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;
}
int main(void)
{	
	void *p,*q;
	
	jit_dmxmap_init();
	setup((t_messlist**)&class_max_jit_dmxmap, (method)max_jit_dmxmap_new, (method)max_jit_dmxmap_free, (short)sizeof(t_max_jit_dmxmap), NULL, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_dmxmap,obex));
	q = jit_class_findbyname(gensym("jit_dmxmap"));
	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;
}
void ext_main(void *r)
{
	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
}
Exemple #17
0
void C74_EXPORT main(void)
{	
	void *p,*q;
	
	jit_noise_init();	
	setup(&max_jit_noise_class, max_jit_noise_new, (method)max_jit_noise_free, (short)sizeof(t_max_jit_noise), 
		0L, A_GIMME, 0);

	p = max_jit_classex_setup(calcoffset(t_max_jit_noise,obex));
	q = jit_class_findbyname(gensym("jit_noise"));    
    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_noise_outputmatrix, "outputmatrix");	
    addmess((method)max_jit_mop_assist, "assist", A_CANT,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");
}
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;
}
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
}
Exemple #21
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();

}
Exemple #23
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);  
}
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");
}
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;
}
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");

}
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;
}
Exemple #28
0
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");
}
Exemple #29
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();
}
Exemple #30
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")));	
}