Ignore:
Timestamp:
Jul 9, 2009, 1:38:39 AM (11 years ago)
Author:
Sam Hocevar
Message:

Implement pipi_rotate(). Currently nearest-neighbour only, supersample if
you need more precision.

File:
1 edited

Legend:

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

    r3418 r3546  
    7272        { "rotate180", 0 },
    7373        { "rotate270", 0 },
     74        { "rotate", 1 },
    7475        { "invert", 0 },
    7576        { "threshold", 1 },
     
    351352    }
    352353    else if(!strcmp(cmd, "brightness") || !strcmp(cmd, "contrast")
    353              || !strcmp(cmd, "threshold"))
     354             || !strcmp(cmd, "threshold") || !strcmp(cmd, "rotate"))
    354355    {
    355356        pipi_image_t *src, *dst = NULL;
     
    369370            case 'b': dst = pipi_brightness(src, val); break;
    370371            case 'c': dst = pipi_contrast(src, val); break;
     372            case 'r': dst = pipi_rotate(src, val); break;
    371373            case 't': dst = pipi_threshold(src, val); break;
    372374        }
Note: See TracChangeset for help on using the changeset viewer.