1
0
mirror of https://github.com/Halofreak1990/XFXFramework synced 2024-12-26 13:49:34 +01:00
XFXFramework/include/Graphics/RenderTarget2D.h
Tom Lint 81af66d336 Code Audit
Replaced all copyright symbols with (c) to improve cross-platform
reading
Added classes to XFX::Audio namespace
Added and updated classes in XFX::Graphics namespace
Updated event function signature
Replaced const char* ToString() with const String& ToString()
2013-06-02 14:32:43 +02:00

58 lines
1.9 KiB
C++

/*****************************************************************************
* RenderTarget2D.h *
* *
* XFX::Graphics::RenderTarget2D definition file *
* Copyright (c) XFX Team. All Rights Reserved *
*****************************************************************************/
#ifndef _XFX_GRAPHICS_RENDERTARGET2D_
#define _XFX_GRAPHICS_RENDERTARGET2D_
#include <System/Event.h>
#include <Graphics/Texture2D.h>
using namespace System;
namespace XFX
{
namespace Graphics
{
class GraphicsDevice;
// Contains a 2D texture that can be used as a render target.
class RenderTarget2D : public Texture2D
{
private:
friend class GraphicsDevice;
int renderBufferIdentifier;
static int bufferCount;
DepthFormat_t depthStencilFormat;
protected:
void Dispose(bool disposing);
virtual void raise_ContentLost(Object * const sender, EventArgs * const e);
public:
DepthFormat_t getDepthStencilFormat() const;
bool IsContentLost() const;
int getMultiSampleCount() const;
RenderTargetUsage_t getRenderTargetUsage() const;
RenderTarget2D(GraphicsDevice * const graphicsDevice, const int width, const int height);
RenderTarget2D(GraphicsDevice * const graphicsDevice, const int width, const int height, const bool mipmap, const SurfaceFormat_t preferredFormat, const DepthFormat_t preferredDepthFormat);
RenderTarget2D(GraphicsDevice * const graphicsDevice, const int width, const int height, const bool mipmap, const SurfaceFormat_t preferredFormat, const DepthFormat_t preferredDepthFormat, const int multisampleCount, const RenderTargetUsage_t usage);
~RenderTarget2D();
EventHandler ContentLost;
int GetType() const;
bool operator ==(const RenderTarget2D& right) const;
bool operator !=(const RenderTarget2D& right) const;
};
}
}
#endif //_XFX_GRAPHICS_RENDERTARGET2D_