public int getTriangleCount(int lod) {
        if (lodLevels != null) {
            if (lod < 0) {
                throw new IllegalArgumentException("LOD level cannot be < 0");
            }

            if (lod >= lodLevels.length) {
                throw new IllegalArgumentException("LOD level " + lod + " does not exist!");
            }

            return computeNumElements(lodLevels[lod].getData().limit());
        } else if (lod == 0) {
            return elementCount;
        } else {
            throw new IllegalArgumentException("There are no LOD levels on the mesh!");
        }
    }
Returns the triangle count for the given LOD level.

@param lod The lod level to look up
@return The triangle count for that LOD level
jme3-core/src/main/java/com/jme3/scene/Mesh.java