Is it possible to get all the points of the objects we have drawn using Graphics object.
For example I have drawn an ellipse using
Collapse
Graphics g = this.GetGraphics();
g.DrawEllipse(Pens.Red, 300, 300, 100, 200);
Than
How I can get all the points or pixels drawn by that function
Or is it possible to get all the points or pixels drawn on form.
Thanks……….
To answer the second part of your question, on how to find pixels affected:
I would highly recommend a mathmatical solution, as listed above. However, for a more
brute-forceoption, you could simply to create a image, draw to it, and then loop through each pixel to find those pixels affected. This will work, but will be very slow as compared to a genuine mathmatical solution. It will grow slower as the size of the image increases.This will not work if you antialiasis your drawn circle, whereas their may be shading and transparency. It will however work for what you have listed above.
e.g.