5

I want to manually draw the graphics, what that mean is without using any library or frame work like QT, directX , whindow.h .... like giving command to every pixels on the screen to show some specific color at different time. Every body gives tutorials on based on these library or whatever they are called. What i want is to make my own GUI. As far as I could think it is going to be very complicated, hard to learn and to understand, messy and a lot of time consuming, but I am ready for that. I need some resources to understand that.

and Yes i know C++ so it would better if I had to work with this language but I will learn other language if it is required, just i want to know which language i should learn.

Sanmveg saini
  • 744
  • 1
  • 7
  • 22
  • What operating system? – rob mayoff Mar 12 '16 at 06:49
  • 2
    You could use a [DOSBox](http://www.dosbox.com/wiki/Main_Page) on a PC and program the emulated x86 PC hardware. – Cheers and hth. - Alf Mar 12 '16 at 06:55
  • See is this is what you want: http://stackoverflow.com/questions/4996777/paint-pixels-to-screen-via-linux-framebuffer – vcp Mar 12 '16 at 07:39
  • windows vista or xp or 7 – Sanmveg saini Mar 12 '16 at 07:51
  • without lib you can not even create an app these days except old MSDOS programs (do not confuse with console apps) so in that case the only possibility is DOS/DOSBOX and direct access to EGA/VGA see [display array of colors in C/C++](http://stackoverflow.com/a/21699076/2521214) or use [ASCII art](http://stackoverflow.com/a/32987834/2521214) in console app ... otherwise you need to use a gfx lib (C/C++ has no gfx api) – Spektre Mar 12 '16 at 07:53
  • According to Tanenbaum, one way of looking at an operating system is seeing it as an extension of the hardware. So according to this interpreation, when you use stuff in ``, you do not use a framework or library but the machine itself. – Christian Hackl Mar 12 '16 at 10:44
  • Possible duplicate of [C how to draw a point / set a pixel without using graphics library or any other library functions](https://stackoverflow.com/questions/15072025/c-how-to-draw-a-point-set-a-pixel-without-using-graphics-library-or-any-other) – phuclv Jun 25 '17 at 03:52

2 Answers2

8

In the old days, you could write directly to video memory with no help from the operating system/ROM. Today, on current hardware, you have to go through the operating system in order to write to the screen. That means using a separate library (like Qt) or using the OS features (windows.h). You could use directX or something and get more raw access to video memory, but that is still using a library/framework.

Rob L
  • 2,351
  • 13
  • 23
4

If you want with C++ and native Windows API (without DirectX) , you should use GDI(Microsoft Graphics device interface) + MFC(Microsoft Foundation Classes) this is a classic implementation of Windows GUI, If you want complicated graphics with shaders you need DirectX/OpenGL without hesitation. meanwhile if you want higher programming framework you can use C#(CSHARP) or Java.