4 * This file is part of OpenTTD.
5 * OpenTTD is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, version 2.
6 * OpenTTD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
7 * See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with OpenTTD. If not, see <http://www.gnu.org/licenses/>.
10 /** @file null.hpp The blitter that doesn't blit. */
12 #ifndef BLITTER_NULL_HPP
13 #define BLITTER_NULL_HPP
17 /** Blitter that does nothing. */
18 class Blitter_Null
: public Blitter
{
20 static const char name
[]; ///< Name of the blitter.
21 static const char desc
[]; ///< Description of the blitter.
23 /* virtual */ uint8
GetScreenDepth() { return 0; }
24 /* virtual */ void Draw(Blitter::BlitterParams
*bp
, BlitterMode mode
, ZoomLevel zoom
) {};
25 /* virtual */ void DrawColourMappingRect(void *dst
, int width
, int height
, PaletteID pal
) {};
26 /* virtual */ Sprite
*Encode (const SpriteLoader::Sprite
*sprite
, bool is_font
, AllocatorProc
*allocator
);
27 /* virtual */ void *MoveTo(void *video
, int x
, int y
) { return NULL
; };
28 /* virtual */ void SetPixel(void *video
, int x
, int y
, uint8 colour
) {};
29 /* virtual */ void DrawRect(void *video
, int width
, int height
, uint8 colour
) {};
30 /* virtual */ void DrawLine(void *video
, int x
, int y
, int x2
, int y2
, int screen_width
, int screen_height
, uint8 colour
, int width
, int dash
) {};
31 /* virtual */ void CopyFromBuffer(void *video
, const void *src
, int width
, int height
) {};
32 /* virtual */ void CopyToBuffer(const void *video
, void *dst
, int width
, int height
) {};
33 /* virtual */ void CopyImageToBuffer(const void *video
, void *dst
, int width
, int height
, int dst_pitch
) {};
34 /* virtual */ void ScrollBuffer(void *video
, int &left
, int &top
, int &width
, int &height
, int scroll_x
, int scroll_y
) {};
35 /* virtual */ int BufferSize(int width
, int height
) { return 0; };
36 /* virtual */ void PaletteAnimate(const Palette
&palette
) { };
37 /* virtual */ Blitter::PaletteAnimation
UsePaletteAnimation() { return Blitter::PALETTE_ANIMATION_NONE
; };
39 /* virtual */ int GetBytesPerPixel() { return 0; }
42 #endif /* BLITTER_NULL_HPP */