; German forum: http://robsite.de/php/pureboard/viewtopic.php?t=1505&highlight= ; Author: [DS]DarkDragon ; Date: 28. June 2003 OpenWindow(0, 0, 0, 500, 500, #PB_Window_TitleBar | #PB_Window_SystemMenu, "Spirale") BOX = CreateImage(0, WindowWidth(), WindowHeight()) PI2.f = ATan(1)*8;Aus dem Beispiel ist auch ein wenig geklaut, bitte nicht böse sein PI1.f = ATan(1)*4 xm = WindowWidth()/2 ym = WindowHeight()/2 radius = WindowWidth()/2-5 steps = 2050 StartDrawing(ImageOutput()) Box(0, 0, ImageWidth(), ImageHeight(), RGB(255, 255, 255)) a.f = PI2 While a >= 0 x = Sin(a+PI1)*radius+xm y = Cos(a+PI1)*radius+ym Plot(x, y, RGB(255, 0, 0)) a-PI2/steps Wend rad2.f = 0 a.f = PI2 b = -1 While a >= -53.5 x = Sin(a+PI1)*rad2+xm y = Cos(a+PI1)*rad2+ym Plot(x, y, RGB(0, 0, 255)) rad2 + 0.0125 a-PI2/steps Wend rad2.f = 0 a.f = PI2 b = -1 While a >= -53.5 x = Sin(a+PI1)*(rad2*-1)+xm y = Cos(a+PI1)*(rad2*-1)+ym Plot(x, y, RGB(0, 255, 255)) rad2 + 0.0125 a-PI2/steps Wend StopDrawing() StartDrawing(WindowOutput()) DrawImage(BOX, 0, 0) StopDrawing() If CreatePopupMenu(0) MenuItem(0, "Copy") EndIf Repeat Event = WaitWindowEvent() Select Event Case #WM_RBUTTONDOWN DisplayPopupMenu(0, WindowID()) Case #PB_Event_Repaint StartDrawing(WindowOutput()) DrawImage(BOX, 0, 0) StopDrawing() Case #PB_Event_Menu Select EventMenuID() Case 0 SetClipboardData(#PB_Clipboard_Image, ImageID()) EndSelect EndSelect Until Event = #PB_Event_CloseWindow End ; ExecutableFormat=Windows ; FirstLine=1 ; EOF