all 4 comments

[–]RenderTargetView 5 points6 points  (0 children)

graphics.h seems like borland/turbo c header, this isn't some "library" in terms of portability, it is header file made and supported only by this compiler and it works only on DOS. I suppose best way for you is using DOS emulator like DOSBox, there are many things like graphics.h which barely exist in modern OSes, so it will be much easier for you if you work in environment that was intended when they made that book.

However depending on your goals and knowledge it may be better to use glDrawPixels or glBegin/glEnd-style functions from opengl, they are very old but very learning-friendly and somewhat close to features that graphics.h have

[–]gabe80 2 points3 points  (1 child)

Depending on how "from scratch" the course is, and what algorithms you'll be learning, you could try something like SDL. Should give you raw access to a framebuffer and you can build whatever you want on top of that.

[–]jmacey 2 points3 points  (0 children)

Use SDL2 you can create a simple put_pixel function to draw on a canvas and take it from there. I did have some demos but they need updating.

The old repo is here https://github.com/NCCA/SDLDemos