cocos2d utility function to create cache image sprite