aboutsummaryrefslogtreecommitdiff
path: root/APEX_1.4/include/ApexSDKCachedData.h
diff options
context:
space:
mode:
Diffstat (limited to 'APEX_1.4/include/ApexSDKCachedData.h')
-rw-r--r--APEX_1.4/include/ApexSDKCachedData.h94
1 files changed, 94 insertions, 0 deletions
diff --git a/APEX_1.4/include/ApexSDKCachedData.h b/APEX_1.4/include/ApexSDKCachedData.h
new file mode 100644
index 00000000..2009280c
--- /dev/null
+++ b/APEX_1.4/include/ApexSDKCachedData.h
@@ -0,0 +1,94 @@
+/*
+ * Copyright (c) 2008-2015, NVIDIA CORPORATION. All rights reserved.
+ *
+ * NVIDIA CORPORATION and its licensors retain all intellectual property
+ * and proprietary rights in and to this software, related documentation
+ * and any modifications thereto. Any use, reproduction, disclosure or
+ * distribution of this software and related documentation without an express
+ * license agreement from NVIDIA CORPORATION is strictly prohibited.
+ */
+
+
+#ifndef APEX_SDKCACHED_DATA_H
+#define APEX_SDKCACHED_DATA_H
+
+/*!
+\file
+\brief classes ModuleCachedData, ApexSDKCachedData
+*/
+
+#include "ApexSDK.h"
+
+namespace NvParameterized
+{
+class Interface;
+};
+
+namespace nvidia
+{
+namespace apex
+{
+
+
+/**
+\brief Cached data is stored per-module.
+*/
+class ModuleCachedData
+{
+public:
+ /**
+ * \brief Retreives the cached data for the asset, if it exists.
+ *
+ * Otherwise returns NULL.
+ */
+ virtual ::NvParameterized::Interface* getCachedDataForAssetAtScale(Asset& asset, const PxVec3& scale) = 0;
+
+ /**
+ * \brief Serializes the cooked data for a single asset into a stream.
+ */
+ virtual PxFileBuf& serializeSingleAsset(Asset& asset, PxFileBuf& stream) = 0;
+
+ /**
+ * \brief Deserializes the cooked data for a single asset from a stream.
+ */
+ virtual PxFileBuf& deserializeSingleAsset(Asset& asset, PxFileBuf& stream) = 0;
+};
+
+/**
+\brief A method for storing actor data in a scene
+*/
+class ApexSDKCachedData
+{
+public:
+ /**
+ * \brief Retreives the scene cached data for the actor, if it exists.
+ *
+ * Otherwise returns NULL.
+ */
+ virtual ModuleCachedData* getCacheForModule(AuthObjTypeID moduleID) = 0;
+
+ /**
+ * \brief Save cache configuration to a stream
+ */
+ virtual PxFileBuf& serialize(PxFileBuf&) const = 0;
+
+ /**
+ * \brief Load cache configuration from a stream
+ */
+ virtual PxFileBuf& deserialize(PxFileBuf&) = 0;
+
+ /**
+ * \brief Clear data
+ */
+ virtual void clear(bool force = true) = 0;
+
+protected:
+ ApexSDKCachedData() {}
+ virtual ~ApexSDKCachedData() {}
+};
+
+}
+} // end namespace nvidia::apex
+
+
+#endif // APEX_SDKCACHED_DATA_H