Skip to content

Commit

Permalink
Update compute_dense_overlap.cc
Browse files Browse the repository at this point in the history
change int to mwSize (thanks to #24 (comment))
  • Loading branch information
peiyunh authored Feb 6, 2018
1 parent 246d431 commit c91223c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions utils/compute_dense_overlap.cc
Original file line number Diff line number Diff line change
Expand Up @@ -64,15 +64,15 @@ void mexFunction(int nlhs, mxArray *plhs[], int nrhs, const mxArray *prhs[]) {
const double zmy = mxGetScalar(prhs[15]);

/* outputs */
const int dims[] = {vsy, vsx, nt, ng};
const mwSize dims[] = {vsy, vsx, nt, ng};
/* printf("dims: %d %d %d %d\n", vsy, vsx, nt, ng); */

mxArray *mx_overlap = mxCreateNumericArray(4, dims, mxDOUBLE_CLASS, mxREAL);
double *overlap = (double *)mxGetPr(mx_overlap);
plhs[0] = mx_overlap;

/* temporary buffer */
const int tmp_dims[] = {(vsy-1)*zmy+1, (vsx-1)*zmx+1, nt};
const mwSize tmp_dims[] = {(vsy-1)*zmy+1, (vsx-1)*zmx+1, nt};
mxArray *mx_tmp_overlap = mxCreateNumericArray(3, tmp_dims, mxDOUBLE_CLASS, mxREAL);
double *tmp_overlap = (double *)mxGetPr(mx_tmp_overlap);

Expand Down

0 comments on commit c91223c

Please sign in to comment.