Sfoglia il codice sorgente

ASE: Add Light constructor which takes name

Turo Lamminen 7 anni fa
parent
commit
f3d702339c
1 ha cambiato i file con 13 aggiunte e 0 eliminazioni
  1. 13 0
      code/ASEParser.h

+ 13 - 0
code/ASEParser.h

@@ -369,6 +369,19 @@ struct Light : public BaseNode
     {
     }
 
+
+    //! Construction from an existing name
+    explicit Light(const std::string &name)
+    : BaseNode   (BaseNode::Light, name)
+    , mLightType (OMNI)
+    , mColor     (1.f,1.f,1.f)
+    , mIntensity (1.f) // light is white by default
+    , mAngle     (45.f)
+    , mFalloff   (0.f)
+    {
+    }
+
+
     LightType mLightType;
     aiColor3D mColor;
     ai_real mIntensity;