Finally, A Perfect Circle !

I was confused, this time, trying to find, What was the mistake I did ? What else could I do, even when this console ratio thing didn’t work ? I and my friends were again into it completely. We sat like ‘Warriors‘ with our ‘Laptops-cum-Weapons’ in front and the seriousness that our faces reflected did give the feel of A Battle Field :p Finally, I realized the mistake. There exists no concept named Console Ratio, if it exists, then it wasn’t needed here.

Here’s the detailed explanation of what actually was going on.
The very first program that I discussed for drawing a circle did not give a circle as output but an ellipse. This happened because the console window entries are non-square i.e. the pixel that a character entity occupies is non-square.In most computers, the height of a pixel is twice (approximately 2 times) as that of the width. What must come into action is the Pixel Aspect Ratio i.e the console character ratio that describes the comparison between the width and height of a pixel. In the second attempt of drawing the circle, I took the values of the height and width of terminal window, that created problem, because, what was actually needed, was the height and width of one pixel. Taking this console character ratio = height/width, we get the value, 2 as the height is approximately twice the width.
The Next post will contain the C++ program that displays A Circle As A ‘Circle’ :p along with the screenshot showing the output.

Leave a Reply

Your email address will not be published. Required fields are marked *

%d bloggers like this: