aboutsummaryrefslogtreecommitdiff
path: root/include/gfesdk/bindings/cpp/isdk_cpp.h
diff options
context:
space:
mode:
authorDwilson_NV <[email protected]>2017-10-18 16:34:35 -0500
committerDwilson_NV <[email protected]>2017-10-18 16:34:35 -0500
commitce27cf3375ce49d79075026d39989f7d24d34739 (patch)
treeefc830137f8cfb93aa54bec277a5efcdfb729301 /include/gfesdk/bindings/cpp/isdk_cpp.h
parentDelete README.md (diff)
downloadarchived-gfesdk-ce27cf3375ce49d79075026d39989f7d24d34739.tar.xz
archived-gfesdk-ce27cf3375ce49d79075026d39989f7d24d34739.zip
Push GFE SDK #147
Corresponds to the 147 build of the SDK (minus the UE4 sample)
Diffstat (limited to 'include/gfesdk/bindings/cpp/isdk_cpp.h')
-rw-r--r--include/gfesdk/bindings/cpp/isdk_cpp.h56
1 files changed, 56 insertions, 0 deletions
diff --git a/include/gfesdk/bindings/cpp/isdk_cpp.h b/include/gfesdk/bindings/cpp/isdk_cpp.h
new file mode 100644
index 0000000..f2c0d03
--- /dev/null
+++ b/include/gfesdk/bindings/cpp/isdk_cpp.h
@@ -0,0 +1,56 @@
+/* Copyright (c) 2017, 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.
+*/
+
+/*!
+ * \file
+ * C++ bindings for GfeSDK.
+ */
+
+#ifndef GFESDK_ISDK_CPP_H
+#define GFESDK_ISDK_CPP_H
+
+#include "sdk_types_cpp.h"
+
+namespace GfeSDK
+{
+// Avoid polluting global namespace with C api, so put it inside namespace
+#include <gfesdk/isdk.h>
+
+// Static functions that don't depend on an instance of the SDK
+// Giving an alias to these to remove the NVGSDK_ prefix in lieu of the namespace
+/*! C++ binding for \ref NVGSDK_SetLogLevel */
+inline NVGSDK_RetCode SetFileLogLevel(NVGSDK_LogLevel level) { return NVGSDK_SetLogLevel(level); }
+/*! C++ binding for \ref NVGSDK_AttachLogListener */
+inline NVGSDK_RetCode AttachLogListener(NVGSDK_LoggingCallback callback) { return NVGSDK_AttachLogListener(callback); }
+/*! C++ binding for \ref NVGSDK_SetListenerLogLevel */
+inline NVGSDK_RetCode SetListenerLogLevel(NVGSDK_LogLevel level) { return NVGSDK_SetListenerLogLevel(level); }
+/*! C++ binding for NVGSDK_RetCodeToString */
+inline const char* RetCodeToString(NVGSDK_RetCode rc) { return NVGSDK_RetCodeToString(rc); }
+
+/*! C++ Core interface */
+class Core
+{
+public:
+ /*! C++ binding for \ref NVGSDK_Create */
+ static Core* Create(CreateInputParams const&, CreateResponse&);
+ virtual ~Core() {}
+
+ /*! C++ binding for \ref NVGSDK_Poll */
+ virtual NVGSDK_RetCode Poll(void) = 0;
+ /*! C++ binding for \ref NVGSDK_RequestPermissionsAsync */
+ virtual void RequestPermissionsAsync(RequestPermissionsParams const&, TCallback cb = nullptr, void* cbContext = nullptr) = 0;
+ /*! C++ binding for \ref NVGSDK_GetUILanguageAsync */
+ virtual void GetUILanguageAsync(TGetUILanguageCallback cb = nullptr, void* cbContext = nullptr) = 0;
+
+ // Return the C API handle;
+ virtual NVGSDK_HANDLE* GetHandle() = 0;
+};
+}
+
+#endif //GFESDK_ISDK_CPP_H