|
-
March 13th, 2008, 09:58 PM
#3
Re: How to move a double dimensional array along an image?
for(i = 0; i < height_image - height_window; i += step_h)
{
for(j = 0; j < width_image - width_window; j+= step_w)
{
for(ii = 0; ii < height_window; ii++)
for(jj = 0; jj < width_window; jj++)
window[ii][jj] = image[i + ii][j + jj];
// your window is here
}
}
Thanks for the sample. I have a doubt where the window will run one time only even the loop is as above.
Let's say, height_window = 40, width_window = 110, height_image = 80 and width_image = 142. step_h and step w are set to 10.
Is it possible the loop stop because of the size of my image and window?
Thanks a lot.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|