diff --git a/cocos/2d/CCNode.cpp b/cocos/2d/CCNode.cpp index 0975c7ca10..58caefea46 100644 --- a/cocos/2d/CCNode.cpp +++ b/cocos/2d/CCNode.cpp @@ -1451,13 +1451,13 @@ void Node::setAdditionalTransform(kmMat4* additionalTransform) AffineTransform Node::getParentToNodeAffineTransform() const { AffineTransform ret; - kmMat4 ret4 = getParentToNodeTransform(); + Matrix ret4 = getParentToNodeTransform(); - GLToCGAffine(ret4.mat,&ret); + GLToCGAffine(ret4.m,&ret); return ret; } -const kmMat4& Node::getParentToNodeTransform() const +const Matrix& Node::getParentToNodeTransform() const { if ( _inverseDirty ) { kmMat4Inverse(&_inverse, &_transform); diff --git a/cocos/2d/CCNode.h b/cocos/2d/CCNode.h index 000741f593..3cd5db9319 100644 --- a/cocos/2d/CCNode.h +++ b/cocos/2d/CCNode.h @@ -1209,7 +1209,7 @@ public: * Returns the matrix that transform parent's space coordinates to the node's (local) space coordinates. * The matrix is in Pixels. */ - virtual const kmMat4& getParentToNodeTransform() const; + virtual const Matrix& getParentToNodeTransform() const; virtual AffineTransform getParentToNodeAffineTransform() const; /** @deprecated Use getParentToNodeTransform() instead */