<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re : Set Angled UCS in .NET Forum</title>
    <link>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914652#M32491</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Maybe this is more readable:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;private Matrix3d Ucs3Points(Point3d origin, Point3d pointX, Point3d pointY)
{
    Vector3d toXAxis = origin.GetVectorTo(pointX).GetNormal();
    Vector3d toZAxis = toXAxis.CrossProduct(origin.GetVectorTo(pointY)).GetNormal();
    Vector3d toYAxis = toZAxis.CrossProduct(toXAxis).GetNormal();
    return Matrix3d.AlignCoordinateSystem(
        Point3d.Origin, Vector3d.XAxis, Vector3d.YAxis, Vector3d.ZAxis,
        origin, toXAxis, toYAxis, toZAxis);
}&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Use with current UCS defined points (e.g. got with ed.GetPoint()):&lt;/P&gt;
&lt;PRE&gt;ed.CurrentUserCoordinateSystem *= Ucs3Points(org, ptX, ptY);&lt;/PRE&gt;
&lt;P&gt;Use with WCS defined points:&lt;/P&gt;
&lt;PRE&gt;ed.CurrentUserCoordinateSystem = Ucs3Points(org, ptX, ptY);&lt;/PRE&gt;</description>
    <pubDate>Thu, 02 Mar 2017 07:39:33 GMT</pubDate>
    <dc:creator>_gile</dc:creator>
    <dc:date>2017-03-02T07:39:33Z</dc:date>
    <item>
      <title>Set Angled UCS</title>
      <link>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914587#M32489</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I am getting 3 points from user and then I need to set the UCS in angled as shown in the picture&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="AngUcs.PNG" style="width: 652px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/328366i6FEDCA7A8E7DBBDA/image-size/large?v=v2&amp;amp;px=999" role="button" title="AngUcs.PNG" alt="AngUcs.PNG" /&gt;&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Please Help Me.....&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Mar 2017 06:34:55 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914587#M32489</guid>
      <dc:creator>abdulhaseeb114</dc:creator>
      <dc:date>2017-03-02T06:34:55Z</dc:date>
    </item>
    <item>
      <title>Re: Set Angled UCS</title>
      <link>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914604#M32490</link>
      <description>&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have you tried something like this :&lt;/P&gt;
&lt;P&gt;&lt;A href="https://knowledge.autodesk.com/search-result/caas/CloudHelp/cloudhelp/2015/ENU/AutoCAD-NET/files/GUID-096085E3-5AD5-4454-BF10-C9177FDB5979-htm.html" target="_blank"&gt;https://knowledge.autodesk.com/search-result/caas/CloudHelp/cloudhelp/2015/ENU/AutoCAD-NET/files/GUID-096085E3-5AD5-4454-BF10-C9177FDB5979-htm.html&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Regards,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 02 Mar 2017 06:45:25 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914604#M32490</guid>
      <dc:creator>kerry_w_brown</dc:creator>
      <dc:date>2017-03-02T06:45:25Z</dc:date>
    </item>
    <item>
      <title>Re : Set Angled UCS</title>
      <link>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914652#M32491</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Maybe this is more readable:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;private Matrix3d Ucs3Points(Point3d origin, Point3d pointX, Point3d pointY)
{
    Vector3d toXAxis = origin.GetVectorTo(pointX).GetNormal();
    Vector3d toZAxis = toXAxis.CrossProduct(origin.GetVectorTo(pointY)).GetNormal();
    Vector3d toYAxis = toZAxis.CrossProduct(toXAxis).GetNormal();
    return Matrix3d.AlignCoordinateSystem(
        Point3d.Origin, Vector3d.XAxis, Vector3d.YAxis, Vector3d.ZAxis,
        origin, toXAxis, toYAxis, toZAxis);
}&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Use with current UCS defined points (e.g. got with ed.GetPoint()):&lt;/P&gt;
&lt;PRE&gt;ed.CurrentUserCoordinateSystem *= Ucs3Points(org, ptX, ptY);&lt;/PRE&gt;
&lt;P&gt;Use with WCS defined points:&lt;/P&gt;
&lt;PRE&gt;ed.CurrentUserCoordinateSystem = Ucs3Points(org, ptX, ptY);&lt;/PRE&gt;</description>
      <pubDate>Thu, 02 Mar 2017 07:39:33 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/net-forum/set-angled-ucs/m-p/6914652#M32491</guid>
      <dc:creator>_gile</dc:creator>
      <dc:date>2017-03-02T07:39:33Z</dc:date>
    </item>
  </channel>
</rss>

