Get Sprite frame name after creation?

Get Sprite frame name after creation?
0.0 0



am I able to retrieve a batched Sprite’s frame name that it was created with?
Sprite* sprite = Sprite::createWithFrameName("bullet.png");
sprite->getFrameName(); // "bullet.png"

I’ve looked at Sprite/SpriteFrame, and know of the SpriteFrame Sprite::displayFrame() method, but I don’t see anyway to actually get the original frame name (e.g. “bullet.png” in the above example)

Thanks for the help


in the file CCSpriteFrame there is protected member called :
that keeps the file name , not sure why its not exposed i also need to get the name of the texture.
what i did is to extend the Sprite class and keep the file name as private member