//@}
/*!
- * @see cec_get_min_version
+ * @see cec_get_min_lib_version
*/
- virtual int8_t GetMinVersion(void) = 0;
+ virtual int8_t GetMinLibVersion(void) = 0;
/*!
- * @see cec_get_lib_version
+ * @see cec_get_lib_version_major
*/
- virtual int8_t GetLibVersion(void) = 0;
+ virtual int8_t GetLibVersionMajor(void) = 0;
/*!
- * @see cec_get_lib_version
+ * @see cec_get_lib_version_minor
*/
virtual int8_t GetLibVersionMinor(void) = 0;
/*!
* @return Get the minimal version of libcec that this version of libcec can interface with.
*/
-extern DECLSPEC int8_t cec_get_min_version(void);
+extern DECLSPEC int8_t cec_get_min_lib_version(void);
/*!
- * @return Get the version of libcec.
+ * @return Get the major version of libcec.
*/
-extern DECLSPEC int8_t cec_get_lib_version(void);
+extern DECLSPEC int8_t cec_get_lib_version_major(void);
/*!
* @return Get the minor version of libcec.
#define ESCOFFSET 3
#define CEC_BUTTON_TIMEOUT 500
-#define CEC_MIN_VERSION 8
-#define CEC_LIB_VERSION 8
-#define CEC_LIB_VERSION_MINOR 1
+#define CEC_MIN_LIB_VERSION 1
+#define CEC_LIB_VERSION_MAJOR 1
+#define CEC_LIB_VERSION_MINOR 0
#ifdef __cplusplus
};
virtual bool PingAdapter(void);
virtual bool StartBootloader(void);
- virtual int8_t GetMinVersion(void) { return CEC_MIN_VERSION; };
- virtual int8_t GetLibVersion(void) { return CEC_LIB_VERSION; };
+ virtual int8_t GetMinLibVersion(void) { return CEC_MIN_LIB_VERSION; };
+ virtual int8_t GetLibVersionMajor(void) { return CEC_LIB_VERSION_MAJOR; };
virtual int8_t GetLibVersionMinor(void) { return CEC_LIB_VERSION_MINOR; };
virtual bool GetNextLogMessage(cec_log_message *message);
int8_t cec_get_min_version(void)
{
if (cec_parser)
- return cec_parser->GetMinVersion();
+ return cec_parser->GetMinLibVersion();
return -1;
}
-int8_t cec_get_lib_version(void)
+int8_t cec_get_lib_version_major(void)
{
if (cec_parser)
- return cec_parser->GetLibVersion();
+ return cec_parser->GetLibVersionMajor();
return -1;
}
using namespace CEC;
using namespace std;
-#define CEC_TEST_CLIENT_VERSION 8
+#define CEC_TEST_CLIENT_VERSION 1
#include <cecloader.h>
int main (int argc, char *argv[])
{
ICECAdapter *parser = LoadLibCec("CECTester");
- if (!parser || parser->GetMinVersion() > CEC_TEST_CLIENT_VERSION)
+ if (!parser || parser->GetMinLibVersion() > CEC_TEST_CLIENT_VERSION)
{
#ifdef __WINDOWS__
cout << "Cannot load libcec.dll" << endl;
return 1;
}
CStdString strLog;
- strLog.Format("CEC Parser created - libcec version %d.%d", parser->GetLibVersion(), parser->GetLibVersionMinor());
+ strLog.Format("CEC Parser created - libcec version %d.%d", parser->GetLibVersionMajor(), parser->GetLibVersionMinor());
cout << strLog.c_str() << endl;
//make stdin non-blocking