//============================================================================================================================= // // EasyAR Sense 3.1.0-final-7bf6504c6 // Copyright (c) 2015-2020 VisionStar Information Technology (Shanghai) Co., Ltd. All Rights Reserved. // EasyAR is the registered trademark or trademark of VisionStar Information Technology (Shanghai) Co., Ltd in China // and other countries for the augmented reality technology developed by VisionStar Information Technology (Shanghai) Co., Ltd. // //============================================================================================================================= #ifndef __EASYAR_ENGINE_HXX__ #define __EASYAR_ENGINE_HXX__ #include "easyar/types.hxx" namespace easyar { class Engine { public: /// /// Gets the version schema hash, which can be used to ensure type declarations consistent with runtime library. /// static int schemaHash(); static bool initialize(String * key); /// /// Handles the app onPause, pauses internal tasks. /// static void onPause(); /// /// Handles the app onResume, resumes internal tasks. /// static void onResume(); /// /// Gets error message on initialization failure. /// static void errorMessage(/* OUT */ String * * Return); /// /// Gets the version number of EasyARSense. /// static void versionString(/* OUT */ String * * Return); /// /// Gets the product name of EasyARSense. (Including variant, operating system and CPU architecture.) /// static void name(/* OUT */ String * * Return); }; } #endif #ifndef __IMPLEMENTATION_EASYAR_ENGINE_HXX__ #define __IMPLEMENTATION_EASYAR_ENGINE_HXX__ #include "easyar/engine.h" namespace easyar { inline int Engine::schemaHash() { int _return_value_ = easyar_Engine_schemaHash(); return _return_value_; } inline bool Engine::initialize(String * arg0) { if (easyar_Engine_schemaHash() != 1925233218) { return false; } bool _return_value_ = easyar_Engine_initialize(arg0->get_cdata()); return _return_value_; } inline void Engine::onPause() { easyar_Engine_onPause(); } inline void Engine::onResume() { easyar_Engine_onResume(); } inline void Engine::errorMessage(/* OUT */ String * * Return) { easyar_String * _return_value_ = NULL; easyar_Engine_errorMessage(&_return_value_); *Return = new String(_return_value_); } inline void Engine::versionString(/* OUT */ String * * Return) { easyar_String * _return_value_ = NULL; easyar_Engine_versionString(&_return_value_); *Return = new String(_return_value_); } inline void Engine::name(/* OUT */ String * * Return) { easyar_String * _return_value_ = NULL; easyar_Engine_name(&_return_value_); *Return = new String(_return_value_); } } #endif