opencv/android/service/engine/jni/BinderComponent/OpenCVEngine.h

38 lines
1.0 KiB
C
Raw Normal View History

2012-06-21 22:50:05 +08:00
#ifndef __OPEN_CV_ENGINE_H__
#define __OPEN_CV_ENGINE_H__
#include "EngineCommon.h"
#include "IOpenCVEngine.h"
#include "BnOpenCVEngine.h"
#include "IPackageManager.h"
#include <binder/IInterface.h>
#include <binder/Parcel.h>
#include <utils/String8.h>
#include <utils/String16.h>
#include <string>
#include <set>
class OpenCVEngine: public BnOpenCVEngine
{
public:
OpenCVEngine(IPackageManager* PkgManager);
int32_t GetVersion();
android::String16 GetLibPathByVersion(android::String16 version);
virtual android::String16 GetLibraryList(android::String16 version);
bool InstallVersion(android::String16 version);
2012-10-17 15:12:04 +08:00
2012-06-21 22:50:05 +08:00
protected:
IPackageManager* PackageManager;
static const std::set<std::string> KnownVersions;
2012-10-17 15:12:04 +08:00
2012-06-21 22:50:05 +08:00
OpenCVEngine();
static std::set<std::string> InitKnownOpenCVersions();
bool ValidateVersionString(const std::string& version);
std::string NormalizeVersionString(std::string version);
bool FixPermissions(const std::string& path);
2012-10-17 15:12:04 +08:00
2012-06-21 22:50:05 +08:00
static const int Platform;
static const int CpuID;
};
#endif