crackrec              package:crackrec              R Documentation

_c_r_a_c_k_r_e_c

_D_e_s_c_r_i_p_t_i_o_n:

     Finds cracks (darker areas) in an image.

_U_s_a_g_e:

     crackrec(x, threshold=NULL, alpha=1, beta=1, size=0)

_A_r_g_u_m_e_n_t_s:

       x: matrix representation of an image, which can be obtained by
          the function 'rbmp'. 

threshold: threshold value. The default value is
          threshold='min'(140,'mean'(x)*4/5).

   alpha: parameter for weight function with values in [0, 1]. This
          parameter is optional. The default value is alpha=1.

    beta: parameter for weight function with values in [0, 1]. This
          parameter is optional. The default value is beta=1.

    size: only crackclusters greater than size=n will be considered.
          The default value is size=0, which means that every
          crackcluster is considered.

_D_e_t_a_i_l_s:

     Here each pixel of the image with grey scale value less than the
     threshold value are treated as vertices of a graph. If vertice u
     is a direct neighbor of vertice v they are connected by an
     undirected edge with weight dist*(1 +
     alpha*(greyValue_u+greyValue_v) +
     beta*abs(greyValue_u-greyValue_v)). Where dist is equal to 1 if u
     and v coincide in one component and sqrt(2) else, alpha and beta
     as described above and greyValue_u means the grey scale value of
     u. Respectively for vertice v.

_V_a_l_u_e:

     a list containing:

  cracks: matrix containing crack length, crack size, start and
          endpoint of cracks

crackpaths: list of crack paths

crackclusters: list of connected components (maximal connected
          subgraphs)

_A_u_t_h_o_r(_s):

     Arne Mueller, Alexander Stepper stepper@mathematik.uni-kassel.de

_S_e_e _A_l_s_o:

     'rbmp', 'threshold.msi', 'shadow.remove', 'medianfilter',
     'crackplot'

_E_x_a_m_p_l_e_s:

     ## Not run: 
     x<-rbmp("image.bmp")
     crackrec(x, threshold=123, alpha=0, beta=0)
     ## End(Not run)

