CommonLibSSE (powerof3)
BSShaderProperty.h
Go to the documentation of this file.
1 #pragma once
2 
4 #include "RE/B/BSTSmartPointer.h"
5 #include "RE/N/NiShadeProperty.h"
6 
7 namespace RE
8 {
9  class BSShaderMaterial;
10 
12  {
13  private:
14  static constexpr auto BIT64 = static_cast<std::uint64_t>(1);
15 
16  public:
17  inline static constexpr auto RTTI = RTTI_BSShaderProperty;
18  inline static constexpr auto Ni_RTTI = NiRTTI_BSShaderProperty;
19 
20  enum class EShaderPropertyFlag : std::uint64_t
21  {
22  kSpecular = BIT64 << 0,
23  kSkinned = BIT64 << 1,
24  kTempRefraction = BIT64 << 2,
25  kVertexAlpha = BIT64 << 3,
26  kGrayscaleToPaletteColor = BIT64 << 4,
27  kGrayscaleToPaletteAlpha = BIT64 << 5,
28  kFalloff = BIT64 << 6,
29  kEnvMap = BIT64 << 7,
30  kRGBFalloff = BIT64 << 8,
31  kCastShadows = BIT64 << 9,
32  kFace = BIT64 << 10,
33  kUIMaskRects = BIT64 << 11,
34  kModelSpaceNormals = BIT64 << 12,
35  kRefractionClamp = BIT64 << 13,
36  kMultiTextureLandscape = BIT64 << 14,
37  kRefraction = BIT64 << 15,
38  kRefractionFalloff = BIT64 << 16,
39  kEyeReflect = BIT64 << 17,
40  kHairTint = BIT64 << 18,
41  kScreendoorAlphaFade = BIT64 << 19,
42  kLocalMapClear = BIT64 << 20,
43  kFaceGenRGBTint = BIT64 << 21,
44  kOwnEmit = BIT64 << 22,
45  kProjectedUV = BIT64 << 23,
46  kMultipleTextures = BIT64 << 24,
47  kTesselate = BIT64 << 25,
48  kDecal = BIT64 << 26,
49  kDynamicDecal = BIT64 << 27,
50  kCharacterLight = BIT64 << 28,
51  kExternalEmittance = BIT64 << 29,
52  kSoftEffect = BIT64 << 30,
53  kZBufferTest = BIT64 << 31,
54  kZBufferWrite = BIT64 << 32,
55  kLODLandscape = BIT64 << 33,
56  kLODObjects = BIT64 << 34,
57  kNoFade = BIT64 << 35,
58  kTwoSided = BIT64 << 36,
59  kVertexColors = BIT64 << 37,
60  kGlowMap = BIT64 << 38,
61  kTransformChanged = BIT64 << 39,
62  kDismembermentMeatCuff = BIT64 << 40,
63  kTint = BIT64 << 41,
64  kVertexLighting = BIT64 << 42,
65  kUniformScale = BIT64 << 43,
66  kFitSlope = BIT64 << 44,
67  kBillboard = BIT64 << 45,
68  kLODLandBlend = BIT64 << 46,
69  kDismemberment = BIT64 << 47,
70  kWireframe = BIT64 << 48,
71  kWeaponBlood = BIT64 << 49,
72  kHideOnLocalMap = BIT64 << 50,
73  kPremultAlpha = BIT64 << 51,
74  kVATSTarget = BIT64 << 52,
75  kAnisotropicLighting = BIT64 << 53,
76  kSkewSpecularAlpha = BIT64 << 54,
77  kMenuScreen = BIT64 << 55,
78  kMultiLayerParallax = BIT64 << 56,
79  kAlphaTest = BIT64 << 57,
80  kInvertedFadePattern = BIT64 << 58,
81  kVATSTargetDrawAll = BIT64 << 59,
82  kPipboyScreen = BIT64 << 60,
83  kTreeAnim = BIT64 << 61,
84  kEffectLighting = BIT64 << 62,
85  kRefractionWritesDepth = BIT64 << 63
86  };
87 
88  ~BSShaderProperty() override; // 00
89 
90  // override (NiShadeProperty)
91  const NiRTTI* GetRTTI() const override; // 02
92  NiObject* CreateClone(NiCloningProcess& a_cloning) override; // 17 - { return 0; }
93  void LoadBinary(NiStream& a_stream) override; // 18
94  void LinkObject(NiStream& a_stream) override; // 19 - { NiShadeProperty::LinkObject(a_stream); }
95  bool RegisterStreamables(NiStream& a_stream) override; // 1A - { return NiShadeProperty::RegisterStreamables(a_stream); }
96  void SaveBinary(NiStream& a_stream) override; // 1B
97  bool IsEqual(NiObject* a_object) override; // 1C - { return false; }
98  void PostLinkObject(NiStream& a_stream) override; // 1E - { NiObjectNET::PostLinkObject(a_stream); }
99  void Unk_27(void) override; // 27 - { return 1; }
100  void Unk_29(void) override; // 29
101 
102  // add
103  virtual void Unk_2A(void) = 0; // 2A
104  virtual void Unk_2B(void); // 2B - { return 0; }
105  virtual void Unk_2C(void); // 2C - { return 0; }
106  virtual void Unk_2D(void); // 2D - { return 0; }
107  virtual void Unk_2E(void); // 2E - { return 1; }
108  virtual void Unk_2F(void); // 2F - { return 0; }
109  virtual void Unk_30(void); // 30
110  virtual void Unk_31(void); // 31 - { return; }
111  virtual void Unk_32(void); // 32 - { return 1.0; }
112  virtual void Unk_33(void); // 33 - { return 1; }
113  virtual void Unk_34(void); // 34
114  virtual void Unk_35(void); // 35 - { return 0; }
115  virtual void Unk_36(void); // 36 - { return 0; }
116  virtual void Unk_37(void); // 37 - { return 0; }
117  virtual void Unk_38(void); // 38 - { return 0; }
118  [[nodiscard]] virtual bool AcceptsEffectData() const; // 39 - { return false; }
119  virtual void Unk_3A(void); // 3A - { return; }
120  virtual void Unk_3B(void); // 3B - { return; }
121  virtual void Unk_3C(void); // 3C - { return 0; }
122  virtual void Unk_3D(void); // 3D - { return 0; }
123  virtual void Unk_3E(void); // 3E - { return 0; }
124 
126 
127  // members
128  float alpha; // 30
129  std::int32_t lastRenderPassState; // 34
131  void* unk40; // 40
132  std::uint64_t unk48; // 48
133  void* unk50; // 50
134  std::uint64_t unk58; // 58
135  std::uint64_t unk60; // 60
137  std::uint64_t unk70; // 70
139  std::uint64_t unk80; // 80
140  };
141  static_assert(sizeof(BSShaderProperty) == 0x88);
142 }
Definition: BSShaderMaterial.h:9
Definition: BSShaderProperty.h:12
virtual void Unk_34(void)
NiObject * CreateClone(NiCloningProcess &a_cloning) override
void LoadBinary(NiStream &a_stream) override
virtual void Unk_3E(void)
BSTSmartPointer< BSEffectShaderData > effectData
Definition: BSShaderProperty.h:136
float alpha
Definition: BSShaderProperty.h:128
std::int32_t lastRenderPassState
Definition: BSShaderProperty.h:129
virtual void Unk_2A(void)=0
virtual void Unk_38(void)
void LinkObject(NiStream &a_stream) override
virtual void Unk_30(void)
std::uint64_t unk48
Definition: BSShaderProperty.h:132
virtual void Unk_2F(void)
virtual void Unk_3B(void)
const NiRTTI * GetRTTI() const override
EShaderPropertyFlag
Definition: BSShaderProperty.h:21
virtual void Unk_3A(void)
virtual void Unk_31(void)
static constexpr auto RTTI
Definition: BSShaderProperty.h:17
stl::enumeration< EShaderPropertyFlag, std::uint64_t > flags
Definition: BSShaderProperty.h:130
void * unk40
Definition: BSShaderProperty.h:131
std::uint64_t unk60
Definition: BSShaderProperty.h:135
~BSShaderProperty() override
void PostLinkObject(NiStream &a_stream) override
virtual void Unk_2C(void)
BSShaderMaterial * material
Definition: BSShaderProperty.h:138
static constexpr auto Ni_RTTI
Definition: BSShaderProperty.h:18
virtual void Unk_3C(void)
virtual void Unk_35(void)
void Unk_27(void) override
std::uint64_t unk80
Definition: BSShaderProperty.h:139
void Unk_29(void) override
void SetEffectShaderData(const BSTSmartPointer< BSEffectShaderData > &a_data)
bool IsEqual(NiObject *a_object) override
virtual void Unk_2B(void)
void SaveBinary(NiStream &a_stream) override
virtual bool AcceptsEffectData() const
virtual void Unk_32(void)
virtual void Unk_2E(void)
virtual void Unk_3D(void)
std::uint64_t unk58
Definition: BSShaderProperty.h:134
std::uint64_t unk70
Definition: BSShaderProperty.h:137
virtual void Unk_2D(void)
virtual void Unk_37(void)
bool RegisterStreamables(NiStream &a_stream) override
virtual void Unk_36(void)
virtual void Unk_33(void)
void * unk50
Definition: BSShaderProperty.h:133
Definition: BSTSmartPointer.h:37
Definition: NiObject.h:37
Definition: NiRTTI.h:6
Definition: NiShadeProperty.h:8
Definition: NiStream.h:6
Definition: AbsorbEffect.h:6
constexpr REL::ID NiRTTI_BSShaderProperty
Definition: Offsets_NiRTTI.h:110
constexpr REL::ID RTTI_BSShaderProperty
Definition: Offsets_RTTI.h:2564