fix: add_edge 返回数组下标(统一 ID 语义)
CI / Build & Test (push) Failing after 32s
CI / Release Build (push) Failing after 31s

This commit is contained in:
茂之钳
2026-07-23 16:46:11 +00:00
parent be76f495dc
commit f250a44875
+3 -3
View File
@@ -17,9 +17,9 @@ int BrepModel::add_edge(int v0, int v1) {
}
int BrepModel::add_edge(int v0, int v1, const curves::NurbsCurve& curve) {
int id = next_id_++;
edges_.push_back({id, v0, v1, std::make_shared<curves::NurbsCurve>(curve), false});
return id;
int idx = static_cast<int>(edges_.size());
edges_.push_back({next_id_++, v0, v1, std::make_shared<curves::NurbsCurve>(curve), false});
return idx;
}
int BrepModel::add_loop(const std::vector<int>& edge_ids, bool outer) {