Add source
This commit is contained in:
parent
796214099c
commit
b052570c1c
5 changed files with 15 additions and 7 deletions
|
@ -1,3 +1,5 @@
|
|||
/* Auteur : Farès BELHADJ (amsi@up8.edu) */
|
||||
|
||||
#version 330
|
||||
|
||||
uniform float delta_temps;
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
/* Auteur : Farès BELHADJ (amsi@up8.edu) */
|
||||
|
||||
#version 330
|
||||
|
||||
layout (location = 0) in vec3 vsiPosition;
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
#include "../includes/animations.h"
|
||||
|
||||
/* TP6 */
|
||||
|
||||
void cube(int etat) {
|
||||
static GLuint cube = 0, proc_id = 0;
|
||||
|
||||
|
@ -9,9 +11,9 @@ void cube(int etat) {
|
|||
|
||||
switch(etat) {
|
||||
case GL4DH_INIT:
|
||||
r = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
g = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
b = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
r = rand() / (float)RAND_MAX;
|
||||
g = rand() / (float)RAND_MAX;
|
||||
b = rand() / (float)RAND_MAX;
|
||||
|
||||
cube = gl4dgGenCubef();
|
||||
proc_id = gl4duCreateProgram("<vs>shaders/cube.vs", "<fs>shaders/cube.fs", NULL);
|
||||
|
|
|
@ -1,5 +1,7 @@
|
|||
#include "../includes/animations.h"
|
||||
|
||||
/* TP6 */
|
||||
|
||||
void cube2(int etat) {
|
||||
static GLuint cube = 0, proc_id = 0;
|
||||
|
||||
|
@ -9,9 +11,9 @@ void cube2(int etat) {
|
|||
|
||||
switch(etat) {
|
||||
case GL4DH_INIT:
|
||||
r = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
g = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
b = (rand() / (float)(RAND_MAX)) * 1.f;
|
||||
r = rand() / (float)RAND_MAX;
|
||||
g = rand() / (float)RAND_MAX;
|
||||
b = rand() / (float)RAND_MAX;
|
||||
|
||||
cube = gl4dgGenCubef();
|
||||
proc_id = gl4duCreateProgram("<vs>shaders/cube.vs", "<fs>shaders/cube.fs", NULL);
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
#include "../includes/animations.h"
|
||||
|
||||
/* Fondu de Farès BELHADJ */
|
||||
/* Auteur : Farès BELHADJ (amsi@up8.edu) */
|
||||
|
||||
void fondu(void (* ancienne_anim)(int), void (* nouvelle_anim)(int), Uint32 temps_total, Uint32 temps_ecoule, int etat) {
|
||||
GLint viewport[4];
|
||||
|
|
Reference in a new issue