Forums > Dev

How to force getvalueof ( ) ?

December 5, 2010 | 5:04 pm

Hello maxers,

i successfully implemented a myobject_getvalueof function but it seems that this function is actually called only when you save the patcher …

How to update the pattrstorage slot when my object’s data change … there is something i don’t understand ; How pattrstorage know my data have been changed ? Do i have to attach and notify ? But which object ?

I don’t find a file to get an example, and i’m a bit lost …


December 6, 2010 | 1:50 pm

pattr and pattrstorage should be the ones attaching to your object using the standard mechanisms. You need to notify your value has changed with object_notify(x, _sym_modified, NULL) when you want to notify any clients.

This is demonstrated in the jslider sdk example for instance.


December 6, 2010 | 4:47 pm

Hello Joshua Kit Clayton,

i found the solution in old PDF (max 4.5 ?) "pattr SDK" ;
sorry, i didn’t see the object_notify ( ) function in jslider.c ;
It works now ;-)


Viewing 3 posts - 1 through 3 (of 3 total)