Original Post
New update: Correction: the leak was caused by DirectX's October 2004 SDK. Installing a newer one fixed the leak. [smile] Update: Looks like the leak originated from the article source. I forgot to use D3D_DEBUG_INFO while compiling the article's code earlier, which had me running in circles looking for the leak elsewhere. Now to figure out the problem.... [totally] Hi there, I've discovered the DX Debug output feature rather late and now I'm having a bit of trouble tracking down the source of the memory leak it's reporting (report attached below). I'm able to isolate the problem to the D3DXLoadMeshHierarchyFromX function. No leaks are reported if the function isn't called or returns a failure. The mesh loading code is from this article: Working with the DirectX .X File Format and Animation in DirectX 9.0 The source from the article compiles fine without any leaks though. Did I overlook something? Or is it possible that the leak is occuring somewhere else but is somehow related to the D3DXLoadMeshHierarchyFromX function? Any debugging tips for a newbie? Thank you for your time! [smile] This is the debug output I've got [Edited by - CCF on December 20, 2006 10:30:41 AM]
Direct3D9: (INFO) :MemFini!
Direct3D9: (ERROR) :Memory still allocated! Alloc count = 117
Direct3D9: (ERROR) :Current Process (pid) = 00000610
Direct3D9: (ERROR) :Memory Address: 00c442bc lAllocID=1 dwSize=000047f8, ReturnAddr=00d734c8 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c4a37c lAllocID=9 dwSize=00000af8, ReturnAddr=00d6c2cb (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c42f7c lAllocID=10 dwSize=00000008, ReturnAddr=00d6c36b (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c4aeb4 lAllocID=11 dwSize=00000e20, ReturnAddr=00d71741 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c42e9c lAllocID=12 dwSize=00000044, ReturnAddr=00d734c8 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c4bd0c lAllocID=13 dwSize=00000050, ReturnAddr=00d734c8 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c48d8c lAllocID=22 dwSize=000006bc, ReturnAddr=00d7f3b3 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c49484 lAllocID=24 dwSize=00000ec4, ReturnAddr=00d745bd (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c42f14 lAllocID=26 dwSize=00000008, ReturnAddr=00d746ee (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c4bd94 lAllocID=28 dwSize=00003508, ReturnAddr=00d734c8 (pid=00000610)
Direct3D9: (ERROR) :Memory Address: 00c4f2dc lAllocID=29 dwSize=00000198, ReturnAddr=00d734c8 (pid=00000610)
Direct3D9: (ERROR) :Total Memory Unfreed From Current Process = 44500 bytes