Fixed compile time error.

This commit is contained in:
Davis King 2016-02-05 12:50:02 -05:00
parent 195c769458
commit 2812014eb5
1 changed files with 9 additions and 2 deletions

View File

@ -515,6 +515,13 @@ namespace mex_binding
img[r][c].blue = *data++; img[r][c].blue = *data++;
} }
// -------------------------------------------------------
template <typename T>
void call_private_set_mxArray(T&, mxArray*) {}
void call_private_set_mxArray(matrix_colmajor& item, mxArray* m) { item._private_set_mxArray(m); }
void call_private_set_mxArray(fmatrix_colmajor& item, mxArray* m) { item._private_set_mxArray(m); }
// ------------------------------------------------------- // -------------------------------------------------------
template <typename T> template <typename T>
@ -578,7 +585,7 @@ namespace mex_binding
throw invalid_args_exception(sout.str()); throw invalid_args_exception(sout.str());
} }
if (is_column_major_matrix<T>::value) if (is_column_major_matrix<T>::value)
arg._private_set_mxArray((mxArray*)prhs); call_private_set_mxArray(arg, (mxArray*)prhs);
else else
assign_mat(arg_idx, arg , pointer_to_matrix(mxGetPr(prhs), nc, nr)); assign_mat(arg_idx, arg , pointer_to_matrix(mxGetPr(prhs), nc, nr));
} }
@ -592,7 +599,7 @@ namespace mex_binding
} }
if (is_column_major_matrix<T>::value) if (is_column_major_matrix<T>::value)
arg._private_set_mxArray((mxArray*)prhs); call_private_set_mxArray(arg,(mxArray*)prhs);
else else
assign_mat(arg_idx, arg , pointer_to_matrix((const float*)mxGetData(prhs), nc, nr)); assign_mat(arg_idx, arg , pointer_to_matrix((const float*)mxGetData(prhs), nc, nr));
} }