You are here

graphics

Web browser project in C, C program to open a website/url

This program opens a website entered by the user. User can open any website .It will launch Mozilla Firefox web browser to open a website so it should be installed on your computer, if you are using an another web browser then you can change the path in the program.

C programming code

#include<stdio.h>
#include<conio.h>
#include<stdlib.h>
#include<graphics.h>
#include<dos.h>
#include<string.h>
 
void initialize_graphics_mode();
int get_key();
void draw();
 
union REGS i, o;
 
main()
{
  int key, i = 0, xpos, ypos, button;
  char arr[200], temp[5], *ptr;

Press me button game in c, download press-me-button game

Press me game in C:- In this game when you try to bring mouse near a button it moves away from the mouse, so you keep on trying pressing the button. In this game we have the coordinates of current position of mouse pointer at every moment of time, whenever we find mouse pointer very close to button we move the button suitably.

C programming code

#include <stdio.h>
#include <conio.h>
#include <dos.h>
#include <graphics.h>
#include <stdlib.h>

union REGS i, o;
int left = 265, top = 250;

void initialize_graphics_mode()
{
  int gd = DETECT, gm, error;

Paint program in C

Paint program in C to draw different shapes using mouse such as line, circle, pixel and many other shapes. You can also change the color, clear the screen.

/* To understand the code see output below the code, it will help you in understanding the code. */

functions of graphics.h

C graphics using graphics.h functions or WinBGIM (Windows 7) can be used to draw different shapes, display text in different fonts, change colors and many more. Using functions of graphics.h in Turbo C compiler you can make graphics programs, animations, projects, and games. You can draw circles, lines, rectangles, bars and many other geometrical figures. You can change their colors using the available functions and fill them. Following is a list of functions of graphics.h header file.

Pages

Subscribe to RSS - graphics