Mercurial > hg > octave-image
changeset 132:964e1e1e54b5
Correct indexing of image
author | sjvdw |
---|---|
date | Wed, 22 Sep 2004 08:45:08 +0000 |
parents | 307d47ef659d |
children | fabd1f3c83e3 |
files | houghtf.cc |
diffstat | 1 files changed, 1 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/houghtf.cc +++ b/houghtf.cc @@ -90,7 +90,7 @@ double cT = cos(theta); double sT = sin(theta); for (int x = 0; x < r; x++) { for (int y = 0; y < c; y++) { - if ( I(y, x) == 1 ) { + if ( I(x, y) == 1 ) { int rho = (int)floor( cT*x + sT*y + 0.5 ); int bin = (int)(rho - bins(0)); if ( (bin > 0) && (bin < bins.length()) ) {