не помогло... >> mex detf.cpp
Error detf.cpp: 1 empty declaration
Error detf.cpp: 1 syntax error; found "C" expecting `;'
Error detf.cpp: 1 unrecognized declaration
Error detf.cpp: 1 unrecognized declaration
Error detf.cpp: 1 illegal character `#'
Error detf.cpp: 1 syntax error; found "mex.h" expecting `;'
Error detf.cpp: 1 unrecognized declaration
Error detf.cpp: 1 unrecognized declaration
Error detf.cpp: 16 missing parameter type
Error detf.cpp: 16 syntax error; found `*' expecting `)'
Error detf.cpp: 16 skipping `*' `plhs' `[' `]' `,'
Error detf.cpp: 17 syntax error; found `int' expecting `{'
Error detf.cpp: 17 missing identifier
Error detf.cpp: 17 syntax error; found `const' expecting `;'
Error detf.cpp: 17 redeclaration of `mxArray' previously declared at detf.cpp 16
Error detf.cpp: 17 syntax error; found `*' expecting `;'
Error detf.cpp: 17 undeclared identifier `prhs'
Error detf.cpp: 17 illegal expression
Error detf.cpp: 17 syntax error; found `)' expecting `]'
Error detf.cpp: 17 skipping `)'
Error detf.cpp: 18 too many errors
C:\PROGRA~1\MATLAB\R2011B\BIN\MEX.PL: Error: Compile of 'detf.cpp' failed.
Error using mex (line 206)
Unable to complete successfully.