mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2025-09-19 12:06:07 +08:00
Added most recent version of unmodified HL2 SDK for Orange Box engine
This commit is contained in:
1096
utils/smdlexp/smdlexp.cpp
Normal file
1096
utils/smdlexp/smdlexp.cpp
Normal file
File diff suppressed because it is too large
Load Diff
8
utils/smdlexp/smdlexp.def
Normal file
8
utils/smdlexp/smdlexp.def
Normal file
@ -0,0 +1,8 @@
|
||||
LIBRARY smdlexp
|
||||
EXPORTS
|
||||
LibDescription @1
|
||||
LibNumberClasses @2
|
||||
LibClassDesc @3
|
||||
LibVersion @4
|
||||
SECTIONS
|
||||
.data READ WRITE
|
325
utils/smdlexp/smdlexp.mak
Normal file
325
utils/smdlexp/smdlexp.mak
Normal file
@ -0,0 +1,325 @@
|
||||
# Microsoft Developer Studio Generated NMAKE File, Format Version 4.20
|
||||
# ** DO NOT EDIT **
|
||||
|
||||
# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
|
||||
|
||||
!IF "$(CFG)" == ""
|
||||
CFG=smdlexp - Win32 Debug
|
||||
!MESSAGE No configuration specified. Defaulting to smdlexp - Win32 Debug.
|
||||
!ENDIF
|
||||
|
||||
!IF "$(CFG)" != "smdlexp - Win32 Release" && "$(CFG)" !=\
|
||||
"smdlexp - Win32 Debug"
|
||||
!MESSAGE Invalid configuration "$(CFG)" specified.
|
||||
!MESSAGE You can specify a configuration when running NMAKE on this makefile
|
||||
!MESSAGE by defining the macro CFG on the command line. For example:
|
||||
!MESSAGE
|
||||
!MESSAGE NMAKE /f "smdlexp.mak" CFG="smdlexp - Win32 Debug"
|
||||
!MESSAGE
|
||||
!MESSAGE Possible choices for configuration are:
|
||||
!MESSAGE
|
||||
!MESSAGE "smdlexp - Win32 Release" (based on\
|
||||
"Win32 (x86) Dynamic-Link Library")
|
||||
!MESSAGE "smdlexp - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
|
||||
!MESSAGE
|
||||
!ERROR An invalid configuration is specified.
|
||||
!ENDIF
|
||||
|
||||
!IF "$(OS)" == "Windows_NT"
|
||||
NULL=
|
||||
!ELSE
|
||||
NULL=nul
|
||||
!ENDIF
|
||||
################################################################################
|
||||
# Begin Project
|
||||
# PROP Target_Last_Scanned "smdlexp - Win32 Debug"
|
||||
RSC=rc.exe
|
||||
MTL=mktyplib.exe
|
||||
CPP=cl.exe
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 0
|
||||
# PROP BASE Output_Dir "Release"
|
||||
# PROP BASE Intermediate_Dir "Release"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 0
|
||||
# PROP Output_Dir "Release"
|
||||
# PROP Intermediate_Dir "Release"
|
||||
# PROP Target_Dir ""
|
||||
OUTDIR=.\Release
|
||||
INTDIR=.\Release
|
||||
|
||||
ALL : "..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE"
|
||||
|
||||
CLEAN :
|
||||
-@erase "$(INTDIR)\smdlexp.obj"
|
||||
-@erase "$(INTDIR)\smdlexp.res"
|
||||
-@erase "$(OUTDIR)\SMDLEXP.exp"
|
||||
-@erase "$(OUTDIR)\SMDLEXP.lib"
|
||||
-@erase "..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE"
|
||||
|
||||
"$(OUTDIR)" :
|
||||
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
|
||||
|
||||
# ADD BASE CPP /nologo /MT /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c
|
||||
# ADD CPP /nologo /MT /W3 /GX /O2 /I "\3DSMAX2.5\MAXSDK\INCLUDE" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /YX /c
|
||||
CPP_PROJ=/nologo /MT /W3 /GX /O2 /I "\3DSMAX2.5\MAXSDK\INCLUDE" /D "WIN32" /D\
|
||||
"NDEBUG" /D "_WINDOWS" /Fp"$(INTDIR)/smdlexp.pch" /YX /Fo"$(INTDIR)/" /c
|
||||
CPP_OBJS=.\Release/
|
||||
CPP_SBRS=.\.
|
||||
# ADD BASE MTL /nologo /D "NDEBUG" /win32
|
||||
# ADD MTL /nologo /D "NDEBUG" /win32
|
||||
MTL_PROJ=/nologo /D "NDEBUG" /win32
|
||||
# ADD BASE RSC /l 0x409 /d "NDEBUG"
|
||||
# ADD RSC /l 0x409 /d "NDEBUG"
|
||||
RSC_PROJ=/l 0x409 /fo"$(INTDIR)/smdlexp.res" /d "NDEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
BSC32_FLAGS=/nologo /o"$(OUTDIR)/smdlexp.bsc"
|
||||
BSC32_SBRS= \
|
||||
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /machine:I386
|
||||
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib COMCTL32.LIB /nologo /subsystem:windows /dll /machine:I386 /out:"\3DSMAX\STDPLUGS\SMDLEXP.DLE"
|
||||
LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
|
||||
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib COMCTL32.LIB /nologo\
|
||||
/subsystem:windows /dll /incremental:no /pdb:"$(OUTDIR)/SMDLEXP.pdb"\
|
||||
/machine:I386 /def:".\smdlexp.def" /out:"\3DSMAX\STDPLUGS\SMDLEXP.DLE"\
|
||||
/implib:"$(OUTDIR)/SMDLEXP.lib"
|
||||
DEF_FILE= \
|
||||
".\smdlexp.def"
|
||||
LINK32_OBJS= \
|
||||
"$(INTDIR)\smdlexp.obj" \
|
||||
"$(INTDIR)\smdlexp.res" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\CORE.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\GEOM.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\MESH.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\UTIL.LIB"
|
||||
|
||||
"..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
|
||||
$(LINK32) @<<
|
||||
$(LINK32_FLAGS) $(LINK32_OBJS)
|
||||
<<
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
# PROP BASE Use_MFC 0
|
||||
# PROP BASE Use_Debug_Libraries 1
|
||||
# PROP BASE Output_Dir "Debug"
|
||||
# PROP BASE Intermediate_Dir "Debug"
|
||||
# PROP BASE Target_Dir ""
|
||||
# PROP Use_MFC 0
|
||||
# PROP Use_Debug_Libraries 1
|
||||
# PROP Output_Dir "Debug"
|
||||
# PROP Intermediate_Dir "Debug"
|
||||
# PROP Target_Dir ""
|
||||
OUTDIR=.\Debug
|
||||
INTDIR=.\Debug
|
||||
|
||||
ALL : "..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE" "$(OUTDIR)\smdlexp.bsc"
|
||||
|
||||
CLEAN :
|
||||
-@erase "$(INTDIR)\smdlexp.obj"
|
||||
-@erase "$(INTDIR)\smdlexp.res"
|
||||
-@erase "$(INTDIR)\smdlexp.sbr"
|
||||
-@erase "$(INTDIR)\vc40.idb"
|
||||
-@erase "$(INTDIR)\vc40.pdb"
|
||||
-@erase "$(OUTDIR)\smdlexp.bsc"
|
||||
-@erase "$(OUTDIR)\SMDLEXP.exp"
|
||||
-@erase "$(OUTDIR)\SMDLEXP.lib"
|
||||
-@erase "$(OUTDIR)\SMDLEXP.pdb"
|
||||
-@erase "..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE"
|
||||
-@erase "..\..\..\3DSMAX\STDPLUGS\SMDLEXP.ILK"
|
||||
|
||||
"$(OUTDIR)" :
|
||||
if not exist "$(OUTDIR)/$(NULL)" mkdir "$(OUTDIR)"
|
||||
|
||||
# ADD BASE CPP /nologo /MTd /W3 /Gm /GX /Zi /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /YX /c
|
||||
# ADD CPP /nologo /MD /W3 /Gm /GX /Zi /Od /I "\3DSMAX2.5\MAXSDK\INCLUDE" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /FR /YX /c
|
||||
CPP_PROJ=/nologo /MD /W3 /Gm /GX /Zi /Od /I "\3DSMAX2.5\MAXSDK\INCLUDE" /D\
|
||||
"WIN32" /D "_DEBUG" /D "_WINDOWS" /FR"$(INTDIR)/" /Fp"$(INTDIR)/smdlexp.pch"\
|
||||
/YX /Fo"$(INTDIR)/" /Fd"$(INTDIR)/" /c
|
||||
CPP_OBJS=.\Debug/
|
||||
CPP_SBRS=.\Debug/
|
||||
# ADD BASE MTL /nologo /D "_DEBUG" /win32
|
||||
# ADD MTL /nologo /D "_DEBUG" /win32
|
||||
MTL_PROJ=/nologo /D "_DEBUG" /win32
|
||||
# ADD BASE RSC /l 0x409 /d "_DEBUG"
|
||||
# ADD RSC /l 0x409 /d "_DEBUG"
|
||||
RSC_PROJ=/l 0x409 /fo"$(INTDIR)/smdlexp.res" /d "_DEBUG"
|
||||
BSC32=bscmake.exe
|
||||
# ADD BASE BSC32 /nologo
|
||||
# ADD BSC32 /nologo
|
||||
BSC32_FLAGS=/nologo /o"$(OUTDIR)/smdlexp.bsc"
|
||||
BSC32_SBRS= \
|
||||
"$(INTDIR)\smdlexp.sbr"
|
||||
|
||||
"$(OUTDIR)\smdlexp.bsc" : "$(OUTDIR)" $(BSC32_SBRS)
|
||||
$(BSC32) @<<
|
||||
$(BSC32_FLAGS) $(BSC32_SBRS)
|
||||
<<
|
||||
|
||||
LINK32=link.exe
|
||||
# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib /nologo /subsystem:windows /dll /debug /machine:I386
|
||||
# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib COMCTL32.LIB /nologo /subsystem:windows /dll /debug /machine:I386 /out:"\3DSMAX\STDPLUGS\SMDLEXP.DLE"
|
||||
LINK32_FLAGS=kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib\
|
||||
advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib COMCTL32.LIB /nologo\
|
||||
/subsystem:windows /dll /incremental:yes /pdb:"$(OUTDIR)/SMDLEXP.pdb" /debug\
|
||||
/machine:I386 /def:".\smdlexp.def" /out:"\3DSMAX\STDPLUGS\SMDLEXP.DLE"\
|
||||
/implib:"$(OUTDIR)/SMDLEXP.lib"
|
||||
DEF_FILE= \
|
||||
".\smdlexp.def"
|
||||
LINK32_OBJS= \
|
||||
"$(INTDIR)\smdlexp.obj" \
|
||||
"$(INTDIR)\smdlexp.res" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\CORE.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\GEOM.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\MESH.LIB" \
|
||||
"..\..\..\quiver\src\utils\3dsmax\UTIL.LIB"
|
||||
|
||||
"..\..\..\3DSMAX\STDPLUGS\SMDLEXP.DLE" : "$(OUTDIR)" $(DEF_FILE) $(LINK32_OBJS)
|
||||
$(LINK32) @<<
|
||||
$(LINK32_FLAGS) $(LINK32_OBJS)
|
||||
<<
|
||||
|
||||
!ENDIF
|
||||
|
||||
.c{$(CPP_OBJS)}.obj:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
.cpp{$(CPP_OBJS)}.obj:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
.cxx{$(CPP_OBJS)}.obj:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
.c{$(CPP_SBRS)}.sbr:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
.cpp{$(CPP_SBRS)}.sbr:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
.cxx{$(CPP_SBRS)}.sbr:
|
||||
$(CPP) $(CPP_PROJ) $<
|
||||
|
||||
################################################################################
|
||||
# Begin Target
|
||||
|
||||
# Name "smdlexp - Win32 Release"
|
||||
# Name "smdlexp - Win32 Debug"
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\smdlexp.cpp
|
||||
DEP_CPP_SMDLE=\
|
||||
".\smedefs.h"\
|
||||
|
||||
NODEP_CPP_SMDLE=\
|
||||
".\ANIMTBL.H"\
|
||||
".\DECOMP.H"\
|
||||
".\istdplug.h"\
|
||||
".\MAX.H"\
|
||||
".\STDMAT.H"\
|
||||
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
|
||||
"$(INTDIR)\smdlexp.obj" : $(SOURCE) $(DEP_CPP_SMDLE) "$(INTDIR)"
|
||||
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
|
||||
"$(INTDIR)\smdlexp.obj" : $(SOURCE) $(DEP_CPP_SMDLE) "$(INTDIR)"
|
||||
|
||||
"$(INTDIR)\smdlexp.sbr" : $(SOURCE) $(DEP_CPP_SMDLE) "$(INTDIR)"
|
||||
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\smdlexp.def
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\smdlexp.rc
|
||||
|
||||
"$(INTDIR)\smdlexp.res" : $(SOURCE) "$(INTDIR)"
|
||||
$(RSC) $(RSC_PROJ) $(SOURCE)
|
||||
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=\quiver\src\utils\3dsmax\UTIL.LIB
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=\quiver\src\utils\3dsmax\GEOM.LIB
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=\quiver\src\utils\3dsmax\MESH.LIB
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
################################################################################
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=\quiver\src\utils\3dsmax\CORE.LIB
|
||||
|
||||
!IF "$(CFG)" == "smdlexp - Win32 Release"
|
||||
|
||||
!ELSEIF "$(CFG)" == "smdlexp - Win32 Debug"
|
||||
|
||||
!ENDIF
|
||||
|
||||
# End Source File
|
||||
# End Target
|
||||
# End Project
|
||||
################################################################################
|
147
utils/smdlexp/smdlexp.rc
Normal file
147
utils/smdlexp/smdlexp.rc
Normal file
@ -0,0 +1,147 @@
|
||||
//Microsoft Developer Studio generated resource script.
|
||||
//
|
||||
#include "smexprc.h"
|
||||
|
||||
#define APSTUDIO_READONLY_SYMBOLS
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 2 resource.
|
||||
//
|
||||
#include "afxres.h"
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#undef APSTUDIO_READONLY_SYMBOLS
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
// English (U.S.) resources
|
||||
|
||||
#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
|
||||
#ifdef _WIN32
|
||||
LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
|
||||
#pragma code_page(1252)
|
||||
#endif //_WIN32
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Dialog
|
||||
//
|
||||
|
||||
IDD_EXPORTOPTIONS DIALOG DISCARDABLE 0, 0, 186, 42
|
||||
STYLE DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "SMD Exporter"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
DEFPUSHBUTTON "OK",IDOK,129,7,50,14
|
||||
PUSHBUTTON "Cancel",IDCANCEL,129,22,50,14
|
||||
CONTROL "Skeletal Animation",IDC_CHECK_SKELETAL,"Button",
|
||||
BS_AUTORADIOBUTTON | WS_GROUP,15,10,74,10
|
||||
CONTROL "Reference Frame",IDC_CHECK_REFFRAME,"Button",
|
||||
BS_AUTORADIOBUTTON | WS_GROUP,15,24,71,10
|
||||
END
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// DESIGNINFO
|
||||
//
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
GUIDELINES DESIGNINFO DISCARDABLE
|
||||
BEGIN
|
||||
IDD_EXPORTOPTIONS, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 179
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 36
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// TEXTINCLUDE
|
||||
//
|
||||
|
||||
1 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"smexprc.h\0"
|
||||
END
|
||||
|
||||
2 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"#include ""afxres.h""\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
3 TEXTINCLUDE DISCARDABLE
|
||||
BEGIN
|
||||
"\r\n"
|
||||
"\0"
|
||||
END
|
||||
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
|
||||
#ifndef _MAC
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Version
|
||||
//
|
||||
|
||||
VS_VERSION_INFO VERSIONINFO
|
||||
FILEVERSION 2,0,0,1
|
||||
PRODUCTVERSION 2,0,0,1
|
||||
FILEFLAGSMASK 0x3fL
|
||||
#ifdef _DEBUG
|
||||
FILEFLAGS 0x1L
|
||||
#else
|
||||
FILEFLAGS 0x0L
|
||||
#endif
|
||||
FILEOS 0x40004L
|
||||
FILETYPE 0x2L
|
||||
FILESUBTYPE 0x0L
|
||||
BEGIN
|
||||
BLOCK "StringFileInfo"
|
||||
BEGIN
|
||||
BLOCK "040904b0"
|
||||
BEGIN
|
||||
VALUE "Comments", "\0"
|
||||
VALUE "CompanyName", "Valve LLC\0"
|
||||
VALUE "FileDescription", "SMD file exporter (3D Studio Max plugin)\0"
|
||||
VALUE "FileVersion", "2, 0, 0, 1\0"
|
||||
VALUE "InternalName", "SMDLEXP\0"
|
||||
VALUE "LegalCopyright", "Copyright <20> 1998, Valve LLC\0"
|
||||
VALUE "LegalTrademarks", "The following are registered trademarks of Autodesk, Inc.: 3D Studio MAX. The following are trademarks of Autodesk, Inc.: Kinetix, Kinetix(logo), BIPED, Physique, Character Studio, MAX DWG, DWG Unplugged, Heidi, FLI, FLC, DXF.\0"
|
||||
VALUE "OriginalFilename", "SMDLEXP.DLE\0"
|
||||
VALUE "PrivateBuild", "\0"
|
||||
VALUE "ProductName", "Valve LLC SMDLEXP\0"
|
||||
VALUE "ProductVersion", "2, 0, 0, 1\0"
|
||||
VALUE "SpecialBuild", "\0"
|
||||
END
|
||||
END
|
||||
BLOCK "VarFileInfo"
|
||||
BEGIN
|
||||
VALUE "Translation", 0x409, 1200
|
||||
END
|
||||
END
|
||||
|
||||
#endif // !_MAC
|
||||
|
||||
#endif // English (U.S.) resources
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
|
||||
#ifndef APSTUDIO_INVOKED
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
//
|
||||
// Generated from the TEXTINCLUDE 3 resource.
|
||||
//
|
||||
|
||||
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
#endif // not APSTUDIO_INVOKED
|
||||
|
178
utils/smdlexp/smedefs.h
Normal file
178
utils/smdlexp/smedefs.h
Normal file
@ -0,0 +1,178 @@
|
||||
//========= Copyright <20> 1996-2005, Valve Corporation, All rights reserved. ============//
|
||||
//
|
||||
// Purpose:
|
||||
//
|
||||
// $NoKeywords: $
|
||||
//
|
||||
//=============================================================================//
|
||||
|
||||
//===================================================================
|
||||
// Useful macros
|
||||
//
|
||||
#define CONSTRUCTOR
|
||||
#define DESTRUCTOR
|
||||
|
||||
#define EXPORT_THIS __declspec(dllexport)
|
||||
|
||||
#define DEFAULT_EXT _T("smd")
|
||||
|
||||
#define FStrEq(sz1, sz2) (strcmp((sz1), (sz2)) == 0)
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Class that implements the scene-export.
|
||||
//
|
||||
class SmdExportClass : public SceneExport
|
||||
{
|
||||
friend BOOL CALLBACK ExportOptionsDlgProc(HWND hDlg, UINT message, WPARAM wParam, LPARAM lParam);
|
||||
friend class DumpModelTEP;
|
||||
friend class DumpDeformsTEP;
|
||||
|
||||
public:
|
||||
CONSTRUCTOR SmdExportClass (void);
|
||||
DESTRUCTOR ~SmdExportClass (void);
|
||||
|
||||
// Required by classes derived from SceneExport
|
||||
virtual int ExtCount (void) { return 1; }
|
||||
virtual const TCHAR* Ext (int i) { return DEFAULT_EXT; }
|
||||
virtual const TCHAR* LongDesc (void) { return _T("Valve Skeletal Model Exporter for 3D Studio Max"); }
|
||||
virtual const TCHAR* ShortDesc (void) { return _T("Valve SMD"); }
|
||||
virtual const TCHAR* AuthorName (void) { return _T("Valve, LLC"); }
|
||||
virtual const TCHAR* CopyrightMessage(void) { return _T("Copyright (c) 1998, Valve LLC"); }
|
||||
virtual const TCHAR* OtherMessage1 (void) { return _T(""); }
|
||||
virtual const TCHAR* OtherMessage2 (void) { return _T(""); }
|
||||
virtual unsigned int Version (void) { return 201; }
|
||||
virtual void ShowAbout (HWND hWnd) { return; }
|
||||
// virtual int DoExport (const TCHAR *name, ExpInterface *ei, Interface *i);
|
||||
virtual int DoExport(const TCHAR *name,ExpInterface *ei,Interface *i, BOOL suppressPrompts=FALSE,DWORD options=0); // Export file
|
||||
|
||||
// Integer constants for this class
|
||||
enum
|
||||
{
|
||||
MAX_NAME_CHARS = 70,
|
||||
UNDESIRABLE_NODE_MARKER = -7777
|
||||
};
|
||||
|
||||
// For keeping info about each (non-ignored) 3dsMax node in the tree
|
||||
typedef struct
|
||||
{
|
||||
char szNodeName[MAX_NAME_CHARS]; // usefull for lookups
|
||||
Matrix3 mat3NodeTM; // node's transformation matrix (at time zero)
|
||||
Matrix3 mat3ObjectTM; // object-offset transformation matrix (at time zero)
|
||||
int imaxnodeParent; // cached index of parent node
|
||||
float xRotFirstFrame; // 1st frame's X rotation
|
||||
float yRotFirstFrame; // 1st frame's Y rotation
|
||||
float zRotFirstFrame; // 1st frame's Z rotation
|
||||
bool isMirrored;
|
||||
} MaxNode;
|
||||
MaxNode *m_rgmaxnode; // array of nodes
|
||||
long m_imaxnodeMac; // # of nodes
|
||||
|
||||
// Animation metrics (gleaned from 3dsMax and cached for convenience)
|
||||
Interval m_intervalOfAnimation;
|
||||
TimeValue m_tvStart;
|
||||
TimeValue m_tvEnd;
|
||||
int m_tpf; // ticks-per-frame
|
||||
|
||||
private:
|
||||
BOOL CollectNodes (ExpInterface *expiface);
|
||||
BOOL DumpBones (FILE *pFile, ExpInterface *pexpiface);
|
||||
BOOL DumpRotations (FILE *pFile, ExpInterface *pexpiface);
|
||||
BOOL DumpModel (FILE *pFile, ExpInterface *pexpiface);
|
||||
BOOL DumpDeforms (FILE *pFile, ExpInterface *pexpiface);
|
||||
|
||||
// Is this MAX file just the reference frame, or an animation?
|
||||
// If TRUE, the "bones" and "mesh" files will be created.
|
||||
// If FALSE, the "rots" file will be created.
|
||||
BOOL m_fReferenceFrame;
|
||||
};
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Basically just a ClassFactory for communicating with 3DSMAX.
|
||||
//
|
||||
class SmdExportClassDesc : public ClassDesc
|
||||
{
|
||||
public:
|
||||
int IsPublic (void) { return TRUE; }
|
||||
void * Create (BOOL loading=FALSE) { return new SmdExportClass; }
|
||||
const TCHAR * ClassName (void) { return _T("SmdExport"); }
|
||||
SClass_ID SuperClassID (void) { return SCENE_EXPORT_CLASS_ID; }
|
||||
Class_ID ClassID (void) { return Class_ID(0x774a43fd, 0x794d2210); }
|
||||
const TCHAR * Category (void) { return _T(""); }
|
||||
};
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Tree Enumeration Callback
|
||||
// Just counts the nodes in the node tree
|
||||
//
|
||||
class CountNodesTEP : public ITreeEnumProc
|
||||
{
|
||||
public:
|
||||
virtual int callback(INode *node);
|
||||
int m_cNodes; // running count of nodes
|
||||
};
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Tree Enumeration Callback
|
||||
// Collects the nodes in the tree into the global array
|
||||
//
|
||||
class CollectNodesTEP : public ITreeEnumProc
|
||||
{
|
||||
public:
|
||||
virtual int callback(INode *node);
|
||||
SmdExportClass *m_phec;
|
||||
};
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Tree Enumeration Callback
|
||||
// Dumps the bone offsets to a file.
|
||||
//
|
||||
class DumpNodesTEP : public ITreeEnumProc
|
||||
{
|
||||
public:
|
||||
virtual int callback(INode *node);
|
||||
FILE *m_pfile; // write to this file
|
||||
SmdExportClass *m_phec;
|
||||
};
|
||||
|
||||
|
||||
//===================================================================
|
||||
// Tree Enumeration Callback
|
||||
// Dumps the per-frame bone rotations to a file.
|
||||
//
|
||||
class DumpFrameRotationsTEP : public ITreeEnumProc
|
||||
{
|
||||
public:
|
||||
virtual int callback(INode *node);
|
||||
void cleanup(void);
|
||||
FILE *m_pfile; // write to this file
|
||||
TimeValue m_tvToDump; // dump snapshot at this frame time
|
||||
SmdExportClass *m_phec;
|
||||
};
|
||||
|
||||
//===================================================================
|
||||
// Tree Enumeration Callback
|
||||
// Dumps the triangle meshes to a file.
|
||||
//
|
||||
class DumpModelTEP : public ITreeEnumProc
|
||||
{
|
||||
public:
|
||||
virtual int callback(INode *node);
|
||||
void cleanup(void);
|
||||
FILE *m_pfile; // write to this file
|
||||
TimeValue m_tvToDump; // dump snapshot at this frame time
|
||||
SmdExportClass *m_phec;
|
||||
IPhyContextExport *m_mcExport;
|
||||
IPhysiqueExport *m_phyExport;
|
||||
Modifier *m_phyMod;
|
||||
Modifier *m_bonesProMod;
|
||||
BonesPro_WeightArray *m_wa;
|
||||
private:
|
||||
Point3 Pt3GetRVertexNormal(RVertex *prvertex, DWORD smGroupFace);
|
||||
void DumpWeights( int iVertex );
|
||||
};
|
||||
|
28
utils/smdlexp/smexprc.h
Normal file
28
utils/smdlexp/smexprc.h
Normal file
@ -0,0 +1,28 @@
|
||||
//========= Copyright <20> 1996-2005, Valve Corporation, All rights reserved. ============//
|
||||
//
|
||||
// Purpose:
|
||||
//
|
||||
// $NoKeywords: $
|
||||
//
|
||||
//=============================================================================//
|
||||
//{{NO_DEPENDENCIES}}
|
||||
// Microsoft Developer Studio generated include file.
|
||||
// Used by smdlexp.rc
|
||||
//
|
||||
#define IDD_SMDLEXP_UI 101
|
||||
#define IDD_EXPORTOPTIONS 101
|
||||
#define IDC_CHECK_SKELETAL 1000
|
||||
#define IDC_CHECK_DEFORM 1001
|
||||
#define IDC_CHECK_REFFRAME 1002
|
||||
#define IDC_CHECK_PHYSIQUE 1003
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
#ifdef APSTUDIO_INVOKED
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 102
|
||||
#define _APS_NEXT_COMMAND_VALUE 40001
|
||||
#define _APS_NEXT_CONTROL_VALUE 1006
|
||||
#define _APS_NEXT_SYMED_VALUE 101
|
||||
#endif
|
||||
#endif
|
Reference in New Issue
Block a user