| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
6.3 Fill
- Method on mglData:
voidFill (floatx1,floatx2,chardir='x') Equidistantly fills the data values to range [x1, x2] in direction dir={‘x’,‘y’,‘z’}.
- Method on mglData:
voidModify (const char *eq,intdim=0) Function fills the value of array according to the formula in string eq. Formula is an arbitrary expression depending on variables ‘x’, ‘y’, ‘z’, ‘u’. Coordinates ‘x’, ‘y’, ‘z’ are data indexes normalized in range [0,1]. Variable ‘u’ is the original value of the array. Modification will be fulfilled only for slices >=dim.
- Method on mglData:
voidModify (const char *eq,const mglData &v) - Method on mglData:
voidModify (const char *eq,const mglData &v,const mglData &w) Function fills the value of array according to the formula in string eq. Formula is an arbitrary expression depending on variables ‘x’, ‘y’, ‘z’, ‘u’, ‘v’, ‘w’. Coordinates ‘x’, ‘y’, ‘z’ are data indexes normalized in range [0,1]. Variable ‘u’ is the original value of the array. Variables ‘v’ and ‘w’ are values of vdat, wdat.
- Method on mglData:
voidPut (floatval,inti=-1,intj=-1,intk=-1) Function sets value(s) of array a[i, j, k] = val. Negative indexes i, j, k=-1 set the value val to whole range in corresponding direction(s). For example,
Fill(val,-1,0,-1);sets a[i,0,j]=val for i=0...(nx-1), j=0...(nz-1).
- Method on mglData:
voidPut (const mglData &v,inti=-1,intj=-1,intk=-1) Function copies value(s) from array v to the range of original array. Negative indexes i, j, k=-1 set the range in corresponding direction(s). At this minor dimensions of array v should be large than corresponding dimensions of this array. For example,
Fill(v,-1,0,-1);sets a[i,0,j]=v.ny>nz ? v[i,j] : v[i], where i=0...(nx-1), j=0...(nz-1) and condition v.nx>=nx is true.
| [ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
