X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fbatch.cpp;h=86ad9435fd29b2072581a73d72df9ab5c10c98ea;hb=b617c5d7b5283ad260a77f01e42e6170cabbc03d;hp=33481a1cdfc8c613692f36de60e667e8413ed698;hpb=927a1aa0a3a27e463ec0efc08bd08e7c4e969909;p=libs%2Fgl.git diff --git a/source/batch.cpp b/source/batch.cpp index 33481a1c..86ad9435 100644 --- a/source/batch.cpp +++ b/source/batch.cpp @@ -20,24 +20,24 @@ Batch::Batch(PrimitiveType t): max_index(0) { } -Batch &Batch::append(uint i) +Batch &Batch::append(unsigned i) { if(indices.empty()) - min_index=max_index=i; + min_index = max_index = i; else { - min_index=min(min_index, i); - max_index=max(max_index, i); + min_index = min(min_index, i); + max_index = max(max_index, i); } indices.push_back(i); return *this; } -void Batch::append(const vector &ind) +void Batch::append(const vector &ind) { indices.reserve(indices.size()+ind.size()); - for(vector::const_iterator i=ind.begin(); i!=ind.end(); ++i) + for(vector::const_iterator i=ind.begin(); i!=ind.end(); ++i) append(*i); } @@ -58,7 +58,7 @@ Batch::Loader::Loader(Batch &b): add("indices", &Loader::indices); } -void Batch::Loader::indices(const vector &ind) +void Batch::Loader::indices(const vector &ind) { obj.append(ind); }