Editing User:Level zero/GSOC13/api

From BRL-CAD

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 4: Line 4:
 
'''Comments'''
 
'''Comments'''
 
*Removes a rectangular portion of a potentially huge image.
 
*Removes a rectangular portion of a potentially huge image.
*''orig'', is the point that corresponds to  Bottom left corner to extract the image from
+
*orig, is the point that corresponds to  Bottom left corner to extract the image from
*''area'' corresponds to the total number of pixels in the new map.
+
*area corresponds to the total number of pixels in the new map.
*''img_out'' is the output image.
+
*img_out is the output image.
  
     int
+
     void
 
     icv_rect(const icv_image_t *img,
 
     icv_rect(const icv_image_t *img,
 
             const icv_point_t *area,
 
             const icv_point_t *area,
Line 19: Line 19:
 
'''Comments'''
 
'''Comments'''
 
*Crops file with arbitrary points
 
*Crops file with arbitrary points
*''p1'', ''p2'', ''p3'', ''p4'' are left lower, right lower, left upper and right upper points respectively.
+
*p1, p2, p3, p4 are left lower, right lower, left upper and right upper points respectively.
*''img_out'' is the output image.
+
*img_out is the output image.
  
     int
+
     void
 
     icv_crop(const icv_image_t *img,
 
     icv_crop(const icv_image_t *img,
 
             const icv_point_t *p1,
 
             const icv_point_t *p1,
Line 33: Line 33:
 
==Operations (Group2)==
 
==Operations (Group2)==
  
'''for bwdiff, pixdiff'''
+
'''for bwdiff, pixdif'''
  
 
'''Comments'''
 
'''Comments'''
*Performs arithmetic operations between the pixels of two images.
+
*Performs airthmetic operations between the pixels of two images.
*''img_1'' and ''img_2'' are two input images.
+
*img_1 and img_2 are two input images.
*''opr'' corresponds to the operation information.
+
*img_out is the output image.
*''img_out'' is the output image.
 
  
 
+
     void
     int
 
 
     icv_airth2(const icv_image_t* img1,
 
     icv_airth2(const icv_image_t* img1,
 
               const icv_image_t* img2,
 
               const icv_image_t* img2,
Line 51: Line 49:
  
 
'''Comments'''
 
'''Comments'''
*Performs arithmetic operations with a value of the pixels of the input image, the resultant value is replaced in the same input image.
+
*Performs airthmetic operations with a value on the pixels of the input image, the resultant array is stored in the same input image.
*''oper'' is the array corresponding to the operations.
+
*orig, is the point that corresponds to  Bottom left corner to extract the image from
*''numop'' is the number of operations.
+
*img_out is the output image.
*''img_out'' is the output image.
 
  
     int
+
     void
     icv_airth1(icv_image_t* img,
+
     icv_airth1(const icv_image_t* img,
 
               const icv_operation_t *oper[],   
 
               const icv_operation_t *oper[],   
 
               const int numop);  
 
               const int numop);  
Line 64: Line 61:
  
 
'''Comments'''
 
'''Comments'''
*''saturation'' is the saturation value  
+
*img is the input image.
*''img_out'' is the output image.
+
*saturation is the saturation value  
 +
*img_out is the output image.
  
     int
+
     void
 
     icv_saturate(const icv_image_t *img,
 
     icv_saturate(const icv_image_t *img,
 
                 const double saturation,
 
                 const double saturation,
Line 76: Line 74:
  
 
'''Comments'''
 
'''Comments'''
*Performs filtering of image using convolution with the kernel.
+
*img is the input image.
*''kernel'' corresponds to kernel used for image filter
+
*kernel is the corresponds to kernel used for image fileter
*''img_out'' is the output image.
+
*img_out is the output image.
  
     int
+
     void
 
     icv_filter(const icv_image_t *img,
 
     icv_filter(const icv_image_t *img,
 
               const icv_kernel_type_t kernel;
 
               const icv_kernel_type_t kernel;
Line 89: Line 87:
  
 
'''Comments'''
 
'''Comments'''
*Finds histogram of the image
+
*img is the input image
*''bin'' is the number of bins for calculating histogram
+
*bin is the number of bins for calculating histogram
*''bin_out1'', ''bin_out2'' and ''bin_out3'' are the pointers for output histograms
+
*bin_out1, bin_out2 and bin_out3 are the pointers for output histograms
 
*For three channel image this is called with all the three output pointers, for bw image this is called with pointers only for first and others are left as NULL
 
*For three channel image this is called with all the three output pointers, for bw image this is called with pointers only for first and others are left as NULL
  
     int
+
     void
 
     icv_hist(const icv_image_t *img,
 
     icv_hist(const icv_image_t *img,
 
             const int bin,
 
             const int bin,
Line 106: Line 104:
 
*Calculates histogram equalization of the image
 
*Calculates histogram equalization of the image
  
     int
+
     void icv_histeq(const icv_image_t *img,
    icv_histeq(const icv_image_t *img,
 
 
                     icv_imgage_file_t *img_out);
 
                     icv_imgage_file_t *img_out);
  
Line 114: Line 111:
  
 
'''Comments'''
 
'''Comments'''
* ''outsize'' is the required output size
+
* outsize is the reqired output size
* ''method'' is the prescribed method     
+
* method is the prescribed method     
  
     int   
+
     void icv_scale(const icv_image_t *img,
    icv_scale(const icv_image_t *img,
 
 
                   const icv_size_t *outsize,
 
                   const icv_size_t *outsize,
 
                   const icv_scale_method_t method,
 
                   const icv_scale_method_t method,
Line 126: Line 122:
  
 
'''Comments'''
 
'''Comments'''
* ''factor'' is shrinking factor.
+
* factor is shrinking factor.
* ''method'' is the prescribed method.
+
* method is the prescribed method.
  
     int
+
     void icv_shrink(const icv_image_t *img,
    icv_shrink(const icv_image_t *img,
 
 
                     icv_image_t *img_out,
 
                     icv_image_t *img_out,
 
                     const int factor,
 
                     const int factor,
Line 144: Line 139:
 
* finds the image statistics  
 
* finds the image statistics  
  
     int
+
     void icv_stat(const icv_image_t *img,
    icv_stat(const icv_image_t *img,
 
 
                   icv_stat_t *stat1,  
 
                   icv_stat_t *stat1,  
 
                   icv_stat_t *stat2,   
 
                   icv_stat_t *stat2,   
Line 152: Line 146:
 
'''for pixcolors'''
 
'''for pixcolors'''
  
     int
+
     void icv_colors(icv_image_t *img)  
    icv_colors(icv_image_t *img)  
 
 
     /* Prints all the colors */     
 
     /* Prints all the colors */     
 
      
 
      
Line 161: Line 154:
  
 
'''Comments'''
 
'''Comments'''
* ''val'' is a pointer to an array of threshold values
+
* val is a pointer to an array of threshold values
* ''num_thresh'' is the number of the threshold values
+
* num_thresh is the number of the threshold values
* ''img_out'' is the output image
+
* img_out is the output image
  
     int
+
     void icv_threshold(const icv_image_t *img,
    icv_threshold(const icv_image_t *img,
 
 
                       icv_image_t *img_out,
 
                       icv_image_t *img_out,
 
                       const unsigned char *val,
 
                       const unsigned char *val,
Line 173: Line 165:
 
'''for pixclump'''
 
'''for pixclump'''
  
     int
+
     void icv_clump()
    icv_clump()
 
 
/* Need Suggestions */
 
/* Need Suggestions */
 
      
 
      
Line 181: Line 172:
  
 
'''Comments'''
 
'''Comments'''
*Interpolates the image two twice its resolution
+
*Iterpolates the image two twice its resolution
  
     int
+
     void icv_interep2x(const icv_image_t *img,
    icv_interep2x(const icv_image_t *img,
 
 
                       icv_image_t *img_out);     
 
                       icv_image_t *img_out);     
  
Line 192: Line 182:
 
*Decimates the image
 
*Decimates the image
  
     int
+
     void icv_halve(const icv_image_t *img,
    icv_halve(const icv_image_t *img,
 
 
                   icv_image_t *img_out);
 
                   icv_image_t *img_out);
  

Please note that all contributions to BRL-CAD may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see BRL-CAD:Copyrights for details). Do not submit copyrighted work without permission!

To edit this page, please answer the question that appears below (more info):

Cancel Editing help (opens in new window)