0

I have already developed the algorithms behind the physics of projectile motion. My only problem is drawing on a form.How would I achieve this from scratch.

user1920206
  • 69
  • 10

1 Answers1

1

The question is a bit too general, but just to shed some light, I think you probably want to create a PictureBox control and draw on that, instead of on the actual form that has your controls and settings.

Here's how you create the Graphics object for a pictureBox, for example, and then draw a line on it: Draw a line on PictureBox from parent

Now, your simulation, I believe, should actually draw lines, between the newly calculated (x,y) and the previously calculated one, in order to plot a full line instead of just dots, and that will probably happen within a loop in which you vary t (time) in intervals.

Community
  • 1
  • 1
Pablo Romeo
  • 11,298
  • 2
  • 30
  • 58