Subversion Repositories gelsvn

Rev

Rev 567 | Rev 601 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 567 Rev 595
Line -... Line 1...
-
 
1
/* ----------------------------------------------------------------------- *
1
// bdl, jab, feb 2005
2
 * This file is part of GEL, http://www.imm.dtu.dk/GEL
2
// Inspired by Nate Robins Obj loader
3
 * Copyright (C) the authors and DTU Informatics
-
 
4
 * For license and list of authors, see ../../doc/intro.pdf
-
 
5
 * ----------------------------------------------------------------------- */
3
 
6
 
4
#include <CGLA/Vec3f.h>
7
#include <CGLA/Vec3f.h>
5
#include <stdio.h>
8
#include <stdio.h>
6
#include <iostream>
9
#include <iostream>
7
 
10
 
Line 15... Line 18...
15
	int TriMesh::find_material(const string& name) const
18
	int TriMesh::find_material(const string& name) const
16
	{
19
	{
17
		for(size_t i=0;i<materials.size(); ++i)
20
		for(size_t i=0;i<materials.size(); ++i)
18
			{
21
			{
19
				if(materials[i].name == name)
22
				if(materials[i].name == name)
20
					return i;
23
                    return i;
21
			}
24
            }
22
		return 0;
25
		return 0;
23
	}
26
	}
24
	
27
	
25
	void TriMesh::compute_normals()
28
	void TriMesh::compute_normals()
26
	{		
29
	{