Research Article
LoCoBoard: Low-Cost Interactive Whiteboard Using Computer Vision Algorithms
Algorithm 2
Pseudo code Algorithm A2.
function ALGORITHM image_height, image_width, image, threshold, step) coordinates of the PL centroid | inputs: image_height, height of the image | image_width, width of the image | image, captured grayscale image | threshold, lower limit of brightness to identify pixels belonging to PL blob | step, interval between consecutive processed pixels per row during search | size ← 0 | colValue ← 0 | rowValue ← 0 | index ← 0 | while index < image_height ⋆ image_width do | row ← index/image_width | column ← index % image_width | image[row][column] threshold then | colValue ← colValue column | rowValue ← rowValue row | size ← size 1 | index ← index + step | colValue ← colValue/size | rowValue ← rowValue/size | return rowValue, colValue) |
|