1//************************************ bs::framework - Copyright 2018 Marko Pintera **************************************//
2//*********** Licensed under the MIT license. See LICENSE.md for full terms. This notice is not to be removed. ***********//
3#pragma once
4
5#include "BsCorePrerequisites.h"
6#include "Reflection/BsRTTIType.h"
7#include "Material/BsTechnique.h"
8
9namespace bs
10{
11 /** @cond RTTI */
12 /** @addtogroup RTTI-Impl-Core
13 * @{
14 */
15
16 class BS_CORE_EXPORT TechniqueRTTI : public RTTIType<Technique, IReflectable, TechniqueRTTI>
17 {
18 private:
19 BS_BEGIN_RTTI_MEMBERS
20 //BS_RTTI_MEMBER_PLAIN(mRenderer, 1)
21 BS_RTTI_MEMBER_REFLPTR_ARRAY(mPasses, 2)
22 BS_RTTI_MEMBER_PLAIN_ARRAY(mTags, 3)
23 BS_RTTI_MEMBER_PLAIN(mLanguage, 4)
24 BS_RTTI_MEMBER_REFL(mVariation, 5)
25 BS_END_RTTI_MEMBERS
26
27 public:
28 void onDeserializationEnded(IReflectable* obj, SerializationContext* context) override
29 {
30 Technique* technique = static_cast<Technique*>(obj);
31 technique->initialize();
32 }
33
34 const String& getRTTIName() override
35 {
36 static String name = "Technique";
37 return name;
38 }
39
40 UINT32 getRTTIId() override
41 {
42 return TID_Technique;
43 }
44
45 SPtr<IReflectable> newRTTIObject() override
46 {
47 return Technique::createEmpty();
48 }
49 };
50
51 /** @} */
52 /** @endcond */
53}
54