「提出予定版」の編集履歴(バックアップ)一覧はこちら

提出予定版」(2007/01/10 (水) 14:29:37) の最新版変更点

追加された行は緑色になります。

削除された行は赤色になります。

*回転変換 void rot(double *x,double *y,double th){ double ox = *x; double oy = *y; *x = ox * cos(th) - oy * sin(th); *y = ox * sin(th) + oy * cos(th); } *描画部 void draw(double th , int xhome , int yhome){ double x,y,x0,y0,x1,y1,tloop; GWsetpen(GWC_BLACK,GWL_SOLID,1,GWX_COPYPEN); func(&x,&y,0); rot(&x,&y,th); x0 = xhome + MAG * x; y0 = yhome - MAG * y; for(tloop = 0 ; tloop <= 360.0 / 180.0 * 3.141592 ; tloop += 1.0 / 180.0 * 3.141592){ func(&x,&y,tloop); rot(&x,&y,th); x1 = xhome + MAG * x; y1 = yhome - MAG * y; GWline(x0,y0,x1,y1); x0 = x1;y0 = y1; } } *角度変更反復部 for(th = 0 ; th <= 360.0 / 180.0 * 3.141592 ; th += 120.0 / 180.0 * 3.141592){ draw(th,xhome,yhome); }

表示オプション

横に並べて表示:
変化行の前後のみ表示: