<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://forums.xna.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Direct3D</title><link>http://forums.xna.com/forums/27.aspx</link><description /><dc:language>en</dc:language><generator>CommunityServer 2007.1 (Build: 0.0)</generator><item><title>Re: How do I get the mesh name list in static XFile</title><link>http://forums.xna.com/forums/thread/194422.aspx</link><pubDate>Mon, 29 Jun 2009 02:37:13 GMT</pubDate><guid isPermaLink="false">4aa5dbf6-357b-46b2-b5b2-1b660a6dc370:194422</guid><dc:creator>legalize</dc:creator><slash:comments>0</slash:comments><comments>http://forums.xna.com/forums/thread/194422.aspx</comments><wfw:commentRss>http://forums.xna.com/forums/commentrss.aspx?SectionID=27&amp;PostID=194422</wfw:commentRss><description>When you use D3DXLoadMeshHierarchyFromX, it will call into your ID3DXAllocateHierarchy implementation once for each mesh in the file.  You can simply make an implementation of this interface that records the names of the meshes it is asked to create without actually creating them.  ID3DXAllocateHierarchy::CreateMeshContainer is passed the name of the mesh.  You will want to release the mesh data that is passed to you, or you will leak memory.</description></item><item><title>Re: How do I get the mesh name list in static XFile</title><link>http://forums.xna.com/forums/thread/194194.aspx</link><pubDate>Sun, 28 Jun 2009 11:02:00 GMT</pubDate><guid isPermaLink="false">4aa5dbf6-357b-46b2-b5b2-1b660a6dc370:194194</guid><dc:creator>Bad Habit</dc:creator><slash:comments>0</slash:comments><comments>http://forums.xna.com/forums/thread/194194.aspx</comments><wfw:commentRss>http://forums.xna.com/forums/commentrss.aspx?SectionID=27&amp;PostID=194194</wfw:commentRss><description>&lt;p&gt;You need to use the ID3DXFileData::GetName() to get the name of an object. Something along these lines:&lt;/p&gt;
&lt;p&gt;// Get size of buffer first&lt;br /&gt;
SIZE_T sz = 0;&lt;br /&gt;
xdata-&amp;gt;GetName(0, &amp;amp;sz);&lt;/p&gt;
&lt;p&gt;// Load if not empty&lt;br /&gt;
char* name = 0;&lt;br /&gt;
if(sz &amp;gt; 1)&lt;br /&gt;
{&lt;br /&gt;
    name = new char[sz];&lt;br /&gt;
    xdata-&amp;gt;GetName(name, &amp;amp;sz);&lt;br /&gt;
}&lt;/p&gt;</description></item><item><title>How do I get the mesh name list in static XFile</title><link>http://forums.xna.com/forums/thread/192175.aspx</link><pubDate>Mon, 22 Jun 2009 03:39:13 GMT</pubDate><guid isPermaLink="false">4aa5dbf6-357b-46b2-b5b2-1b660a6dc370:192175</guid><dc:creator>akira32</dc:creator><slash:comments>0</slash:comments><comments>http://forums.xna.com/forums/thread/192175.aspx</comments><wfw:commentRss>http://forums.xna.com/forums/commentrss.aspx?SectionID=27&amp;PostID=192175</wfw:commentRss><description>How do I get the mesh name list in static XFile?&lt;br /&gt;
I have a special requirement to get the mesh name list from a static XFile(without animation).&lt;br /&gt;
Which function should I use? Or I must parse the XFile with DirectX function?</description></item></channel></rss>