]> rtime.felk.cvut.cz Git - opencv.git/commitdiff
repair windows package and compile errors on Windows
authorvp153 <vp153@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Tue, 29 Sep 2009 10:29:11 +0000 (10:29 +0000)
committervp153 <vp153@73c94f0f-984f-4a5f-82bc-2d8db8d8ee08>
Tue, 29 Sep 2009 10:29:11 +0000 (10:29 +0000)
git-svn-id: https://code.ros.org/svn/opencv/trunk@2197 73c94f0f-984f-4a5f-82bc-2d8db8d8ee08

16 files changed:
opencv/CMakeLists.txt
opencv/COPYING
opencv/ChangeLog
opencv/OpenCVInstallRequiredSystemLibraries.cmake
opencv/Package.cmake.in
opencv/README
opencv/doc/Cv-cpp.tex
opencv/doc/CvReference.tex
opencv/doc/CxCore-cpp.tex
opencv/doc/CxCore.tex
opencv/doc/index.htm
opencv/doc/license.txt
opencv/include/opencv/ml.h
opencv/interfaces/python/CMakeLists.txt
opencv/src/ml/mlem.cpp
opencv/src/ml/mlknearest.cpp

index 2c2c0a145b4d91fd6c8c1d5db42eff49a00a9b4a..1b003981a0e53ddcbc0ba9fee876d25e4ca34eec 100644 (file)
@@ -464,6 +464,11 @@ foreach(v "6.1" "6.0" "5.3" "5.2" "5.1")
 endforeach()\r
 \r
 message(STATUS "IPP detected: ${IPP_FOUND}")\r
+\r
+if(WIN32 AND NOT MSVC)\r
+    set(IPP_FOUND)\r
+endif()\r
+\r
 set(USE_IPP ${IPP_FOUND} CACHE BOOL "Use IPP when available")\r
 \r
 if(IPP_FOUND AND USE_IPP)\r
@@ -800,7 +805,7 @@ if(BUILD_PACKAGE)
        \r
     include(${CMAKE_BINARY_DIR}/.cpack/Package.cmake)\r
 \r
-    set(root_files AUTHORS README ChangeLog COPYING INSTALL NEWS THANKS)\r
+    set(root_files README ChangeLog)\r
 \r
     file(GLOB root_src_files *.in *.sh *.cmake CMakeLists.txt)\r
 \r
@@ -822,12 +827,22 @@ if(BUILD_PACKAGE)
                        COMPONENT main\r
                        )\r
 \r
+        if(CMAKE_INSTALL_DEBUG_LIBRARIES)\r
+            foreach(m cxcore cv cvaux ml highgui opencv_ffmpeg)\r
+                install(FILES ${CMAKE_BINARY_DIR}/bin/Debug/${m}${OPENCV_DLLVERSION}d.dll\r
+                       DESTINATION bin COMPONENT main)\r
+                install(FILES ${CMAKE_BINARY_DIR}/lib/Debug/${m}${OPENCV_DLLVERSION}d.lib\r
+                       DESTINATION lib COMPONENT main)\r
+            endforeach()     \r
+        endif()\r
+\r
         install(DIRECTORY data samples DESTINATION "." COMPONENT main PATTERN ".svn" EXCLUDE)\r
         install(DIRECTORY 3rdparty apps interfaces src tests utils DESTINATION "." COMPONENT src PATTERN ".svn" EXCLUDE)\r
         install(DIRECTORY doc/ DESTINATION doc COMPONENT src FILES_MATCHING PATTERN "*.tex")\r
         install(DIRECTORY doc/pics DESTINATION doc COMPONENT src PATTERN ".svn" EXCLUDE)\r
         install(DIRECTORY doc/plastex DESTINATION doc COMPONENT src PATTERN ".svn" EXCLUDE)\r
-       endif()\r
+    \r
+    endif()\r
 endif()\r
 \r
 \r
