Show framebuffertarget.h syntax highlighted
/***************************************************************************
framebuffertarget.h - Frame buffer render target
-------------------
begin : Fri Apr 25 2003
copyright : (C) 2003 by Reality Rift Studios
email : mattias@realityrift.com
***************************************************************************
The contents of this file are subject to the Mozilla Public License Version
1.1 (the "License"); you may not use this file except in compliance with
the License. You may obtain a copy of the License at
http://www.mozilla.org/MPL/
Software distributed under the License is distributed on an "AS IS" basis,
WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
for the specific language governing rights and limitations under the
License.
The Original Code is the NeoEngine, NeoDevOpenGL, framebuffertarget.h
The Initial Developer of the Original Code is Mattias Jansson.
Portions created by Mattias Jansson are Copyright (C) 2003
Reality Rift Studios. All Rights Reserved.
***************************************************************************/
#ifndef __NEOGLFRAMEBUFFERTARGET_H
#define __NEOGLFRAMEBUFFERTARGET_H
/**
* \file framebuffertarget.h
* Frame buffer render target
*/
#include "device.h"
#include "rendertarget.h"
namespace NeoOGL
{
/**
* \brief Frame buffer render target
* \author Mattias Jansson (mattias@realityrift.com)
*/
class FrameBufferRenderTarget : public RenderTarget
{
public:
#ifdef WIN32
/*! Window device context */
HDC m_hDC;
/*! OpenGL render context handle */
HGLRC m_hRC;
#elif __APPLE__
/*! OpenGL context for AGL (windowed) rendering */
AGLContext m_aglContext;
/*! Pixel format for AGL (windowed) rendering */
AGLPixelFormat m_aglPixelFormat;
/*! Pixel format for CGL (fullscreen) rendering */
CGLPixelFormatObj m_cglPixelFormat;
/*! OpenGL context for CGL (fullscreen) rendering */
CGLContextObj m_cglContext;
#elif POSIX
/*! GLX Context */
GLXContext m_glxContext;
#endif
/**
* Initialize data
* \param pkDevice Device
*/
FrameBufferRenderTarget( Device *pkDevice );
/**
* Deallocate memory
*/
virtual ~FrameBufferRenderTarget();
/**
* Flip buffers
*/
virtual void Flip();
/**
* \return Render target identifier
*/
virtual unsigned int GetID() { return NeoEngine::RenderDevice::FRAMEBUFFER; }
/**
* Activate
*/
inline virtual void Activate();
/**
* Deactivate
*/
inline virtual void Deactivate();
virtual int GetWidth();
virtual int GetHeight();
};
}; // namespace NeoOGL
#endif
See more files for this project here