In the previous two posts (Graphics Library Reference part 1 and part 2) I have discussed few important functions of graphics.h library in C Programming. As promised here is the sample C language program which will demonstrate the use of graphics functions using C language and draw some geometrical shapes on the console. If you have followed the previous two posts the you will not find the source code difficult to compile and execute. If you still experience any problems using the source code or compiling the code the please do let me know, and I will try to figure it out.

In the meantime you can browse through more source code for C Programming and C++ Programming and even more source code under Source Code section.

I hope this explanation of common functions present in graphics.h library and the sample code would help you learn graphics programming in C language.

Here’s Must-Read List of C programming books for beginners

C Programming Language

C Programming Language, 2nd Edition

With over 600 5-star reviews on Amazon, readers agree that C Programming Language, 2nd Edition by Brian Kernighan and Dennis Ritchie is the best C Programming book for Beginners. The authors present the complete guide to ANSI standard C language programming. Written by the developers of C, this new version helps readers keep up with the finalized ANSI standard for C while showing how to take advantage of C’s rich set of operators, economy of expression, improved control flow, and data structures.


21st Century C

21st Century C: C Tips from the New School

Throw out your old ideas about C and get to know a programming language that’s substantially outgrown its origins. With this revised edition of 21st Century C, you’ll discover up-to-date techniques missing from other C tutorials, whether you’re new to the language or just getting reacquainted.


C Programming Absolute Beginners Guide

C Programming Absolute Beginner’s Guide

Greg Perry is the author of over 75 computer books and known for bringing programming topics down to the beginner’s level. His book C Programming Absolute Beginner’s Guide, is today’s best beginner’s guide to writing C programs–and to learning skills to use with practically any language. Its simple, practical instructions will help you start creating useful, reliable C code, from games to mobile apps. Plus, it’s fully updated for the new C11 standard and today’s free, open source tools!


C Programming - A Modern Approach

C Programming: A Modern Approach, 2nd Edition

KN King tackles on some C standard library specifics header by header in his C Programming: A Modern Approach book. The second edition maintains all the book’s popular features and brings it up to date with coverage of the C99 standard. The new edition also adds a significant number of exercises and longer programming projects, and includes extensive revisions and updates.


Programming Arduino

Programming Arduino: Getting Started with Sketches

Simon Monk, a Ph.D. in software engineering, writes this great little book for learning to program the arduino using C language. This bestselling guide explains how to write well-crafted sketches using Arduino’s modified C language. You will learn how to configure hardware and software, develop your own sketches, work with built-in and custom Arduino libraries, and explore the Internet of Things—all with no prior programming experience required!