diff options
| author | Stanislaw Halik <sthalik@misaki.pl> | 2016-05-16 11:19:10 +0200 |
|---|---|---|
| committer | Stanislaw Halik <sthalik@misaki.pl> | 2016-06-09 10:28:01 +0200 |
| commit | be2926499af2e372c313d965533be3a7ee0dcf4d (patch) | |
| tree | 34501ef650da4a2990912bd0b38ed7135696c164 /Tobii EyeX/include/eyex-cpp/Mask.inl | |
| parent | 6eb99f06be3ead3c898b400d7b9072583c7addf0 (diff) | |
add tobii eyex sdk
Diffstat (limited to 'Tobii EyeX/include/eyex-cpp/Mask.inl')
| -rwxr-xr-x | Tobii EyeX/include/eyex-cpp/Mask.inl | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/Tobii EyeX/include/eyex-cpp/Mask.inl b/Tobii EyeX/include/eyex-cpp/Mask.inl new file mode 100755 index 0000000..3e7ed2d --- /dev/null +++ b/Tobii EyeX/include/eyex-cpp/Mask.inl @@ -0,0 +1,58 @@ +/*********************************************************************************************************************
+ * Copyright 2013-2014 Tobii Technology AB. All rights reserved.
+ * Mask.inl
+ *********************************************************************************************************************/
+
+#if !defined(__TOBII_TX_CLIENT_CPPBINDINGS_MASK__INL__)
+#define __TOBII_TX_CLIENT_CPPBINDINGS_MASK__INL__
+
+/*********************************************************************************************************************/
+
+TX_NAMESPACE_BEGIN
+
+/*********************************************************************************************************************/
+
+inline Mask::Mask(const std::shared_ptr<const Context>& spContext, TX_HANDLE hMask)
+: InteractionObject(spContext, hMask)
+{ }
+
+/*********************************************************************************************************************/
+
+inline int Mask::GetColumnCount() const
+{
+ int columnCount, rowCount;
+ TX_VALIDATE(txGetMaskData(_hObject, &columnCount, &rowCount, nullptr, nullptr));
+ return columnCount;
+}
+
+/*********************************************************************************************************************/
+
+inline int Mask::GetRowCount() const
+{
+ int columnCount, rowCount;
+ TX_VALIDATE(txGetMaskData(_hObject, &columnCount, &rowCount, nullptr, nullptr));
+ return rowCount;
+}
+
+/*********************************************************************************************************************/
+
+inline void Mask::GetData(std::vector<TX_BYTE>& data) const
+{
+ int columnCount, rowCount, dataSize = 0;
+ if(TX_VALIDATE(txGetMaskData(_hObject, &columnCount, &rowCount, nullptr, &dataSize)))
+ return;
+
+ data.resize(dataSize);
+ TX_VALIDATE(txGetMaskData(_hObject, &columnCount, &rowCount, &data[0], &dataSize));
+}
+
+/*********************************************************************************************************************/
+
+TX_NAMESPACE_END
+
+/*********************************************************************************************************************/
+
+
+#endif // !defined(__TOBII_TX_CLIENT_CPPBINDINGS_MASK__INL__)
+
+/*********************************************************************************************************************/
|
