• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC SKILL
  3. how to get the bounding box of an instance excluding the...

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 144
  • Views 17271
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

how to get the bounding box of an instance excluding the labels inside that instance?

ashley
ashley over 16 years ago
Hi,
I'm new in skill coding and maybe someone can help me with my problem. 
How can I compute the bounding box of an instance excluding the labels inside that instance (and also the labels on its sub-cells)?  BBox of labels are sometimes out-of-grid and I want to exclude them especially when they are located on the edges.  I can filter out the labels if they are within the current cell view, but I don't know how to do it if they are inside the instances.
Thank you very much.
regards,
ashley
  • Cancel
Parents
  • skillUser
    skillUser over 16 years ago

     Hi Ashley,

    There is a function, dbComputeBBoxNoNLP(), that will calculate a cellviews' bounding box excluding any NLP labels that it contains, or its sub-cells.  Here is an example of how it might be used:

     ;; get the seleted instance object id
     inst = car(geGetSelectedSet())
     ;; calculate the bounding box of the instances' master and
     ;; transform the bounding box (to the current cellview's
     ;; co-ordinate system) using the instance transform
     geTransformUserBBox(dbComputeBBoxNoNLP(inst~>master) geGetInstTransform(inst))

    Now, I don't know if you are working in a layout (I will guess "yes") or a schematic, but there will likely be labels that are not NLP labels if you are working in a layout, so the above may not help too much.  If this is the case, then it may be necessary to write something like the dbComputeBBoxNoNLP() function yourself, excluding labels from the calculated bounding box. Let us know - someone may have already written such code that they wouldn't mind sharing.

    I hope that the above is at least a good starting point, if not the actual answer that you are looking for.

    Regards,

    Lawrence.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • skillUser
    skillUser over 16 years ago

     Hi Ashley,

    There is a function, dbComputeBBoxNoNLP(), that will calculate a cellviews' bounding box excluding any NLP labels that it contains, or its sub-cells.  Here is an example of how it might be used:

     ;; get the seleted instance object id
     inst = car(geGetSelectedSet())
     ;; calculate the bounding box of the instances' master and
     ;; transform the bounding box (to the current cellview's
     ;; co-ordinate system) using the instance transform
     geTransformUserBBox(dbComputeBBoxNoNLP(inst~>master) geGetInstTransform(inst))

    Now, I don't know if you are working in a layout (I will guess "yes") or a schematic, but there will likely be labels that are not NLP labels if you are working in a layout, so the above may not help too much.  If this is the case, then it may be necessary to write something like the dbComputeBBoxNoNLP() function yourself, excluding labels from the calculated bounding box. Let us know - someone may have already written such code that they wouldn't mind sharing.

    I hope that the above is at least a good starting point, if not the actual answer that you are looking for.

    Regards,

    Lawrence.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
No Data

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information