1 #include <mingpp.h> 2 #include <cstdlib> 3 main()4int main() 5 { 6 try { 7 SWFMovie *m = new SWFMovie(8); 8 SWFBitmap *bmp = new SWFBitmap(MEDIADIR "/image01.dbl"); 9 10 SWFFillStyle *fill = SWFFillStyle::BitmapFillStyle(bmp, SWFFILL_CLIPPED_BITMAP); 11 SWFShape *shape = new SWFShape(); 12 shape->setRightFillStyle(fill); 13 14 shape->setLine(1, 0,0,0,255); 15 shape->drawLine(100, 0); 16 shape->drawLine(0, 100); 17 shape->drawLine(-100, 0); 18 shape->drawLine(0, -100); 19 20 m->add(shape); 21 m->save("test04.swf"); 22 } 23 catch(SWFException &e) 24 { 25 std::cerr << "SWFException: " << e.what() << std::endl << std::endl; 26 return EXIT_FAILURE; 27 } 28 return 0; 29 30 } 31