Lines Matching full:branches
15 std::vector<Branch> branches; in insert() local
16 branches.reserve(N); in insert()
27 branches.push_back(b); in insert()
30 fCount = (int)branches.size(); in insert()
36 n->fChildren[0] = branches[0]; in insert()
38 fRoot.fBounds = branches[0].fBounds; in insert()
41 fRoot = this->bulkLoad(&branches); in insert()
57 int SkRTree::CountNodes(int branches) { in CountNodes() argument
58 if (branches == 1) { in CountNodes()
61 int numBranches = branches / kMaxChildren; in CountNodes()
62 int remainder = branches % kMaxChildren; in CountNodes()
73 while (currentBranch < branches) { in CountNodes()
86 for (int k = 1; k < incrementBy && currentBranch < branches; ++k) { in CountNodes()
93 SkRTree::Branch SkRTree::bulkLoad(std::vector<Branch>* branches, int level) { in bulkLoad() argument
94 if (branches->size() == 1) { // Only one branch. It will be the root. in bulkLoad()
95 return (*branches)[0]; in bulkLoad()
98 // We might sort our branches here, but we expect Blink gives us a reasonable x,y order. in bulkLoad()
101 int numBranches = (int)branches->size() / kMaxChildren; in bulkLoad()
102 int remainder = (int)branches->size() % kMaxChildren; in bulkLoad()
107 // If the remainder isn't enough to fill a node, we'll add fewer nodes to other branches. in bulkLoad()
116 while (currentBranch < (int)branches->size()) { in bulkLoad()
130 n->fChildren[0] = (*branches)[currentBranch]; in bulkLoad()
132 b.fBounds = (*branches)[currentBranch].fBounds; in bulkLoad()
135 for (int k = 1; k < incrementBy && currentBranch < (int)branches->size(); ++k) { in bulkLoad()
136 b.fBounds.join((*branches)[currentBranch].fBounds); in bulkLoad()
137 n->fChildren[k] = (*branches)[currentBranch]; in bulkLoad()
141 (*branches)[newBranches] = b; in bulkLoad()
144 branches->resize(newBranches); in bulkLoad()
145 return this->bulkLoad(branches, level + 1); in bulkLoad()