Click here to Skip to main content
15,877,675 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
I'm writing a program to create isometric line drawings and I need to figure out how to convert 2D circles to ellipses using a shear matrix transform. I've searched Google for a few days now but can't seem to come up with any code examples. Data I use is centrepoint and radius.

Can someone point me to a resource?
Posted
Comments
[no name] 10-Apr-14 1:36am    
You may have to write your own. Do do you want major axis to be diameter? If so I think it could be done by rotating circle about an axis and computing projection. If you wish to elongate the circle into an ellipse that is a stretch along an axis and not a shear transformation

1 solution

You can leave the circle (and everything else) unmodified and let the Graphics object deal with shearing via its Transform property. It's of type Matrix, which supports Shaer out of the box.
 
Share this answer
 
Comments
Paul Hildebrandt 10-Apr-14 15:10pm    
I need to get the ellipse with its centerpoint and radii, not just draw the graphics.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900