Not being able to load a dicom image

Help
Adrian
2014-06-19
2014-06-19
  • Adrian
    Adrian
    2014-06-19

    Hello!

    I know I am not providing many hints, but the point is that this code:

    #include "CImg.h"

    using namespace cimg_library;

    #define cimg_medcon_path "C:\Program Files\XMedCon\bin\medcon.exe"

    int main(int argc, const char * argv[]){

    CImg<> img("poc.dcm");
    
    int success = 1;
    
    return success;
    

    }

    is reporting me that "medcon.exe" is not recognized as an executable program or sth like that. Same thing when i comment out the cimg_medcon_path line.

    I have just installed medcon in a standard form, and i have checkeed that xmedcon.exe makes the gui appear, and that medcon.exe makes some prints in the console. I am running Windows 7, by the way, and using Visual Studio 2010.

    Any help will be greatly appreciated!

    Many thanks,

    Adrian

     
  • mahamoti
    mahamoti
    2014-06-19

    You need to #define cimg_medcon_path before including cimg.h for it to have any effect. That could very likely be your problem.