//Load the HLSL shader HRESULT hr = D3DXCreateEffectFromFile(D3DDevice, "AdvancedPassShader.fx", 0, 0, 0, 0, &ParallaxMapEffect, &pErrorMsg); if (FAILED(hr)){ MessageBox(hwnd, "The graphics failed where is the error.txt?!?! FIND IT", "ITS DIED!", 0); MessageBox(hwnd, "Fetching error", "ITS DIED!", 0); //Error(s) have occured. //Allocate a character buffer the size of the ID3DXBuffer char *data = new char[pErrorMsg->GetBufferSize]; //(the program freezes on this line) MessageBox(hwnd, "Gathered data", "ITS DIED!", 0); // Copy the buffer data over memcpy( data, pErrorMsg->GetBufferPointer(), pErrorMsg->GetBufferSize());
Any attempt to interact with pErrorMsg causes the program to crash, how on earth can I identify the error when I cannot interact with the error holding device without causing a crash?
Obviously I cannot debug the code on these machines without putting the SDK on. What can I do to test things?
[Edited by - EnlightenedOne on August 29, 2010 4:52:29 PM]