1. Rght

I am trying to do a Randimized Generalized Hough Transform. A document detailing this is available at
http://www.cse.cuhk.edu.hk/~pffung/p...ce/CPR1996.pdf

The problem I am having is in the first two steps of the algroithm

Hor-Mask = -1 -2 -3 -2 -1
0 0 0 0 0
1 2 3 2 1

After executing step 1. The image doesn't change much. Jusct a black line around the edge.

I know the code below is not great but I was just testing it. I would be greatful of any input.

int Matrix[3][5] = {-1,-2,-3,-2,-1,
0,0,0,0,0,
1,2,3,2,1};
int row;
int col;
int value;

for (row = 2; row < Image1->Height - 1; row++)
for (col = 1; col < Image1->Width - 2; col++)
{
value = Image1->Canvas->Pixels[col - 2][row - 1] * Matrix[0][0];
value =+ Image1->Canvas->Pixels[col - 1][row - 1] * Matrix[0][1];
value =+ Image1->Canvas->Pixels[col][row - 1] * Matrix[0][2];
value =+ Image1->Canvas->Pixels[col + 1][row - 1] * Matrix[0][3];
value =+ Image1->Canvas->Pixels[col + 2][row - 1] * Matrix[0][4];

value =+ Image1->Canvas->Pixels[col - 2][row + 1] * Matrix[2][0];
value =+ Image1->Canvas->Pixels[col - 1][row + 1] * Matrix[2][1];
value =+ Image1->Canvas->Pixels[col][row + 1] * Matrix[2][2];
value =+ Image1->Canvas->Pixels[col + 1][row + 1] * Matrix[2][3];
value =+ Image1->Canvas->Pixels[col + 2][row + 1] * Matrix[2][4];

Image2->Canvas->Pixels[col][row] = value;
}

2. Truthfully, I don't understand a darn thing about what it is you're saying, but something caught my eye in your code.
Code:
`value =+ Image1...`
I think you want to add the right hand side to value and store the whole shebang in value. If so, you want to use +=. The way your code is being interpreted by the computer is the + is a unary operator only operating on Image1. That might be your problem or I might be dead wrong. It's worth letting you know that, though. Good Luck.

3. Thanks.
That was one of my mistakes.

I'm sure there are many more.

4. My suggestion to you is to repost your revised code using code tags this time and ask a specific question. Hopefully then, someone more qualified than me could help you.