- optimize BatchNode a bit
git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@9286 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
This commit is contained in:
parent
0345dd9601
commit
b7affd0147
@ -238,9 +238,9 @@ public class BatchNode extends Node implements Savable {
|
||||
List<Geometry> list = map.get(g.getMaterial());
|
||||
if (list == null) {
|
||||
//trying to compare materials with the isEqual method
|
||||
for (Material mat : map.keySet()) {
|
||||
if (g.getMaterial().isEqual(mat)) {
|
||||
list = map.get(mat);
|
||||
for ( Map.Entry<Material, List<Geometry>> mat : map.entrySet()) {
|
||||
if (g.getMaterial().isEqual(mat.getKey())) {
|
||||
list = mat.getValue();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user