2 Star 3 Fork 1

叮当/opencvsharp

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
download_opencv_windows.ps1 1.30 KB
一键复制 编辑 原始数据 按行查看 历史
shimat 提交于 2021-04-04 16:20 +08:00 . 4.5.2
$tag = "4.5.2.20210404"
$version = "452"
$uriArray =@(
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv${version}_win_x64.zip"
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv${version}_win_x86.zip"
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv${version}_uwp_x64.zip"
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv${version}_uwp_x86.zip"
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv${version}_uwp_ARM.zip"
)
function Download($uri, $outFile) {
Write-Host "Downloading ${uri}"
if (!(Test-Path $outFile)) {
Invoke-WebRequest -Uri $uri -OutFile $outFile -ErrorAction Stop
}
}
New-Item opencv_files -Type directory -Force -ErrorAction Stop | Out-Null
cd opencv_files
[Net.ServicePointManager]::SecurityProtocol = @([Net.SecurityProtocolType]::Tls,[Net.SecurityProtocolType]::Tls11,[Net.SecurityProtocolType]::Tls12)
foreach($uri in $uriArray){
$outFile = [System.IO.Path]::GetFileName($uri)
$outFileWithoutExtension = [System.IO.Path]::GetFileNameWithoutExtension($uri)
Download $uri $outFile
Expand-Archive -Path $outFile -DestinationPath $outFileWithoutExtension -Force -ErrorAction Stop
Remove-Item -Path $outFile -ErrorAction Stop
}
cd ..
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
C#
1
https://gitee.com/zl33842901/opencvsharp.git
git@gitee.com:zl33842901/opencvsharp.git
zl33842901
opencvsharp
opencvsharp
master

搜索帮助