Rotate3D method example

Sub Rotate3D_Example()
' This example creates a cone in model space.
' It then rotates the cone about an axis.
    Const PI = 3.14159265
    Dim coneObj As Acad3DSolid
    Dim conePt(0 To 2) As Double
    Dim rotPt1(0 To 2) As Double
    Dim rotPt2(0 To 2) As Double
    conePt(0) = 2: conePt(1) = 2: conePt(2) = 0
    rotPt1(0) = 1: rotPt1(1) = 2: rotPt1(2) = 0
    rotPt2(0) = 3: rotPt2(1) = 4: rotPt2(2) = 0
    Set coneObj = ThisDrawing.ModelSpace.AddCone(conePt, 3, 4)
    MsgBox "About to 3d rotate cone"
    coneObj.Rotate3D rotPt1, rotPt2, PI / 4
    ThisDrawing.Application.ZoomAll
End Sub

© Bricsys NV. All rights reserved.