From: Teemu I. <tpi...@pc...> - 2004-08-09 12:16:17
|
On 08/08/04 20:50, Josep Mon=E9s i Teixidor wrote: > Let's introduce padarray... Hi Josep, padarray.m seems to replicate and extend the functionality in impad.m, wh= ich is already in octave-forge. Since padarray is more Matlab compatible, we should probably start using it instead. "rgrep -l impad *" gives: image/fftconv2.m image/impad.m image/imrotate.m image/imshear.m image/imtranslate.m image/medfilt2.m image/ordfilt2.m Would you be interested in changing the function calls to impad in these functions to padarray, so that impad can be deprecated? Teemu >=20 > -- Function File: B =3D padarray (A,PADSIZE) > -- Function File: B =3D padarray (A,PADSIZE,PADVAL) > -- Function File: B =3D padarray (A,PADSIZE,PADVAL,DIRECTION) > Pads an array in a configurable way. >=20 > B =3D padarray(A,padsize) pads an array A with zeros, where PADSIZ= E > defines the amount of padding to add in each dimension (it must be > a vector of positive integers). >=20 > Each component of PADSIZE defines the number of elements of > padding that will be added in the corresponding dimension. For > instance, [4,5] adds 4 elements of padding in first dimension > (vertical) and 5 in second dimension (horizontal). >=20 > B =3D padarray(A,padsize,padval) pads A using the value specified = by > PADVAL. PADVAL can be a scalar or a string. Possible values are: > `0' > Pads with 0 as described above. This is the default behaviour. >=20 > `scalar' > Pads using PADVAL as a padding value. >=20 > `'circular'' > Pads with a circular repetition of elements in A (similar to > tiling A). >=20 > `'replicate'' > Pads 'replicating' values of A which are at the border of the > array. >=20 > `'symmetric'' > Pads with a mirror reflection of A. >=20 > B =3D padarray(A,padsize,padval,direction) pads A defining the > direction of the pad. Possible values are: > `'both'' > For each dimension it pads before the first element the numbe= r > of elements defined by PADSIZE and the same number again afte= r > the last element. This is the default value. >=20 > `'pre'' > For each dimension it pads before the first element the > number of elements defined by PADSIZE. >=20 > `'post'' > For each dimension it pads after the last element the number > of elements defined by PADSIZE. >=20 >=20 > --=20 > Josep Mon=E9s i Teixidor > Clau GnuPG: gpg --recv-keys 80E85CC4 |