-
Notifications
You must be signed in to change notification settings - Fork 4
Expand file tree
/
Copy pathBasicRimShadowMaterial.h
More file actions
41 lines (34 loc) · 1.33 KB
/
BasicRimShadowMaterial.h
File metadata and controls
41 lines (34 loc) · 1.33 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#pragma once
#include "Core/Engine.h"
#include "Core/util/WeakPointer.h"
#include "Core/material/Material.h"
class BasicRimShadowMaterial : public Core::Material {
friend class Core::Engine;
public:
virtual Core::Bool build() override;
virtual Core::Int32 getShaderLocation(Core::StandardAttribute attribute, Core::UInt32 offset = 0) override;
virtual Core::Int32 getShaderLocation(Core::StandardUniform uniform, Core::UInt32 offset = 0) override;
virtual void sendCustomUniformsToShader() override;
virtual Core::WeakPointer<Material> clone() override;
void setHighlightLowerBound(Core::Real lowerBound);
void setHighlightScale(Core::Real scale);
void setHighlightColor(Core::Color color);
private:
BasicRimShadowMaterial();
void bindShaderVarLocations();
Core::Int32 positionLocation;
Core::Int32 normalLocation;
Core::Int32 faceNormalLocation;
Core::Int32 colorLocation;
Core::Int32 uvLocation;
Core::Int32 projectionMatrixLocation;
Core::Int32 viewMatrixLocation;
Core::Int32 modelMatrixLocation;
Core::Int32 modelInverseTransposeMatrixLocation;
Core::Int32 highlightColorLocation;
Core::Int32 highlightScaleLocation;
Core::Int32 highlightLowerBoundLocation;
Core::Color highlightColor;
Core::Real highlightScale;
Core::Real highlightLowerBound;
};