2011-11-16 22:17:37 +00:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2011-2011 Gregory hainaut
|
|
|
|
* Copyright (C) 2007-2009 Gabest
|
|
|
|
*
|
|
|
|
* This Program 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; either version 2, or (at your option)
|
|
|
|
* any later version.
|
|
|
|
*
|
|
|
|
* This Program 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. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
* along with GNU Make; see the file COPYING. If not, write to
|
2012-09-09 18:16:11 +00:00
|
|
|
* the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA USA.
|
2011-11-16 22:17:37 +00:00
|
|
|
* http://www.gnu.org/copyleft/gpl.html
|
|
|
|
*
|
|
|
|
*/
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "GSRendererHW.h"
|
|
|
|
|
|
|
|
#include "GSRenderer.h"
|
|
|
|
#include "GSTextureCacheOGL.h"
|
|
|
|
#include "GSVertexHW.h"
|
|
|
|
|
2012-01-15 17:25:49 +00:00
|
|
|
class GSRendererOGL : public GSRendererHW
|
2011-11-16 22:17:37 +00:00
|
|
|
{
|
|
|
|
private:
|
2011-12-19 21:03:23 +00:00
|
|
|
GSVector2 m_pixelcenter;
|
2015-06-03 07:56:07 +00:00
|
|
|
int m_accurate_blend;
|
2015-05-08 08:40:43 +00:00
|
|
|
bool m_accurate_date;
|
2015-05-19 22:51:37 +00:00
|
|
|
bool m_accurate_colclip;
|
2015-05-08 08:40:43 +00:00
|
|
|
|
2011-12-19 21:03:23 +00:00
|
|
|
bool UserHacks_AlphaHack;
|
2012-08-15 10:14:13 +00:00
|
|
|
bool UserHacks_AlphaStencil;
|
2013-02-23 15:35:56 +00:00
|
|
|
unsigned int UserHacks_TCOffset;
|
|
|
|
float UserHacks_TCO_x, UserHacks_TCO_y;
|
2011-11-16 22:17:37 +00:00
|
|
|
|
|
|
|
protected:
|
2013-05-27 16:53:38 +00:00
|
|
|
void EmulateGS();
|
2012-02-11 10:22:02 +00:00
|
|
|
void SetupIA();
|
2012-01-15 17:25:49 +00:00
|
|
|
|
2011-11-16 22:17:37 +00:00
|
|
|
public:
|
|
|
|
GSRendererOGL();
|
2011-12-19 21:03:23 +00:00
|
|
|
virtual ~GSRendererOGL() {};
|
2011-11-16 22:17:37 +00:00
|
|
|
|
|
|
|
bool CreateDevice(GSDevice* dev);
|
2011-12-19 21:03:23 +00:00
|
|
|
|
2012-01-15 17:25:49 +00:00
|
|
|
void DrawPrims(GSTexture* rt, GSTexture* ds, GSTextureCache::Source* tex);
|
2015-04-24 18:53:59 +00:00
|
|
|
|
|
|
|
bool PrimitiveOverlap();
|
2015-05-09 13:01:39 +00:00
|
|
|
|
|
|
|
void SendDraw(bool require_barrier);
|
2011-11-16 22:17:37 +00:00
|
|
|
};
|