diff options
Diffstat (limited to 'src/others/mimesh/g3dviewer-0.2.99.4/src/texture.c')
-rw-r--r-- | src/others/mimesh/g3dviewer-0.2.99.4/src/texture.c | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/src/others/mimesh/g3dviewer-0.2.99.4/src/texture.c b/src/others/mimesh/g3dviewer-0.2.99.4/src/texture.c new file mode 100644 index 0000000..0b6dccf --- /dev/null +++ b/src/others/mimesh/g3dviewer-0.2.99.4/src/texture.c | |||
@@ -0,0 +1,43 @@ | |||
1 | /* $Id: texture.c 42 2006-05-22 13:31:45Z mmmaddd $ */ | ||
2 | |||
3 | /* | ||
4 | G3DViewer - 3D object viewer | ||
5 | |||
6 | Copyright (C) 2005, 2006 Markus Dahms <mad@automagically.de> | ||
7 | |||
8 | This program is free software; you can redistribute it and/or modify | ||
9 | it under the terms of the GNU General Public License as published by | ||
10 | the Free Software Foundation; either version 2 of the License, or | ||
11 | (at your option) any later version. | ||
12 | |||
13 | This program is distributed in the hope that it will be useful, | ||
14 | but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
15 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
16 | GNU General Public License for more details. | ||
17 | |||
18 | You should have received a copy of the GNU General Public License | ||
19 | along with this program; if not, write to the Free Software | ||
20 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
21 | */ | ||
22 | |||
23 | #ifdef HAVE_CONFIG_H | ||
24 | # include <config.h> | ||
25 | #endif | ||
26 | |||
27 | #include <stdlib.h> | ||
28 | |||
29 | #include <g3d/g3d.h> | ||
30 | |||
31 | #include "gl.h" | ||
32 | |||
33 | int texture_load_all_textures(G3DModel *model) | ||
34 | { | ||
35 | if(model == NULL) return EXIT_FAILURE; | ||
36 | |||
37 | if(model->tex_images != NULL) | ||
38 | g_hash_table_foreach(model->tex_images, | ||
39 | gl_load_texture, NULL); | ||
40 | |||
41 | return EXIT_SUCCESS; | ||
42 | } | ||
43 | |||