How does a GPU forms a frame?

 

Pixels, the smallest unit of an image that is on a screen, thousands to millions of the pixels (depending on the resolution of the screen, like 1080p got 2,073,600 pixels)on a screen forms an image or frame, and as we know these pixels are arranged in a two-dimensional grid. The physical size of these pixels may vary from type of screen to screen, but that is a topic for later. Well, I guess we all might be knowing that but how does a pixel know what colour should it represent to be part of an image or frame, well that instruction is given by the GPU, but how does it work?
SO HOW DOES GPU DO IT?

Now to display a frame all the pixels on a screen which can be in millions have to be assigned a different colour separately and the computer has to decide what to do with each of these pixels, for that a translator- a GPU is needed.
A graphical processing unit takes binary data and turns it into an image, now each pixel has a unique address, and it can be represented as a function f(x,y) 
An image can be seen as a matrix, where the amplitude of each pixel is its intensity that is what colour value it can represent from 0-255, where 0 is black and 255 is completely white(depends on the type of screen), but that's for later posts, today we are just looking at how does a GPU post an image or frame on a screen.
As a frame is to be shown on a screen, the CPU processes that frame as binary data, and that is sent to GPU which turns it into an image and cuts that image in pixels by the resolution, As CPU receives a signal to form an image on the screen, that information is sent to video memory, where the GPU as said earlier divides the image it forms into pixels and allocates an address to the values each pixel need to be and that information is then sent to a RAMDAC which converts the digital data into analogue data which associates each of Red, Blue and Green intensity, and that data is sent to monitor to each pixel address and that pixel is then set to that value and then as a whole an image is formed.
But in modern day GPUs you won't find RAMDAC, well that's because RAMDAC is used in VGA monitors which can only accept analog data, whereas modern monitors can work on the digital signal by HDMI, Digital port, etc, now these don't use RAMDAC, instead, the data is sent directly from video memory to the screen, the video data is sent to a frame buffer so next frames can be loaded quickly and GPU can work on next frames.


Comments