strk wrote: > Problem is that in SWF the bitmaps are not standalone characters, > that is they can not appear on stage as characters, but can only > be used as bitmap fills for shapes. You'll get what you're after > if you do so. Ok thanks a lot. Sorry for my delay in the reply, I was away from my computer. I have been testing this code: ... SWFBitmap* image = new SWFBitmap( "label.png" ); SWFFillStyle* fillstyle = SWFFillStyle::BitmapFillStyle( image, 0x40 ); SWFShape* circle = new SWFShape(); circle->setRightFillStyle( fillstyle ); ... circle->drawCircle( 50 ); SWFButton* button = new SWFButton(); button->addCharacter( circle, SWFBUTTON_UP|SWFBUTTON_HIT ); SWFDisplayItem* buttonDI = swfmovie->add( button ); buttonDI->moveTo( 100, 100 ); ... and it works, but this is not the desired behavior because it fills "circle" with a lot of "label.png" images and what I need is to have "label.png" as a button. I have a question here, in class SWFFillStyle declared in mingpp.h in function static SWFFillStyle *BitmapFillStyle(SWFBitmap *bitmap, byte flags) what is the meaning of the parameter flags, in the example I use 0x40, but simply because it works. > See newSWFShapeFromBitmap. --- Comment #1 from strk@xxxxxxxxxx 2010-06-04 16:50:32 EDT --- The C api has a newSWFShapeFromBitmap function, maybe you could be interested in adding an SWFShape constructor to the C++ api with the same semantic. Sure, I have been working on. I added the following code to the SWFShape class SWFShape( c_SWFBitmap bitmap, int flag ) { this->shape = newSWFShapeFromBitmap( bitmap, flag ); if(this->shape == NULL) throw SWFException("SWFShape( c_SWFBitmap bitmap, int flag )"); this->character = (c_SWFCharacter)shape; } but when I try to run an example using it the compiler give me the following messages: error: no matching function for call to ‘SWFShape::SWFShape(SWFBitmap*&, int)’ note:candidates are: SWFShape::SWFShape(const SWFShape&) note:SWFShape::SWFShape(SWFCharacter_s*, int) note:SWFShape::SWFShape(SWFShape_s*) note:SWFShape::SWFShape() I thought it was because I did something wrong with the data types and tried to run an example using the SWFShape(c_SWFShape shape) constructor and again the compiler shows errors: error: no matching function for call to ‘SWFShape::SWFShape(SWFShape*&)’ ... here is the code: SWFShape* circle = new SWFShape(); circle->setRightFillStyle( ... ); circle->setLineStyle( ... ); //Only for testing the constructor //the error is at this line SWFShape* imageShape = new SWFShape( circle ); I have not idea why it does not recognize the SWFBitmap data type, any help will be welcome. I think ming is working fine and it is all my fault. Regards. -dac- ------------------------------------------------------------------------------ ThinkGeek and WIRED's GeekDad team up for the Ultimate GeekDad Father's Day Giveaway. ONE MASSIVE PRIZE to the lucky parental unit. See the prize list and enter to win: http://p.sf.net/sfu/thinkgeek-promo _______________________________________________ Ming-users mailing list Ming-users@xxxxxxxxxxxxxxxxxxxxx https://lists.sourceforge.net/lists/listinfo/ming-users