View Full Version : Compiling MR shaders for 3ds max 2012 64-bit, please help!
February 13th, 2012, 14:30
Okay, so I finally got a 64-bit machine, and its been a while since I've had to set up visual studio to compile anything. I was wondering if anyone knows how to set up visual studio to compile 64-bit shaders with 3ds max 2012 with mental ray 3.9.3. I was using visual studio 2008 express to compile 32-bit shaders. Would using visual studio 2010 with the sdk for windows 7 and .net 4 be better? Is this even possible with the express version? I think there is a tutorial somewhere on here for compiling 64-bit with 2008, but I think the process was pretty complicated using environment variables. Is visual studio 2010 and the sdk all I need?
Thanks in advance -Ian
February 13th, 2012, 15:18
if I would be you I'd go for vs2011 devpreview. Eventually http://stackoverflow.com/questions/1865069/how-to-compile-a-64-bit-application-using-visual-c-2010-express
February 13th, 2012, 16:50
Hey, thanks for the reply, I decided to get the vs2010 with the sdk. I haven't gone through any of the configuration steps in the link you gave yet. If I update to the 2011 preview, will I still need the sdk?
February 13th, 2012, 20:21
not sure how vs2010expr interact with 2011 but generally you can use the platform toolset from a previous version doing the same you do when you select the the sdk toolset. for example I have 2010 as IDE but I can use intel12, intel12.1, v100 and v90 toolset, haven't installed 2011 but I suppose I can use at least the previous v100 and v90. so either ways leave what you have installed and when established on that you may give a shot to 2011 without losing compatibility with your stuff. point in using 2011 eventually is that you have support for the forever upcoming cpp new standards, and it seems finally some worth of note vectorization and fast code optimin, and even if that may or may be not crucial in the work you do, there should be some general gain anyway in performances (at least a line up with the other compilers, yep actually in vs even writing good code you can't be sure to have it compiled in the most efficent way). cheers.
February 14th, 2012, 20:09
Well, thanks max for your replies, I haven't been on this forum for a while, its nice to see that there is help here still. Yeah I'll probably stick to just 2010 for a while. I was able to get a successful compile, and MR didn't spit out any errors. So now it looks like I'll have to adjust my folder structure a little to separate 32 and 64 bit shaders from my growing collection of shaders. Since I would like to be able to render from 2 32-bit machines that I have, as well as my 64-bit machine on my network. Another thing I would like to do, is to figure out hot to make a Win64 Console Application template for the Express version of VS, which I think would make my workflow for new shader projects easier instead of having to start with the Win32 template, and configuring that for 64-bit, but I could be wrong. I think I could just open the Win32 template and configure it in VS, and save it as Win64, and it should hopefully work. Really, I'm not a VS pro, and I only use it to compile shaders. I don't even like to edit my shaders in the VS editor.
I tried looking everywhere for a tutorial on just configuring VS and compiling for 64-bit. I remember seeing a helpful tutorial that Jeff Patton did for 2008, but that was for 32-bit, which I can't even find that now. If I get a chance, I'll post a similar document with a workflow that helped me, using 2010 and 64-bit.
February 15th, 2012, 03:47
not sure about express, but you have the configuration manager for that. if you have a couple of dropdown menu with for example 'release-win32', from there (or also from the solutionexplorer by rightclick on the solution) select configurationmanager, then in the active.solution get a new x64 with 'copy from win32'. btw, you can follow any tut about a dynamic lib setup to get a grip on that.
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.