ResidualVM logo ResidualVM website - Forums - Contact us BuildBot - Doxygen - Wiki curved edge

scaler.h

Go to the documentation of this file.
00001 /* ScummVM - Graphic Adventure Engine
00002  *
00003  * ScummVM is the legal property of its developers, whose names
00004  * are too numerous to list here. Please refer to the COPYRIGHT
00005  * file distributed with this source distribution.
00006  *
00007  * This program is free software; you can redistribute it and/or
00008  * modify it under the terms of the GNU General Public License
00009  * as published by the Free Software Foundation; either version 2
00010  * of the License, or (at your option) any later version.
00011  *
00012  * This program is distributed in the hope that it will be useful,
00013  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015  * GNU General Public License for more details.
00016  *
00017  * You should have received a copy of the GNU General Public License
00018  * along with this program; if not, write to the Free Software
00019  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
00020  *
00021  */
00022 
00023 #ifndef GRAPHICS_SCALER_H
00024 #define GRAPHICS_SCALER_H
00025 
00026 #include "common/scummsys.h"
00027 #include "graphics/surface.h"
00028 
00029 extern void InitScalers(uint32 BitFormat);
00030 extern void DestroyScalers();
00031 
00032 typedef void ScalerProc(const uint8 *srcPtr, uint32 srcPitch,
00033                             uint8 *dstPtr, uint32 dstPitch, int width, int height);
00034 
00035 #define DECLARE_SCALER(x)   \
00036     extern void x(const uint8 *srcPtr, uint32 srcPitch, uint8 *dstPtr, \
00037                     uint32 dstPitch, int width, int height)
00038 
00039 
00040 DECLARE_SCALER(Normal1x);
00041 
00042 #ifdef USE_SCALERS
00043 
00044 DECLARE_SCALER(Normal2x);
00045 DECLARE_SCALER(Normal3x);
00046 DECLARE_SCALER(Normal1o5x);
00047 
00048 DECLARE_SCALER(_2xSaI);
00049 DECLARE_SCALER(Super2xSaI);
00050 DECLARE_SCALER(SuperEagle);
00051 
00052 DECLARE_SCALER(AdvMame2x);
00053 DECLARE_SCALER(AdvMame3x);
00054 
00055 DECLARE_SCALER(TV2x);
00056 DECLARE_SCALER(DotMatrix);
00057 
00058 #ifdef USE_HQ_SCALERS
00059 DECLARE_SCALER(HQ2x);
00060 DECLARE_SCALER(HQ3x);
00061 #endif
00062 
00063 #endif // #ifdef USE_SCALERS
00064 
00065 // creates a 160x100 thumbnail for 320x200 games
00066 // and 160x120 thumbnail for 320x240 and 640x480 games
00067 // only 565 mode
00068 enum {
00069     kThumbnailWidth = 160,
00070     kThumbnailHeight1 = 100,
00071     kThumbnailHeight2 = 120
00072 };
00073 
00080 //ResidualVM specific:
00081 inline bool createThumbnailFromScreen(Graphics::Surface *surf) { return true; }
00082 
00092 extern bool createThumbnail(Graphics::Surface *surf, const uint8 *pixels, int w, int h, const uint8 *palette);
00093 
00094 #endif


Generated on Sat Jul 13 2019 05:01:15 for ResidualVM by doxygen 1.7.1
curved edge   curved edge