Salut a tous. Bon le titre est explicite et je ne suis surement pas le premier a avoir ce genre de problème ( dans le cas contraire je suis vraiment a la ramasse en Delphi ) mais comme j'ai pas envie de chercher dans les anciens sujets je reposte.


Bref voila mon problème, impossible d'afficher une texture, voila mon code :

_________________________________________________________________
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
 
unit testtextures;
 
interface
 
 uses
   SysUtils,
   OPENGL,
   glfw,
   SDLUtils,
   glaux,
   Textures;
 
 procedure initialisation();
 
implementation
 
 
procedure initialisation();
var
 jouer: boolean;
 fond: GLuint;
 
begin
 jouer:=TRUE;
 
 while (jouer) do
   begin
                                                        //initialisation de la fenetre OPENGL
     glfwInit();
     glfwOpenWindow(1000, 700, 0, 0, 0, 0, 42, 0, GLFW_WINDOW);
     glfwSetWindowTitle('Moteur'); // optionnel
     glBlendFunc(GL_SRC_ALPHA,GL_ONE);
     glClearColor( 0.0, 0.0, 0.0, 0.0 );
     glClear(GL_COLOR_BUFFER_BIT Or GL_DEPTH_BUFFER_BIT);
     glEnable( GL_DEPTH_TEST );
     glEnable(GL_TEXTURE_2D);
     LoadTexture('fond.jpg', fond, FALSE);
 
     glViewPort(0, 0, 1000, 700);
     glMatrixMode(GL_PROJECTION);
     gluperspective(70,(640/480),1,100);    
 
     glMatrixMode(GL_MODELVIEW);
     glLoadIdentity;
     gluLookAt(10, 0, 10, -5, 0,0, 0, 0, 1);
     glLoadIdentity;
 
 
     glBindTexture(GL_TEXTURE_2D, fond);
 
     glpushmatrix();     
     glBegin(GL_QUADS);
       glTexCoord2f(0,1);glVertex3f(0,0,0);
       glTexCoord2f(0,0);glVertex3f(0,1,0);
       glTexCoord2f(1,0);glVertex3f(0,1,1);
       glTexCoord2f(1,1);glVertex3f(1,0,1);
     glEnd;
     glpopmatrix();
 
 
     glfwSwapBuffers();
 
jouer := glfwGetKey(GLFW_KEY_ESC) = 0;
 
end;
end;
end.

J'appuie sur F9 et j'ai une magnifique fenetre noire.
Voila, si quelqu'un pouvait me dire ce qui va pas ...