00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013 #ifndef header_blit_transparent_rle
00014 #define header_blit_transparent_rle
00015
00016 #include "blitters.h"
00017
00018 class CL_SurfaceProvider;
00019
00020 class CL_Blit_Transparent_RLE :
00021 public CL_Blit_NoClip
00022 {
00023 protected:
00024 int width, height, no_sprs;
00025 int bytes_per_pixel;
00026 unsigned char **rle_lines;
00027
00028 enum
00029 {
00030 cmd_skip,
00031 cmd_copy,
00032 cmd_alpha,
00033 cmd_end
00034 };
00035
00036 int calc_rle_size(unsigned char *alpha_line);
00037
00038 virtual unsigned char *make_rle_line(
00039 unsigned char *src_line,
00040 unsigned char *alpha_line) = 0;
00041
00042 virtual void blt_line(
00043 unsigned char *s,
00044 unsigned char *d) = 0;
00045
00046 public:
00047
00048 CL_Blit_Transparent_RLE(
00049 CL_SurfaceProvider *provider,
00050 int bytes_per_pixel);
00051
00052 virtual ~CL_Blit_Transparent_RLE();
00053
00054 virtual void blt_noclip(
00055 CL_Target *dest_surf,
00056 int x,
00057 int y,
00058 int spr_no);
00059 };
00060
00061 #endif