Rice GLES2 (from mupen64plus-ae) plugin. Compile but doesn't works well on the OpenPa...
[mupen64plus-pandora.git] / source / gles2rice / src / OGLCombinerTNT2.h
CommitLineData
292f9317 1/*
2Copyright (C) 2003 Rice1964
3
4This program is free software; you can redistribute it and/or
5modify it under the terms of the GNU General Public License
6as published by the Free Software Foundation; either version 2
7of the License, or (at your option) any later version.
8
9This program is distributed in the hope that it will be useful,
10but WITHOUT ANY WARRANTY; without even the implied warranty of
11MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12GNU General Public License for more details.
13
14You should have received a copy of the GNU General Public License
15along with this program; if not, write to the Free Software
16Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17*/
18
19#ifndef _OGL_COMBINER_TNT2_H_
20#define _OGL_COMBINER_TNT2_H_
21
22#include <SDL_opengl.h>
23
24#define GL_SOURCE3_RGB_EXT 0x8583
25#define GL_SOURCE3_ALPHA_EXT 0x858B
26#define GL_OPERAND3_RGB_EXT 0x8593
27#define GL_OPERAND3_ALPHA_EXT 0x859B
28
29#include "OGLExtCombiner.h"
30#include "OGLDecodedMux.h"
31#include "CNvTNTCombiner.h"
32
33//========================================================================
34
35class COGLColorCombinerTNT2 : public COGLColorCombiner4, CNvTNTCombiner
36{
37public:
38 bool Initialize(void);
39protected:
40 friend class OGLDeviceBuilder;
41
42 void InitCombinerCycle12(void);
43
44 virtual void GenerateCombinerSetting(int);
45 virtual void GenerateCombinerSettingConstants(int);
46
47 COGLColorCombinerTNT2(CRender *pRender);
48 ~COGLColorCombinerTNT2() {} ;
49
50 bool m_bTNT2Supported; // Is this NV OGL extension combiner supported by the video card driver?
51
52#ifdef DEBUGGER
53 void DisplaySimpleMuxString(void);
54#endif
55
56private:
57 virtual GLint MapRGBArgs(uint8 arg);
58 static GLint MapRGBArgFlags(uint8 arg);
59 virtual GLint MapAlphaArgs(uint8 arg);
60 static GLint MapAlphaArgFlags(uint8 arg);
61 static GLint RGBArgsMap[];
62 static const char* GetOpStr(GLenum op);
63
64};
65
66
67
68#endif
69