mirror of https://github.com/axmolengine/axmol.git
reset change to getDirectionInWorld
This commit is contained in:
parent
53dee7ef86
commit
744e09c141
|
@ -76,9 +76,9 @@ const Vec3& DirectionLight3D::getDirection() const
|
|||
dir.set(-mat.m[8], -mat.m[9], -mat.m[10]);
|
||||
return dir;
|
||||
}
|
||||
Vec3 DirectionLight3D::getDirectionInWorld() const
|
||||
const Vec3& DirectionLight3D::getDirectionInWorld() const
|
||||
{
|
||||
Vec3 dir;
|
||||
static Vec3 dir;
|
||||
Mat4 mat = getNodeToWorldTransform();
|
||||
dir.set(-mat.m[8], -mat.m[9], -mat.m[10]);
|
||||
return dir;
|
||||
|
@ -139,9 +139,9 @@ const Vec3& SpotLight3D::getDirection() const
|
|||
return dir;
|
||||
}
|
||||
|
||||
Vec3 SpotLight3D::getDirectionInWorld() const
|
||||
const Vec3& SpotLight3D::getDirectionInWorld() const
|
||||
{
|
||||
Vec3 dir;
|
||||
static Vec3 dir;
|
||||
Mat4 mat = getNodeToWorldTransform();
|
||||
dir.set(-mat.m[8], -mat.m[9], -mat.m[10]);
|
||||
return dir;
|
||||
|
|
|
@ -126,7 +126,7 @@ public:
|
|||
/**
|
||||
* Returns direction in world.
|
||||
*/
|
||||
Vec3 getDirectionInWorld() const;
|
||||
const Vec3& getDirectionInWorld() const;
|
||||
|
||||
CC_CONSTRUCTOR_ACCESS:
|
||||
DirectionLight3D();
|
||||
|
@ -196,7 +196,7 @@ public:
|
|||
/**
|
||||
* Returns direction in world.
|
||||
*/
|
||||
Vec3 getDirectionInWorld() const;
|
||||
const Vec3& getDirectionInWorld() const;
|
||||
|
||||
/**
|
||||
* Sets the range of point or spot light.
|
||||
|
|
Loading…
Reference in New Issue