<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Object size not updated after points move]]></title><description><![CDATA[<p dir="auto">Hi there,</p>
<p dir="auto">I have a technical Python question which I can't seem to solve.</p>
<p dir="auto">The following script is used to store the points in an object, then reset the rotation of the object and then put the points back into their old position:</p>
<pre><code>def reAlignPoints(Object):
    if (Object.GetType() == c4d.Opolygon) or (Object.GetType() == c4d.Opoint):
        oldm = Object.GetMg()
        points = Object.GetAllPoints()
        pcount = Object.GetPointCount()
        Object.SetAbsRot(c4d.Vector(0))
        Object.SetAbsScale(c4d.Vector(1))
        newm = Object.GetMg()
        

        for p in range(pcount):
            Object.SetPoint(p,~newm*oldm*points[p])
</code></pre>
<p dir="auto">This works very well, however I'm running into a problem if I look under the Coordinate Manager of the object and then it's size. Under size the object still appears to be in it's old orientation at first glance.<br />
However, if I click on any of the size values and then simply hit enter, all the values jump around to the give the object it's correct orientation again.<br />
For instance, the longest axis is initially the "Z" axis (old orientation) but when I click the value and hit enter, the contents of the "Z" axis jump to the "Y" axis where they should be.</p>
<p dir="auto">My question is two fold:</p>
<ul>
<li>Why is this happening? What is going awry in my code that the object size is not properly updated?</li>
<li>What is the best way to fix this in python code and/or can I automate this clicking and hitting enter to switch the values around?</li>
</ul>
<p dir="auto">Currently I read the bounding box of the/multiple objects and compile a custom bounding box afterwards, but this currently has the wrong orientation because the size parameters are not in the correct axis.</p>
<p dir="auto">Kind regards,</p>
]]></description><link>http://developers.maxon.net/forum/topic/13840/object-size-not-updated-after-points-move</link><generator>RSS for Node</generator><lastBuildDate>Mon, 08 Jun 2026 15:32:20 GMT</lastBuildDate><atom:link href="http://developers.maxon.net/forum/topic/13840.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 14 Mar 2022 11:23:37 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Object size not updated after points move on Mon, 14 Mar 2022 14:27:10 GMT]]></title><description><![CDATA[<p dir="auto">Well, that indeed fixed the issue, now the size gets properly updated! <img src="http://developers.maxon.net/forum/assets/plugins/nodebb-plugin-emoji/emoji/android/1f642.png?v=0b8ddba251d" class="not-responsive emoji emoji-android emoji--slightly_smiling_face" style="height:23px;width:auto;vertical-align:middle" title=":)" alt="🙂" /></p>
<p dir="auto">Thank you very much for the help</p>
]]></description><link>http://developers.maxon.net/forum/post/68583</link><guid isPermaLink="true">http://developers.maxon.net/forum/post/68583</guid><dc:creator><![CDATA[Peek]]></dc:creator><pubDate>Mon, 14 Mar 2022 14:27:10 GMT</pubDate></item><item><title><![CDATA[Reply to Object size not updated after points move on Tue, 15 Mar 2022 08:28:20 GMT]]></title><description><![CDATA[<p dir="auto">Did you update the object? Can't see that in your code as posted.<br />
<a href="https://developers.maxon.net/docs/py/2023_2/modules/c4d/C4DAtom/GeListNode/BaseList2D/BaseObject/PointObject/index.html?highlight=setpoint#PointObject.SetPoint" target="_blank" rel="noopener noreferrer nofollow ugc">API docs say</a>:<br />
"Call obj.Message (c4d.MSG_UPDATE) after you set all your points to update the object."<br />
Which normally recalculates the bounding box (and whatever internal data the object holds).</p>
]]></description><link>http://developers.maxon.net/forum/post/68582</link><guid isPermaLink="true">http://developers.maxon.net/forum/post/68582</guid><dc:creator><![CDATA[Cairyn]]></dc:creator><pubDate>Tue, 15 Mar 2022 08:28:20 GMT</pubDate></item></channel></rss>