File tree Expand file tree Collapse file tree 7 files changed +542
-7
lines changed Expand file tree Collapse file tree 7 files changed +542
-7
lines changed Load Diff Large diffs are not rendered by default.
Original file line number Diff line number Diff line change @@ -70,10 +70,14 @@ Licensing
7070---------
7171
7272Opencv-python package (scripts in this repository) is available under
73- MIT license. The OpenCV itself is available under `3-clause BSD
73+ MIT license.
74+
75+ OpenCV itself is available under `3-clause BSD
7476License <https://github.com/opencv/opencv/blob/master/LICENSE> `__
7577(`LICENSE-3RD-PARTY.txt <https://github.com/skvark/opencv-python/blob/master/LICENSE-3RD-PARTY.txt >`__).
7678
79+ This software uses code of `FFmpeg <http://ffmpeg.org >`__ licensed under the `LGPLv2.1 <http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html >`__.
80+
7781Versioning
7882----------
7983
@@ -137,4 +141,4 @@ supported by the manylinux containers.
137141OS X
138142~~~~
139143
140- Currently built for Python 2.7 and 3.4 .
144+ Currently built for Python 2.7, 3.4 and 3.5 .
Original file line number Diff line number Diff line change @@ -29,7 +29,7 @@ install:
2929 C:\Python35-x64\python.exe -m pip install -r requirements.txt
3030
3131build_script :
32- - cmd : > -
32+ - cmd : | -
3333
3434 if not exist "%APPVEYOR_BUILD_FOLDER%\opencv\build" mkdir "%APPVEYOR_BUILD_FOLDER%\opencv\build"
3535
@@ -52,36 +52,46 @@ build_script:
5252 cmake --build . --config Release
5353
5454 cd ..\..
55-
55+ cd
5656 xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build\lib\RELEASE\*.pyd" cv2
57+ xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build\bin\Release\*.dll" cv2
58+ del cv2\*64.dll
5759
5860 C:\Python27\python.exe setup.py bdist_wheel
5961
6062 del cv2\*.pyd
63+ del cv2\*.dll
6164
6265 rmdir "%APPVEYOR_BUILD_FOLDER%\build" /s /q
6366
6467 xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build64\lib\RELEASE\*.pyd" cv2
68+ xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build64\bin\Release\*64.dll" cv2
6569
6670 C:\Python27-x64\python.exe setup.py bdist_wheel
6771
6872 del cv2\*.pyd
73+ del cv2\*.dll
6974
7075 rmdir "%APPVEYOR_BUILD_FOLDER%\build" /s /q
7176
7277 xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build\lib\python3\Release\*.pyd" cv2
78+ xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build\bin\Release\*.dll" cv2
79+ del cv2\*64.dll
7380
7481 C:\Python35\python.exe setup.py bdist_wheel
7582
7683 del cv2\*.pyd
84+ del cv2\*.dll
7785
7886 rmdir "%APPVEYOR_BUILD_FOLDER%\build" /s /q
7987
8088 xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build64\lib\python3\Release\*.pyd" cv2
89+ xcopy "%APPVEYOR_BUILD_FOLDER%\opencv\build64\bin\Release\*64.dll" cv2
8190
8291 C:\Python35-x64\python.exe setup.py bdist_wheel
8392
8493 del cv2\*.pyd
94+ del cv2\*.dll
8595
8696 rmdir "%APPVEYOR_BUILD_FOLDER%\build" /s /q
8797
Original file line number Diff line number Diff line change 11import sys
2+ import os
3+
4+ # FFMPEG dll is not found on Windows without this
5+ os .environ ["PATH" ] += os .pathsep + os .path .dirname (os .path .realpath (__file__ ))
6+
27from . import cv2
38sys .modules ['cv2' ] = cv2
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ def is_pure(self):
3333if os .name == 'posix' :
3434 package_data ['cv2' ] = ['*.so' ]
3535else :
36- package_data ['cv2' ] = ['*.pyd' ]
36+ package_data ['cv2' ] = ['*.pyd' , '*.dll' ]
3737
3838setup (name = 'opencv-python' ,
3939 version = opencv_version ,
Original file line number Diff line number Diff line change 11import unittest
2+ import os
23
34class OpenCVTest (unittest .TestCase ):
45 """ Simple functionality tests. """
56
67 def test_import (self ):
78 """ Test that the cv2 module can be imported. """
8- import cv2
9+ import cv2
10+
11+ def test_video_capture (self ):
12+
13+ if os .name != 'posix' :
14+ import cv2
15+
16+ cap = cv2 .VideoCapture ("SampleVideo_1280x720_1mb.mp4" )
17+ self .assertTrue (cap .isOpened ())
You can’t perform that action at this time.
0 commit comments