• 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. Allegro X Scripting - Skill
  3. Get a size of part outline

Stats

  • Replies 9
  • Subscribers 19
  • Views 13081
  • Members are here 0
More Content

Get a size of part outline

Rascal
Rascal over 6 years ago

Hi,

I'm trying to get a size of symbol's outline

I used axlDBGetExtents, but it only answers (0:0 0:0).

Help me to get a value of symbol's outline

  • Cancel
  • Sign in to reply
Parents
  • DavidJHutchins
    DavidJHutchins over 6 years ago

    I think axlDBGetExtents only works with physical objects (such as symbol, shape, lines), not logical objects ( such as components, functions & nets )

    below is an example of getting a symbol's outline, I only have package geometry/place_bound_top visible:

    \i (00:04:27) skill db1=car(axlGetSelSet())
    (00:04:27) dbid:357367248
    \i (00:04:30) skill db1->??
    (00:04:30) (prop nil bBox
    (00:04:30) ((1756.0 1364.4)
    (00:04:30) (2980.5 1964.4)
    (00:04:30) ) readOnly
    (00:04:30) t pins
    (00:04:30) (dbid:359594208 dbid:360335600) objType "symbol"
    (00:04:30) embeddedAttach nil embeddedMethod nil embeddedLayer
    (00:04:30) nil embedded nil fixedByTestPoint nil
    (00:04:30) component dbid:357309280 xy
    (00:04:30) (1876.0 1732.5) type
    (00:04:30) "PACKAGE" rotation 0.0 refdes "FB18"
    (00:04:30) parent dbid:297174832 name "SFB1612A" definition
    (00:04:30) dbid:357356208 mirrorType "NO" isMirrored nil
    (00:04:30) etchChildren nil children
    (00:04:30) (dbid:360907216 dbid:360907296 dbid:360907376 dbid:360907464 dbid:360907552
    (00:04:30) dbid:360907640 dbid:360907720 dbid:360907800 dbid:360907880 dbid:360908432
    (00:04:30) dbid:360908664 dbid:360908920 dbid:360909152 dbid:360909344 dbid:360909536
    (00:04:30) ) parentGroups
    (00:04:30) nil
    (00:04:30) )

    \i (00:04:56) skill 'axlDBGetExtents(db1 nil)'
    (00:04:56) ((1756.0 1364.4)
    (00:04:56) (2980.5 1964.4)
    (00:04:56) )
    \i (00:05:08) skill 'axlDBGetExtents(db1 t)'
    (00:05:08) ((1803.5 1364.4)
    (00:05:08) (2980.5 1964.4)
    (00:05:08) )

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Rascal
    Rascal over 6 years ago in reply to DavidJHutchins

    Thanks

    But I did same code, still it only showed me nil

    Is there any settings or something else that prior to get a extents from symbol ?

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 6 years ago in reply to Rascal

    It's not clear what you want.

    You could try axlDBGetExtents(axlDBGetShapes("PACKAGE GEOMETRY/PLACE_BOUND_TOP"), nil)

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
  • Jason Hsu
    Jason Hsu over 6 years ago in reply to eDave

    Hi Dave,

      axlDBGetExtents(axlDBGetShapes("PACKAGE GEOMETRY/PLACE_BOUND_TOP") is the extent if multi shapes exist on one layer.

      car(axlDBGetShapes("PACKAGE GEOMETRY/PLACE_BOUND_TOP")) ->bBox is only for one shape's extent, right? I learn one tip from you againSlight smile.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • eDave
    eDave over 6 years ago in reply to Jason Hsu

    Yes

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
  • Rascal
    Rascal over 6 years ago in reply to eDave

    Hi Dave, I also tried your comment but it's not what I want.

    What I really want is the shape of symbol on Place_Bound_Top Layer

    Because of library conditions, maybe, or my miss understanding of Allegro PCB Tools, I couldn't get proper data with axlDBGetExtents.

    Also, I found the value of my symbol Extents at Design Parameter tap (from mouse right click option), but the value was weird like Left X : -1000, Lower Y : -987.5000, Width 2000, Height 2000. (Maybe it's not the value that you mentioned.)  

    Anyway, I could found the value of symbol's shape at bBox value among the symbol's children properties, which objType was shape

    I'm still confused with the meaning of Extent, shape and bounding box.

    I'd appreciate if you explain how they are diffrent. 

    Thanks

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Reply
  • Rascal
    Rascal over 6 years ago in reply to eDave

    Hi Dave, I also tried your comment but it's not what I want.

    What I really want is the shape of symbol on Place_Bound_Top Layer

    Because of library conditions, maybe, or my miss understanding of Allegro PCB Tools, I couldn't get proper data with axlDBGetExtents.

    Also, I found the value of my symbol Extents at Design Parameter tap (from mouse right click option), but the value was weird like Left X : -1000, Lower Y : -987.5000, Width 2000, Height 2000. (Maybe it's not the value that you mentioned.)  

    Anyway, I could found the value of symbol's shape at bBox value among the symbol's children properties, which objType was shape

    I'm still confused with the meaning of Extent, shape and bounding box.

    I'd appreciate if you explain how they are diffrent. 

    Thanks

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Cancel
Children
  • Ejlersen
    Ejlersen over 6 years ago in reply to Rascal

    Hi

    Explaining these in detail is a long story. In short 

    Bounding Box is always the smallest rectangle embracing an object (or selection) The result is the lower left corner and upper right corner

    Design Extent. This is like a piece of paper that has a width and height. Left x is the leftmost x-coordinate and Lower Y is the bottom y-coordinate of the paper.

    So if you have a board that is 2000x2000 with lower left -1000 and lower Y -987.5 then the coordinate of the bottom left corner of the paper is -1000,-987.5 - in other words your 0,0 is placed approximately at the center of the paper - namely 1000 units in the x direction and 987.5 units in the y-direction

    If you then have a shape, whatever type or size, it will have a bounding box. Your Board or footprint will have extents.

    Hope this helps

    Ole

    • Cancel
    • Vote Up +1 Vote Down
    • Sign in to reply
    • Cancel
Cadence Guidelines

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