index 260d1b8acfe1a4d0e82ed27f0c47797df4d349c6..9bda85ac5c1a1cd38e0cd9f4683463124bb521fc 100644 (file)
@@ -9,7 +9,7 @@ IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
                For Open Source Computer Vision Library
 
 Copyright (C) 2000-2008, Intel Corporation, all rights reserved.
-Copyright (C) 2009, Willow Garage Inc., all rights reserved.
+Copyright (C) 2008-2009, Willow Garage Inc., all rights reserved.
 Third party copyrights are property of their respective owners.
 
 Redistribution and use in source and binary forms, with or without modification,
index 770707d9b3492b455f32145429d6d5393283a184..0e200e6360c2bc916960a425543f22086407efa8 100644 (file)
Binary files a/opencv/ChangeLog and b/opencv/ChangeLog differ
index 9c9ee91b7af8785424d58d8036283ce1586017db..25d026f1787caa76bb60d7b6fea6559dbe57bd64 100644 (file)
@@ -110,8 +110,8 @@ IF(MSVC)
         SET(MSVC90_OPENMP_DIR
           "${MSVC90_REDIST_DIR}/Debug_NonRedist/${CMAKE_MSVC_ARCH}/Microsoft.VC90.DebugOPENMP")
         SET(__install__libs ${__install__libs}
-          "${MSVC90_CRT_DIR}/Microsoft.VC90.DebugOpenMP.manifest"
-          "${MSVC90_CRT_DIR}/vcomp90d.dll"
+          "${MSVC90_OPENMP_DIR}/Microsoft.VC90.DebugOpenMP.manifest"
+          "${MSVC90_OPENMP_DIR}/vcomp90d.dll"
           )
       ENDIF(CMAKE_INSTALL_DEBUG_LIBRARIES)
     ENDIF(CMAKE_INSTALL_OPENMP_LIBRARIES) 
index 30f35826f33dc2f63e13cc92ce95e7f9e66df6d5..664e0e3fba3f6de8a7a54d92830a369f151d5f7a 100644 (file)
@@ -5,23 +5,19 @@
 #
 
 set(CMAKE_INSTALL_DEBUG_LIBRARIES 1)
-set(CMAKE_INSTALL_OPENMP_LIBRARIES 1)
-#include(OpenCVInstallRequiredSystemLibraries.cmake)
-include(InstallRequiredSystemLibraries)
-
-
-if(WIN32)
-       # Add "<install_path>/bin" to the system PATH
-       SET(CPACK_NSIS_MODIFY_PATH ON)
-endif(WIN32)
+if(ENABLE_OPENMP)
+    set(CMAKE_INSTALL_OPENMP_LIBRARIES 1)
+endif()
+include(OpenCVInstallRequiredSystemLibraries.cmake)
+#include(InstallRequiredSystemLibraries)
 
 set(CPACK_PACKAGE_NAME "OpenCV")
 set(CPACK_PACKAGE_VENDOR "OpenCV project opencvlibrary.sourceforge.net")
 
 set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "OpenCV SDK for ${CMAKE_GENERATOR} is an All-In-One package for developing computer vision applications")
 
-set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README")
-set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/COPYING")
+#set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_SOURCE_DIR}/README")
+set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_SOURCE_DIR}/doc/license.txt")
 
 set(CPACK_PACKAGE_VERSION_MAJOR "${OPENCV_VERSION_MAJOR}")
 set(CPACK_PACKAGE_VERSION_MINOR "${OPENCV_VERSION_MINOR}")
