<?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: Resolving file references via c++ api in Maya Programming Forum</title>
    <link>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/6412059#M13025</link>
    <description>&lt;P&gt;Hi dculyba,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not sure if could be done with&amp;nbsp;C++ API.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But you can get unresolved referenced path and alter them with &lt;A href="http://help.autodesk.com/view/MAYAUL/2016/ENU/?url=http://help.autodesk.com/cloudhelp/2016/ENU/Maya-Tech-Docs/Commands/filePathEditor.html" target="_self"&gt;filePathEditor&lt;/A&gt;&amp;nbsp;and &lt;EM&gt;file -lr&lt;/EM&gt; to reload them later in MEL.&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>Thu, 30 Jun 2016 06:06:35 GMT</pubDate>
    <dc:creator>cheng_xi_li</dc:creator>
    <dc:date>2016-06-30T06:06:35Z</dc:date>
    <item>
      <title>Resolving file references via c++ api</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/6411690#M13024</link>
      <description>&lt;P&gt;I'm working with a legacy model pipeline that uses the Maya 2013 C++ libraries to process a large batch (hundreds) of models. Some of these models have file references that are absolute and incorrect for the machine the batch is running on. And given the existing workflow of the pipeline, these file references are essentially immutable. I've been looking for a way to remap these file references to match the directory structure of the batch machine, but all of my attempts have proven fruitless.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I've specifically tried all variations (different reference modes, &lt;EM&gt;wantUnresolvedNames=true, etc.)&amp;nbsp;&lt;/EM&gt;of MFileIO::open(), MFileIO::getReferences(), and MFileIO::getFiles().&amp;nbsp;If the referenced file is at the expected path then these calls return the expected references, but if the referenced file is missing then I get nothing.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Is there a right way to do this? Is this the right part of the pipeline to be doing this sort of thing?&lt;/P&gt;</description>
      <pubDate>Wed, 29 Jun 2016 21:44:22 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/6411690#M13024</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2016-06-29T21:44:22Z</dc:date>
    </item>
    <item>
      <title>Re: Resolving file references via c++ api</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/6412059#M13025</link>
      <description>&lt;P&gt;Hi dculyba,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am not sure if could be done with&amp;nbsp;C++ API.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;But you can get unresolved referenced path and alter them with &lt;A href="http://help.autodesk.com/view/MAYAUL/2016/ENU/?url=http://help.autodesk.com/cloudhelp/2016/ENU/Maya-Tech-Docs/Commands/filePathEditor.html" target="_self"&gt;filePathEditor&lt;/A&gt;&amp;nbsp;and &lt;EM&gt;file -lr&lt;/EM&gt; to reload them later in MEL.&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>Thu, 30 Jun 2016 06:06:35 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/6412059#M13025</guid>
      <dc:creator>cheng_xi_li</dc:creator>
      <dc:date>2016-06-30T06:06:35Z</dc:date>
    </item>
    <item>
      <title>Re: Resolving file references via c++ api</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/7546184#M13026</link>
      <description>&lt;P&gt;I'm trying to master the work with the &lt;STRONG&gt;filePathEditor&lt;/STRONG&gt; function in &lt;STRONG&gt;PyMEL 1.0.8&lt;/STRONG&gt; according to the &lt;A href="https://help.autodesk.com/cloudhelp/2016/ENU/Maya-Tech-Docs/PyMel/generated/functions/pymel.core.system/pymel.core.system.filePathEditor.html" target="_blank"&gt;documentation&lt;/A&gt;.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;But I was faced with the fact that not all flags are correctly received inside the &lt;STRONG&gt;Script Editor&lt;/STRONG&gt;.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Since this function is inherited from the &lt;STRONG&gt;MEL&lt;/STRONG&gt;, I also tried to use it via the &lt;STRONG&gt;MEL Script Editor&lt;/STRONG&gt;. But I had the same problems again. Whether I incorrectly apply them, or whether these flags don`t work in the mode described on the function page.&lt;BR /&gt;&lt;BR /&gt;I mean following flags:&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;-unresolved&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;FONT color="#FF0000"&gt;&lt;STRONG&gt;-attributeOnly&lt;/STRONG&gt;&lt;/FONT&gt;&lt;BR /&gt;&lt;BR /&gt;Could you tell me what's the problem?&lt;BR /&gt;Screenshot attached:&lt;BR /&gt;&lt;BR /&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="Maya2016_MEL_FPE_invalid_flags+comm.png" style="width: 705px;"&gt;&lt;img src="https://forums.autodesk.com/t5/image/serverpage/image-id/426575iEC90619AB5B3F93E/image-size/large?v=v2&amp;amp;px=999" role="button" title="Maya2016_MEL_FPE_invalid_flags+comm.png" alt="Maya2016_MEL_FPE_invalid_flags+comm.png" /&gt;&lt;/span&gt;&lt;BR /&gt;&lt;BR /&gt;P.S. By the way, in the description of the &lt;STRONG&gt;FilePathEditor&lt;/STRONG&gt; class in the file &lt;EM&gt;.../maya2016/devkit/other/pymel/extras/completion/py/pymel/core/system.py&lt;/EM&gt; these flags are absent. Maybe they are simply not supported?&lt;/P&gt;</description>
      <pubDate>Wed, 15 Nov 2017 14:13:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/7546184#M13026</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2017-11-15T14:13:56Z</dc:date>
    </item>
    <item>
      <title>Re: Resolving file references via c++ api</title>
      <link>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/7546252#M13027</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;It could be a flag added in Maya 2016 Extension 2. Document for Maya 2016 online contains 2016 Extension 2 content.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I tried both Maya 2016 and Maya 2016 Extension 2, it seems working fine in Maya 2016 Extension 2.&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, 15 Nov 2017 14:28:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/maya-programming-forum/resolving-file-references-via-c-api/m-p/7546252#M13027</guid>
      <dc:creator>cheng_xi_li</dc:creator>
      <dc:date>2017-11-15T14:28:43Z</dc:date>
    </item>
  </channel>
</rss>

