• Rotating and Moving Elements with VBA

    Jon Summers
    Jon Summers
    I've posted some articles about using matrices and transforms with MicroStation VBA to rotate or move (translate) a DGN element. The articles explain the purpose and use of Matrix3d and Transform3d , and how to apply them to an element.
    • http://www.la-solutions.co.uk/content/connect/mvba/MVBA-Matrices.htm
    • View
    • Hide
    • over 1 year ago
    • MicroStation Programming
    • MicroStation Programming Blog
  • Rotation and transformation matrix

    Finn Mejding
    Finn Mejding
    Hi, I'm struggling with placing a cell along an arc in VBA. I have a Complex Chain where I will place a cell along the whol chain with a fixed distance. I have solved the rotation on the "Line" part of the chainm but having trouble with the arc…
    • Answered
    • over 5 years ago
    • MicroStation Programming
    • MicroStation Programming Forum
  • RE: [V8i VBA] Automating rotated cell insertion - which Matrix3d method?

    Jon Summers
    Jon Summers
    Function ConstructMatrix3D (ByVal degrees As Double) As Matrix3D Dim angle As Double angle = Radians (degrees) ' Your angle is measured from North, so you may need to subtract 90 degrees if cell is oriented along X axis angle = angle - Pi() Const…
    • over 6 years ago
    • MicroStation Programming
    • MicroStation Programming Forum
  • RE: [V8i vba] how to tell if your cursor is to the left or right of a point in a rotated view

    Jon Summers
    Jon Summers
    Unknown said: How to tell if your cursor is to the left or right of a point? I've written a VBA project that shows how to do that... The macro works in dynamics. Start by identifying a cell. Move the cursor, and it draws the yellow line from the…
    • over 6 years ago
    • MicroStation Programming
    • MicroStation Programming Forum
  • RE: How to get rotation around axis?

    Jon Summers
    Jon Summers
    Unknown said: I have got the following details: slope angle angle of the slant edge width of the roof width, length, height of the beam When dealing with 3D geometry, work with vectors, transformations and matrices. MicroStation VBA…
    • over 6 years ago
    • MicroStation Programming
    • MicroStation Programming Forum
  • Re: Applying a 3D rotation to a cell

    Jon Summers
    Jon Summers
    Something like … Dim origin As Point3d origin = oElement.Origin Dim offset As Point3d offset = Point3dSubtract (Point3dZero, origin) oElement.Move offset ... do rotation oElement.Move origin oElement.Rewrite You haven't told us how you…
    • over 12 years ago
    • MicroStation Programming
    • [Archived] MicroStation V8i VBA Forum
  • Re: 'Target' module rotation error

    Jon Summers
    Jon Summers
    Matrix3d Initialisation Joshua Chung said: Dim RotMatrix As Matrix3d ... 'Create Circles Set MyCir = Application.CreateEllipseElement2(Nothing, CenPt, 0.25, 0.25, RotMatrix) Application.ActiveModelReference.AddElement MyCir …
    • over 12 years ago
    • MicroStation Programming
    • [Archived] MicroStation V8i VBA Forum
  • Re: Ellipses Rotated Incorrectly

    Jon Summers
    Jon Summers
    Initialise Data Correctly Dim rotMatrix As Matrix3d ... Set myCir = CreateEllipseElement2(Nothing, myCen, 0.068, 0.068, rotMatrix) You use a rotation matrix without initialising that variable. When you declare a variable and don't assign it a…
    • over 11 years ago
    • MicroStation Programming
    • [Archived] MicroStation V8i VBA Forum
  • Re: Applying a 3D rotation to a cell

    Jon Summers
    Jon Summers
    Both the order of rotation and the centre of rotation are important in 3D. In 2D it's much simpler. In 4D it's beyond human comprehension 8-) I'd start with 2D, just to keep things as simple as possible. When you construct a rotation matrix,…
    • over 12 years ago
    • MicroStation Programming
    • [Archived] MicroStation V8i VBA Forum
  • Re: Placing Orthographic Cell in Isometric Transformation

    Jon Summers
    Jon Summers
    3D Geometry Mike: I am looking to set a rotation using Matrix3d ... If you are working in 3D then understanding rotation matrices, embodied in VBA as Matrix3d , is vital. Rotation matrices are pretty well universal in 3D manipulations, and…
    • over 13 years ago
    • MicroStation Programming
    • [Archived] MicroStation V8 XM Edition Programming Forum
  • Re: How to get textelement rotation value in degree?

    Jon Summers
    Jon Summers
    VBA Forum Aravinthkumar: How can I get rotation value from TextElement . It returns the value only in Matrix3d . How can I get it in degrees? Post questions about MicroStation VBA to the VBA Forum . MicroStation is a 3D environment…
    • over 14 years ago
    • MicroStation
    • MicroStation Forum