MCPcopy Create free account
hub / github.com/KLayout/klayout / bbox

Method bbox

src/laybasic/laybasic/layLayerProperties.cc:815–839  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

813}
814
815db::DBox
816LayerPropertiesNode::bbox () const
817{
818 tl_assert (mp_view);
819 lay::CellView cv = mp_view->cellview (cellview_index ());
820
821 if (! cv.is_valid ()) {
822
823 return db::DBox ();
824
825 } else if (is_cell_box_layer ()) {
826
827 return overall_bbox ();
828
829 } else {
830
831 db::DBox b;
832 double dbu = cv->layout ().dbu ();
833 for (std::vector<db::DCplxTrans>::const_iterator t = trans ().begin (); t != trans ().end (); ++t) {
834 b += (*t * db::CplxTrans (dbu) * cv.context_trans ()) * cv.cell ()->bbox (layer_index ());
835 }
836 return b;
837
838 }
839}
840
841void
842LayerPropertiesNode::attach_view (LayoutViewBase *view, unsigned int list_index)

Callers

nothing calls this directly

Calls 12

cellview_indexFunction · 0.85
is_cell_box_layerFunction · 0.85
cellviewMethod · 0.80
context_transMethod · 0.80
layer_indexFunction · 0.70
transFunction · 0.50
is_validMethod · 0.45
dbuMethod · 0.45
layoutMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
cellMethod · 0.45

Tested by

no test coverage detected