mirror of https://github.com/KLayout/klayout.git
Some cleanup
This commit is contained in:
parent
4543eaabac
commit
dc6408a068
|
|
@ -1070,7 +1070,6 @@ AsIfFlatRegion::run_check (db::edge_relation_type rel, bool different_polygons,
|
||||||
#if defined(USE_LOCAL_PROCESSOR)
|
#if defined(USE_LOCAL_PROCESSOR)
|
||||||
|
|
||||||
bool needs_merged_primary = different_polygons || options.needs_merged ();
|
bool needs_merged_primary = different_polygons || options.needs_merged ();
|
||||||
needs_merged_primary = true; // @@@
|
|
||||||
|
|
||||||
db::RegionIterator polygons (needs_merged_primary ? begin_merged () : begin ());
|
db::RegionIterator polygons (needs_merged_primary ? begin_merged () : begin ());
|
||||||
bool primary_is_merged = ! merged_semantics () || needs_merged_primary || is_merged ();
|
bool primary_is_merged = ! merged_semantics () || needs_merged_primary || is_merged ();
|
||||||
|
|
|
||||||
|
|
@ -1561,7 +1561,7 @@ CompoundRegionCheckOperationNode::CompoundRegionCheckOperationNode (CompoundRegi
|
||||||
tl_assert (input == 0); // input is a dummy parameter
|
tl_assert (input == 0); // input is a dummy parameter
|
||||||
|
|
||||||
m_has_other = other->has_external_inputs ();
|
m_has_other = other->has_external_inputs ();
|
||||||
// @@@ needs a concept to deal with merged/non-merged inputs
|
// TODO: needs a concept to deal with merged/non-merged inputs
|
||||||
m_is_other_merged = other->is_merged ();
|
m_is_other_merged = other->is_merged ();
|
||||||
|
|
||||||
set_description ("check");
|
set_description ("check");
|
||||||
|
|
@ -1588,8 +1588,8 @@ CompoundRegionCheckOperationNode::computed_dist () const
|
||||||
void
|
void
|
||||||
CompoundRegionCheckOperationNode::do_compute_local (CompoundRegionOperationCache * /*cache*/, db::Layout *layout, const shape_interactions<db::Polygon, db::Polygon> &interactions, std::vector<std::unordered_set<db::EdgePair> > &results, size_t max_vertex_count, double area_ratio) const
|
CompoundRegionCheckOperationNode::do_compute_local (CompoundRegionOperationCache * /*cache*/, db::Layout *layout, const shape_interactions<db::Polygon, db::Polygon> &interactions, std::vector<std::unordered_set<db::EdgePair> > &results, size_t max_vertex_count, double area_ratio) const
|
||||||
{
|
{
|
||||||
// @@@ needs a concept to deal with merged/non-merged primary
|
// TODO: needs a concept to deal with merged/non-merged inputs
|
||||||
bool is_merged = true;
|
bool is_merged = true;
|
||||||
db::check_local_operation<db::Polygon, db::Polygon> op (m_check, m_different_polygons, is_merged, m_has_other, m_is_other_merged, m_options);
|
db::check_local_operation<db::Polygon, db::Polygon> op (m_check, m_different_polygons, is_merged, m_has_other, m_is_other_merged, m_options);
|
||||||
|
|
||||||
tl_assert (results.size () == 1);
|
tl_assert (results.size () == 1);
|
||||||
|
|
@ -1606,8 +1606,8 @@ bool is_merged = true;
|
||||||
void
|
void
|
||||||
CompoundRegionCheckOperationNode::do_compute_local (CompoundRegionOperationCache * /*cache*/, db::Layout *layout, const shape_interactions<db::PolygonRef, db::PolygonRef> &interactions, std::vector<std::unordered_set<db::EdgePair> > &results, size_t max_vertex_count, double area_ratio) const
|
CompoundRegionCheckOperationNode::do_compute_local (CompoundRegionOperationCache * /*cache*/, db::Layout *layout, const shape_interactions<db::PolygonRef, db::PolygonRef> &interactions, std::vector<std::unordered_set<db::EdgePair> > &results, size_t max_vertex_count, double area_ratio) const
|
||||||
{
|
{
|
||||||
// @@@ needs a concept to deal with merged/non-merged primary
|
// TODO: needs a concept to deal with merged/non-merged inputs
|
||||||
bool is_merged = true;
|
bool is_merged = true;
|
||||||
db::check_local_operation<db::PolygonRef, db::PolygonRef> op (m_check, m_different_polygons, is_merged, m_has_other, m_is_other_merged, m_options);
|
db::check_local_operation<db::PolygonRef, db::PolygonRef> op (m_check, m_different_polygons, is_merged, m_has_other, m_is_other_merged, m_options);
|
||||||
|
|
||||||
tl_assert (results.size () == 1);
|
tl_assert (results.size () == 1);
|
||||||
|
|
|
||||||
|
|
@ -317,7 +317,7 @@ check_local_operation<TS, TI>::do_compute_local (db::Layout *layout, const shape
|
||||||
++nn;
|
++nn;
|
||||||
}
|
}
|
||||||
|
|
||||||
// @@@ Use edges directly
|
// TODO: Use edges directly
|
||||||
polygons.clear ();
|
polygons.clear ();
|
||||||
|
|
||||||
db::polygon_ref_generator<TI> ps (layout, polygons);
|
db::polygon_ref_generator<TI> ps (layout, polygons);
|
||||||
|
|
@ -402,7 +402,7 @@ check_local_operation<TS, TI>::do_compute_local (db::Layout *layout, const shape
|
||||||
++nn;
|
++nn;
|
||||||
}
|
}
|
||||||
|
|
||||||
// @@@ Use edges directly
|
// TODO: Use edges directly
|
||||||
spolygons.clear ();
|
spolygons.clear ();
|
||||||
|
|
||||||
db::polygon_ref_generator<TS> ps (layout, spolygons);
|
db::polygon_ref_generator<TS> ps (layout, spolygons);
|
||||||
|
|
@ -836,7 +836,10 @@ void interacting_local_operation<TS, TI, TR>::do_compute_local (db::Layout * /*l
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
tl_assert (nstart > 0);
|
if (nstart == 0) {
|
||||||
|
// should not happen - but for safety we return here.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
db::InteractionDetector id (m_mode, nstart - 1);
|
db::InteractionDetector id (m_mode, nstart - 1);
|
||||||
id.set_include_touching (m_touching);
|
id.set_include_touching (m_touching);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue