I don't want to use a pre-made Graphics system to do my graphics. How do I start drawing pixels on a screen, without a pre-made graphics program?
Is it similar to cout and putting data in the stream?
Printable View
I don't want to use a pre-made Graphics system to do my graphics. How do I start drawing pixels on a screen, without a pre-made graphics program?
Is it similar to cout and putting data in the stream?
If you're using Windows, normally you perform all the drawings in a window and not directly on the screen.
If you're using MFC you perform drawing operations in the OnPaint function member of a CWnd derived class.
If you're not using MFC, you perform the drawings in the WM_PAINT message handler of a window procedure.
If you want to perform drawing directly to the screen disregarding any window, you'll need a dc for the entire screen. You can get it using GetDCEx .
Before attempting to draw anthing, I suggest you to search the MSDN for the topic GDI (Graphic Design Interface) and read all of its subtopics.