Beginner's Question: GDI CIRCLE

This is a discussion on Beginner's Question: GDI CIRCLE within the Windows Programming forums, part of the Platform Specific Boards category; How exactly can you make a circle?? I've seen that you do it with an elipse function. If it is ...

1. Beginner's Question: GDI CIRCLE

How exactly can you make a circle?? I've seen that you do it with an elipse function. If it is an ellipse how can you reshape it to a circle?? Sorry...I am a bigginer to windows programming. I am into GDI...and want to understand it so I can make a simple pong game...with GDI before advancing into DirectX and COM stuff...
THANK YOU IN ADVANCE!!!

2. Are you using MFC or WIN32?

Elipse() takes a rectangle. If you send in a square it will draw a circle.

You can also draw a point with a very thick pen..

for a pen with a dot (circle) 20 pixel in diameter
HPEN hPen=CreatePen(PS_SOLID, 20, RGB(255, 255, 255) );

RGB(255, 255, 255) is the colour. Red, Green, Blue from 0 - 255 where 0 = blackest (no colour) and 255 = white (max colour).

Popular pages Recent additions