Setup visual Studio
From Odwiki
Setup Visual Studio .NET
Nowadays you don't need to compile your HDK-based SOP/Standalone exe/DSO etc using hcustom or a MAKEFILE. You can also work directly inside Visual Studio .NET and compile your code there.
Visual Studio .NET may be setup differently depending on which Houdini Version you are currently using.
Please be aware of that the information below is only suggestions and pointers to setup your Visual Studio. The version below is/was working on the authors computer, and doesn't garantuee that it will work on your computer.
Visual Studio .NET 2003 for Houdini 8.2.238
- First you need to startup a project in Visual Studio
- Go in to the project properties. You can do this either by click on 'Project->options' or right-click on the project icon in the sollution explorer and choose 'Properties'
- Go to 'C/C++ -> General', here you must add the paths to the Houdini include folders: "$HoudiniRoot$/Houdini 8.2.238/toolkit/include" and "$HoudiniRoot$/Houdini 8.2.238/custom/include".
- Go to 'C/C++ ->Command Line. Here you need to add special definitions that Houdini uses to compile the code. This may vary from computer to computer.
One thing you can do, to get which defintions you might need is to compile the following sample from Houdini in the hcustom:
hcustom -d $HT/samples/SOP/SOP_Star.C
When compiling this, the commando line will show which definitions i uses to compile the SOP_Star.C SOP file. Include these into the Command Line in VS.
Defines that you might have to include here could look something like this:
-DDLLEXPORT=__declspec(dllexport) -DSESI_LITTLE_ENDIAN -DVERSION="8.2.238" -DI386 -DWIN32 -DSWAP_BITFIELDS -DMAKING_DSO
- Go to 'Linker -> General -> Additional Library Directories'. Here you need to add the directories to the Houdini libs. As same as the include directories, The installation path varies, depending on where you have installed your Houdini:
$HoudiniRoot$/custom/houdini/dsolib/ $HoudiniRoot$/bin
- Go to 'Linker -> Input -> Additional Dependencies'. This can be little tricky here. You will need to add the specific libs that you will be needing in your project.
A basic rule of thumb here, is if you will use for example 'UT_String.h' in your project, then you will need to add 'libUT.a' to here.
This should be all you need to do to setup your Visual Studio .NET 2003 for Houdini 8.x. When working in Visual Studio you will need to add includes to certain header files. Which files depends on which ones you need to use in the current project.



