Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
613b2893
Commit
613b2893
authored
Dec 18, 2015
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
python: add launch script for winpack python demo
parent
4fa91e46
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
47 additions
and
0 deletions
+47
-0
_run_winpack_demo_python27.cmd
samples/python/_run_winpack_demo_python27.cmd
+47
-0
No files found.
samples/python/_run_winpack_demo_python27.cmd
0 → 100644
View file @
613b2893
@echo off
if NOT exist %CD%\..\..\..\build (
echo ERROR: OpenCV Winpack installation is required
pause
exit
)
:: Path to FFMPEG binary files
set PATH=%PATH%;%CD%\..\..\..\build\bin\
:: Detect Python binary
python -V
if %ERRORLEVEL% EQU 0 (
set PYTHON=python
) else (
if exist C:\Python27-x64\python.exe (
set PYTHON=C:\Python27-x64\python.exe
) else (
if exist C:\Python27\python.exe (
set PYTHON=C:\Python27\python.exe
) else (
echo ERROR: Python not found
pause
exit
)
)
)
echo Using python: %PYTHON%
:: Detect python architecture
%PYTHON% -c "import platform; exit(64 if platform.architecture()[0] == '64bit' else 32)"
if %ERRORLEVEL% EQU 32 (
echo Detected: Python 32-bit
set PYTHONPATH=%CD%\..\..\..\build\python\2.7\x86
) else (
if %ERRORLEVEL% EQU 64 (
echo Detected: Python 64-bit
set PYTHONPATH=%CD%\..\..\..\build\python\2.7\x64
) else (
echo ERROR: Unknown python arch
pause
exit
)
)
:: Launch demo
%PYTHON% demo.py
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment