}//*/ public void DrawGuideLine(Graphics g, PlayingData pd) { Pen borderlinedrawer = new Pen(Color.White, 0.5f); for (int i = 0; i < pd.hsnapcnt; i++)//Horizontal guideline { int x = this.Width * (i + 1) / ((int)pd.hsnapcnt + 1); g.DrawLine(borderlinedrawer, x, 0, x, this.Height); }//Horizontal guideline int beat = ((int)(pd.now * 48 / pd.bsnapcnt)) * pd.bsnapcnt; double l = beat / 48d; while (beat < 0) { beat += 48; } for (; l < pd.now + pd.scale; l += 1d / 48d) { Pen linedrawer; beat %= 48;//detect beat if (beat % (48 / pd.bsnapcnt) != 0) { beat++; continue; } if (beat == 0 && ((l + 12.1) % 4) < 0.4)//thick line every large beat(4 small beat) { linedrawer = new Pen(Editor.BeatSnapColor.col[beat], 3); } else { linedrawer = new Pen(Editor.BeatSnapColor.col[beat], 1); } int y = MusicMath.TimingToY(l, pd); g.DrawLine(linedrawer, 0, y, pd.width, y); beat++; }//vertical(beat)guideline }