Hi,
Long story short I had to add an array as a data member to an existing class in my game engine. I would like to know if in the class's destructor or in it's release member function do I need to add special code to delete this array without causing a memory leak?
The array has been initialised with a fixed size as shown, it is not just a pointer:
D3DXHANDLE* myArray[10];
Will the class's destructor take care of this for me? With all other attributes which point to objects such as DirectX objects special code is needed and you have to loop through each entry and call the release function of each object contained in the array.
D3DXHANDLE is not an object though, it is a LPCTSTR variable. Similar-ish to a char pointer so I hear.
Any ideas? I'd like to do this properly. I could advance beyond this right now but I'd rather keep the brakes on before I compile this DLL file and leave it be.
Much thanks,
Chris![]()



7Likes
LinkBack URL
About LinkBacks




