From 446ce137c6823ba9eff273bdafdaf266287c7c98 Mon Sep 17 00:00:00 2001 From: Bryan Galdrikian Date: Tue, 21 Feb 2017 12:07:59 -0800 Subject: first commit --- NvBlast/tools/common/IMeshFileWriter.h | 41 ++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 NvBlast/tools/common/IMeshFileWriter.h (limited to 'NvBlast/tools/common/IMeshFileWriter.h') diff --git a/NvBlast/tools/common/IMeshFileWriter.h b/NvBlast/tools/common/IMeshFileWriter.h new file mode 100644 index 0000000..562df70 --- /dev/null +++ b/NvBlast/tools/common/IMeshFileWriter.h @@ -0,0 +1,41 @@ +#pragma once +#include "NvBlastExtAuthoringTypes.h" +#include +#include +#include + +struct NvBlastAsset; + +class IMeshFileWriter +{ +public: + + /** + Input mesh geometry as triangle array + */ + virtual bool saveToFile(const NvBlastAsset* asset, std::vector> chunksGeometry, std::string assetName, std::string outputPath) = 0; + + + /** + Input mesh geometry as vertex buffers with separate indices for positions, normals and uvs. Is used for compressed output to .obj file. + */ + virtual bool saveToFile(const NvBlastAsset* asset, const std::string& name, const std::string& outputPath, const std::vector& pos, const std::vector& norm, + const std::vector& uvs, + const std::vector > >& posIndex, + const std::vector > >& normIndex, + const std::vector > >& texIndex, + const std::vector& texPathes, + const uint32_t submeshCount) = 0; + + + /** + Input mesh geometry as vertex buffers and single index array. + */ + virtual bool saveToFile(const NvBlastAsset* asset, const std::string& name, const std::string& outputPath, const std::vector& pos, const std::vector& norm, const std::vector& uvs, + const std::vector > >& indices) = 0; + + virtual bool getConvertToUE4() { return bConvertToUE4; } + virtual void setConvertToUE4(bool bConvert) { bConvertToUE4 = bConvert; } +private: + bool bConvertToUE4; +}; -- cgit v1.2.3