2012-04-05 23:09:41 +00:00
|
|
|
//
|
|
|
|
|
// KRLight.h
|
|
|
|
|
// KREngine
|
|
|
|
|
//
|
|
|
|
|
// Created by Kearwood Gilbert on 12-04-05.
|
|
|
|
|
// Copyright (c) 2012 Kearwood Software. All rights reserved.
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
#ifndef KREngine_KRLight_h
|
|
|
|
|
#define KREngine_KRLight_h
|
|
|
|
|
|
|
|
|
|
#import "KRResource.h"
|
2012-04-12 00:43:53 +00:00
|
|
|
#import "KRNode.h"
|
2012-04-05 23:09:41 +00:00
|
|
|
|
2012-04-12 00:43:53 +00:00
|
|
|
class KRLight : public KRNode {
|
2012-04-05 23:09:41 +00:00
|
|
|
public:
|
2012-04-12 00:43:53 +00:00
|
|
|
virtual ~KRLight();
|
|
|
|
|
virtual std::string getElementName() = 0;
|
|
|
|
|
virtual tinyxml2::XMLElement *saveXML( tinyxml2::XMLNode *parent);
|
|
|
|
|
|
|
|
|
|
void setIntensity(float intensity);
|
|
|
|
|
float getIntensity();
|
|
|
|
|
void setDecayStart(float decayStart);
|
|
|
|
|
float getDecayStart();
|
|
|
|
|
const KRVector3 &getColor();
|
|
|
|
|
void setColor(const KRVector3 &color);
|
2012-04-05 23:09:41 +00:00
|
|
|
|
|
|
|
|
protected:
|
|
|
|
|
KRLight(std::string name);
|
2012-04-12 00:43:53 +00:00
|
|
|
|
|
|
|
|
float m_intensity;
|
|
|
|
|
float m_decayStart;
|
|
|
|
|
KRVector3 m_color;
|
2012-04-05 23:09:41 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
|
|
#endif
|