software on the vertical plane is expected to vary
from 0,04 to 0,07 mm, and on the horizontal plane
0,05 to 0,1 mm (value of the pixel).
4 DETECTION OF THE SPINOUS
PROCESSES
To develop the software for detecting spinous
process we used Matlab (MATrix LABoratory, a
numeric computer environment for programming),
where respectively, the processing code and image
analysis, as well as functions for communication
with the mechanical equipment were created.
The first step in the development of the software
to detect the spinous process consisted of choosing
the marker to sign the spinous process in the skin.
For this purpose, several tests were made to find the
best marker, this tests were made to see how the
markers behaved in the skin. It was observed that if
the ink of the marker spread in contact with the skin
the marker could not be used, because the detection
of the point would became harder or could even fail.
The tests showed that skin has mainly the red and
green components in a RBG camera, so the blue will
be the best bet for the marker.
As the processing and image analysis is based on
logical operators, it was necessary to binarize the
image. However, since the processing of the image
in terms of the detection of the points and the laser
mark had to be done in real time and as swiftly as
possible, complex binarization algorithms could not
be used. Therefore, it was decided to make a
binarization by comparing the green and blue
components of the image to detect the blue marks.
This binarization option is the result of tests
performed with the markers. It was observed that
only the area of the blue mark had the blue image
component higher than the green. In other areas of
the skin, the red component of the image dominated,
followed by the green and finally blue. More tests
must be performed to see if this is compatible with
all skin types (Caucasian restricted at this point), but
for now this feature was taken in advantage to make
the image binarization.
An opening operation was applied to the image
in order to reduce the artefacts caused by
binarization. This operation is the result of an
erosion followed by dilatation of the image with the
same mask. This image processing operation keeps
only the structures that are similar to the mask, and
also the ones that are contained within the area of
those same structures.
After this treatment, an algorithm of connected
components (Gonzalez, 2002, 2004) was applied to
the image. This algorithm allows the detection of
objects in binarized images.
Following the detection of objects and using
image analyses the dimensions and centroids of the
objects were calculated. Subsequently, some
comparisons were made to test whether the object
being analyzed is actually the point made by the
marker or not. If the object detected is really a mark,
its coordinates are stored.
The detection of the laser mark is made in a
similar manner to that used in the detection of the
points, yet its binarization is different.
To find the mark position of the laser diode the
red component of the image is compared with the
green component. When the green component has a
higher level than the red component this means that
it is in the area of the laser mark.
Figure 7: Aspect of the blue and green laser mark on the
skin (a); Binarization plus opening operation of the blue
mark (b); Binarization of the laser mark (c).
In order to move the mechanical equipment to
put the mark of the laser diode on top of the blue
dots it is necessary to calculate the distance from the
laser point to the blue point in pixels and convert it
into real values. For this conversion a reference in
the image is needed, the reference used was the
mark of the laser diode. The mark of the laser diode
was also used to calculate distances allowing us to
calculate the third spatial coordinate of the blue
mark (Muljowidodo K, 2009
).
When the equipment is on the right spot, the
BIODEVICES 2011 - International Conference on Biomedical Electronics and Devices
228