Ignore:
Timestamp:
08/14/08 20:34:44 (5 years ago)
Author:
sam
Message:
  • blur.c: add an argument to the gaussian convolution to specify an angle. Of course since the kernel is no longer separable, it becomes awfully slow with large images. Here is a tileable brushed metal texture: # pipi pipi:random512x512 --wrap --blur 20x0r25 -o image.png
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libpipi/trunk/pipi/context.c

    r2713 r2715  
    119119        char const *arg; 
    120120        va_list ap; 
    121         double w, h; 
     121        double w, h, a = 0.0; 
    122122 
    123123        if(ctx->nimages < 1) 
     
    129129        arg = strchr(arg, 'x'); 
    130130        if(arg) 
     131        { 
    131132            h = atof(arg + 1); 
     133            arg = strchr(arg, 'r'); 
     134            if(arg) 
     135                a = atof(arg + 1); 
     136        } 
    132137        src = ctx->images[ctx->nimages - 1]; 
    133         dst = pipi_gaussian_blur_ext(src, w, h, 0.0, 0.0); 
     138        dst = pipi_gaussian_blur_ext(src, w, h, a, 0.0, 0.0); 
    134139        if(dst == NULL) 
    135140            return -1; 
Note: See TracChangeset for help on using the changeset viewer.