edges                package:adimpro                R Documentation

_I_m_a_g_e _P_r_o_c_e_s_s_i_n_g

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

     Edge detection using Laplacian, Sobel, or Robert Cross filter.

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

     edges(img, type = "Laplacian", ltype=1)

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

     img: an object of class "adimpro". 

    type: type of edges detection filter. "Laplacian" (default),
          "Sobel" , or "Robertcross". 

   ltype: type of laplacian filter. 1,2,3, or 4 

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

     This function applies the  Laplacian, Sobel, or Robert Cross
     filter to the input image 'img'. The filter is applied to each
     color channel separately. 'ltype' determines the different
     matrices for Laplacian filter used in the literature. 'ltype == 1'
     will use:

     'conv <- matrix(c(-1,-1,-1,-1,-1, -1,-1,-1,-1,-1, -1,-1,24,-1,-1,
     -1,-1,-1,-1,-1, -1,-1,-1,-1,-1),5,5)'

     'ltype == 2' will use:

     'conv <- matrix(c(0,-1,0,-1,4,-1,0,-1,0), 3, 3)'

     'ltype == 3' will use:

     'conv <- matrix(c(-1,-1,-1,-1,8,-1,-1,-1,-1), 3, 3)'

     'ltype == 4' (default) will use:

     'conv <- matrix(c(1,-2,1,-2,4,-2,1,-2,1), 3, 3)'

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

     Array containing the values for the edge detector in each pixel
     and  color channel.

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

     Karsten Tabelow tabelow@wias-berlin.de, Joerg Polzehl
     polzehl@wias-berlin.de

_R_e_f_e_r_e_n_c_e_s:

     Gonzalez, R.C., and Woods, R.E. (2002). Digital Image Processing.
     Prentice Hall.

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

     img <- read.image(system.file("img/wias.ppm",package="adimpro"))
     X11(height=5,width=10)
     par(mfrow=c(1,2))
     show.image(img,main="Original Image")
     img.edge <- edges(img)
     show.image(img.edge,main="Edges in green channel",channel=2)

