Cube Rotation

#include<stdlib.h>#include<stdio.h>#include<GL/glut.h>#include<math.h>float v[8][3] = { {-1,-1,1},{-1,1,1},{1,1,1},{1,-1,1},{-1,-1,-1},{-1,1,-1},{1,1,-1},{1,-1,-1} };float p[8][3] = { {0,0,1},{0,1,1},{1,1,1},{1,0,1},{0,0,0},{0,1,0},{1,1,0},{1,0,0} };float theta[3] = { 0,0,0 };int flag = 2; void myinit(){    glMatrixMode(GL_PROJECTION);    glLoadIdentity();    glOrtho(-2, 2, -2, 2, -2, 2);    glMatrixMode(GL_MODELVIEW);}void idlefunc(){    theta[flag]++;    if (theta[flag] > 360)theta[flag] = 0;    glutPostRedisplay();}void mousefunc(int button, int status, int x, int y){    …

Cube Rotation Read More »

DiagnoEasy Healthcare

Business Address: 202 B, Sunrise Apartment (4th Floor), kolkata. West Bengal. 700068 India Business Phone: +91 6291 558 006 Business E-mail: support@diagnoeasy.com Website: https://diagnoeasy.com/ Description: If you’re like most people, the thought of going to the doctor or a lab for blood work can be daunting. But what if you could have a doctor’s visit …

DiagnoEasy Healthcare Read More »

Paste text,images,html and share with anyone
Scroll to Top