How to fill circle with color and unable 50% opacity (for transparent effect )


#1

Hello im trying to fill primitive circle with color , and then set the color opacity to 50% transparent .
i searched the net and haven’t found any solution only cocos2d-iphone stuff .
i created inherited from sprite
and it does paint me circle .

 void CircleSprite::draw(void)
{


 glLineWidth(2);
 cocos2d::ccDrawColor4B(0, 255, 255, 255);
 cocos2d::ccDrawCircle( ccp(100/2, 100/2), 50, CC_DEGREES_TO_RADIANS(90), 50, false);

}

#ifndef __CIRCLESPRITE_H__
#define __CIRCLESPRITE_H__

#include "cocos2d.h"

class CircleSprite : public cocos2d::CCSprite
{
    public :
        virtual void draw(void);
    private:

};



#endif


in the main loop :
CCSize winSize = CCDirector::sharedDirector()->getWinSize();
        CCSprite* cloud = drowCloud();
        cloud->setPosition(ccp(cloud->getContentSize().width/2,winSize.height/2));
        this->addChild(cloud);


CCSprite* HelloWorld::drowCloud()
{
    CCSprite * pCloud = new CircleSprite();
    return pCloud;
}  

#2

is it possible even ?
i saw that someone checkedin the function to the source code , but haven’t saw it in the source code