@@ -31,7 +27,7 @@ set(CPACK_PACKAGE_INSTALL_DIRECTORY "OpenCV${CPACK_PACKAGE_VERSION_MAJOR}.${CPAC
 
 set(CPACK_PACKAGE_EXECUTABLES "")
 
-set(CPACK_COMPONENTS_ALL main src)
+set(CPACK_COMPONENTS_ALL main src Unspecified)
 
 set(CPACK_COMPONENT_main_DISPLAY_NAME "Binaries and the Documentation")
 set(CPACK_COMPONENT_src_DISPLAY_NAME "The source code")
@@ -58,20 +54,23 @@ set(CPACK_SOURCE_IGNORE_FILES
        "\\\\.aux$"
        "\\\\.bbl$"
        "\\\\.blg$"
+    "\\\\.dsp$"
        "\\\\.idx$"
        "\\\\.ilg$"
        "\\\\.ind$"
        "\\\\.log$"
        "\\\\.toc$"
        "\\\\.out$"
+    "\\\\.vcproj$"
        "/1$"
        "${CPACK_SOURCE_IGNORE_FILES}")
 
 if(WIN32)
-       set(CPACK_GENERATOR "NSIS")
-       set(CPACK_NSIS_MUI_ICON "${CMAKE_SOURCE_DIR}\\\\utils\\\\opencv.ico")
-       set(CPACK_NSIS_MUI_UNIICON "${CMAKE_SOURCE_DIR}\\\\utils\\\\opencv.ico")
-       #set(CPACK_PACKAGE_ICON "utils/opencv.ico")     
+    set(CPACK_GENERATOR "NSIS")
+    set(CPACK_NSIS_PACKAGE_NAME "OpenCV ${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
+    set(CPACK_NSIS_MUI_ICON "${CMAKE_SOURCE_DIR}\\\\utils\\\\opencv.ico")
+    set(CPACK_NSIS_MUI_UNIICON "${CMAKE_SOURCE_DIR}\\\\utils\\\\opencv.ico")
+    #set(CPACK_PACKAGE_ICON "utils/opencv.ico")        
                
     set(CPACK_NSIS_INSTALLED_ICON_NAME "${CMAKE_SOURCE_DIR}\\\\utils\\\\opencv.ico")
     set(CPACK_NSIS_HELP_LINK "http:\\\\\\\\opencvlibrary.sourceforge.net")
@@ -85,15 +84,18 @@ if(WIN32)
         "CMakeLists.txt" "The Build Script (open with CMake)"
         "samples\\\\c" "C Samples"
         "samples\\\\python" "Python Samples")
-else()
-       set(CPACK_GENERATOR "TBZ2")
-       set(CPACK_SOURCE_GENERATOR "TBZ2")
-       set(CPACK_SOURCE_PACKAGE_FILE_NAME
-               "${CMAKE_PROJECT_NAME}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
        
-       if(APPLE)
-               set(CPACK_GENERATOR "PackageMaker;TBZ2")
-       endif()
+    # Add "<install_path>/bin" to the system PATH
+    set(CPACK_NSIS_MODIFY_PATH ON)
+else()
+    set(CPACK_GENERATOR "TBZ2")
+    set(CPACK_SOURCE_GENERATOR "TBZ2")
+    set(CPACK_SOURCE_PACKAGE_FILE_NAME
+       "${CMAKE_PROJECT_NAME}-${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
+    
+    if(APPLE)
+       set(CPACK_GENERATOR "PackageMaker;TBZ2")
+    endif()
 endif()
 
 include(CPack)
index a138819da62fc9a3f69c650f4b2fa24145f57e7a..f8bfd8a4d57b33a501587f3bb01749cf9a26dc70 100644 (file)
@@ -1 +1 @@
-See docs/index.htm
+See doc/index.htm
index b20f36150e7e20d4a6741b88cd0b877adc55a464..da3567a6d447f30b07b49bc7c5f3d33bb34db85a 100644 (file)
@@ -1829,19 +1829,19 @@ The above formulas for converting RGB to/from various color spaces have been tak
 
  \item Bayer $\rightarrow$ RGB (\texttt{CV\_BayerBG2BGR, CV\_BayerGB2BGR, CV\_BayerRG2BGR, CV\_BayerGR2BGR, CV\_BayerBG2RGB, CV\_BayerGB2RGB, CV\_BayerRG2RGB, CV\_BayerGR2RGB}) The Bayer pattern is widely used in CCD and CMOS cameras. It allows one to get color pictures from a single plane where R,G and B pixels (sensors of a particular component) are interleaved like this:
 
-\newcommand{\R}{\color{red}R}
-\newcommand{\G}{\color{green}G}
-\newcommand{\B}{\color{blue}B}
+\newcommand{\Rcell}{\color{red}R}
+\newcommand{\Gcell}{\color{green}G}
+\newcommand{\Bcell}{\color{blue}B}
 
 
 \[
 \definecolor{BackGray}{rgb}{0.8,0.8,0.8}
 \begin{array}{ c c c c c }
-\R&\G&\R&\G&\R\\
-\G&\colorbox{BackGray}{\B}&\colorbox{BackGray}{\G}&\B&\G\\
-\R&\G&\R&\G&\R\\
-\G&\B&\G&\B&\G\\
-\R&\G&\R&\G&\R
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell\\
+\Gcell&\colorbox{BackGray}{\Bcell}&\colorbox{BackGray}{\Gcell}&\Bcell&\Gcell\\
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell\\
+\Gcell&\Bcell&\Gcell&\Bcell&\Gcell\\
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell
 \end{array}
 \]
 
index 8ead7b00877e2badb6bd3f712f657169efe0e1b9..81c06626cc2c5073e971c99f59f6d127aa1870b1 100644 (file)
@@ -1660,19 +1660,19 @@ the Ford98
 
  \item Bayer $\rightarrow$ RGB (\texttt{CV\_BayerBG2BGR, CV\_BayerGB2BGR, CV\_BayerRG2BGR, CV\_BayerGR2BGR, CV\_BayerBG2RGB, CV\_BayerGB2RGB, CV\_BayerRG2RGB, CV\_BayerGR2RGB}) The Bayer pattern is widely used in CCD and CMOS cameras. It allows one to get color pictures from a single plane where R,G and B pixels (sensors of a particular component) are interleaved like this:
 
-\newcommand{\R}{\color{red}R}
-\newcommand{\G}{\color{green}G}
-\newcommand{\B}{\color{blue}B}
+\newcommand{\Rcell}{\color{red}R}
+\newcommand{\Gcell}{\color{green}G}
+\newcommand{\Bcell}{\color{blue}B}
 
 
 \[
 \definecolor{BackGray}{rgb}{0.8,0.8,0.8}
 \begin{array}{ c c c c c }
-\R&\G&\R&\G&\R\\
-\G&\colorbox{BackGray}{\B}&\colorbox{BackGray}{\G}&\B&\G\\
-\R&\G&\R&\G&\R\\
-\G&\B&\G&\B&\G\\
-\R&\G&\R&\G&\R
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell\\
+\Gcell&\colorbox{BackGray}{\Bcell}&\colorbox{BackGray}{\Gcell}&\Bcell&\Gcell\\
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell\\
+\Gcell&\Bcell&\Gcell&\Bcell&\Gcell\\
+\Rcell&\Gcell&\Rcell&\Gcell&\Rcell
 \end{array}
 \]
 
index 7bbf25e56ea42d254e5d344e1758d3973443c510..0ad185adedec85d9505968f5423e16f18de28938 100644 (file)
@@ -2935,7 +2935,7 @@ The function \texttt{flip} flips the array in one of three different ways (row a
 
 The example scenarios of function use are:
 \begin{itemize}
-  \item vertical flipping of the image ($\texttt{flipCode} > 0$) to switch between top-left and bottom-left image origin, which is a typical operation in video processing in Windows.
+  \item vertical flipping of the image ($\texttt{flipCode} = 0$) to switch between top-left and bottom-left image origin, which is a typical operation in video processing in Windows.
   \item horizontal flipping of the image with subsequent horizontal shift and absolute difference calculation to check for a vertical-axis symmetry ($\texttt{flipCode} > 0$)
   \item simultaneous horizontal and vertical flipping of the image with subsequent shift and absolute difference calculation to check for a central symmetry ($\texttt{flipCode} < 0$)
   \item reversing the order of 1d point arrays ($\texttt{flipCode} > 0$ or $\texttt{flipCode} = 0$)
index a8662e004e79a22b618b02f764ec7ceed4a7ffd5..bc00ea8f63a9c1191308780349141912b5a6f494 100644 (file)
@@ -2044,7 +2044,7 @@ dst(i,j) = \forkthree
 
 The example scenarios of function use are:
 \begin{itemize}
-  \item vertical flipping of the image (flip\_mode > 0) to switch between top-left and bottom-left image origin, which is a typical operation in video processing under Win32 systems.
+  \item vertical flipping of the image (flip\_mode = 0) to switch between top-left and bottom-left image origin, which is a typical operation in video processing under Win32 systems.
   \item horizontal flipping of the image with subsequent horizontal shift and absolute difference calculation to check for a vertical-axis symmetry (flip\_mode $>$ 0)
   \item simultaneous horizontal and vertical flipping of the image with subsequent shift and absolute difference calculation to check for a central symmetry (flip\_mode $<$ 0)
   \item reversing the order of 1d point arrays (flip\_mode > 0)
index 405440e020556c787ab0e050e24c652f67005704..e3b9fdf005b648c2e2fc4be6d335bf4195913913 100644 (file)
@@ -75,11 +75,12 @@ quad- and many-core systems.
 <hr>
 
 <h1>Who created it</h1>
-<p>The list of authors and major contributors can be found in the file <a href="../THANKS">THANKS</a>.</p>
+The list of authors and major contributors can be found at
+<a href="http://opencv.willowgarage.com/wiki/Contributors">http://opencv.willowgarage.com/wiki/Contributors</a>.</p>
 <hr>
 
 <h1>What's New</h1>
-<p>See the <a href="../ChangeLog">ChangeLog</a>.
+<p>See the <a href="../ChangeLog.txt">ChangeLog.txt</a>.
 <hr>
 
 <h1>Where to get OpenCV</h1>
@@ -88,6 +89,11 @@ If it does not work, type "OpenCV" in
 <a href="http://www.google.com/search?hl=en&ie=UTF-8&q=opencv+computer+vision&btnG=%D0%9F%D0%BE%D0%B8%D1%81%D0%BA&lr=">Google (http://www.google.com)</a>.</p>
 
 <hr>
+<h1>How to build it</h1>
+<p>See the installation guide: <a href="http://opencv.willowgarage.com/wiki/InstallGuide">http://opencv.willowgarage.com/wiki/InstallGuide</a>.
+
+<hr>
+
 <h1><a name="troubleshooting">If you have a problem with installing/running/using OpenCV</a></h1>
 
 <ol>
index 260d1b8acfe1a4d0e82ed27f0c47797df4d349c6..9bda85ac5c1a1cd38e0cd9f4683463124bb521fc 100644 (file)
@@ -9,7 +9,7 @@ IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.
                For Open Source Computer Vision Library
 
 Copyright (C) 2000-2008, Intel Corporation, all rights reserved.
-Copyright (C) 2009, Willow Garage Inc., all rights reserved.
+Copyright (C) 2008-2009, Willow Garage Inc., all rights reserved.
 Third party copyrights are property of their respective owners.
 
 Redistribution and use in source and binary forms, with or without modification,
index e5c8d8eeda17e5be53a4664e85ce749c9495b1a2..6998bd8151c9c47880f77be0b77316899cc83861 100644 (file)
@@ -1310,8 +1310,8 @@ public:
     
     virtual bool train( const cv::Mat& _train_data, int _tflag,
                        const cv::Mat& _responses, const cv::Mat& _var_idx=cv::Mat(),
-                       const cv::Mat& _sample_idx=0, const cv::Mat& _var_type=cv::Mat(),
-                       const cv::Mat& _missing_mask=0,
+                       const cv::Mat& _sample_idx=cv::Mat(), const cv::Mat& _var_type=cv::Mat(),
+                       const cv::Mat& _missing_mask=cv::Mat(),
                        CvBoostParams params=CvBoostParams(),
                        bool update=false );
     
index 2f65c3093ed8f2c23aeef77ca68b31463913710d..fdfb1cd4a7b18d862455c408121c073069fe23a7 100644 (file)
@@ -25,5 +25,26 @@ add_library(${the_target} SHARED ${lib_srcs} ${lib_hdrs} ${lib_int_hdrs} ${CMAKE
 target_link_libraries(${the_target} ${PYTHON_LIBRARIES} cxcore cv highgui)
 set_target_properties(${the_target} PROPERTIES PREFIX "")
 set_target_properties(${the_target} PROPERTIES OUTPUT_NAME "cv")
-set_target_properties(${the_target} PROPERTIES SUFFIX ".so")
-install(FILES ${LIBRARY_OUTPUT_PATH}/cv.so DESTINATION ${PYTHON_PACKAGES_PATH})
+if(WIN32)
+   set(CVPY_SUFFIX ".pyd")
+else()
+   set(CVPY_SUFFIX ".so")
+endif()
+
+set_target_properties(${the_target} PROPERTIES SUFFIX ${CVPY_SUFFIX})
+
+set(cvpy_files cv${CVPY_SUFFIX})
+
+if(WIN32)
+    install(TARGETS ${the_target}
+            RUNTIME DESTINATION "Python${PYTHON_VERSION_MAJOR_MINOR}/Lib/site-packages" COMPONENT main
+            LIBRARY DESTINATION "Python${PYTHON_VERSION_MAJOR_MINOR}/Lib/site-packages" COMPONENT main
+            ARCHIVE DESTINATION "Python${PYTHON_VERSION_MAJOR_MINOR}/Lib/site-packages" COMPONENT main
+            )
+else()
+    install(TARGETS ${the_target}
+            RUNTIME DESTINATION ${PYTHON_PLUGIN_INSTALL_PATH} COMPONENT main
+            LIBRARY DESTINATION ${PYTHON_PLUGIN_INSTALL_PATH} COMPONENT main
+            ARCHIVE DESTINATION ${PYTHON_PLUGIN_INSTALL_PATH} COMPONENT main
+            )
+endif()
index 83cae176c5faadb7beb2c0637a3354177e36856b..d15643c5de374f1a7527060dd6cfa2ece2735a14 100644 (file)
@@ -1134,7 +1134,7 @@ bool CvEM::train( const Mat& _samples, const Mat& _sample_idx,
             _labels->create(nsamples, 1, CV_32SC1);
         plabels = &(labels = *_labels);
     }
-    return train(&samples, sidx.data.ptr ? &sidx : 0, params, plabels);
+    return train(&samples, sidx.data.ptr ? &sidx : 0, _params, plabels);
 }
 
 float
index 0b545fbebf29e2cfc025331015b18832a5b02d91..8b769e0c8cab8c323465e1bcd3e220bfc0c2c93a 100644 (file)
@@ -413,7 +413,7 @@ bool CvKNearest::train( const Mat& _train_data, const Mat& _responses,
 {
     CvMat tdata = _train_data, responses = _responses, sidx = _sample_idx;
     
-    return train(_train_data, _responses, sidx.data.ptr ? &sidx : 0, _is_regression, _max_k, _update_base );
+    return train(&tdata, &responses, sidx.data.ptr ? &sidx : 0, _is_regression, _max_k, _update_base );
 }