OpenCV (Open Source Computer Vision) is a library of programming functions mainly aimed at real-time computer vision, originally developed by an Intel research center and now open source.
TouchDesigner comes pre-installed with OpenCV 3.2, and numpy which interface with TouchDesigner's Python 3.5, making it possible for TouchDesigner to access the OpenCV functions directly.
- open TouchDesigner099
- open the Textport with Alt+t
- run following script:
TouchDesigner 64-Bit 099 Build 2017.2620 compile on Fri Feb 17 16:03:29 2017 Python 3.5.1+ (default, Apr 21 2016, 11:06:11) [MSC v.1900 64 bit (AMD64)] python >>> import cv2 python >>> image = cv2.imread(app.samplesFolder+'/Map/Trillium.jpg') python >>> print(image)
- if the output is an array of numbers and no errors, OpenCV is working properly.
OpenCV C++ Documentation is here.
OpenCV License Agreement
TouchDesigner uses parts of OpenCV (the Blob Track TOP) under the following license.
Intel License Agreement.
Copyright (C) 2000, Intel Corporation, rights reserved. Third party copyrights are property of their respective owners.
Redistribution of OpenCV and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
- Redistribution's of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
- Redistribution's in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
- The name of Intel Corporation may not be used to endorse or promote products derived from this software without specific prior written permission.
The OpenCV software is provided by the copyright holders and contributors "as is" and any express or implied warranties, including, but not limited to, the implied warranties of merchantability and fitness for a particular purpose are disclaimed. In no event shall the Intel Corporation or contributors be liable for any direct, indirect, incidental, special, exemplary, or consequential damages (including, but not limited to, procurement of substitute goods or services; loss of use, data, or profits; or business interruption) however caused and on any theory of liability, whether in contract, strict liability, or tort (including negligence or otherwise) arising in any way out of the use of this software, even if advised of the possibility of such damage.