| Issue 15: | I find a bug in 3dsplay.cpp code | |
| 1 person starred this issue and may be notified of changes. | Back to list |
I find a bug in demo code "3dsplay.cpp"
in function
static void render_node(Lib3dsNode *node)
{
...
#ifdef USE_SDL
Player_texture *pt = NULL;
int tex_mode = 0;
#endif
if (mesh->faces[p].material > 0) {
mat = file->materials[mesh->faces[p].material];
}
...
}
I think "if (mesh->faces[p].material > 0) " should to "if (mesh->faces[p].material >= 0) "
if use ">", it could not use first material in 3ds file.
|