IRenderTarget.h
Go to the documentation of this file.
1 
2 #pragma once
3 
4 #include <ionCore.h>
5 #include <ionMath.h>
6 #include <ionFramework.h>
7 
8 #include "ITexture.h"
9 
10 
11 namespace ion
12 {
13  namespace Graphics
14  {
15 
18  {
19 
20  public:
21 
22  virtual void ClearColor() = 0;
23  virtual void ClearDepth() = 0;
24  virtual void ClearColorAndDepth() = 0;
25 
26  virtual void SetClearColor(color4f const & Color) = 0;
27 
28  virtual void Bind() = 0;
29  virtual IRenderTarget * GetCurrentlyBound() = 0;
30  virtual void SetViewport(vec2i const & Min, vec2i const & Max) = 0;
31  virtual void ClearViewport() = 0;
32 
33  virtual CImage * ReadImage() = 0;
34 
35  virtual ~IRenderTarget()
36  {}
37 
38  };
39 
42  {
43 
44  public:
45 
46  virtual ~IDepthBuffer()
47  {}
48 
49  };
50 
52  class IFrameBuffer : public virtual IRenderTarget
53  {
54 
55  public:
56 
57  virtual void AttachColorTexture(SharedPointer<ITexture2D> Texture, uint const Attachment) = 0;
58  virtual void AttachDepthTexture(SharedPointer<ITexture2D> Texture) = 0;
59  virtual void AttachDepthBuffer(SharedPointer<IDepthBuffer> DepthBuffer) = 0;
60 
61  virtual bool CheckCorrectness() = 0;
62 
63  virtual ~IFrameBuffer()
64  {}
65 
66  };
67 
68  }
69 }
Definition: SColor.h:8
Definition: IRenderTarget.h:17
virtual ~IFrameBuffer()
Definition: IRenderTarget.h:63
std::shared_ptr< T > SharedPointer
Definition: ionSmartPointer.h:22
virtual void ClearViewport()=0
virtual ~IDepthBuffer()
Definition: IRenderTarget.h:46
Definition: IRenderTarget.h:52
virtual ~IRenderTarget()
Definition: IRenderTarget.h:35
unsigned int uint
Definition: ionTypes.h:99
virtual void ClearColorAndDepth()=0
Customized variant of vec4 that intelligently handles conversion between floating point and integer c...
Definition: SColor.h:62
Definition: IRenderTarget.h:41
Definition: CCatmullRomAdvancedSplineInterpolator.h:7
virtual void SetClearColor(color4f const &Color)=0
virtual CImage * ReadImage()=0
virtual IRenderTarget * GetCurrentlyBound()=0
virtual void SetViewport(vec2i const &Min, vec2i const &Max)=0
Definition: CImage.h:10
virtual void ClearDepth()=0
virtual void ClearColor()=0