How to transform top level bBox into an instance bBox(top level tolevel1) ?

Discussion in 'Cadence' started by PolyPusher, Jan 26, 2012.

  1. PolyPusher

    PolyPusher Guest

    I am trying to Convert bBox from Top to Bottom, but couldn't get the
    answer I was needing.


    TopbBox=((320.54 -200.635) (320.94 -196.59))
    CellTransform=car(geGetSelectedSet())~>transform which equals ((307.21
    -192.96) "MXR90" 1.0)

    geTransformUserBBox(TopbBox CellTransform) which returns ((106.575
    127.58) (110.62 127.98))

    when I was expecting, by drawing the object with edit in place to be
    sure, (((-7.675 13.33)(-3.63 13.73)))

    What did I do wrong?

    Thank you in advance for any help,
    PolyPusher
     
    PolyPusher, Jan 26, 2012
    #1
  2. PolyPusher

    PolyPusher Guest

    "If it was a single level, you'd use dbTransformBBox() with the
    inst~>transform (actually that's going to be the wrong way around -
    that would transform from the instance coordinate space to the top
    level, not the other way. There is a function in IC5141 called
    icDbInvertTransform, but it's not documented in IC61X (it's part of
    Preview so whilst the function still exists in the IC614 build, it may
    be removed at some point) - so it would be safer to write your own
    (not hard). If you want to handle more than one level of hierarchy,
    you'd need to concatenate the transformations down through the
    hierarchy to the right instance by using dbConcatTransform.

    If the path to the instance is in the same form as returned by
    dbGet*Overlaps (e.g. dbGetTrueOverlaps) you could use
    geGetInstTransform to get the complete transformation - but again,
    this allows you to transform something from the level 2 coordinate
    space to level 0.

    Regards,

    Andrew."

    I found this post by Andrew that answers my question. The
    inst~>transform is for transforming form the instance up,
    icDbinvertTransform returns the opposite. From the top to the Master.

    TopbBox=((320.54 -200.635)(320.94 -196.59))
    CellTransformFromTopToMasterCell=icDbInvertTransform(geGetEditRep()
    car(geGetSelectedSet())~>transform)
    geTransformUserBBox(TopbBox CellTransformFromTopToMasterCell)

    Thank you,
    Eric
     
    PolyPusher, Jan 30, 2012
    #2
  3. Alternatively if this is for handling edit in place, you may just want
    to use geWindowToEditPoint - so in the case of a bBox, you'd do:

    newBBox=foreach(mapcar point TopbBox geWindowToEditPoint(windowId point))

    Andrew.
     
    Andrew Beckett, Jan 31, 2012
    #3
  4. PolyPusher

    PolyPusher Guest

    Andrew,

    In this case it wasn't for edit in place, but I do very much
    appreciate your reply. We needed to "push" routing from level 0 to
    level 1.

    Thank you for your support,
    Eric
     
    PolyPusher, Jan 31, 2012
    #4
Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.