Paint program in c language

painting program in language

Paint program in c language   This program can draw different shapes using mouse such as line, circle, pixel and many other shapes. You can also change the color, clear the screen. #include<graphics.h> #include<dos.h> #include<math.h> #include<stdlib.h> #include<stdio.h> #include<conio.h> union REGS i, o; int leftcolor[15]; int get_key() { union REGS i,o; i.h.ah = 0; int86(22, &i, … Read more

Drawing concentric circles – C graphics examples

c graphics program example

Drawing concentric circles – C graphics examples   #include <graphics.h> int main() { int gd = DETECT, gm; int x = 320, y = 240, radius; initgraph(&gd, &gm, “C:\\TC\\BGI”); for ( radius = 25; radius <= 125 ; radius = radius + 20) circle(x, y, radius); getch(); closegraph(); return 0; }