I am trying to use SLIC superpixel matlab code. The source code contains .c files. After using mex -slicmex.c
The following errors appear :
slicmex.c slicmex.c(108) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(109) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(123) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(126) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(171) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(172) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(173) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(174) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(386) : warning C4267: '=' : conversion from 'size_t' to 'int', possible loss of data slicmex.c(387) : error C2275: 'mwSize' : illegal use of this type as an expression C:\Program Files\MATLAB\R2012a\extern\include\tmwtypes.h(792) : see declaration of 'mwSize' slicmex.c(387) : error C2146: syntax error : missing ';' before identifier 'numdims' slicmex.c(387) : error C2065: 'numdims' : undeclared identifier slicmex.c(393) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data slicmex.c(445) : warning C4244: '=' : conversion from 'double' to 'int', possible loss of data
C:\PROGRA~1\MATLAB\R2012A\BIN\MEX.PL: Error: Compile of 'slicmex.c' failed.
Error using mex (line 206) Unable to complete successfully.