# 8bpp_optimized.hpp

Go to the documentation of this file.

    00001 /* $Id: 8bpp_optimized.hpp 13551 2008-06-17 17:25:22Z smatz $ */
    00002
    00005 #ifndef BLITTER_8BPP_OPTIMIZED_HPP
    00006 #define BLITTER_8BPP_OPTIMIZED_HPP
    00007
    00008 #include "8bpp_base.hpp"
    00009 #include "factory.hpp"
    00010
    00011 class Blitter_8bppOptimized : public Blitter_8bppBase {
    00012 public:
    00013   struct SpriteData {
    00014     uint32 offset[ZOOM_LVL_COUNT];
    00015     byte data[VARARRAY_SIZE];
    00016   };
    00017
    00018   /* virtual */ void Draw(Blitter::BlitterParams *bp, BlitterMode mode, ZoomLevel zoom);
    00019   /* virtual */ Sprite *Encode(SpriteLoader::Sprite *sprite, Blitter::AllocatorProc *allocator);
    00020
    00021   /* virtual */ const char *GetName() { return "8bpp-optimized"; }
    00022 };
    00023
    00024 class FBlitter_8bppOptimized: public BlitterFactory<FBlitter_8bppOptimized> {
    00025 public:
    00026   /* virtual */ const char *GetName() { return "8bpp-optimized"; }
    00027   /* virtual */ const char *GetDescription() { return "8bpp Optimized Blitter (compression + all-ZoomLevel cache)"; }
    00028   /* virtual */ Blitter *CreateInstance() { return new Blitter_8bppOptimized(); }
    00029 };
    00030
    00031 #endif /* BLITTER_8BPP_OPTIMIZED_HPP */