Skip to content

Tag Archives: c-graphics

The header file graphics.h contains linerel() function which draws a line from the current position (x_pos1, y_pos1) to a point that is at a relative… Read More
The header file graphics.h contains lineto() function which draws a line from current position to the point(x,y). Note : Use getx() and gety() to get… Read More
The header file graphics.h contains getmaxy() function which returns the maximum Y coordinate for current graphics mode and driver. Syntax : int getmaxy(); Below is… Read More
The header file graphics.h contains getmaxx() function which returns the maximum X coordinate for current graphics mode and driver. Syntax : int getmaxx(); Below is… Read More
The header file graphics.h contains gety() function which returns the Y coordinate of the current position. Syntax : int gety(); Example : Explanation : Initially,… Read More
The header file graphics.h contains moveto() function which changes the current position to (x, y) Syntax : void moveto(int x, int y); Examples : Input… Read More
The header file graphics.h contains fillellipse() function which draws and fills an ellipse with center at (x, y) and (x_radius, y_radius) as x and y… Read More
The header file graphics.h contains sector() function which draws and fills an elliptical pie slice with (x, y) as center, (s_angle, e_angle) as starting and… Read More
The header file graphics.h contains getx() function which returns the X coordinate of the current position. Syntax : int getx(); Example : Explanation : Initially,… Read More
The header file graphics.h contains setlinestyle() function which sets the style for all lines drawn by line, lineto, rectangle, drawpoly, and so on. Syntax :… Read More
The header file graphics.h contains outtext() function which displays text at current position. Syntax : void outtext(char *string); Examples : Input : string = "Hello… Read More
The header file graphics.h contains settextstyle() function which is used to change the way in which text appears. Using it we can modify the size… Read More
The header file graphics.h contains fillpoly() function which is used to draw and fill a polygon i.e. triangle, rectangle, pentagon, hexagon etc. It require same… Read More
The header file graphics.h contains grapherrormsg() function which returns an error message string. Syntax : char *grapherrormsg( int errorcode ); where, errorcode: code for the… Read More
The header file graphics.h contains textwidth () function which returns the width of input string in pixels. Syntax : int textwidth(char *string); Example : Input… Read More