1
0
mirror of https://github.com/Halofreak1990/XFXFramework synced 2024-12-26 13:49:34 +01:00
XFXFramework/include/Graphics/RenderTarget2D.h
Halofreak1990 40c4811c04 Got everything to compile again.
Began transforming of current API to represent XNA 4.0, which is cleaner.
Dictionary<TKey, TValue> should now work (sort of-- need to implement resizing and enumerating)
Currently hunting down GraphicsDevice initialization
Up next: (hopefully successful) rendering of primitives
2012-09-28 20:36:02 +00:00

58 lines
1.8 KiB
C++

/********************************************************
* RenderTarget2D.h *
* *
* XFX RenderTarget2D definition file *
* Copyright © 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_