semi working mxj implementation of adaptive granular synthesis