Mercurial > octave-dspies
view examples/mycell.c @ 18669:cf3db95a75f0
axis.m: Fix regression when accepting input handle (cset 5032ac119d52).
* axis.m: When setting xlim, ylim, zlim to numeric values the functions
must be called with the desired axis handle so that id doesn't always
operate on gca.
author | Rik <rik@octave.org> |
---|---|
date | Thu, 24 Apr 2014 07:13:37 -0700 |
parents | 224e76250443 |
children |
line wrap: on
line source
#include "mex.h" void mexFunction (int nlhs, mxArray* plhs[], int nrhs, const mxArray* prhs[]) { mwSize n; mwIndex i; if (nrhs != 1 || ! mxIsCell (prhs[0])) mexErrMsgTxt ("ARG1 must be a cell"); n = mxGetNumberOfElements (prhs[0]); n = (n > nlhs ? nlhs : n); for (i = 0; i < n; i++) plhs[i] = mxDuplicateArray (mxGetCell (prhs[0], i)); }