Ignore:
Timestamp:
Apr 18, 2006, 5:11:25 PM (14 years ago)
Author:
Sam Hocevar
Message:
  • Renamed caca_t into caca_display_t.
  • Renamed canvas handle variables from "c" to "cv". Eh ouais mon gros.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/cucul/sprite.c

    r810 r811  
    247247 *         frame does not exist, nothing is displayed.
    248248 *
    249  *  \param c A libcucul canvas
     249 *  \param cv A libcucul canvas
    250250 *  \param x The X coordinate.
    251251 *  \param y The Y coordinate.
     
    254254 *  \return void
    255255 */
    256 void cucul_draw_sprite(cucul_canvas_t *c, int x, int y, cucul_sprite_t const *sprite, int f)
     256void cucul_draw_sprite(cucul_canvas_t *cv, int x, int y,
     257                       cucul_sprite_t const *sprite, int f)
    257258{
    258259    int i, j;
     
    268269    frame = &sprite->frames[f];
    269270
    270     oldfg = c->fgcolor;
    271     oldbg = c->bgcolor;
     271    oldfg = cv->fgcolor;
     272    oldbg = cv->bgcolor;
    272273
    273274    for(j = 0; j < frame->h; j++)
     
    278279            if(col >= 0)
    279280            {
    280                 cucul_set_color(c, col, CUCUL_COLOR_BLACK);
    281                 cucul_putchar(c, x + i - frame->dx, y + j - frame->dy,
     281                cucul_set_color(cv, col, CUCUL_COLOR_BLACK);
     282                cucul_putchar(cv, x + i - frame->dx, y + j - frame->dy,
    282283                              frame->chars[frame->w * j + i]);
    283284            }
     
    285286    }
    286287
    287     cucul_set_color(c, oldfg, oldbg);
     288    cucul_set_color(cv, oldfg, oldbg);
    288289}
    289290
Note: See TracChangeset for help on using the changeset viewer.