Max 5 API Reference
![]() |
Functions | |
t_jit_err | max_jit_classex_mop_wrap (void *mclass, void *jclass, long flags) |
Adds default methods and attributes to the MOP Max wrapper class. | |
t_jit_err | max_jit_classex_mop_mproc (void *mclass, void *jclass, void *mproc) |
Sets a custom matrix procedure for the MOP Max wrapper class. | |
t_jit_err | max_jit_mop_setup (void *x) |
Sets up necessary resources for MOP Max wrapper object. | |
t_jit_err | max_jit_mop_variable_addinputs (void *x, long c) |
Sets the number of inputs for a variable input MOP Max wrapper object. | |
t_jit_err | max_jit_mop_variable_addoutputs (void *x, long c) |
Sets the number of outputs for a variable input MOP Max wrapper object. | |
t_jit_err | max_jit_mop_inputs (void *x) |
Creates input resources for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_outputs (void *x) |
Creates output resources for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_matrixout_new (void *x, long c) |
Creates matrix outlet for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_matrix_args (void *x, long argc, t_atom *argv) |
Process matrix arguments for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_jit_matrix (void *x, t_symbol *s, long argc, t_atom *argv) |
Default jit_matrix method for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_assist (void *x, void *b, long m, long a, char *s) |
Default assist method for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_bang (void *x) |
Default bang method for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_outputmatrix (void *x) |
Default outputmatrix method for a MOP Max wrapper object. | |
void | max_jit_mop_clear (void *x) |
Default clear method for a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_notify (void *x, t_symbol *s, t_symbol *msg) |
Default notify method for a MOP Max wrapper object. | |
void | max_jit_mop_free (void *x) |
Frees additional resources used by a MOP Max wrapper object. | |
t_jit_err | max_jit_mop_adapt_matrix_all (void *x, void *y) |
Adapts all input and output matrices to matrix specified. | |
void * | max_jit_mop_get_io_by_name (void *x, t_symbol *s) |
Retrieves t_jit_mop_io object pointer by name. | |
void * | max_jit_mop_getinput (void *x, long c) |
Retrieves input t_jit_mop_io object pointer index. | |
void * | max_jit_mop_getoutput (void *x, long c) |
Retrieves output t_jit_mop_io object pointer index. | |
long | max_jit_mop_getoutputmode (void *x) |
Retrieves current MOP Max wrapper class output mode. | |
t_jit_err | max_jit_mop_setup_simple (void *x, void *o, long argc, t_atom *argv) |
Initializes default state and resources for MOP Max wrapper class. |
t_jit_err max_jit_classex_mop_mproc | ( | void * | mclass, | |
void * | jclass, | |||
void * | mproc | |||
) |
Sets a custom matrix procedure for the MOP Max wrapper class.
mclass | max jit classex pointer returned from max_jit_classex_setup | |
jclass | t_jit_class pointer, typcially returned from jit_class_findbyname | |
mproc | matrix procedure |
Definition at line 342 of file max.jit.mop.c.
References jit_class_adornment_get(), and jit_object_method().
t_jit_err max_jit_classex_mop_wrap | ( | void * | mclass, | |
void * | jclass, | |||
long | flags | |||
) |
Adds default methods and attributes to the MOP Max wrapper class.
mclass | max jit classex pointer returned from max_jit_classex_setup | |
jclass | t_jit_class pointer, typcially returned from jit_class_findbyname | |
flags | flags to override default MOP Max wrapper behavior |
Definition at line 33 of file max.jit.mop.c.
References A_CANT, A_GIMME, addbang(), addmess(), JIT_ATTR_GET_DEFER_LOW, jit_attr_getlong(), jit_attr_getsym(), JIT_ATTR_SET_USURP_LOW, jit_class_adornment_get(), JIT_MATRIX_MAX_DIMCOUNT, jit_object_method(), jit_object_new(), max_addmethod_defer_low(), max_addmethod_usurp_low(), max_jit_classex_addattr(), max_jit_mop_bang(), max_jit_mop_clear(), MAX_JIT_MOP_FLAGS_OWN_ADAPT, MAX_JIT_MOP_FLAGS_OWN_BANG, MAX_JIT_MOP_FLAGS_OWN_CLEAR, MAX_JIT_MOP_FLAGS_OWN_DIM, MAX_JIT_MOP_FLAGS_OWN_JIT_MATRIX, MAX_JIT_MOP_FLAGS_OWN_NAME, MAX_JIT_MOP_FLAGS_OWN_NOTIFY, MAX_JIT_MOP_FLAGS_OWN_OUTPUTMATRIX, MAX_JIT_MOP_FLAGS_OWN_OUTPUTMODE, MAX_JIT_MOP_FLAGS_OWN_PLANECOUNT, MAX_JIT_MOP_FLAGS_OWN_TYPE, max_jit_mop_jit_matrix(), max_jit_mop_notify(), max_jit_mop_outputmatrix(), and t_symbol::s_name.
t_jit_err max_jit_mop_adapt_matrix_all | ( | void * | x, | |
void * | y | |||
) |
Adapts all input and output matrices to matrix specified.
Typically used within the MOP Max Wrapper jit_matrix method for left most input.
x | Max object pointer | |
y | matrix to adapt to |
Definition at line 1298 of file max.jit.mop.c.
References t_jit_matrix_info::dim, t_jit_matrix_info::dimcount, jit_attr_getlong(), jit_object_free(), jit_object_method(), jit_object_new(), max_jit_obex_adornment_get(), t_jit_matrix_info::planecount, and t_jit_matrix_info::type.
Referenced by max_jit_mop_jit_matrix().
t_jit_err max_jit_mop_assist | ( | void * | x, | |
void * | b, | |||
long | m, | |||
long | a, | |||
char * | s | |||
) |
Default assist method for a MOP Max wrapper object.
x | Max object pointer | |
b | ignored | |
m | inlet or outlet type | |
a | index | |
s | output string |
Definition at line 727 of file max.jit.mop.c.
References jit_attr_getsym(), jit_object_method(), and max_jit_obex_adornment_get().
t_jit_err max_jit_mop_bang | ( | void * | x | ) |
Default bang method for a MOP Max wrapper object.
Simply calls the default outputmatrix method.
x | Max object pointer |
Definition at line 766 of file max.jit.mop.c.
References typedmess().
Referenced by max_jit_classex_mop_wrap().
void max_jit_mop_clear | ( | void * | x | ) |
Default clear method for a MOP Max wrapper object.
Calls the clear method on all input and output matrices.
x | Max object pointer |
Definition at line 823 of file max.jit.mop.c.
References jit_attr_getlong(), jit_object_method(), and max_jit_obex_adornment_get().
Referenced by max_jit_classex_mop_wrap().
void max_jit_mop_free | ( | void * | x | ) |
Frees additional resources used by a MOP Max wrapper object.
x | Max object pointer |
Definition at line 921 of file max.jit.mop.c.
References jit_attr_getlong(), jit_attr_getsym(), jit_attr_setsym(), jit_object_detach(), jit_object_free(), jit_object_method(), and max_jit_obex_adornment_get().
void* max_jit_mop_get_io_by_name | ( | void * | x, | |
t_symbol * | s | |||
) |
Retrieves t_jit_mop_io object pointer by name.
x | Max object pointer | |
s | input/output name (e.g. in, in2 , out, out2, etc.) |
Definition at line 1559 of file max.jit.mop.c.
References JIT_MOP_INPUT, JIT_MOP_OUTPUT, jit_object_method(), and max_jit_obex_adornment_get().
void* max_jit_mop_getinput | ( | void * | x, | |
long | c | |||
) |
Retrieves input t_jit_mop_io object pointer index.
x | Max object pointer | |
c | input index |
Definition at line 1594 of file max.jit.mop.c.
References jit_object_method(), and max_jit_obex_adornment_get().
void* max_jit_mop_getoutput | ( | void * | x, | |
long | c | |||
) |
Retrieves output t_jit_mop_io object pointer index.
x | Max object pointer | |
c | output index |
Definition at line 1615 of file max.jit.mop.c.
References jit_object_method(), and max_jit_obex_adornment_get().
long max_jit_mop_getoutputmode | ( | void * | x | ) |
Retrieves current MOP Max wrapper class output mode.
x | Max object pointer |
Definition at line 1635 of file max.jit.mop.c.
References jit_attr_getlong(), and max_jit_obex_adornment_get().
t_jit_err max_jit_mop_inputs | ( | void * | x | ) |
Creates input resources for a MOP Max wrapper object.
x | Max object pointer |
Definition at line 430 of file max.jit.mop.c.
References jit_attr_getlong(), jit_attr_setsym(), jit_matrix_info_default(), jit_object_attach(), jit_object_method(), jit_object_new(), jit_object_register(), max_jit_obex_adornment_get(), and max_jit_obex_proxy_new().
Referenced by max_jit_mop_setup_simple().
Default jit_matrix method for a MOP Max wrapper object.
x | Max object pointer | |
s | message symbol ("jit_matrix") | |
argc | argument count | |
argv | argument vector |
Definition at line 630 of file max.jit.mop.c.
References jit_atom_getsym(), jit_attr_getlong(), jit_attr_setsym(), jit_error_code(), jit_object_findregistered(), jit_object_method(), max_jit_mop_adapt_matrix_all(), max_jit_mop_outputmatrix(), max_jit_obex_adornment_get(), max_jit_obex_inletnumber_get(), max_jit_obex_jitob_get(), and outlet_anything().
Referenced by max_jit_classex_mop_wrap().
t_jit_err max_jit_mop_matrix_args | ( | void * | x, | |
long | argc, | |||
t_atom * | argv | |||
) |
Process matrix arguments for a MOP Max wrapper object.
x | Max object pointer | |
argc | argument count | |
argv | argument vector |
Definition at line 536 of file max.jit.mop.c.
References t_jit_matrix_info::dim, t_jit_matrix_info::dimcount, jit_atom_arg_getlong(), jit_atom_arg_getsym(), jit_attr_getlong(), jit_attr_setlong(), jit_matrix_info_default(), jit_object_method(), max_jit_attr_args_offset(), max_jit_obex_adornment_get(), t_jit_matrix_info::planecount, and t_jit_matrix_info::type.
Referenced by max_jit_mop_setup_simple().
t_jit_err max_jit_mop_matrixout_new | ( | void * | x, | |
long | c | |||
) |
Creates matrix outlet for a MOP Max wrapper object.
x | Max object pointer | |
c | output index (zero based) |
Definition at line 508 of file max.jit.mop.c.
References jit_object_method(), max_jit_obex_adornment_get(), and outlet_new().
Referenced by max_jit_mop_outputs().
Default notify method for a MOP Max wrapper object.
Handles any notification methods from any input and output matrix.
x | Max object pointer | |
s | notifier name | |
msg | notification message |
Definition at line 865 of file max.jit.mop.c.
References jit_attr_getlong(), jit_attr_getsym(), jit_attr_setsym(), jit_object_attach(), jit_object_findregistered(), jit_object_method(), jit_object_new(), jit_object_register(), and max_jit_obex_adornment_get().
Referenced by max_jit_classex_mop_wrap().
t_jit_err max_jit_mop_outputmatrix | ( | void * | x | ) |
Default outputmatrix method for a MOP Max wrapper object.
Calculates and outputs according to the MOP outputmode attribute.
x | Max object pointer |
Definition at line 784 of file max.jit.mop.c.
References jit_atom_setsym(), jit_attr_getlong(), jit_attr_getsym(), jit_object_method(), max_jit_obex_adornment_get(), and outlet_anything().
Referenced by max_jit_classex_mop_wrap(), and max_jit_mop_jit_matrix().
t_jit_err max_jit_mop_outputs | ( | void * | x | ) |
Creates output resources for a MOP Max wrapper object.
x | Max object pointer |
Definition at line 468 of file max.jit.mop.c.
References jit_attr_getlong(), jit_attr_setsym(), jit_matrix_info_default(), jit_object_attach(), jit_object_method(), jit_object_new(), jit_object_register(), max_jit_mop_matrixout_new(), and max_jit_obex_adornment_get().
Referenced by max_jit_mop_setup_simple().
t_jit_err max_jit_mop_setup | ( | void * | x | ) |
Sets up necessary resources for MOP Max wrapper object.
x | Max object pointer |
Definition at line 363 of file max.jit.mop.c.
References jit_class_adornment_get(), jit_object_class(), jit_object_method(), and max_jit_obex_jitob_get().
Referenced by max_jit_mop_setup_simple().
t_jit_err max_jit_mop_setup_simple | ( | void * | x, | |
void * | o, | |||
long | argc, | |||
t_atom * | argv | |||
) |
Initializes default state and resources for MOP Max wrapper class.
x | Max object pointer | |
o | Jitter object pointer | |
argc | argument count | |
argv | argument vector |
max_jit_obex_jitob_set(x,o); max_jit_obex_dumpout_set(x,outlet_new(x,NULL)); max_jit_mop_setup(x); max_jit_mop_inputs(x); max_jit_mop_outputs(x); max_jit_mop_matrix_args(x,argc,argv); return JIT_ERR_NONE;
Definition at line 1683 of file max.jit.mop.c.
References max_jit_mop_inputs(), max_jit_mop_matrix_args(), max_jit_mop_outputs(), max_jit_mop_setup(), max_jit_obex_dumpout_set(), max_jit_obex_jitob_set(), and outlet_new().
t_jit_err max_jit_mop_variable_addinputs | ( | void * | x, | |
long | c | |||
) |
Sets the number of inputs for a variable input MOP Max wrapper object.
x | Max object pointer | |
c | inlet count |
Definition at line 386 of file max.jit.mop.c.
References gensym(), jit_object_method(), and max_jit_obex_adornment_get().
t_jit_err max_jit_mop_variable_addoutputs | ( | void * | x, | |
long | c | |||
) |
Sets the number of outputs for a variable input MOP Max wrapper object.
x | Max object pointer | |
c | inlet count |
Definition at line 408 of file max.jit.mop.c.
References gensym(), jit_object_method(), and max_jit_obex_adornment_get().