Quantcast
Channel: MicroStation Programming Forum - Recent Threads
Viewing all articles
Browse latest Browse all 7260

RE: problem with matrix3d rotation

$
0
0

[quote user="Werner Vinck"]Dim Axis As Point3d
        Axis.X = 0
        Axis.Y = 0
        Axis.Z = 1[/quote]

Dim Axis As Point3d
Axis = Point3dFromXYZ (0, 0, 1)

Is that clearer?

[quote user="Werner Vinck"]Vect.X = Tpoint(0).X - Tpoint(1).X
            Vect.Y = Tpoint(0).Y - Tpoint(1).Y
            Vect.Z = Tpoint(0).Z - Tpoint(1).Z[/quote]

Vect = Point3dSubtract (Tpoint(0), Tpoint(1))

That's definitely clearer!

[quote user="Werner Vinck"]If Vect.X <> 0 Then Vect.X = (Vect.X / AfstV) * Ls
            If Vect.Y <> 0 Then Vect.Y = (Vect.Y / AfstV) * Ls
            If Vect.Z <> 0 Then Vect.Z = (Vect.Y / AfstV) * Ls[/quote]

Not sure what that test is for!  You want to scale Vect.X by Ls / AfstV?  If Vect.X is zero then the result is zero: why test for non-zero? 

Vect = Point3dScale (Vect, Ls / AfstV)


Viewing all articles
Browse latest Browse all 7260

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>