Ignore:
Timestamp:
Nov 29, 2003, 8:35:07 PM (19 years ago)
Author:
Sam Hocevar
Message:
  • src/caca.c src/caca.h: + Added caca_get_dithering_name().
  • src/bitmap.c: + Created a new dithering method with an 8x8 ordered matrix. + Replaced the char list with a string for better readability. + Dithering functions now return a value between 0 and 255.
  • examples/demo.c examples/view.c: + Adapted to use caca_get_dithering_name().
File:
1 edited

Legend:

Unmodified
Added
Removed
  • libcaca/trunk/src/caca.h

    r226 r235  
    8282};
    8383
     84const char *caca_get_color_name(enum caca_color);
     85
    8486/**
    8587 * The dithering modes to be used with caca_set_dithering().
     
    8789enum caca_dithering
    8890{
    89     CACA_DITHER_NONE,
    90     CACA_DITHER_ORDERED,
    91     CACA_DITHER_RANDOM
    92 };
     91    CACA_DITHERING_NONE = 0,
     92    CACA_DITHERING_ORDERED4 = 1,
     93    CACA_DITHERING_ORDERED8 = 2,
     94    CACA_DITHERING_RANDOM = 3
     95};
     96
     97const char *caca_get_dithering_name(enum caca_dithering);
     98
     99/* Backwards compatibility */
     100#define CACA_DITHER_NONE    CACA_DITHERING_NONE
     101#define CACA_DITHER_ORDERED CACA_DITHERING_ORDERED8
     102#define CACA_DITHER_RANDOM  CACA_DITHERING_RANDOM
    93103
    94104/**
     
    139149unsigned int caca_get_width(void);
    140150unsigned int caca_get_height(void);
    141 const char *caca_get_color_name(unsigned int);
    142151void caca_refresh(void);
    143152void caca_end(void);
Note: See TracChangeset for help on using the changeset viewer.