<?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 Dead UV questions. in 3ds Max Programming Forum</title>
    <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/dead-uv-questions/m-p/13662942#M29014</link>
    <description>&lt;P&gt;UPD: Ugh, serves me right for being lazy and grabbing UV reading code from previous script, instead of searching docs for proper way of doing it.&lt;BR /&gt;Should have used&amp;nbsp;$.Unwrap_UVW.getVertexPosition&amp;nbsp;t v&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After a series of unfolds and welds, something happens with UVs.&lt;BR /&gt;For example, I'm getting vertex index from face, but max gives an error when I try to get this vert's coords.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;$.Unwrap_UVW.GetVertexIndexFromFace 2 3
674

polyop.getMapVert $ 1 674
-- Runtime error: Mesh map vertex index out of range:  &amp;lt; 1 or &amp;gt; 448: 674
-- MAXScript callstack:
--	thread data: threadID:3220
--	------------------------------------------------------
--	[stack level: 0]
--	In top-level&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;Questions are:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1. How to detect it&lt;/STRONG&gt;&lt;BR /&gt;Atm seems like I can check it by comparing these:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;polyop.getNumMapVerts $ 1
448

$.Unwrap_UVW.NumberVertices()
688&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2. How to solve it&lt;/STRONG&gt;&lt;BR /&gt;So far only solution I found is to collapse the stack. Ideally, I would like a way that allows me to fix it with code, something clean and simple, similar to&amp;nbsp;polyop.deleteIsoVerts $ for example.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;3. How to prevent it&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Only operations are unfold and weld on current selection&lt;/P&gt;&lt;LI-CODE lang="general"&gt;$.unwrap_UVW.unfoldMap 1 true
$.unwrap_UVW.weldSelected()&lt;/LI-CODE&gt;&lt;P&gt;Anything wrong with that, should I do it in some different way?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attaching a max2021 file in case you like puzzles and willing to investigate.&lt;/P&gt;</description>
    <pubDate>Tue, 03 Jun 2025 08:34:49 GMT</pubDate>
    <dc:creator>dmitriy.shpilevoy</dc:creator>
    <dc:date>2025-06-03T08:34:49Z</dc:date>
    <item>
      <title>Dead UV questions.</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/dead-uv-questions/m-p/13662942#M29014</link>
      <description>&lt;P&gt;UPD: Ugh, serves me right for being lazy and grabbing UV reading code from previous script, instead of searching docs for proper way of doing it.&lt;BR /&gt;Should have used&amp;nbsp;$.Unwrap_UVW.getVertexPosition&amp;nbsp;t v&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;After a series of unfolds and welds, something happens with UVs.&lt;BR /&gt;For example, I'm getting vertex index from face, but max gives an error when I try to get this vert's coords.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;$.Unwrap_UVW.GetVertexIndexFromFace 2 3
674

polyop.getMapVert $ 1 674
-- Runtime error: Mesh map vertex index out of range:  &amp;lt; 1 or &amp;gt; 448: 674
-- MAXScript callstack:
--	thread data: threadID:3220
--	------------------------------------------------------
--	[stack level: 0]
--	In top-level&lt;/LI-CODE&gt;&lt;P&gt;&lt;BR /&gt;Questions are:&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;1. How to detect it&lt;/STRONG&gt;&lt;BR /&gt;Atm seems like I can check it by comparing these:&lt;/P&gt;&lt;LI-CODE lang="general"&gt;polyop.getNumMapVerts $ 1
448

$.Unwrap_UVW.NumberVertices()
688&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;2. How to solve it&lt;/STRONG&gt;&lt;BR /&gt;So far only solution I found is to collapse the stack. Ideally, I would like a way that allows me to fix it with code, something clean and simple, similar to&amp;nbsp;polyop.deleteIsoVerts $ for example.&lt;BR /&gt;&lt;BR /&gt;&lt;STRONG&gt;3. How to prevent it&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Only operations are unfold and weld on current selection&lt;/P&gt;&lt;LI-CODE lang="general"&gt;$.unwrap_UVW.unfoldMap 1 true
$.unwrap_UVW.weldSelected()&lt;/LI-CODE&gt;&lt;P&gt;Anything wrong with that, should I do it in some different way?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Attaching a max2021 file in case you like puzzles and willing to investigate.&lt;/P&gt;</description>
      <pubDate>Tue, 03 Jun 2025 08:34:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/dead-uv-questions/m-p/13662942#M29014</guid>
      <dc:creator>dmitriy.shpilevoy</dc:creator>
      <dc:date>2025-06-03T08:34:49Z</dc:date>
    </item>
    <item>
      <title>Re: Dead UV questions.</title>
      <link>https://forums.autodesk.com/t5/3ds-max-programming-forum/dead-uv-questions/m-p/13764659#M29086</link>
      <description>&lt;P&gt;GetVertexIndexFromFace gives you the index corresponding to the current map state defined by the Unwrap_UVW. The Polyop method returns you data before the modifier. If you want to get the current map vertex position, use the current mesh and meshop methods.&lt;/P&gt;&lt;LI-CODE lang="general"&gt;meshop.getmapvert $.mesh&lt;/LI-CODE&gt;</description>
      <pubDate>Tue, 12 Aug 2025 18:26:43 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/3ds-max-programming-forum/dead-uv-questions/m-p/13764659#M29086</guid>
      <dc:creator>denisT.MaxDoctor</dc:creator>
      <dc:date>2025-08-12T18:26:43Z</dc:date>
    </item>
  </channel>
</rss>

