I have a server and my only monitor is plugged into its graphics card.

My question is - do all programs (Windows explorer, Excel whatever) draw their output using the graphics card and more specifically an API such as OpenGL?

The output is coming from the graphics card so I do not see how it could not be but it seems like that would require anyone who is using a server to have a GPU to any visual output.

up vote 5 down vote accepted

In general, no. Most applications, unless they are games, or 3D applications like CAD or animation software, will use OS APIs to do their drawing. On Windows, this can be things like GDI or GDI+. On macOS you would usually use CoreGraphics or one of its derivatives.

At a lower level than the application level, the operating system talks to the graphics driver to tell it to draw things on the screen. They may do so using OpenGL or a proprietary API that's not usually exposed directly to applications. (For example on older macOS versions, the Window Server used OpenGL directly to do its compositing. I believe it uses Metal now.) Additionally, some drawing may not be done by the graphics card at all, but the results may be sent to the graphics card for display. For example, the original Windows GDI did its drawing using the CPU, as hardware accelerated graphics were not included on every machine.

So really, there are a variety of ways for applications to do their drawing. They rarely use OpenGL, DirectX, etc. directly unless they have heavy graphics requirements. However, under the hood, the OS may be using those technologies or something similar, or something even lower-level.

  • So the typical flow for something like Excel would be: Draw using GDI -> OS passes those pixels to the GPU for display? – Startec Nov 8 at 7:32
  • Yes, typically it would happen like that. – user1118321 Nov 8 at 17:13

Your Answer

 

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.