-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
207 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,76 @@ | ||
# nspec | ||
|
||
This plugin exposes functions for MAXScript for modifying explicit normals. It exposes 'nspec' class and 'inspec' interface and it's functions | ||
``` | ||
<int> GetNumNormals <Mesh> | ||
<int> GetNumFaces <Mesh> | ||
<point3> GetNormal <Mesh> <int normalId> | ||
<int> GetNormalId <Mesh> <int face> <int corner> | ||
<bool> SetNumNormals <Mesh> <int> | ||
<bool> SetNumFaces <Mesh> <int> | ||
SetNormal <Mesh> <int normalId> <point3 normal> | ||
SetNormalId <Mesh> <int face> <int corner> <int normalId> | ||
SetNormalExplicit <Mesh> <int normalId> <bool explicit> | ||
<bool> GetNormalExplicit <Mesh> <int normalId> | ||
``` | ||
Sample usage: | ||
``` | ||
nspec.getnormal $.mesh 14 | ||
``` | ||
or | ||
``` | ||
nspec.inspec.getnormal $.mesh 14 | ||
``` | ||
|
||
This is how I came up with the name 'nspec'... | ||
I use a class called MeshNormalSpec from the SDK, so MeshNormalSpec -> NormalSpec -> nspec | ||
|
||
## Requirements | ||
|
||
This plugin requires Autodesk 3ds Max SDK and the SDK's dependencies | ||
|
||
https://www.autodesk.com/developer-network/platform-technologies/3ds-max#3dsmax-sdk | ||
|
||
The SDK also comes with the 3ds Max installer. | ||
|
||
**nspec_2014** | ||
MSVC v100 (2010) | ||
3ds Max 2014 SDK | ||
|
||
**nspec_2015** | ||
MSVC v110 (2012) | ||
3ds Max 2015 SDK | ||
|
||
**nspec_2017** | ||
MSVC v140 (2015) | ||
3ds Max 2017 SDK | ||
|
||
**nspec_2018** | ||
MSVC v140 (2015) | ||
Windows SDK 10.0.10586 | ||
3ds Max 2018 SDK | ||
|
||
**nspec_2019** | ||
MSVC v140 (2015) | ||
Windows SDK 10.0.10586 | ||
3ds Max 2019 SDK | ||
|
||
**nspec_2020** | ||
MSVC v141 (2017) | ||
Windows SDK 10.0.17134.0 | ||
3ds Max 2020 SDK | ||
|
||
**nspec_2022** | ||
MSVC v141 (2017) | ||
Windows SDK 10.0.17134.0 | ||
3ds Max 2022 SDK | ||
|
||
**nspec_2023** | ||
MSVC v142 (2019) | ||
Windows SDK 10.0.19041.0 | ||
3ds Max 2023 SDK | ||
|
||
## Building | ||
- Open 'nspec.sln' in Visual Studio | ||
- Set the configuration to 'Release' | ||
- Build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<ItemGroup Label="ProjectConfigurations"> | ||
<ProjectConfiguration Include="Debug|x64"> | ||
<Configuration>Debug</Configuration> | ||
<Platform>x64</Platform> | ||
</ProjectConfiguration> | ||
<ProjectConfiguration Include="Hybrid|x64"> | ||
<Configuration>Hybrid</Configuration> | ||
<Platform>x64</Platform> | ||
</ProjectConfiguration> | ||
<ProjectConfiguration Include="Release|x64"> | ||
<Configuration>Release</Configuration> | ||
<Platform>x64</Platform> | ||
</ProjectConfiguration> | ||
</ItemGroup> | ||
<PropertyGroup Label="Globals"> | ||
<ProjectName>nspec_2023</ProjectName> | ||
<ProjectGuid>{DD41347B-D5A8-4709-B984-19F68E295C1D}</ProjectGuid> | ||
<ConfigurationType>DynamicLibrary</ConfigurationType> | ||
<MaxSDK>$(ADSK_3DSMAX_SDK_2023)</MaxSDK> | ||
</PropertyGroup> | ||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> | ||
<Import Project="$(MaxSDK)\ProjectSettings\PropertySheets\3dsmax.general.project.settings.props" /> | ||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> | ||
<ImportGroup Label="PropertySheets"> | ||
<Import Project="$(MaxSDK)\ProjectSettings\PropertySheets\3dsmax.cpp.props" /> | ||
</ImportGroup> | ||
<PropertyGroup> | ||
<_ProjectFileVersion>10.0.30319.1</_ProjectFileVersion> | ||
<OutDir>$(ProjectDir)\bin\$(Configuration)_$(Platform)\2023\</OutDir> | ||
<IntDir>$(ProjectDir)\obj\$(Configuration)_$(Platform)\2023\</IntDir> | ||
<TargetName>nspec</TargetName> | ||
<TargetExt>.gup</TargetExt> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> | ||
<LinkIncremental>true</LinkIncremental> | ||
</PropertyGroup> | ||
<ItemDefinitionGroup> | ||
<ClCompile> | ||
<WholeProgramOptimization>false</WholeProgramOptimization> | ||
<PreprocessorDefinitions>_USRDLL;%(PreprocessorDefinitions)</PreprocessorDefinitions> | ||
<AdditionalIncludeDirectories>$(MaxSdkInc);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories> | ||
<WarningLevel>Level4</WarningLevel> | ||
<DebugInformationFormat Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">EditAndContinue</DebugInformationFormat> | ||
</ClCompile> | ||
<Link> | ||
<AdditionalLibraryDirectories>$(MaxSdkLib);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories> | ||
<AdditionalDependencies>bmm.lib;core.lib;geom.lib;gfx.lib;mesh.lib;maxutil.lib;maxscrpt.lib;gup.lib;paramblk2.lib;;%(AdditionalDependencies)</AdditionalDependencies> | ||
<ModuleDefinitionFile>nspec.def</ModuleDefinitionFile> | ||
<GenerateDebugInformation Condition="'$(Configuration)'=='Release'">false</GenerateDebugInformation> | ||
</Link> | ||
</ItemDefinitionGroup> | ||
<ItemGroup> | ||
<ClCompile Include="nspec.cpp" /> | ||
<ClCompile Include="DllEntry.cpp" /> | ||
<ClCompile Include="util.cpp" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ClInclude Include="resource.h" /> | ||
<ClInclude Include="util.h" /> | ||
<ClInclude Include="nspec.h" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<None Include="nspec.def" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ResourceCompile Include="nspec.rc" /> | ||
</ItemGroup> | ||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<ItemGroup> | ||
<Filter Include="Source Files"> | ||
<UniqueIdentifier>{fbad0f2d-faaa-4b0b-865c-583fac8ddcb1}</UniqueIdentifier> | ||
<Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions> | ||
</Filter> | ||
<Filter Include="Header Files"> | ||
<UniqueIdentifier>{92f20462-242f-4a0c-883e-b3c33819b84b}</UniqueIdentifier> | ||
<Extensions>h;hpp;hxx;hm;inl</Extensions> | ||
</Filter> | ||
<Filter Include="Resource Files"> | ||
<UniqueIdentifier>{ad6e765e-4300-41dc-b185-05b019286785}</UniqueIdentifier> | ||
<Extensions>ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe</Extensions> | ||
</Filter> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ClCompile Include="DllEntry.cpp"> | ||
<Filter>Source Files</Filter> | ||
</ClCompile> | ||
<ClCompile Include="util.cpp"> | ||
<Filter>Source Files</Filter> | ||
</ClCompile> | ||
<ClCompile Include="nspec.cpp"> | ||
<Filter>Source Files</Filter> | ||
</ClCompile> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ClInclude Include="util.h"> | ||
<Filter>Header Files</Filter> | ||
</ClInclude> | ||
<ClInclude Include="nspec.h"> | ||
<Filter>Header Files</Filter> | ||
</ClInclude> | ||
<ClInclude Include="resource.h"> | ||
<Filter>Header Files</Filter> | ||
</ClInclude> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<None Include="nspec.def"> | ||
<Filter>Source Files</Filter> | ||
</None> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<ResourceCompile Include="nspec.rc"> | ||
<Filter>Source Files</Filter> | ||
</ResourceCompile> | ||
</ItemGroup> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters