TDME2 1.9.121
PostProcessingShaderBaseImplementation.h
Go to the documentation of this file.
1#pragma once
2
3#include <tdme/tdme.h>
8
12
13/**
14 * Post processing shader base implementation
15 * @author Andreas Drewke
16 * @version $Id$
17 */
19{
20protected:
21 int32_t programId { -1 };
22
23 int32_t vertexShaderId { -1 };
24 int32_t fragmentShaderId { -1 };
25
32
33 bool isRunning { false };
34 bool initialized { false };
35 Renderer* renderer { nullptr };
36
37public:
38 /**
39 * Public constructor
40 * @param renderer renderer
41 */
43
44 // overridden methods
45 virtual bool isInitialized() override;
46 virtual void initialize() override;
47 virtual void useProgram(int contextIdx) override;
48 virtual void unUseProgram() override;
49 virtual void setBufferPixelWidth(int contextIdx, float pixelWidth) override;
50 virtual void setBufferPixelHeight(int contextIdx, float pixelHeight) override;
51 virtual void setShaderParameters(int contextIdx, Engine* engine) override = 0;
52
53};
Engine main class.
Definition: Engine.h:122
Frame buffer class.
Definition: FrameBuffer.h:21
virtual void setShaderParameters(int contextIdx, Engine *engine) override=0
Set shader parameters.
virtual void setBufferPixelHeight(int contextIdx, float pixelHeight) override
Set source buffer pixel height.
virtual void setBufferPixelWidth(int contextIdx, float pixelWidth) override
Set source buffer pixel width.