#ifndef Cube_h #define Cube_h #include #include "Ecran.h" typedef struct { int x, y; } point; // Assign human-readable names to some common 16-bit color values: #define BLACK 0x0000 #define BLUE 0x001F #define RED 0xF800 #define GREEN 0x07E0 #define CYAN 0x07FF #define MAGENTA 0xF81F #define YELLOW 0xFFE0 #define WHITE 0xFFFF class Cube { public : Cube(Ecran * ecran); void draw(); private: void QuickSort(int deb, int fin); public : float x, y; private: Ecran * ecran; int key; float a = 0.0, b = 0.0; //float ax,ay,az; short lx[8] = {1, 1, 1, 1, -1, -1, -1, -1}; short ly[8] = {1, 1, -1, -1, 1, 1, -1, -1}; short lz[8] = {1, -1, 1, -1, 1, -1, 1, -1}; float lxn[8], lyn[8], lzn[8]; float xd[8], yd[8]; float c = 1.0; float xt, yt, zt; float mr[3][3]; float znm; int face[6][4] = {{4, 0, 1, 5}, {1, 0, 2, 3}, {5, 1, 3, 7}, {4, 5, 7, 6}, {0, 4, 6, 2}, {3, 2, 6, 7}}; int facec[6] = {10, 20, 30, 20, 30, 10}; point points[10]; // Quick sort int tri[12]; int zface[12]; }; #endif