Get the coordinates of the inner wrapper

I use microstation 08.11.09.578, DGN 2D V7 Upgrade V8
I use C# language

When fitview it will align the map
I want to get the polygon coordinates that wrap the inner lines like the green line, is it possible?

Bentley.Interop.MicroStationDGN.View v = app.ActiveDesignFile.Views[1];
Point3d point = v.get_Origin();
Point3d point2 = v.get_Center();

The code I tried but not as expected

Parents
  • I use MicroStation 08.11. I use C# language.

    When you write C# code for MicroStation V8i, you're using an InterOp to call the VBA COM interface.

    Element Range

    I want to get the polygon coordinates that wrap the inner lines

    Every graphic DGN element has a range (VBA Range3d), which you can obtain using Element.Range.  You can scan a DGN model to get its elements, and then calculate the intersection of all element ranges.  If you're trying to get all elements in a DGN model, then ModelReference.Range is a faster way to get what you want.

    Convex Hull

    A convex hull is analogous to an elastic band stretched around a set of DGN elements.  I've described a way to generate a convex hull in MicroStation.  However, that requires a different programming language (C++ or C#) — VBA is not up to the task.

     
    Regards, Jon Summers
    LA Solutions

Reply
  • I use MicroStation 08.11. I use C# language.

    When you write C# code for MicroStation V8i, you're using an InterOp to call the VBA COM interface.

    Element Range

    I want to get the polygon coordinates that wrap the inner lines

    Every graphic DGN element has a range (VBA Range3d), which you can obtain using Element.Range.  You can scan a DGN model to get its elements, and then calculate the intersection of all element ranges.  If you're trying to get all elements in a DGN model, then ModelReference.Range is a faster way to get what you want.

    Convex Hull

    A convex hull is analogous to an elastic band stretched around a set of DGN elements.  I've described a way to generate a convex hull in MicroStation.  However, that requires a different programming language (C++ or C#) — VBA is not up to the task.

     
    Regards, Jon Summers
    LA Solutions

Children