Changeset 374 for trunk/src/formats
- Timestamp:
- 05/26/15 17:35:06 (10 years ago)
- Location:
- trunk/src/formats
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/formats/md2_loader.cc
r367 r374 238 238 } 239 239 240 size_t md2_loader::get_max_frames() const240 nv::size_t md2_loader::get_max_frames() const 241 241 { 242 242 return static_cast< size_t >( ((md2_t*)m_md2)->header.num_frames ); -
trunk/src/formats/md3_loader.cc
r367 r374 172 172 source.read( surface->vertices, sizeof( md3_vertex_t ), static_cast<size_t>( surface->header.num_verts * surface->header.num_frames ) ); 173 173 174 if ( source.tell() != static_cast<s td::size_t>( pos + surface->header.ofs_end ) ) return false;174 if ( source.tell() != static_cast<size_t>( pos + surface->header.ofs_end ) ) return false; 175 175 176 176 return true; -
trunk/src/formats/md5_loader.cc
r367 r374 344 344 vtc.tangent = glm::vec3(0); 345 345 346 std::sort( weights + start_weight, weights + start_weight + weight_count, [](const md5_weight& a, const md5_weight& b) -> bool { return a.bias > b.bias; } ); 346 stable_sort( weights + start_weight, weights + start_weight + weight_count, [] ( const md5_weight& a, const md5_weight& b ) -> bool { return a.bias > b.bias; } ); 347 //std::sort( weights + start_weight, weights + start_weight + weight_count, [](const md5_weight& a, const md5_weight& b) -> bool { return a.bias > b.bias; } ); 347 348 348 349 if ( weight_count > 4 ) -
trunk/src/formats/obj_loader.cc
r319 r374 53 53 std::string next_name; 54 54 55 s td::size_t size;56 bool 55 size_t size; 56 bool eof; 57 57 58 58 obj_reader(); … … 172 172 { 173 173 mesh_data_reader( bool normals ) : m_normals( normals ) {} 174 virtual s td::size_t add_face( uint32* vi, uint32* ti, uint32* ni, size_t count )174 virtual size_t add_face( uint32* vi, uint32* ti, uint32* ni, size_t count ) 175 175 { 176 176 if ( count < 3 ) return 0; // TODO : report error? … … 178 178 // TODO : support if normals not present; 179 179 vec3 nullvec; 180 s td::size_t result = 0;180 size_t result = 0; 181 181 // Simple triangulation - obj's shouldn't have more than quads anyway 182 182 … … 278 278 } 279 279 280 for (s td::size_t a = 0; a < count; ++a )280 for (size_t a = 0; a < count; ++a ) 281 281 { 282 282 const vec3& n = m_data[a].normal;
Note: See TracChangeset
for help on using the changeset viewer.