Drawing shapes in CCSprite

Hello,

I can use ccDrawPoly() to draw polygons, but how I draw polygons inside a CCSprite? It could possibly be added as a child CCSprite. It would then subject to any transformations I apply on the CCSprite.

Thanks.

[edit]
That is, the polygon would be contained within the hierarchy of the CCSprite.

you can reimplement the CCSPrite::Draw() method ,I think there is a example in the test project of the Cocos2d-x.