Ignore:
Timestamp:
Sep 27, 2008, 3:12:46 PM (11 years ago)
Author:
Sam Hocevar
Message:

Starting refactoring to get rid of libcucul. The initial reason for the
split is rendered moot by the plugin system: when enabled, binaries do
not link directly with libX11 or libGL. I hope this is a step towards
more consisteny and clarity.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/caca/driver_vga.c

    r2305 r2821  
    2121#if defined(USE_VGA)
    2222
    23 #include "cucul.h"
    2423#include "caca.h"
    2524#include "caca_internals.h"
     
    7675    /* We don't have much choice */
    7776    dp->resize.allow = 1;
    78     cucul_set_canvas_size(dp->cv, 80, 25);
     77    caca_set_canvas_size(dp->cv, 80, 25);
    7978    dp->resize.allow = 0;
    8079
     
    117116{
    118117    char *screen = (char *)(intptr_t)0x000b8000;
    119     uint32_t const *cvchars = (uint32_t const *)cucul_get_canvas_chars(dp->cv);
    120     uint32_t const *cvattrs = (uint32_t const *)cucul_get_canvas_attrs(dp->cv);
    121     int width = cucul_get_canvas_width(dp->cv);
    122     int height = cucul_get_canvas_height(dp->cv);
     118    uint32_t const *cvchars = (uint32_t const *)caca_get_canvas_chars(dp->cv);
     119    uint32_t const *cvattrs = (uint32_t const *)caca_get_canvas_attrs(dp->cv);
     120    int width = caca_get_canvas_width(dp->cv);
     121    int height = caca_get_canvas_height(dp->cv);
    123122    int n;
    124123
    125124    for(n = height * width; n--; )
    126125    {
    127         char ch = cucul_utf32_to_cp437(*cvchars++);
    128         if(n && *cvchars == CUCUL_MAGIC_FULLWIDTH)
     126        char ch = caca_utf32_to_cp437(*cvchars++);
     127        if(n && *cvchars == CACA_MAGIC_FULLWIDTH)
    129128        {
    130129            *screen++ = '[';
    131             *screen++ = cucul_attr_to_ansi(*cvattrs++);
     130            *screen++ = caca_attr_to_ansi(*cvattrs++);
    132131            ch = ']';
    133132            cvchars++;
     
    135134        }
    136135        *screen++ = ch;
    137         *screen++ = cucul_attr_to_ansi(*cvattrs++);
     136        *screen++ = caca_attr_to_ansi(*cvattrs++);
    138137    }
    139138}
     
    142141{
    143142    /* We know nothing about our window */
    144     dp->resize.w = cucul_get_canvas_width(dp->cv);
    145     dp->resize.h = cucul_get_canvas_height(dp->cv);
     143    dp->resize.w = caca_get_canvas_width(dp->cv);
     144    dp->resize.h = caca_get_canvas_height(dp->cv);
    146145}
    147146
Note: See TracChangeset for help on using the changeset viewer.