Untitled

mail@pastecode.io avatar
unknown
plain_text
a year ago
587 B
1
Indexable
Never
#include<stdio.h>
#include<conio.h>
#include<dos.h>
#include<graphics.h>
void main()
{
	int gd=DETECT,gm;
	float shx,shy;
	initgraph(&gd,&gm,"C:\\TurboC3\\BGI");
	printf("Enter shear factor shy along y-axis :");
	scanf("%f",&shy);
	line(200,110,300,110);
	line(300,110,300,300);
	line(300,300,200,300);
	line(200,300,200,110);
	printf("Y-shear");
	setcolor(12);
	line(200,110+(shy*200),300,110+(shy*300));
	line(300,110+(shy*300),300,300+(shy*300));
	line(300,300+(shy*300),200,300+(shy*200));
	line(200,300+(shy*200),200,110+(shy*200));
	getch();
	closegraph();
}