diff options
| author | Ben Marsh <[email protected]> | 2019-10-22 09:07:59 -0400 |
|---|---|---|
| committer | Ben Marsh <[email protected]> | 2019-10-22 09:07:59 -0400 |
| commit | bd0027e737c6512397f841c22786274ed74b927f (patch) | |
| tree | f7ffbdb8f3741bb7f24635616cc189cba5cb865c /mayaPlug/shaveAPIimpl.h | |
| download | archived-shave-and-a-haircut-bd0027e737c6512397f841c22786274ed74b927f.tar.xz archived-shave-and-a-haircut-bd0027e737c6512397f841c22786274ed74b927f.zip | |
Adding Shave-and-a-Haircut 9.6
Diffstat (limited to 'mayaPlug/shaveAPIimpl.h')
| -rw-r--r-- | mayaPlug/shaveAPIimpl.h | 82 |
1 files changed, 82 insertions, 0 deletions
diff --git a/mayaPlug/shaveAPIimpl.h b/mayaPlug/shaveAPIimpl.h new file mode 100644 index 0000000..60f3164 --- /dev/null +++ b/mayaPlug/shaveAPIimpl.h @@ -0,0 +1,82 @@ +#ifndef shaveAPIimpl_h +#define shaveAPIimpl_h +// Shave and a Haircut +// (c) 2019 Epic Games +// US Patent 6720962 + +#include <maya/MStatus.h> +#include <vector> + +#include "libShave.h" +#include "shaveAPI.h" +#include "shaveGlobals.h" +#include "shaveSDK.h" + +#if MAYA_API_VERSION < 20180000 +class MObjectArray; +#endif + +class shaveHairShape; + + +class LIBSHAVE_API shaveAPIimpl +{ +public: + static MStatus clearHairStack(); + + static MStatus createHairStack( + MObjectArray& shaveHairShapes, + const shaveGlobals::Globals& globals + ); + + static MStatus exportAllHair( + shaveAPI::HairInfo* hairInfo, bool renderableOnly + ); + + static MStatus exportDRAFile(MString filename); + + static MStatus exportHair( + MObjectArray& shaveHairShapes, + shaveAPI::HairInfo* hairInfo + ); + + static MStatus exportOcclusions( + shaveAPI::SceneGeom* hairOcclusions, + shaveAPI::SceneGeom* shadowOcclusions + ); + + static void freeHairInfo(shaveAPI::HairInfo* hairInfo); + static void initHairInfo(shaveAPI::HairInfo* hairInfo); + + //****************************************** + // + // SceneGeom Interfaces + // + //****************************************** + static void freeSceneGeom(shaveAPI::SceneGeom* sceneGeom); + static void initSceneGeom(shaveAPI::SceneGeom* sceneGeom); + + //****************************************** + // + // Utility Methods + // + //****************************************** + static void copyWFTYPEToSceneGeom( + shaveAPI::SceneGeom* sceneGeom, WFTYPE& wf + ); + + static shaveHairShape* getNodeFromStack(unsigned int nodeIndex); + +protected: + static std::vector<shaveHairShape*> mShaveNodes; + + static MStatus doExport( + MObjectArray& shaveHairShapes, + shaveAPI::HairInfo* hairInfo, + const shaveGlobals::Globals& globals + ); + + static MStatus doInitHairIterator(MObjectArray& shaveHairShapes); +}; + +#endif |