Abstract:
A surface analysis method and system, the system comprising a digital imaging system for generating a digital image of a surface, a processor so coupled to the digital imaging system as to receive the digital image, to process the digital image and to generate a processed digital image highlighting relief variations in the surface, and a display system for displaying the processed digital image. The processor being so configured as to apply at least one digital filter to the digital image to highlight relief variation in the surface.

Description:
CROSS-REFERENCE TO RELATED APPLICATION 
       [0001]    The present application claims the benefits of U.S. provisional patent application No. 60/733,178 filed Nov. 4, 2005, which is hereby incorporated by reference. 
     
    
     TECHNICAL FIELD 
       [0002]    The present invention relates to a surface analysis method and system. More specifically, the present invention relates to a surface analysis method and system for the diagnostic of postural abnormalities in the structure of the human body. 
       BACKGROUND 
       [0003]    Various non-invasive biomedical investigation and diagnosis methods and systems have been explored, in particular optical methods and systems because of the relative simplicity and affordability of the equipment employed. 
         [0004]    Different known optical methods involve both passive and active means of optically investigating the organism. In the first case, the organism&#39;s own radiation at the infrared (IR) range is recorded, while in the second case, external illumination of insignificant density, absolutely harmless for the human organism, is employed. 
         [0005]    In the case of IR investigation, the recorded thermal radiation results from the metabolic generation of heat emanating from the human body. The patterns of such thermal emissions are affected by the activities of the tissues, organs and vessels inside the body. The amount of radiation can reflect the metabolic rate of the human body. 
         [0006]    For example, U.S. Pat. No. 6,023,637 entitled “Method and apparatus for thermal radiation imaging”, issued to Liu et al. on Feb. 8, 2002, discloses a method and apparatus for obtaining images reflecting the metabolic activity within the body of a patient. This is accomplished using digital images indicative of the patient&#39;s body IR intensity. The various IR intensities are assigned distinct colors, which forms a new image reflecting the patient&#39;s metabolic activity. 
         [0007]    In the case of external illumination, one of the most common applications is the investigation of skin condition. For example, angled lighting has been used to generate a gradient of the illuminating field on the skin in order to enhance the visualization of wrinkles and fine lines. Depending on the direction of the gradient (vertical or horizontal), different sets of wrinkles and fine lines may be visually enhanced. 
         [0008]    Polarized light photography has also been developed to selectively enhance either surface or subsurface features of the skin. These results are accomplished by placing a polarizing filter (typically a linear polarizing filter) both in front of the flash unit, and in front of the camera. When the polarizing filters are in the same orientation with each other, surface features of the skin such as scales, wrinkles, fine lines, pores, and hairs are visually enhanced. When the polarizing filters are aligned perpendicular to each other, subsurface features of the skin such as erythema, pigmentation and blood vessels are visually enhanced. 
         [0009]    Ultraviolet photography, where the flash unit is filtered to produce ultraviolet A (UVA) light and the camera is filtered so that only visible light enters the lens, has been used to visually enhance the appearance of pigmentation, the bacteria p. acnes, and horns. A variation of ultraviolet photography has been termed the “sun camera” where UVA light is used to illuminate the skin and an UVA sensitive film or a digital camera is used to record the reflected ultraviolet light from the skin. In this arrangement, both the pigment distribution and the surface features of the skin are visually enhanced. 
         [0010]    For example, U.S. Pat. No. 6,907,193, entitled “Method of taking polarized images of the skin and the use thereof”, issued to Kollias et al. on Jun. 14, 2006, discloses a method of investigation of the skin using first a white light, followed by an ultraviolet light and finally a phosphorescent blue light. Each time a specific lighting is used, a picture of the patient is taken at an angle between 35 and 55 degrees. The angle allows the amplification of skin characteristics such as fine lines, skin texture, hairs, etc. Furthermore, the use of filters, such as polarizing filters is described. High frequency filters, red light blocking filters, etc. are also used to amplify some characteristics of the skin. 
         [0011]    Another example is U.S. Pat. No. 5,747,789, entitled “Method for investigation of distribution of physiological components in human body tissues and apparatus for its realization”, issued to Godik on May 5, 1998, which discloses a method for the investigation a region of a patient&#39;s body. The method begins by illuminating the region under investigation and recording, at regular intervals, the spatial distribution of the intensity of the reflected light using, for example, a digital camera. The sequence of spatial distribution of the intensity of the reflected light thus obtained gives information on a spatial picture of the functional dynamics of the arterial and venous capillary blood content. Depending on the physiological component to be investigated, a light source composed of specific wavelengths is used in order to heighten the sensitivity of the method. This wavelength specific light source is produced with the use of optical filters. 
         [0012]    Finally, US patent application No. 2004/0125996, entitled “Skin diagnostic imaging method and apparatus”, naming Eddowes et al. as inventors and published on Jul. 1, 2004, discloses a method and apparatus for face skin diagnostic, the method consisting in illuminating the face of a patient with a white light combined with red and blue or red and green filters, and taking a digital images of the patient&#39;s face thus illuminated. A digital image of the patient&#39;s face is also taken using an ultraviolet light source. The images thus obtained are analyzed by a computer program which identifies skin regions requiring preventive skin treatment. 
         [0013]    There is a need for a simple non-invasive analysis method and system, which doe not require sophisticated equipment, for the diagnostic of postural abnormalities in the structure of the human body. 
       SUMMARY 
       [0014]    The present invention relates to surface analysis system, comprising:
       a digital imaging system for generating a digital image of a surface;   a processor so coupled to the digital imaging system as to receive the digital image, to process the digital image and to generate a processed digital image highlighting relief variations in the surface; the processor being so configured as to apply at least one digital filter to the digital image to highlight relief variation in the surface; and   a display system for displaying the processed digital image.       
 
         [0018]    The present invention further relates to the above described surface analysis system wherein the at least one digital filter includes a custom filter, the processor, when applying the custom filter to the digital image, performing the steps of:
       a. applying a first set of rules to a selected color component of each pixel of the digital image, the first set of rules comprising:
           i. adding to an intensity value of the selected color component a value equal to the product of the intensity value, to which is subtracted the sum of intensity values of eight neighboring pixels, multiplied by a predetermined fraction associated with the selected color component;   
           b. applying a second set of rules to the remaining color components of each pixel of the digital image, the second set of rules comprising:
           i. adding to an intensity value of each of the remaining color components a value equal to the product of the intensity value multiplied by a predetermined fraction associated with each of the remaining color components;   
           c. setting to the minimum value any color component intensity value lower than the minimum value; and   d. setting to a maximum value any color component intensity value greater than the maximum value.       
 
         [0025]    The present invention also relates to a surface analysis method, comprising:
       a. capturing a digital image of a surface;   b. processing the digital image using at least one digital filter to highlight relief variations in the surface; and   c. displaying the processed digital image.       
 
         [0029]    As well, the present invention relates to digital filtering method for filtering a digital image provided with at least two color components, the digital filtering method comprising:
       a. selecting a color component;   b. applying a first set of rules to the selected color component of each pixel of a digital image, the first set of rules comprising:
           i. adding to an intensity value of the selected color component a value equal to the product of the intensity value, to which is subtracted the sum of intensity values of eight neighboring pixels, multiplied by a predetermined fraction associated with the selected color component;   
           c. applying a second set of rules to the remaining color components of each pixel of the digital image, the second set of rules comprising:
           i. adding to an intensity value of each of the remaining color component a value equal to the product of the intensity value multiplied by a predetermined fraction associated with each of the remaining color components;   
           d. setting to a minimum value any color component intensity value lower than the minimum value; and   e. setting to a maximum value any color component intensity value greater than the maximum value.       
 
     
    
     
       BRIEF DESCRIPTION OF THE DRAWINGS 
         [0037]    A non-limitative illustrative embodiment of the invention will now be described by way of example only with reference to the accompanying drawings, in which: 
           [0038]      FIG. 1  is a flow diagram of a surface analysis method according to a non-limitative illustrative embodiment of the present invention; 
           [0039]      FIG. 2  is a digital image of the front view of a patient&#39;s feet; 
           [0040]      FIG. 3  is the digital image of  FIG. 2  to which an inverse filter was applied; 
           [0041]      FIG. 4  is a flow diagram of an inverse filter algorithm; 
           [0042]      FIG. 5  is the digital image of  FIG. 2  to which a solarize filter with a level equal to 0 was applied; 
           [0043]      FIG. 6  is the digital image of  FIG. 2  to which a solarize filter with a level equal to 128 was applied; 
           [0044]      FIG. 7  is a flow diagram of a solarize filter algorithm; 
           [0045]      FIG. 8  is the digital image of  FIG. 2  to which an edge detect and inverse filters were applied; 
           [0046]      FIGS. 9   a  and  9   b  is a flow diagram of an edge detect filter algorithm; 
           [0047]      FIG. 10  is the digital image of  FIG. 2  to which a custom filter was applied; 
           [0048]      FIG. 11  is the digital image of  FIG. 2  to which the custom and inverse filters were applied; 
           [0049]      FIGS. 12   a  and  12   b  is a flow diagram of the custom filter algorithm; 
           [0050]      FIG. 13  is a digital image of the back of a patient to which was applied the custom filter with a level of 255 followed by the inverse filter; 
           [0051]      FIG. 14  is a digital image of the front of a patient; 
           [0052]      FIG. 15  is the digital image of  FIG. 14  to which was applied a custom filter with a level of 255 followed by the inverse filter; 
           [0053]      FIG. 16  is a digital image of the front view of a patient&#39;s feet, showing eversion of the lower limbs, to which was applied a custom filter with a level of 255 followed by the inverse filter; 
           [0054]      FIG. 17  is a digital image of the front view of a patient&#39;s feet, showing normal lower limbs, to which was applied the custom filter with a level of 255 followed by the inverse filter; 
           [0055]      FIG. 18  is a digital image of the back view of a patient&#39;s feet, showing eversion of the lower limbs, to which was applied the custom filter with a level of 255 followed by the inverse filter; 
           [0056]      FIG. 19  is a digital image of the back view of a patient&#39;s feet, showing normal lower limbs, to which was applied the custom filter with a level of 255 followed by the inverse filter; and 
           [0057]      FIG. 20  is a schematic view of a surface analysis system. 
       
    
    
     DETAILED DESCRIPTION 
       [0058]    Generally stated, a method and system according to a non-limitative illustrative embodiment of the present invention provide a surface analysis system and method for the diagnostic of postural abnormalities in the structure of the human body. The method generally consist in using a digital filter, or a combination of digital filters, applied to digital images of a human body in order to highlight deformities and asymmetries on the surface of the skin covering the human body structure by accentuating the reflection of light upon the relief of the skin surface. It is to be understood that such a method may also be used in other contexts such as, for example, the analysis of the surface of the metallic body of a vehicle in order to identify any warping or indentations caused by an impact or an applied torque. 
         [0059]    A system  1  that may be use to implement the method is shown in  FIG. 20  and advantageously consist of a digital camera  2 , at least one flash unit, constant direct or diffuse source of light or a combination thereof  4  and a processing unit  6 , such as, for example, a personal computer, to process digital images taken of a patient  8  by the digital camera  2  by applying the various filters to the digital images. It is to be understood that in an alternative embodiment the patient may be replaced by an object, for example a vehicle in the case where the surface under analysis is a metallic body of a vehicle. 
         [0060]    Referring to  FIG. 1 , there is shown a flow diagram depicting the steps involved in the surface analysis method according to an illustrative embodiment of the present invention, which is indicated by blocks  102  to  106 . 
         [0061]    At block  102  the method starts by importing one, or more, digital image of the surface to be analyzed, for example a digital image of the body of a patient or the body of a vehicle. The digital image may be obtained using a digital imaging system such as, for example, a digital camera or a digital scanner or by scanning a conventional photograph or image. 
         [0062]    Then, at block  104 , one, or more, digital filter is applied to the digital image using, for example, a dedicated processor or a personal computer, in order to accentuate the reflection of light upon the surface. Four filters plus combinations of filters may be used in particular; these will be detailed further below. 
         [0063]    At block  106 , the filtered digital image are displayed, for example on a computer screen or a color printer. 
         [0064]    Optionally, at block  108 , the filtered digital image may be analyzed so as to detect deformities and asymmetries on the surface under analysis. The filtered digital image may be analyzed, for example, by a skilled technician observing the display or by an automated process recognizing certain colored structures and/or patterns. 
       Filters 
       [0065]    As mentioned above, four filters and combinations of filters may be used in particular although it is to be understood that other filters or other combinations of filters may be used as well. 
         [0066]    The first three filters are common filters, namely: the inverse filter, the solarize filter and the edge detect filter. The fourth filter is a custom type of filter. As for the combinations of filters, they are the application of the inverse filter to a digital image on which the edge detect filter has already been applied and the application of the inverse filter to a digital image on which the custom filter has already been applied. 
         [0067]    The effects of the four filters, and the combinations of filters, will now be described with reference to  FIG. 2  which is an original digital image  10  of the front view of the feet of a patient. 
         [0068]    In the following description, reference will be made to the Red Green Blue (RGB) color model, for which the intensity value of each component varies from a minimum value of 0 to a maximum value of 255. It is to be understood that other color models, having different ranges of values, may be used as well. 
       Inverse Filter 
       [0069]    The inverse filter helps with the viewing of contrast by producing a negative image of the original digital image  10 . This is achieved by inversing the intensity of the Red Green Blue (RGB) components of each pixels of the original digital image  10 , i.e. the new intensity value of each of the RGB component of a given pixel will be 255 (the maximum intensity value) minus the original intensity value of that component of the pixel. For example,  FIG. 3  shows the inversed image  12  of the original digital image  10  of  FIG. 2  after the application of the inverse filter. 
         [0070]    An illustrative example of an inverse filter algorithm that may be used is depicted by the flow diagram shown in  FIG. 4 . The steps of the algorithm are indicated by blocks  202  to  208 . 
         [0071]    The algorithm starts at block  202  by selecting a pixel “p” of the original digital image  10  which has not yet been selected. At block  204 , new intensity values of the RGB components are computed for pixel p using the following equations: 
         [0000]        R ′( p )=255 −R ( p );  Equation 1 
         [0000]        G ′( p )=255 −G ( p );  Equation 2 
         [0000]        B ′( p )=255 −B ( p );  Equation 3 
         [0072]    where
       R′(p) is the new red component intensity value of pixel p after the application of the inverse filter, R(p) being the original red component intensity value of pixel p;   G′(p) is the new green component intensity value of pixel p after the application of the inverse filter, G(p) being the original green component intensity value of pixel p; and   B′(p) is the new blue component intensity value of pixel p after the application of the inverse filter, B(p) being the original blue component intensity value of pixel p.       
 
         [0076]    Then, at block  206 , the algorithm verifies if there are any remaining pixels that have not yet been selected, if so it returns to block  202 , if not it exits at block  208 . 
       Solarize Filter 
       [0077]    The solarize filter is similar in concept to the inverse filter with the difference that, for each pixel, the solarize filter only inverses the intensity value of the RGB components which are smaller or equal to a predetermined level “L”, the level having a value in between 0 (the minimum intensity value) and 255 (the maximum intensity value). Basically, the solarize filter may be used to invert the RGB intensity values for low intensity pixels of a digital image. Thus, if the level is set at 255, the solarize filter&#39;s effect is the same as that of the inverse filter.  FIGS. 5 and 6  show examples of effects of the solarize filter upon the original digital image  10  of  FIG. 2 . In  FIG. 5  the level is set to 0, resulting in digital image  14 , while in  FIG. 6  the level is set to 128, resulting in digital image  15 . 
         [0078]    An illustrative example of a solarize filter algorithm that may be used is depicted by the flow diagram shown in  FIG. 7 . The steps of the algorithm are indicated by blocks  302  to  328 . 
         [0079]    The algorithm starts at block  302  by setting the level L and then, at block  304 , selecting a pixel “p” of the original digital image  10  which has not yet been selected. At block  306 , the red component intensity value of pixel p, R(p), is compared with level L, if R(p) is lower than L, then the algorithm proceeds to block  308  and computes the new red component intensity value of pixel p using Equation 1, if not, the algorithm proceeds to block  310  where the new red component intensity value of pixel p is computed using the following equation: 
         [0000]        R ′( p )= R ( p ).  Equation 4 
         [0080]    At block  312 , the green component intensity value of pixel p, G(p), is compared with level L, if G(p) is lower than L, then the algorithm proceeds to block  314  and computes the new green component intensity value of pixel p using Equation 2, if not, the algorithm proceeds to block  316  where the new green component intensity value of pixel p is computed using the following equation: 
         [0000]        G ′( p )= G ( p ).  Equation 5 
         [0081]    Similarly, At block  318 , the blue component intensity value of pixel p, B(p), is compared with level L, if B(p) is lower than L, then the algorithm proceeds to block  320  and computes the new blue component intensity value of pixel p using Equation 3, if not, the algorithm proceeds to block  322  where the new blue component intensity value of pixel p is computed using the following equation: 
         [0000]        B ′( p )= B ( p ).  Equation 6 
         [0082]    Then, at block  324 , the algorithm verifies if there are any remaining pixels that have not yet been selected, if so it returns to block  302 , if not is exits at block  328 . 
       Edge Detect Filter 
       [0083]    The purpose of the edge detect filter is to highlight edges between high intensity and low intensity areas of the original digital image  10 , i.e. the limit between areas having high RGB intensity variations. For each RGB component intensity value of a given pixel, the value of the difference between the intensity value of that RGB component and the average of the intensity values of the eight (8) neighboring pixels, for that same RGB component, is computed. If that difference value is greater than a certain level “L”, then it is set to 255 (the maximum intensity value). Finally, the pixel&#39;s new three RGB intensity values are set to the value of the RGB component having the greatest difference value. This results in a shades of grey image where the lighter lines identify edges and contours in the original digital image  10 . For example,  FIG. 8  shows the resulting image  16  after the application of the edge detect filter and the inverse filter to the original digital image  10  of  FIG. 2 . The inverse filter simply being applied for added clarity in order to show the edge lines in dark lines over a light background instead of light lines on a dark background. 
         [0084]    It is to be understood that the background of the original digital image  10  may be selected according to the surface being photographed so as to provide improved contrast. 
         [0085]    An illustrative example of an edge detect filter algorithm that may be used is depicted by the flow diagram shown in  FIGS. 9   a  and  9   b . The steps of the algorithm are indicated by blocks  402  to  436 . 
         [0086]    The algorithm starts at block  402  by setting the level L and then, at block  404 , selecting a pixel “p” of the original digital image  10  which has not yet been selected. At block  406 , the average of the red component intensity values of the eight (8) neighboring pixels to pixel p, Avg 8 [R(p)], is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               R 
                                
                               
                                 ( 
                                 p 
                                 ) 
                               
                             
                             ] 
                           
                         
                         = 
                           
                          
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               R 
                                
                               
                                 ( 
                                 
                                   x 
                                   , 
                                   y 
                                 
                                 ) 
                               
                             
                             ] 
                           
                         
                       
                     
                   
                   
                     
                       
                         
                           = 
                             
                            
                           
                             
                               1 
                               8 
                             
                             [ 
                             
                               
                                 ∑ 
                                 
                                   i 
                                   = 
                                   
                                     - 
                                     1 
                                   
                                 
                                 
                                   + 
                                   1 
                                 
                               
                                
                               
                                   
                               
                                
                               
                                 
                                   ∑ 
                                   
                                     j 
                                     = 
                                     
                                       - 
                                       1 
                                     
                                   
                                   
                                     
                                       + 
                                       1 
                                     
                                     , 
                                     
                                       j 
                                       ≠ 
                                       i 
                                     
                                   
                                 
                                  
                                 
                                   R 
                                    
                                   
                                     ( 
                                     
                                       
                                         x 
                                         + 
                                         i 
                                       
                                       , 
                                       
                                         y 
                                         + 
                                         j 
                                       
                                     
                                     ) 
                                   
                                 
                               
                             
                             ] 
                           
                         
                         ; 
                       
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   7 
                 
               
             
           
         
       
     
         [0087]    where
       x and y are the coordinates of pixel p.       
 
         [0089]    Following which, at block  408 , the absolute difference between the red component intensity value of pixel p, R(p), and the average Avg 8 [R(p)] of block  406  is computed as Diff 8 [R(p)]. More specifically: 
         [0000]        Diff   8   [R ( p )]=| R ( p )−Avg 8   [R ( p )]|.  Equation 8 
         [0090]    Then, at block  410 , Diff 8 [R(p)] is compared with level L, if Diff 8 [R(p)] is greater than L, then the algorithm proceeds to block  412  where it sets Diff 8 [R(p)] to 255 and then proceeds to block  414 , if not, the algorithm proceeds to block  414 . 
         [0091]    At block  414 , the average of the green component intensity values of the eight (8) neighboring pixels to pixel p, Avg 8 [G(p)], is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               G 
                                
                               
                                 ( 
                                 p 
                                 ) 
                               
                             
                             ] 
                           
                         
                         = 
                           
                          
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               G 
                                
                               
                                 ( 
                                 
                                   x 
                                   , 
                                   y 
                                 
                                 ) 
                               
                             
                             ] 
                           
                         
                       
                     
                   
                   
                     
                       
                         
                           = 
                             
                            
                           
                             
                               1 
                               8 
                             
                             [ 
                             
                               
                                 ∑ 
                                 
                                   i 
                                   = 
                                   
                                     - 
                                     1 
                                   
                                 
                                 
                                   + 
                                   1 
                                 
                               
                                
                               
                                   
                               
                                
                               
                                 
                                   ∑ 
                                   
                                     j 
                                     = 
                                     
                                       - 
                                       1 
                                     
                                   
                                   
                                     
                                       + 
                                       1 
                                     
                                     , 
                                     
                                       j 
                                       ≠ 
                                       i 
                                     
                                   
                                 
                                  
                                 
                                   G 
                                    
                                   
                                     ( 
                                     
                                       
                                         x 
                                         + 
                                         i 
                                       
                                       , 
                                       
                                         y 
                                         + 
                                         j 
                                       
                                     
                                     ) 
                                   
                                 
                               
                             
                             ] 
                           
                         
                         ; 
                       
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   9 
                 
               
             
           
         
       
     
         [0000]    where
       x and y are the coordinates of pixel p.       
 
         [0093]    Following which, at block  416 , the absolute difference between the green component intensity value of pixel p, G(p), and the average Avg 8 [G(p)] of block  414  is computed as Diff 8 [G(p)]. More specifically: 
         [0000]        Diff   8   [G ( p )]=| G ( p )−Avg 8   [G ( p )]|.  Equation 10 
         [0094]    Then, at block  418 , Diff 8 [G(p)] is compared with level L, if Diff 8 [G(p)] is greater than L, then the algorithm proceeds to block  420  where it sets Diff 8 [G(p)] to 255 (the maximum intensity value) and then proceeds to block  422 , if not, the algorithm proceeds to block  422 . 
         [0095]    At block  422 , the average of the blue component intensity values of the eight (8) neighboring pixels to pixel p, Avg 8 [B(p)], is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               B 
                                
                               
                                 ( 
                                 p 
                                 ) 
                               
                             
                             ] 
                           
                         
                         = 
                           
                          
                         
                           
                             Avg 
                             8 
                           
                            
                           
                             [ 
                             
                               B 
                                
                               
                                 ( 
                                 
                                   x 
                                   , 
                                   y 
                                 
                                 ) 
                               
                             
                             ] 
                           
                         
                       
                     
                   
                   
                     
                       
                         
                           = 
                             
                            
                           
                             
                               1 
                               8 
                             
                             [ 
                             
                               
                                 ∑ 
                                 
                                   i 
                                   = 
                                   
                                     - 
                                     1 
                                   
                                 
                                 
                                   + 
                                   1 
                                 
                               
                                
                               
                                   
                               
                                
                               
                                 
                                   ∑ 
                                   
                                     j 
                                     = 
                                     
                                       - 
                                       1 
                                     
                                   
                                   
                                     
                                       + 
                                       1 
                                     
                                     , 
                                     
                                       j 
                                       ≠ 
                                       i 
                                     
                                   
                                 
                                  
                                 
                                   B 
                                    
                                   
                                     ( 
                                     
                                       
                                         x 
                                         + 
                                         i 
                                       
                                       , 
                                       
                                         y 
                                         + 
                                         j 
                                       
                                     
                                     ) 
                                   
                                 
                               
                             
                             ] 
                           
                         
                         ; 
                       
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   11 
                 
               
             
           
         
       
     
         [0096]    where
       x and y are the coordinates of pixel p.       
 
         [0098]    Following which, at block  424 , the absolute difference between the green component intensity value of pixel p, G(p), and the average Avg 8 [G(p)] of block  422  is computed as Diff 8 [B(p)]. More specifically: 
         [0000]        Diff   8   [B ( p )]=| B ( p )−Avg 8   [B ( p )]|.  Equation 12 
         [0099]    Then, at block  426 , Diff 8 [B(p)] is compared with level L, if Diff 8 [B(p)] is greater than L, then the algorithm proceeds to block  428  where it sets Diff 8 [B(p)] to 255 (the maximum intensity value) and then proceeds to block  430 , if not, the algorithm proceeds to block  430 . 
         [0100]    At block  430 , the algorithm identifies the maximum absolute difference MaxDiff 8 [RGB(p)] among Diff 8 [R(p)], Diff 8 [G(p)] and Diff 8 [B(p)], and, at block  432 , assigns MaxDiff 8 [RGB(p)] to each new individual RGB component intensity value of pixel p, i.e. R′(p), G′(p) and B′(p). Therefore, if one of the absolute differences Diff 8 [R(p)], Diff 8 [G(p)] and Diff 8 [B(p)] are greater than level L, all the individual RGB component intensity value of pixel p will be set to 255 (the maximum intensity value). 
         [0101]    Then, at block  434 , the algorithm verifies if there are any remaining pixels that have not yet been selected, if so it returns to block  404 , if not is exits at block  436 . 
       Custom Filter 
       [0102]    For each pixel the custom filter applies two different sets of rules, one for the green and blue components and one for the red component. It is to be understood that in the illustrative embodiment the red component is particularly present in the skin of a patient, in other applications it may be the green or the blue components which may warrant a different rule. 
         [0103]    For the green and blue components of a given pixel “p”, a value equal to the product of the component&#39;s intensity value and a predetermined levels “L G ” or “L B ” divided by 100 is added to that component&#39;s original intensity value to yield the resulting component intensity value. It is to be understood that any resulting intensity value lower than the minimum value, in this case 0, is set to 0 (possible in the case where L G  or L B  has a negative value) and that any resulting intensity value greater than the maximum value, in this case 255, is set to 255. 
         [0104]    For the red component of the given pixel, a value equal to the product of the red intensity value, to which is subtracted the value of the red component intensity values of the eight (8) neighbouring pixels, and a predetermined level “L R ” divided by 100 is added to the red component&#39;s original intensity value to yield the resulting red intensity value. 
         [0105]    Again, it is to be understood that any resulting intensity value lower than 0 is set to 0 and that any resulting intensity value greater than 255 is set to 255. 
         [0106]    For example,  FIG. 10  shows the resulting image  18  after the application of the custom filter to the original digital image  10  of  FIG. 2 . As for  FIG. 11 , it shows the resulting image  20  after the application of both the custom filter and the inverse filter to the original digital image  10  of  FIG. 2 , the inverse filter simply being applied for added clarity. 
         [0107]    An illustrative example of the custom filter algorithm that may be used is depicted by the flow diagram shown in  FIGS. 12   a  and  12   b . The steps of the algorithm are indicated by blocks  502  to  540 . 
         [0108]    The algorithm starts at block  502  by setting the levels L R , L G  and L B , and then, at block  504 , selecting a pixel “p” of the original digital image  10  which has not yet been selected. At block  506 , the sum of the red component intensity values of the eight (8) neighboring pixels to pixel p, Sum 8 [R(p)], is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       
                         
                           
                             Sum 
                             8 
                           
                            
                           
                             [ 
                             
                               R 
                                
                               
                                 ( 
                                 p 
                                 ) 
                               
                             
                             ] 
                           
                         
                         = 
                           
                          
                         
                           
                             Sum 
                             8 
                           
                            
                           
                             [ 
                             
                               R 
                                
                               
                                 ( 
                                 
                                   x 
                                   , 
                                   y 
                                 
                                 ) 
                               
                             
                             ] 
                           
                         
                       
                     
                   
                   
                     
                       
                         
                           = 
                             
                            
                           
                             
                               ∑ 
                               
                                 i 
                                 = 
                                 
                                   - 
                                   1 
                                 
                               
                               
                                 + 
                                 1 
                               
                             
                              
                             
                                 
                             
                              
                             
                               
                                 ∑ 
                                 
                                   j 
                                   = 
                                   
                                     - 
                                     1 
                                   
                                 
                                 
                                   
                                     + 
                                     1 
                                   
                                   , 
                                   
                                     j 
                                     ≠ 
                                     i 
                                   
                                 
                               
                                
                               
                                 R 
                                  
                                 
                                   ( 
                                   
                                     
                                       x 
                                       + 
                                       i 
                                     
                                     , 
                                     
                                       y 
                                       + 
                                       j 
                                     
                                   
                                   ) 
                                 
                               
                             
                           
                         
                         ; 
                       
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   13 
                 
               
             
           
         
       
     
         [0109]    where
       x and y are the coordinates of pixel p.       
 
         [0111]    Following which, at block  508 , the new value of the red component intensity value of pixel p, R′(p), is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       
                         R 
                         ′ 
                       
                        
                       
                         ( 
                         p 
                         ) 
                       
                     
                     = 
                     
                       
                         R 
                          
                         
                           ( 
                           p 
                           ) 
                         
                       
                       + 
                       
                         
                           
                             [ 
                             
                               
                                 R 
                                  
                                 
                                   ( 
                                   p 
                                   ) 
                                 
                               
                               - 
                               
                                 
                                   Sum 
                                   8 
                                 
                                  
                                 
                                   [ 
                                   
                                     R 
                                      
                                     
                                       ( 
                                       p 
                                       ) 
                                     
                                   
                                   ] 
                                 
                               
                             
                             ] 
                           
                           · 
                           
                             L 
                             R 
                           
                         
                         100 
                       
                     
                   
                   , 
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   14 
                 
               
             
           
         
       
     
         [0112]    Then, at block  510 , the algorithm verifies if R′(p) is greater than 255 (the maximum intensity value), if so then the algorithm proceeds to block  512  where it sets R′(p) to 255, if not, the algorithm proceeds to block  514  where it verifies if R′(p) is lower than 0 (the minimum intensity value), if so then the algorithm proceeds to block  516  where it sets R′(p) to 0. 
         [0113]    At block  518 , the new value of the green component intensity value of pixel p, G′(p), is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       G 
                       ′ 
                     
                      
                     
                       ( 
                       p 
                       ) 
                     
                   
                   = 
                   
                     
                       G 
                        
                       
                         ( 
                         p 
                         ) 
                       
                     
                     + 
                     
                       
                         
                           
                             G 
                              
                             
                               ( 
                               p 
                               ) 
                             
                           
                           · 
                           
                             L 
                             G 
                           
                         
                         100 
                       
                       . 
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   15 
                 
               
             
           
         
       
     
         [0114]    Then, at block  520 , the algorithm verifies if G′(p) is greater than 255 (the maximum intensity value), if so then the algorithm proceeds to block  522  where it sets G′(p) to 255, if not, the algorithm proceeds to block  524  where it verifies if G′(p) is lower than 0 (the minimum intensity value), if so then the algorithm proceeds to block  526  where it sets G′(p) to 0. 
         [0115]    At block  528 , the new value of the blue component intensity value of pixel p, B′(p), is computed using the following equation: 
         [0000]    
       
         
           
             
               
                 
                   
                     
                       B 
                       ′ 
                     
                      
                     
                       ( 
                       p 
                       ) 
                     
                   
                   = 
                   
                     
                       B 
                        
                       
                         ( 
                         p 
                         ) 
                       
                     
                     + 
                     
                       
                         
                           
                             B 
                              
                             
                               ( 
                               p 
                               ) 
                             
                           
                           · 
                           
                             L 
                             B 
                           
                         
                         100 
                       
                       . 
                     
                   
                 
               
               
                 
                   Equation 
                    
                   
                       
                   
                    
                   16 
                 
               
             
           
         
       
     
         [0116]    Then, at block  530 , the algorithm verifies if B′(p) is greater than 255 (the maximum intensity value), if so then the algorithm proceeds to block  532  where it sets B′(p) to 255, if not, the algorithm proceeds to block  534  where it verifies if B′(p) is lower than 0 (the minimum intensity value), if so then the algorithm proceeds to block  536  where it sets G′(p) to 0. 
         [0117]    Then, at block  538 , the algorithm verifies if there are any remaining pixels that have not yet been selected, if so it returns to block  504 , if not is exits at block  540 . 
       Filter Combinations 
       [0118]    As mentioned previously, the various filters may be used individually or in combination. For example,  FIG. 8  illustrates the combination of the edge detect filter with the inverse filter while  FIG. 11  illustrates the combination of the custom filter with the inverse filter. 
       Analysis 
       [0119]    In the illustrative embodiment described herein, the surface analysis method is used in the context of the diagnostic of postural abnormalities in the structure of the human body. The patient&#39;s postural evaluation is based on the detection of light reflection pattern changes on the surface of his or her skin. Those changes are influenced by the position of the patient&#39;s different body segments compared to each other and by muscle mass and/or tension differences. 
         [0120]    Referring to  FIG. 13 , there is shown a treated image  30  of the back of a patient after the application of the custom filter with levels “L R ”, “L G ” and “L B ” of 255 followed by the inverse filter. It may be seen that the light reflection patterns on the left side of the patient, more particularly in areas  32   a ,  34   a  and  36   a , differ from those on the right side, that is areas  32   b ,  34   b  and  36   b . It may be observed that there is less light reflected off the right scapula area  32   b  compared to the left scapula area  32   a . From this it may be deduced that the right scapula area  32   b  is further away from the camera, indicating a possible postural problem. The treated image  30  also permits the identification of abnormalities of the underlying muscle structure on the right side of the patient, by comparing lines  35   a  and  35   b.    
         [0121]    Referring now to  FIGS. 14 and 15 , there is shown an untreated digital image  40  of a patient ( FIG. 14 ) and the resulting treated image  50  ( FIG. 15 ) after the application of the custom filter with levels “L R ”, “L G ” and “L B ” of 255 followed by the inverse filter. Referring to  FIG. 14 , when observing the right and left shoulder areas,  42   a  and  42   b , respectively, and the right and left upper leg areas,  44   a  and  44   b , respectively, no obvious abnormalities or asymmetries may be easily observed. Referring now to  FIG. 15 , the treated image  50  now shows clear abnormalities and asymmetries in the same corresponding areas, namely right and left shoulders  52   a ,  52   b  and right and left upper legs  54   a ,  54   b , which may help a practitioner in establishing a diagnostic. 
         [0122]    An example of the application of the custom filter, with levels “L R ”, “L G ” and “L B ” of 255, followed by the inverse filter to a digital image of a patient for the diagnostic of a physiological condition is illustrated in  FIGS. 16 to 19 .  FIGS. 16 and 17  show front views of the lower limbs of two different patients while  FIGS. 18 and 19  respectively show back views of the lower limbs of the same patients. 
         [0123]    Referring to  FIG. 16 , it may be seen that the treated image  60  shows signs of eversion of the lower limbs while the treated image  70  of  FIG. 17  shows normal lower limbs. This may be deduced by various factors, such as, for example, observing that the calf  62  of treated image  60  is less illuminated and the reflection less uniform than that the calf  72  of treated image  70 , which is an indicator of the presence of tibial rotation. 
         [0124]    Another sign of eversion may be seen by examining the ankle regions  64  and  74 , and observing that in treated image  60  the intern malleoli and the navicular bone, illustrated by line  65 , are medially positioned compared to normal, which is illustrated by line  75  on treated image  70 . A further sign of eversion may be seen by examining the foot region  66  of treated image  60  and tracing a line  67  in the center of the brightest portion of the light reflection, indicating the direction of the foot&#39;s center of gravity. As it may be observed, line  67  is at an angle with the vertical, this is an indication that the foot&#39;s center of gravity is not centered. Conversely, examining the foot region  76  of treated image  70  and tracing a line  77  in the center of the brightest portion of the light reflection, it may be observed that line  77  is vertical, indicating that the foot&#39;s center of gravity is in the middle of the foot and thus normal. 
         [0125]    Referring now to  FIG. 18 , it may be seen that the treated image  80  also shows signs of eversion of the lower limbs while the treated image  90  of  FIG. 19  shows normal lower limbs. An indication of eversion may be seen by examining the heel region  82  of treated image  80  and tracing a line  83  in the center of the brightest portion of the light reflection, indicating the alignment of the Achilles tendon. As it may be observed, line  83  is at an angle with the vertical, this is an indication that the Achilles tendon is inclined. Conversely, examining the heel region  92  of treated image  90  and tracing a line  93  in the center of the brightest portion of the light reflection, it may be observed that line  93  is vertical, indicating that the Achilles tendon is straight and thus normal. 
         [0126]    Treated images such as those shown above may be taken before each treatment given to a patient in order to observe the progress of the treatment and, if necessary, readjust it. 
         [0127]    It is to be understood that a physician or other skilled professional may use other reference structures highlighted by the treated image in order to help him or her establish a diagnostic as well as compute values such as the hallux abductus angle or the Q angle which commonly require and X-ray image of the patient. It is also to be understood that other body parts or regions may be examined such as, for example, the underfoot in order to analyze the arch of the foot. It may be further understood that the above described operations may be automated using, for example, an algorithm to identify the highlighted structures and compute values such as the hallux abductus angle or the Q angle. 
         [0128]    Although the present invention has been described by way of a non-restrictive illustrative embodiment and examples thereof, it should be noted that it will be apparent to persons skilled in the art that modifications may be applied to the present illustrative embodiment without departing from the scope of the present invention. It is also to be understood that the present invention may be used for the detection of abnormalities in other types of surfaces such as, for example, vehicle bodywork or the surfaces of high precision metal components.