Ignore:
Timestamp:
Apr 15, 2006, 5:23:13 PM (15 years ago)
Author:
Jean-Yves Lamoureux
Message:
  • Fixed sprite functions (it compiles now) (Y'a des connards qui font ce qu'ils veulent, mais qui finissent pas)
Location:
libcaca/trunk/test
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/test/demo.c

    r734 r774  
    5656
    5757    /* Initialize data */
    58     sprite = cucul_load_sprite(qq, DATADIR "/caca.txt");
     58    sprite = cucul_load_sprite(DATADIR "/caca.txt");
    5959    if(!sprite)
    60         sprite = cucul_load_sprite(qq, "caca.txt");
     60        sprite = cucul_load_sprite("caca.txt");
    6161    if(!sprite)
    62         sprite = cucul_load_sprite(qq, "examples/caca.txt");
     62        sprite = cucul_load_sprite("examples/caca.txt");
    6363
    6464    /* Disable cursor */
  • libcaca/trunk/test/spritedit.c

    r752 r774  
    4545        return 1;
    4646
    47     sprite = cucul_load_sprite(qq, argv[1]);
     47    sprite = cucul_load_sprite(argv[1]);
    4848
    4949    if(!sprite)
     
    7676                break;
    7777            case '+':
    78                 if(frame < cucul_get_sprite_frames(qq, sprite) - 1)
     78                if(frame < cucul_get_sprite_frames(sprite) - 1)
    7979                    frame++;
    8080                break;
     
    8787        if(play) {
    8888            if(!delay) {
    89                 if(frame < cucul_get_sprite_frames(qq, sprite) - 1) {
     89                if(frame < cucul_get_sprite_frames(sprite) - 1) {
    9090                    frame++;
    9191                }
     
    110110        sprintf(buf, "sprite `%s'", argv[1]);
    111111        cucul_putstr(qq, 3, 2, buf);
    112         sprintf(buf, "frame %i/%i", frame, cucul_get_sprite_frames(qq, sprite) - 1);
     112        sprintf(buf, "frame %i/%i", frame, cucul_get_sprite_frames(sprite) - 1);
    113113        cucul_putstr(qq, 3, 3, buf);
    114114
     
    119119
    120120        /* Boxed sprite */
    121         xa = -1 - cucul_get_sprite_dx(qq, sprite, frame);
    122         ya = -1 - cucul_get_sprite_dy(qq, sprite, frame);
    123         xb = xa + 1 + cucul_get_sprite_width(qq, sprite, frame);
    124         yb = ya + 1 + cucul_get_sprite_height(qq, sprite, frame);
     121        xa = -1 - cucul_get_sprite_dx(sprite, frame);
     122        ya = -1 - cucul_get_sprite_dy(sprite, frame);
     123        xb = xa + 1 + cucul_get_sprite_width(sprite, frame);
     124        yb = ya + 1 + cucul_get_sprite_height(sprite, frame);
    125125        cucul_set_color(qq, CUCUL_COLOR_BLACK, CUCUL_COLOR_BLACK);
    126126        cucul_fill_box(qq, 57 + xa, 10 + ya, 57 + xb, 10 + yb, " ");
Note: See TracChangeset for help on using the changeset viewer.