Hi,
mex-it.h fails when using matrices which are not of type double.
I guess the error is on line 356:
sizeof(double) must be replaced by sizeof(T)
A similar error needs to be fixed on line 380.
Else everything works fine, thanks for this VERY handy function!
Cheers,
Fab