Hey!
I have a compile/build question... i see that the examples in nuke come
under windows with multi byte character set... for several reasons i would
liek to use Unicode... just switching the VS project was of course no
luck...

i am getting an error in fnWindows.h. It somhow wants WIn64 to be
defined... which as far as i know VS never really defines that and everyone
uses #ifdef WIN32 hence my error.... i changed it around so the code is run
anyways and deleted the win32 stuff.... i compile and build fine but am
super scared that i am setting myself up for desater later...
here is the bit in question the bold part i kept the rest is trashed...

i get it working BUT i am wondering what a) the need is for multi byte
characters in Nuke and b) am i setting myself up for desaster later?

Thanks!

#ifdef WIN64 //And we are 64 bit too








*    //If we are 64 bit and OS is 64 bit, use std mechanism    HRESULT st =
SHGetFolderPath(NULL, CSIDL_PROGRAM_FILES, NULL,    SHGFP_TYPE_CURRENT,
programFilesPath);    if(st == S_OK)    {      programFilesPathValid =
true;      return FnBuildString(programFilesPath);    }    else { return
FnBuildString(FnLiteralBuildString("C:\\Program Files\\")); }*
    #else //We are 32 bit
    //If we are 32 bit and OS is 64 bit, we have to hack it to get the
correct path
    //the only msdn mechanisms to get it are for Vista, thanks Micorsoft!
    HRESULT st = SHGetFolderPath(NULL, CSIDL_PROGRAM_FILES, NULL,
    SHGFP_TYPE_CURRENT, programFilesPath);
    if(st == S_OK)
    {
      FnBuildString x86Part(" (x86)");
      FnBuildString pfp(programFilesPath);

      size_t start = pfp.rfind(x86Part);
      if(start!=FnBuildString::npos){
          pfp.erase(start,x86Part.size());
      }
      programFilesPathValid = true;
      sprintf_s(programFilesPath, MAX_PATH, "%s",pfp.c_str());
      return FnBuildString(programFilesPath);
    }
    else { return FnBuildString(FnLiteralBuildString("C:\\Program
Files\\")); }
    #endif
_______________________________________________
Nuke-dev mailing list
[email protected], http://forums.thefoundry.co.uk/
http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-dev

Reply via email to