<?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 anyone know how to use MUserData properly? in Maya Programming Forum</title>
    <link>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8048757#M9718</link>
    <description>&lt;P&gt;so i understand if your developing a plugin for maya2018 using mpxDrawOverride class. That it is not good to run calculations in the addIUDrawables fn of the class. instead you should use preparefordraw() call and MUserData class.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;question is. If im already calculating stuff in the compute of the mpxlocatorNode how can i pass this to the MuserData so that prepare for draw can use it?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;can i communicate with MUserData from the compute of the MPxLocatorNode?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;</description>
    <pubDate>Tue, 05 Jun 2018 20:05:19 GMT</pubDate>
    <dc:creator>a3dcreator</dc:creator>
    <dc:date>2018-06-05T20:05:19Z</dc:date>
    <item>
      <title>anyone know how to use MUserData properly?</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8048757#M9718</link>
      <description>&lt;P&gt;so i understand if your developing a plugin for maya2018 using mpxDrawOverride class. That it is not good to run calculations in the addIUDrawables fn of the class. instead you should use preparefordraw() call and MUserData class.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;question is. If im already calculating stuff in the compute of the mpxlocatorNode how can i pass this to the MuserData so that prepare for draw can use it?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;can i communicate with MUserData from the compute of the MPxLocatorNode?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jun 2018 20:05:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8048757#M9718</guid>
      <dc:creator>a3dcreator</dc:creator>
      <dc:date>2018-06-05T20:05:19Z</dc:date>
    </item>
    <item>
      <title>Re: anyone know how to use MUserData properly?</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8049418#M9719</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Since you are using MPxDrawOverride,&amp;nbsp;the override is initialized with the object of your MPxLocatorNode. You could get a pointer to your node with &lt;A href="http://help.autodesk.com/cloudhelp/2018/ENU/Maya-SDK/cpp_ref/class_m_fn_dependency_node.html#a4f2c53c9d1dcf25a6462c70fb25aead1" target="_blank"&gt;MFnDependencyNode::userNode.&lt;/A&gt; &amp;nbsp;You could access to the data in your node directly through this pointer and prepare the userData in the prepareDraw.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Yours,&lt;/P&gt;
&lt;P&gt;Li&lt;/P&gt;</description>
      <pubDate>Wed, 06 Jun 2018 03:34:42 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8049418#M9719</guid>
      <dc:creator>cheng_xi_li</dc:creator>
      <dc:date>2018-06-06T03:34:42Z</dc:date>
    </item>
    <item>
      <title>Re: anyone know how to use MUserData properly?</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8064457#M9720</link>
      <description>&lt;P&gt;Thank you Cheng it worked!&lt;/P&gt;</description>
      <pubDate>Wed, 13 Jun 2018 05:39:21 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/anyone-know-how-to-use-muserdata-properly/m-p/8064457#M9720</guid>
      <dc:creator>a3dcreator</dc:creator>
      <dc:date>2018-06-13T05:39:21Z</dc:date>
    </item>
  </channel>
</rss>

