Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ai-learn-use/opencvsharp
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: master
Choose a base ref
...
head repository: shimat/opencvsharp
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref

Commits on Apr 3, 2021

  1. Copy the full SHA
    412d571 View commit details

Commits on Apr 4, 2021

  1. 4.5.2

    shimat committed Apr 4, 2021
    Copy the full SHA
    3fb4858 View commit details
  2. gapi???

    shimat committed Apr 4, 2021
    Copy the full SHA
    9a5aacb View commit details
  3. 452

    shimat committed Apr 4, 2021
    Copy the full SHA
    285c9a1 View commit details
  4. 4.5.2 -> 452

    shimat committed Apr 4, 2021
    Copy the full SHA
    b364220 View commit details
  5. Copy the full SHA
    3addd84 View commit details
  6. remove net48

    shimat committed Apr 4, 2021
    Copy the full SHA
    74ded8b View commit details
  7. update samples

    shimat committed Apr 4, 2021
    Copy the full SHA
    7187b31 View commit details

Commits on Apr 5, 2021

  1. Copy the full SHA
    110a773 View commit details

Commits on Apr 7, 2021

  1. Update README.md

    shimat authored Apr 7, 2021
    Copy the full SHA
    ea7c67f View commit details

Commits on Apr 10, 2021

  1. Copy the full SHA
    1698d32 View commit details
  2. Copy the full SHA
    efe45d1 View commit details

Commits on Apr 30, 2021

  1. Update README.md

    shimat authored Apr 30, 2021
    Copy the full SHA
    101fd81 View commit details
  2. Update README.md

    shimat authored Apr 30, 2021
    Copy the full SHA
    abf67a2 View commit details
  3. Update README.md

    shimat authored Apr 30, 2021
    Copy the full SHA
    34fb3c7 View commit details

Commits on May 5, 2021

  1. Copy the full SHA
    78ff2c3 View commit details
  2. Fix target runtime

    m-roberts committed May 5, 2021
    Copy the full SHA
    a8997d2 View commit details
  3. Copy the full SHA
    f288b22 View commit details
  4. Copy the full SHA
    ebd6e57 View commit details

Commits on May 6, 2021

  1. Copy the full SHA
    2a18e85 View commit details
  2. Use all cores for 'make'

    m-roberts committed May 6, 2021
    Copy the full SHA
    5792c30 View commit details
  3. Copy the full SHA
    e94ad03 View commit details
  4. Fix filepath

    m-roberts committed May 6, 2021
    Copy the full SHA
    fdf869f View commit details
  5. -o ./artifacts_arm

    m-roberts committed May 6, 2021
    Copy the full SHA
    8d35b39 View commit details
  6. Copy the full SHA
    e08ea56 View commit details
  7. Copy the full SHA
    2af4f37 View commit details
  8. Update path to csproj file

    jcapona committed May 6, 2021
    Copy the full SHA
    6b68bfd View commit details
  9. Copy the full SHA
    ab81700 View commit details
  10. Copy the full SHA
    32a0691 View commit details
  11. Copy the full SHA
    fc04220 View commit details

Commits on May 8, 2021

  1. Merge pull request shimat#1259 from pi-top/add-linux-arm

    Add Linux ARM package to NuGet repository
    shimat authored May 8, 2021
    Copy the full SHA
    7fa8be0 View commit details
  2. Update README.md

    shimat authored May 8, 2021
    Copy the full SHA
    3cb3b91 View commit details
  3. Update README.md

    shimat authored May 8, 2021
    Copy the full SHA
    ac2a09e View commit details

Commits on May 29, 2021

  1. Copy the full SHA
    74c9905 View commit details
  2. Copy the full SHA
    5b31160 View commit details

Commits on May 30, 2021

  1. Merge pull request shimat#1271 from shimat/runlength

    Add ximgproc run_length methods
    shimat authored May 30, 2021
    Copy the full SHA
    ac72995 View commit details
  2. Add CalibrateRobertson

    shimat committed May 30, 2021
    Copy the full SHA
    1930b7d View commit details
  3. Merge pull request shimat#1272 from shimat/photo_calibrate

    Add CalibrateRobertson
    shimat authored May 30, 2021
    Copy the full SHA
    984607c View commit details

Commits on Jun 2, 2021

  1. Update docfx.yml

    shimat authored Jun 2, 2021
    Copy the full SHA
    c925aba View commit details

Commits on Jun 4, 2021

  1. Copy the full SHA
    f17bcde View commit details
  2. add some missing properties of video Capture/Writer

    add video Capture/Writer parameter for hardware acceleration
    add methods of video Capture/Writer for hardware acceleration
    AvenSun committed Jun 4, 2021
    Copy the full SHA
    6d9258c View commit details

Commits on Jun 6, 2021

  1. Copy the full SHA
    0dd7b54 View commit details

Commits on Jun 10, 2021

  1. Merge pull request shimat#1277 from AvenSun/master

    enable hardware acceleration of VideoCapture and VideoWriter
    shimat authored Jun 10, 2021
    Copy the full SHA
    5c10f5c View commit details

Commits on Jul 11, 2021

  1. 4.5.3

    shimat committed Jul 11, 2021
    Copy the full SHA
    aeebc17 View commit details
  2. docker

    shimat committed Jul 11, 2021
    Copy the full SHA
    8796eca View commit details
  3. Update docker-amazonlinux.yml

    shimat authored Jul 11, 2021
    Copy the full SHA
    e73e59a View commit details
  4. Update windows.yml

    shimat authored Jul 11, 2021
    Copy the full SHA
    e38a19a View commit details
  5. Update Dockerfile

    shimat authored Jul 11, 2021
    Copy the full SHA
    7c61bb0 View commit details

Commits on Jul 13, 2021

  1. Copy the full SHA
    8774c9e View commit details
  2. Copy the full SHA
    85df071 View commit details
Showing 752 changed files with 101,852 additions and 96,850 deletions.
68 changes: 67 additions & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
@@ -1,4 +1,63 @@
[*.cs]
# Rules in this file were initially inferred by Visual Studio IntelliCode from the C:\Projects\randd\randd_address_separator\dotnet\Sansan.RD.AddressSeparator.Tests\ codebase based on best match to current usage at 2022/08/18
# You can modify the rules from these initially generated values to suit your own policies
# You can learn more about editorconfig here: https://docs.microsoft.com/en-us/visualstudio/ide/editorconfig-code-style-settings-reference
[*.cs]


# IDE0160: Convert to file-scoped namespace
csharp_style_namespace_declarations = file_scoped:warning

#Core editorconfig formatting - indentation

#use soft tabs (spaces) for indentation
indent_style = space

#Formatting - new line options

#require braces to be on a new line for methods and types (also known as "Allman" style)
csharp_new_line_before_open_brace = all#methods, types

#Formatting - organize using options

#sort System.* using directives alphabetically, and place them before other usings
dotnet_sort_system_directives_first = true

#Formatting - spacing options

#remove space between method call name and opening parenthesis
csharp_space_between_method_call_name_and_opening_parenthesis = false
#do not place space characters after the opening parenthesis and before the closing parenthesis of a method call
csharp_space_between_method_call_parameter_list_parentheses = false
#place a space character after the opening parenthesis and before the closing parenthesis of a method declaration parameter list.
csharp_space_between_method_declaration_parameter_list_parentheses = false

#Style - expression bodied member options

#prefer block bodies for methods
csharp_style_expression_bodied_methods = when_on_single_line:suggestion

#Style - implicit and explicit types

#prefer var over explicit type in all cases, unless overridden by another code style rule
csharp_style_var_elsewhere = true:suggestion
#prefer var is used to declare variables with built-in system types such as int
csharp_style_var_for_built_in_types = true:suggestion

#Style - language keyword and framework type options

#prefer the language keyword for local variables, method parameters, and class members, instead of the type name, for types that have a keyword to represent them
dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion

#Style - modifier options

#prefer accessibility modifiers to be declared except for public interface members. This will currently not differ from always and will act as future proofing for if C# adds default interface methods.
dotnet_style_require_accessibility_modifiers = for_non_interface_members:suggestion

#Style - Modifier preferences

#when this rule is set to a list of modifiers, prefer the specified ordering.
csharp_preferred_modifier_order = public,internal:suggestion


# CA1711: Identifiers should not have incorrect suffix
dotnet_diagnostic.CA1711.severity = none
@@ -15,3 +74,10 @@ dotnet_diagnostic.CA1014.severity = none

# IDE0079: Remove unnecessary suppression
dotnet_diagnostic.IDE0079.severity = none


[*.{cs,vb}]
dotnet_style_allow_statement_immediately_after_block_experimental=false:silent

[*]
insert_final_newline = true
37 changes: 29 additions & 8 deletions .github/workflows/docfx.yml
Original file line number Diff line number Diff line change
@@ -3,33 +3,54 @@ name: DocFX
on:
push:
branches:
- master
- main
workflow_dispatch:

jobs:
build:

runs-on: windows-2019
runs-on: windows-latest

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Install .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: 8.0.x

- name: Setup MSBuild.exe
uses: microsoft/setup-msbuild@v2

- name: DocFX
shell: cmd
run: |
choco install docfx -y
docfx docfx\docfx.json
- name: Upload DocFX packages
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: docfx_site
path: ${{ github.workspace }}\docfx\_site

- name: Publish Documentation on GitHub Pages
uses: peaceiris/actions-gh-pages@v3
- uses: actions/upload-pages-artifact@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docfx/_site
path: docfx/_site

deploy:
needs: build
permissions:
pages: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
23 changes: 0 additions & 23 deletions .github/workflows/docker-amazonlinux.yml

This file was deleted.

47 changes: 47 additions & 0 deletions .github/workflows/docker-deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
name: Publish Docker Images

on:
workflow_dispatch:
inputs:
docker_image_tag:
description: 'Docker Image Tag (yyyyMMdd)'
required: true

env:
DEBIAN_FRONTEND: noninteractive
DOCKER_IMAGE_NAME1: "ubuntu24-dotnet8-opencv4.12.0"

jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: read
packages: write
timeout-minutes: 60

steps:
- name: validate input
run: |
if [[ ! ${{ github.event.inputs.docker_image_tag }} =~ ^[0-9]{8}$ ]]; then
echo "::error Invalid tag name '${{ github.event.inputs.docker_image_tag }}'"
exit 1
fi
- uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Log into registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Build and push Docker image
id: build-and-push
uses: docker/build-push-action@v6
with:
context: docker/${{ env.DOCKER_IMAGE_NAME1 }}
push: true
tags: ghcr.io/shimat/opencvsharp/${{ env.DOCKER_IMAGE_NAME1 }}:${{ github.event.inputs.docker_image_tag }}
21 changes: 21 additions & 0 deletions .github/workflows/docker-ubuntu.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
name: Docker Test

on:
pull_request:
types: [synchronize, opened]

env:
DEBIAN_FRONTEND: noninteractive

jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 60

steps:
- uses: actions/checkout@v4

- name: docker build
run: |
cd docker/ubuntu24-dotnet8-opencv4.12.0
docker build -t shimat/ubuntu24-dotnet8-opencv4.12.0 .
53 changes: 53 additions & 0 deletions .github/workflows/linux-arm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Linux ARM (Docker)

on:
pull_request:
types: [synchronize, opened]
push:
branches:
- main

env:
DEBIAN_FRONTEND: noninteractive
OPENCV_VERSION: 4.12.0

jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- uses: docker/setup-qemu-action@v3

- uses: docker/setup-buildx-action@v3
with:
install: true

# Build with Buildx and cache Docker layers in GitHub Actions cache
- name: Build with Docker (cached)
uses: docker/build-push-action@v6
with:
context: ./docker/ubuntu24-dotnet8-opencv4.12.0
platforms: linux/arm64
build-args: |
OPENCV_VERSION=${{ env.OPENCV_VERSION }}
# Load the built image to local Docker for later docker create/cp
outputs: type=docker,name=opencvsharp-linux-arm:latest
cache-from: type=gha
cache-to: type=gha,mode=max

- name: Extract build files from Docker instance
run: |
docker create -ti --name opencvsharp-linux-arm-tmp opencvsharp-linux-arm bash
docker cp opencvsharp-linux-arm-tmp:/artifacts .
- name: Patch nuspec with version and build NuGet package
run: |
sed -E --in-place=.bak "s/<version>[0-9]\.[0-9]{1,2}\.[0-9]{1,2}.[0-9]{8}(-beta[0-9]*)?<\/version>/<version>${OPENCV_VERSION}.$(date '+%Y%m%d')<\/version>/" nuget/OpenCvSharp4.runtime.linux-arm.nuspec
cp artifacts/libOpenCvSharpExtern.so nuget/
dotnet pack nuget/OpenCvSharp4.runtime.linux-arm.csproj -o artifacts_arm
- uses: actions/upload-artifact@v4
with:
name: artifacts_linux_arm
path: artifacts_arm
Original file line number Diff line number Diff line change
@@ -5,29 +5,29 @@ on:
types: [synchronize, opened]
push:
branches:
- master
- main

env:
DEBIAN_FRONTEND: noninteractive
OPENCV_VERSION: 4.5.1
OPENCV_VERSION: 4.8.0

jobs:
build:

runs-on: macos-10.15
runs-on: macos-11

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
with:
fetch-depth: 1

- name: Install build dependencies
run: |
brew install wget pkg-config mono-libgdiplus gtk+ ffmpeg glog yasm harfbuzz jpeg libpng libtiff openexr openjpeg metis openblas opencore-amr protobuf tbb webp
brew install wget pkg-config mono-libgdiplus gtk+ ffmpeg@4 glog yasm harfbuzz jpeg libpng libtiff openjpeg metis openblas opencore-amr protobuf tbb webp # openexr

# - name: Cache OpenCV
# id: opencv-cache
# uses: actions/cache@v2
# uses: actions/cache@v3
# with:
# path: ${{ github.workspace }}/opencv_macos/
# key: opencv-${{ env.OPENCV_VERSION }}-macos-rev1
@@ -53,24 +53,30 @@ jobs:
-DBUILD_opencv_python_tests=OFF \
-DBUILD_opencv_ts=OFF \
-DBUILD_opencv_js=OFF \
-DBUILD_opencv_app=OFF \
-DBUILD_opencv_js_bindings_generator=OFF \
-DBUILD_opencv_apps=OFF \
-DBUILD_opencv_barcode=OFF \
-DBUILD_opencv_bioinspired=OFF \
-DBUILD_opencv_ccalib=OFF \
-DBUILD_opencv_datasets=OFF \
-DBUILD_opencv_dnn_objdetect=OFF \
-DBUILD_opencv_dpm=OFF \
-DBUILD_opencv_fuzzy=OFF \
-DBUILD_opencv_gapi=OFF \
-DBUILD_opencv_gapi=ON \
-DBUILD_opencv_intensity_transform=OFF \
-DBUILD_opencv_mcc=OFF \
-DBUILD_opencv_objc_bindings_generator=OFF \
-DBUILD_opencv_rapid=OFF \
-DBUILD_opencv_reg=OFF \
-DBUILD_opencv_stereo=OFF \
-DBUILD_opencv_structured_light=OFF \
-DBUILD_opencv_surface_matching=OFF \
-DBUILD_opencv_wechat_qrcode=ON \
-DBUILD_opencv_videostab=OFF \
-DWITH_GSTREAMER=OFF \
-DWITH_EIGEN=OFF \
-DWITH_ADE=OFF \
-DWITH_OPENEXR=OFF \
-DOPENCV_ENABLE_NONFREE=ON \
-DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/opencv_macos ..
make -j2
@@ -95,8 +101,13 @@ jobs:
nm libOpenCvSharpExtern.dylib
echo -ne "#include <stdio.h> \n int core_Mat_sizeof(); int main(){ int i = core_Mat_sizeof(); printf(\"sizeof(Mat) = %d\", i); return 0; }" > test.c
gcc -I./ -L./ test.c -o test -lOpenCvSharpExtern
LD_LIBRARY_PATH=. ./test
LD_LIBRARY_PATH=. ./test

- name: Install .NET
uses: actions/setup-dotnet@v3
with:
dotnet-version: '6.0.x'

- name: Create NuGet package
env:
BETA: ""
@@ -108,23 +119,23 @@ jobs:
dotnet pack ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.osx.10.15-x64.csproj -o ${GITHUB_WORKSPACE}/artifacts_macos
ls ${GITHUB_WORKSPACE}/artifacts_macos

- uses: actions/upload-artifact@v1
- uses: actions/upload-artifact@v3
with:
name: artifacts_macos_10
path: artifacts_macos

- name: Test
run: |
cd ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests
ls
dotnet build -c Release -f netcoreapp3.1
cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.dylib ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/netcoreapp3.1/
# ls
dotnet build -c Release -f net6.0
cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.dylib ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/net6.0/
cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.dylib ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/
ls ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/netcoreapp3.1/
ls
# ls ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/net6.0/
# ls
sudo cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.dylib /usr/local/lib/
LD_LIBRARY_PATH=.
dotnet test OpenCvSharp.Tests.csproj -c Release -f netcoreapp3.1 --runtime osx-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null
dotnet test OpenCvSharp.Tests.csproj -c Release -f net6.0 --runtime osx-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null
ls
ls TestResults

38 changes: 26 additions & 12 deletions .github/workflows/publish_nuget.yml
Original file line number Diff line number Diff line change
@@ -5,39 +5,53 @@ on:

jobs:
Publish:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4

- name: Download windows artifact
uses: dawidd6/action-download-artifact@v2
uses: dawidd6/action-download-artifact@v6
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: windows.yml
name: packages_windows

- name: Download ubuntu artifact
uses: dawidd6/action-download-artifact@v2
uses: dawidd6/action-download-artifact@v8
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: ubuntu18.yml
name: artifacts_ubuntu_18
workflow: ubuntu22.yml
name: artifacts_ubuntu_22

- name: Download macos artifact
uses: dawidd6/action-download-artifact@v2
- name: Download ubuntu arm artifact
uses: dawidd6/action-download-artifact@v8
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: macos10.yml
name: artifacts_macos_10
workflow: linux-arm.yml
name: artifacts_linux_arm

#- name: Download macos artifact
# uses: dawidd6/action-download-artifact@v6
# with:
# github_token: ${{secrets.GITHUB_TOKEN}}
# workflow: macos10.yml
# name: artifacts_macos_10

- name: Download wasm artifact
uses: dawidd6/action-download-artifact@v8
with:
github_token: ${{secrets.GITHUB_TOKEN}}
workflow: wasm.yml
name: artifacts_wasm

- run: |
ls -l
- name: Install .NET
uses: actions/setup-dotnet@v1
uses: actions/setup-dotnet@v4
with:
dotnet-version: '3.1.x'
dotnet-version: 8.0.x

- name: Rename
run: |
121 changes: 65 additions & 56 deletions .github/workflows/ubuntu18.yml → .github/workflows/ubuntu22.yml
Original file line number Diff line number Diff line change
@@ -1,164 +1,173 @@
name: Ubuntu 18.04
name: Ubuntu 22.04

on:
pull_request:
types: [synchronize, opened]
push:
branches:
- master
- main

env:
DEBIAN_FRONTEND: noninteractive
OPENCV_VERSION: 4.5.1
OPENCV_VERSION: 4.11.0
OPENCV_CACHE_VERSION: 1

jobs:
build:

runs-on: ubuntu-18.04
runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v4
with:
fetch-depth: 1
path: opencvsharp

- name: Install dependencies
run: |
pwd
echo ${GITHUB_WORKSPACE}
current_path=$(pwd)
sudo apt-get update -y
sudo apt-get install -y --no-install-recommends \
apt-transport-https \
software-properties-common \
wget \
unzip \
ca-certificates \
build-essential \
g++ \
make \
cmake \
git \
libtbb-dev \
libatlas-base-dev \
libgtk2.0-dev \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
libdc1394-22-dev \
libdc1394-dev \
libxine2-dev \
libv4l-dev \
libtheora-dev \
libvorbis-dev \
libxvidcore-dev \
libopencore-amrnb-dev \
libopencore-amrwb-dev \
libavresample-dev \
x264 \
libtesseract-dev
- name: Cache OpenCV
id: opencv-cache
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ${{ github.workspace }}/opencv_ubuntu/
key: opencv-${{ env.OPENCV_VERSION }}-rev1

path: ${{ github.workspace }}/opencv_artifacts/
key: opencv-${{ env.OPENCV_VERSION }}-rev${{ env.OPENCV_CACHE_VERSION }}

- name: Checkout OpenCV
if: steps.opencv-cache.outputs.cache-hit != 'true'
uses: actions/checkout@v4
with:
repository: opencv/opencv
path: opencv
ref: ${{ env.OPENCV_VERSION }}
- name: Checkout OpenCV Contrib
if: steps.opencv-cache.outputs.cache-hit != 'true'
uses: actions/checkout@v4
with:
repository: opencv/opencv_contrib
path: opencv_contrib
ref: ${{ env.OPENCV_VERSION }}

- name: Build OpenCV
if: steps.opencv-cache.outputs.cache-hit != 'true'
run: |
wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip -Oopencv-${OPENCV_VERSION}.zip && unzip opencv-${OPENCV_VERSION}.zip
wget https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip -Oopencv_contrib-${OPENCV_VERSION}.zip && unzip opencv_contrib-${OPENCV_VERSION}.zip
cd opencv-${OPENCV_VERSION} && mkdir build && cd build
mkdir opencv/build && cd opencv/build
cmake \
-S . \
-B build \
-D CMAKE_BUILD_TYPE=Release \
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib-${OPENCV_VERSION}/modules \
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules \
-D BUILD_SHARED_LIBS=OFF \
-D ENABLE_CXX11=ON \
-D BUILD_EXAMPLES=OFF \
-D BUILD_DOCS=OFF \
-D BUILD_PERF_TESTS=OFF \
-D BUILD_TESTS=OFF \
-D BUILD_JAVA=OFF \
-D BUILD_opencv_app=OFF \
-D BUILD_opencv_apps=OFF \
-D BUILD_opencv_barcode=OFF \
-D BUILD_opencv_java_bindings_generator=OFF \
-D BUILD_opencv_python_bindings_generator=OFF \
-D BUILD_opencv_python_tests=OFF \
-D BUILD_opencv_ts=OFF \
-D BUILD_opencv_js=OFF \
-D BUILD_opencv_js_bindings_generator=OFF \
-D BUILD_opencv_bioinspired=OFF \
-D BUILD_opencv_ccalib=OFF \
-D BUILD_opencv_datasets=OFF \
-D BUILD_opencv_dnn_objdetect=OFF \
-D BUILD_opencv_dpm=OFF \
-D BUILD_opencv_fuzzy=OFF \
-D BUILD_opencv_gapi=OFF \
-D BUILD_opencv_gapi=ON \
-D BUILD_opencv_intensity_transform=OFF \
-D BUILD_opencv_mcc=OFF \
-D BUILD_opencv_objc_bindings_generator=OFF \
-D BUILD_opencv_rapid=OFF \
-D BUILD_opencv_reg=OFF \
-D BUILD_opencv_stereo=OFF \
-D BUILD_opencv_structured_light=OFF \
-D BUILD_opencv_surface_matching=OFF \
-D BUILD_opencv_wechat_qrcode=ON \
-D BUILD_opencv_videostab=OFF \
-D WITH_GSTREAMER=OFF \
-D WITH_ADE=OFF \
-D OPENCV_ENABLE_NONFREE=ON \
-D CMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/opencv_ubuntu ..
make -j2
make install
-D CMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/opencv_artifacts ..
cmake --build build
cmake --install build
sudo ldconfig
cd ${GITHUB_WORKSPACE}
ls
- name: Build OpenCvSharpExtern
run: |
ls ${GITHUB_WORKSPACE}/opencv_ubuntu
echo "-----"
ls ${GITHUB_WORKSPACE}/opencv_ubuntu/lib
echo "-----"
mkdir src/build && cd $_
cmake -D CMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/opencv_ubuntu ..
make -j2
run: |
mkdir opencvsharp/src/build && cd $_
cmake -D CMAKE_PREFIX_PATH=${GITHUB_WORKSPACE}/opencv_artifacts ..
make -j
ls OpenCvSharpExtern
cp OpenCvSharpExtern/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/nuget/
ldd OpenCvSharpExtern/libOpenCvSharpExtern.so
cp OpenCvSharpExtern/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/opencvsharp/nuget/
- name: Check OpenCvSharpExtern
run: |
cd ${GITHUB_WORKSPACE}/nuget/
cd ${GITHUB_WORKSPACE}/opencvsharp/nuget/
ldd libOpenCvSharpExtern.so
nm libOpenCvSharpExtern.so
echo -ne "#include <stdio.h> \n int core_Mat_sizeof(); int main(){ int i = core_Mat_sizeof(); printf(\"sizeof(Mat) = %d\", i); return 0; }" > test.c
gcc -I./ -L./ test.c -o test -lOpenCvSharpExtern
LD_LIBRARY_PATH=. ./test
- name: Install .NET
uses: actions/setup-dotnet@v1
uses: actions/setup-dotnet@v4
with:
dotnet-version: '3.1.x'
dotnet-version: '8.0.x'

- name: Create NuGet package
env:
BETA: ""
run: |
yyyymmdd=`date '+%Y%m%d'`
echo $yyyymmdd
sed -E --in-place=.bak "s/<version>[0-9]\.[0-9]{1,2}\.[0-9]{1,2}.[0-9]{8}(-beta[0-9]*)?<\/version>/<version>${OPENCV_VERSION}.${yyyymmdd}${BETA}<\/version>/" ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.ubuntu.18.04-x64.nuspec
cat ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.ubuntu.18.04-x64.nuspec
dotnet pack ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.ubuntu.18.04-x64.csproj -o ${GITHUB_WORKSPACE}/artifacts_ubuntu
cd ${GITHUB_WORKSPACE}/opencvsharp
sed -E --in-place=.bak \
"s/<version>[0-9]\.[0-9]{1,2}\.[0-9]{1,2}.[0-9]{8}(-beta[0-9]*)?<\/version>/<version>${OPENCV_VERSION}.${yyyymmdd}${BETA}<\/version>/" \
nuget/OpenCvSharp4.official.runtime.linux-x64.nuspec
cat nuget/OpenCvSharp4.official.runtime.linux-x64.nuspec
dotnet pack nuget/OpenCvSharp4.official.runtime.linux-x64.csproj -o ${GITHUB_WORKSPACE}/artifacts_ubuntu
ls ${GITHUB_WORKSPACE}/artifacts_ubuntu
- uses: actions/upload-artifact@v1
- uses: actions/upload-artifact@v4
with:
name: artifacts_ubuntu_18
name: artifacts_ubuntu_22
path: artifacts_ubuntu

- name: Test
run: |
cd ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests
dotnet build -c Release -f netcoreapp3.1
cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/netcoreapp3.1/
cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/
sudo cp ${GITHUB_WORKSPACE}/nuget/libOpenCvSharpExtern.so /usr/lib/
ls ${GITHUB_WORKSPACE}/test/OpenCvSharp.Tests/bin/Release/netcoreapp3.1/
ls
LD_LIBRARY_PATH=. dotnet test OpenCvSharp.Tests.csproj -c Release -f netcoreapp3.1 --runtime ubuntu.18.04-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null
ls
ls TestResults
cd ${GITHUB_WORKSPACE}/opencvsharp/test/OpenCvSharp.Tests
dotnet build -c Release -f net8.0
cp ${GITHUB_WORKSPACE}/opencvsharp/nuget/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/opencvsharp/test/OpenCvSharp.Tests/bin/Release/net8.0/
cp ${GITHUB_WORKSPACE}/opencvsharp/nuget/libOpenCvSharpExtern.so ${GITHUB_WORKSPACE}/opencvsharp/test/OpenCvSharp.Tests/
sudo cp ${GITHUB_WORKSPACE}/opencvsharp/nuget/libOpenCvSharpExtern.so /usr/lib/
LD_LIBRARY_PATH=. dotnet test OpenCvSharp.Tests.csproj -c Release -f net8.0 --runtime linux-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null
176 changes: 176 additions & 0 deletions .github/workflows/wasm.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,176 @@
name: Wasm

on:
pull_request:
types: [synchronize, opened]
push:
branches:
- main

env:
DEBIAN_FRONTEND: noninteractive
OPENCV_VERSION: 4.11.0
EM_VERSION: 3.1.32
EM_CACHE_FOLDER: 'emsdk-cache'

jobs:
build:

runs-on: ubuntu-22.04

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 1

- name: Install dependencies
run: |
pwd
echo ${GITHUB_WORKSPACE}
current_path=$(pwd)
sudo apt-get update -y
sudo apt-get install -y --no-install-recommends \
apt-transport-https \
software-properties-common \
wget \
unzip \
ca-certificates \
g++ \
make \
cmake \
libtbb-dev \
libatlas-base-dev \
libgtk2.0-dev \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
libdc1394-dev \
libxine2-dev \
libv4l-dev \
libtheora-dev \
libvorbis-dev \
libxvidcore-dev \
libopencore-amrnb-dev \
libopencore-amrwb-dev \
x264 \
libtesseract-dev
- name: Cache OpenCV
id: opencv-cache
uses: actions/cache@v4
with:
path: ${{ github.workspace }}/opencv_wasm/
key: opencv-${{ env.OPENCV_VERSION }}-wasm

- name: Setup Emscripten cache
id: cache-system-libraries
uses: actions/cache@v4
with:
path: ${{env.EM_CACHE_FOLDER}}
key: ${{env.EM_VERSION}}-${{ runner.os }}
- uses: mymindstorm/setup-emsdk@v14
with:
version: ${{env.EM_VERSION}}
actions-cache-folder: ${{env.EM_CACHE_FOLDER}}

- name: Build OpenCV
if: steps.opencv-cache.outputs.cache-hit != 'true'
run: |
wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip -Oopencv-${OPENCV_VERSION}.zip && unzip opencv-${OPENCV_VERSION}.zip
wget https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip -Oopencv_contrib-${OPENCV_VERSION}.zip && unzip opencv_contrib-${OPENCV_VERSION}.zip
cd opencv-${OPENCV_VERSION} && mkdir build && cd build
emcmake cmake \
-DCMAKE_BUILD_TYPE=Release \
-DOPENCV_EXTRA_MODULES_PATH=../../opencv_contrib-${OPENCV_VERSION}/modules \
-DBUILD_SHARED_LIBS=OFF \
-DENABLE_CXX11=ON -DBUILD_TESTS=OFF \
-DBUILD_PERF_TESTS=OFF \
-DBUILD_DOCS=OFF \
-DBUILD_EXAMPLES=OFF \
-DBUILD_JAVA=OFF \
-DBUILD_opencv_java_bindings_generator=OFF \
-DBUILD_opencv_python_bindings_generator=OFF \
-DBUILD_opencv_python_tests=OFF \
-DBUILD_opencv_ts=OFF \
-DBUILD_opencv_js=OFF \
-DBUILD_opencv_js_bindings_generator=OFF \
-DBUILD_opencv_apps=OFF \
-DBUILD_opencv_barcode=OFF \
-DBUILD_opencv_bioinspired=OFF \
-DBUILD_opencv_ccalib=OFF \
-DBUILD_opencv_datasets=OFF \
-DBUILD_opencv_dnn_objdetect=OFF \
-DBUILD_opencv_dpm=OFF \
-DBUILD_opencv_fuzzy=OFF \
-DBUILD_opencv_gapi=ON \
-DBUILD_opencv_intensity_transform=OFF \
-DBUILD_opencv_mcc=OFF \
-DBUILD_opencv_objc_bindings_generator=OFF \
-DBUILD_opencv_rapid=OFF \
-DBUILD_opencv_reg=OFF \
-DBUILD_opencv_stereo=OFF \
-DBUILD_opencv_structured_light=OFF \
-DBUILD_opencv_surface_matching=OFF \
-DBUILD_opencv_wechat_qrcode=ON \
-DBUILD_opencv_videostab=OFF \
-DWITH_GSTREAMER=OFF \
-DWITH_EIGEN=OFF \
-DWITH_ADE=OFF \
-DOPENCV_ENABLE_NONFREE=ON \
-DCMAKE_INSTALL_PREFIX=${GITHUB_WORKSPACE}/opencv_wasm \
-DCMAKE_C_FLAGS='-s WASM=1' -DCMAKE_CXX_FLAGS='-s WASM=1' \
-DWITH_ITT=OFF \
-DWITH_JPEG=OFF \
-DWITH_TIFF=OFF \
-DWITH_PNG=OFF \
-DWITH_IPP=OFF \
-DWITH_LAPACK=OFF \
-DCV_ENABLE_INTRINSICS=OFF \
-DBUILD_opencv_dnn=ON \
..
make -j
make install
em++ -r -o ${GITHUB_WORKSPACE}/opencv_wasm/libopencv.o \
-Wl,--whole-archive ${GITHUB_WORKSPACE}/opencv_wasm/lib/*.a \
${GITHUB_WORKSPACE}/opencv_wasm/lib/opencv4/3rdparty/*.a
cd ${GITHUB_WORKSPACE}
ls
- name: Build OpenCvSharpExtern
run: |
ls ${GITHUB_WORKSPACE}/opencv_wasm
echo "-----"
mkdir src/build && cd $_
emcmake cmake -DCMAKE_BUILD_TYPE=Release -DOpenCV_DIR=${GITHUB_WORKSPACE}/opencv_wasm/lib/cmake/opencv4 -DWASM_LIB=${GITHUB_WORKSPACE}/opencv_wasm/libopencv.o ..
make -j
ls OpenCvSharpExtern
cp OpenCvSharpExtern/libOpenCvSharpExtern.a ${GITHUB_WORKSPACE}/nuget/
- name: Check OpenCvSharpExtern
run: |
echo TODO
- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: '8.0.x'

- name: Create NuGet package
env:
BETA: ""
run: |
yyyymmdd=`date '+%Y%m%d'`
echo $yyyymmdd
sed -E --in-place=.bak "s/<version>[0-9]\.[0-9]{1,2}\.[0-9]{1,2}.[0-9]{8}(-beta[0-9]*)?<\/version>/<version>${OPENCV_VERSION}.${yyyymmdd}${BETA}<\/version>/" ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.wasm.nuspec
cat ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.wasm.nuspec
dotnet pack ${GITHUB_WORKSPACE}/nuget/OpenCvSharp4.runtime.wasm.csproj -o ${GITHUB_WORKSPACE}/artifacts_wasm
ls ${GITHUB_WORKSPACE}/artifacts_wasm
- uses: actions/upload-artifact@v4
with:
name: artifacts_wasm
path: artifacts_wasm

- name: Test
run: |
echo TODO
111 changes: 78 additions & 33 deletions .github/workflows/windows.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,25 @@
name: Windows Server 2019
name: Windows Server 2022

on:
pull_request:
types: [synchronize, opened]
push:
branches:
- master
- main

env:
OPENCV_VERSION: 4.5.1
OPENCV_VERSION: "4.11.0"
OPENCV_FILES_TAG: "4.11.0.20250505"
TESSERACT_RELEASE_VERSION: "2024.08.19"

jobs:
build:

runs-on: windows-2019
runs-on: windows-2022

steps:
- name: Checkout
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
fetch-depth: 1
submodules: true
@@ -30,44 +32,60 @@ jobs:
# restore-keys: |
# ${{ runner.os }}-nuget-

- name: NuGet restore
shell: cmd
run: |
nuget restore
- name: Install Server-Media-Foundation
shell: powershell
run: |
Install-WindowsFeature Server-Media-Foundation
- name: Cache OpenCV binaries
id: cache_opencv
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ${{ github.workspace }}/opencv_files
key: opencv-${{ env.OPENCV_VERSION }}-rev2
key: opencv-${{ env.OPENCV_VERSION }}-rev1

- name: Download OpenCV binaries
- name: Download OpenCV binaries
if: steps.cache_opencv.outputs.cache-hit != 'true'
shell: powershell
env:
GH_TOKEN: ${{ github.token }}
run: |
. ".\download_opencv_windows.ps1"
gh release download --repo shimat/opencv_files ${env:OPENCV_FILES_TAG} --pattern "opencv_win_x64.zip"
gh release download --repo shimat/opencv_files ${env:OPENCV_FILES_TAG} --pattern "opencv_win_x86.zip"
Expand-Archive -Path opencv_win_x64.zip -DestinationPath opencv_files/opencv_win_x64 -Force -ErrorAction Stop
Expand-Archive -Path opencv_win_x86.zip -DestinationPath opencv_files/opencv_win_x86 -Force -ErrorAction Stop
ls opencv_files
ls opencv_files/opencv_win_x64
- name: Cache Tesseract binaries
id: cache_tesseract
uses: actions/cache@v2
uses: actions/cache@v4
with:
path: ${{ github.workspace }}/tesseract_files
key: tesseract-rev2
key: tesseract-41-rev2

- name: Download Tesseract binaries
- name: Download Tesseract binaries
if: steps.cache_tesseract.outputs.cache-hit != 'true'
shell: powershell
env:
GH_TOKEN: ${{ github.token }}
run: |
gh release download --repo shimat/tesseract_vcpkg ${TESSERACT_RELEASE_VERSION} --pattern "*.zip" --output tesseract.zip
Expand-Archive -Path tesseract.zip -DestinationPath tesseract_files -Force -ErrorAction Stop
ls tesseract_files
Move-Item tesseract_files/tesseract_vcpkg.0.0.9-beta tesseract_files/tesseract_vcpkg
ls tesseract_files/tesseract_vcpkg
New-Item tesseract_files/tesseract_vcpkg -ItemType Directory -Force
Move-Item tesseract_files/tesseract_vcpkg/installed/* tesseract_files/tesseract_vcpkg/
ls tesseract_files/tesseract_vcpkg
- name: NuGet restore
shell: cmd
run: |
nuget restore
- name: Install Server-Media-Foundation
shell: powershell
run: |
. ".\download_tesseract_windows.ps1"
Install-WindowsFeature Server-Media-Foundation
- name: Add msbuild to PATH
uses: microsoft/setup-msbuild@v1.0.2
uses: microsoft/setup-msbuild@v2

- name: Build x64
shell: cmd
@@ -77,13 +95,27 @@ jobs:
shell: cmd
run: msbuild OpenCvSharp.sln /t:build /p:configuration=Release /p:platform=x86 -maxcpucount

- name: Build ARM
#- name: Build ARM
# shell: cmd
# run: msbuild OpenCvSharp.sln /t:build /p:configuration=Release /p:platform=ARM -maxcpucount

- name: Install .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
- name: Build
shell: cmd
run: msbuild OpenCvSharp.sln /t:build /p:configuration=Release /p:platform=ARM -maxcpucount
run: |
dotnet build src/OpenCvSharp.Extensions/OpenCvSharp.Extensions.csproj -f net6.0 -p:configuration=Release -maxcpucount
dotnet build src/OpenCvSharp.WpfExtensions/OpenCvSharp.WpfExtensions.csproj -f net6.0-windows -p:configuration=Release -maxcpucount
- name: Pack NuGet packages
shell: powershell
run: |
$ErrorActionPreference = "Stop"
$date = Get-Date -Format "yyyyMMdd"
$version = "${env:OPENCV_VERSION}.${date}-beta"
Write-Host "version = ${version}"
@@ -95,40 +127,53 @@ jobs:
}
$windowsNuspec = "${env:GITHUB_WORKSPACE}\nuget\OpenCvSharp4.Windows.nuspec"
$extensionsNuspec = "${env:GITHUB_WORKSPACE}\nuget\OpenCvSharp4.Extensions.nuspec"
$wpfExtensionsNuspec = "${env:GITHUB_WORKSPACE}\nuget\OpenCvSharp4.WpfExtensions.nuspec"
$nuspecFiles = @($windowsNuspec, $wpfExtensionsNuspec)
$nuspecFiles = @($windowsNuspec, $extensionsNuspec, $wpfExtensionsNuspec)
foreach ( $nuspecFile in $nuspecFiles ) {
[xml]$xml = Get-Content $nuspecFile
foreach ($group in $xml.package.metadata.dependencies.ChildNodes){
foreach ($dependency in $group.ChildNodes){
Write-Host "before: " $dependency.GetAttribute("id") "=" $dependency.GetAttribute("version")
$dependency.SetAttribute("version", $version)
Write-Host "after: " $dependency.GetAttribute("id") "=" $dependency.GetAttribute("version")
$xml.Save($nuspecFile)
$packageId = $dependency.GetAttribute("id")
if ($packageId.StartsWith("OpenCvSharp")){
Write-Host "before: " $packageId "=" $dependency.GetAttribute("version")
$dependency.SetAttribute("version", $version)
Write-Host "after: " $packageId "=" $dependency.GetAttribute("version")
$xml.Save($nuspecFile)
}
else {
Write-Host "Skipped: " $packageId
}
}
}
}
nuget pack nuget/OpenCvSharp4.nuspec -OutputDirectory artifacts -Symbols -SymbolPackageFormat snupkg
nuget pack nuget/OpenCvSharp4.Windows.nuspec -OutputDirectory artifacts
nuget pack nuget/OpenCvSharp4.Extensions.nuspec -OutputDirectory artifacts -Symbols -SymbolPackageFormat snupkg
nuget pack nuget/OpenCvSharp4.WpfExtensions.nuspec -OutputDirectory artifacts -Symbols -SymbolPackageFormat snupkg
nuget pack nuget/OpenCvSharp4.runtime.win.nuspec -OutputDirectory artifacts
nuget pack nuget/OpenCvSharp4.runtime.uwp.nuspec -OutputDirectory artifacts
- name: Test
shell: powershell
run: |
cd ${env:GITHUB_WORKSPACE}\test\OpenCvSharp.Tests
dotnet test -c Release -f net48 --runtime win-x64
- name: Test Windows-only functions
shell: powershell
run: |
cd ${env:GITHUB_WORKSPACE}\test\OpenCvSharp.Tests.Windows
dotnet test -c Release -f net48 --runtime win-x64
- name: Run ReleaseMaker
shell: powershell
run: |
cd "${env:GITHUB_WORKSPACE}\tool\OpenCvSharp.ReleaseMaker"
dotnet run -c Release --runtime win-x64 -- "${env:GITHUB_WORKSPACE}" "${env:GITHUB_WORKSPACE}\artifacts" ${{env.OPENCV_VERSION}}
- name: Upload NuGet packages and Release packages
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: packages_windows
path: ${{ github.workspace }}\artifacts
13 changes: 0 additions & 13 deletions .travis.yml

This file was deleted.

2 changes: 1 addition & 1 deletion LICENSE
Original file line number Diff line number Diff line change
@@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.

Copyright [yyyy] [name of copyright owner]
Copyright 2008 shimat

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
58 changes: 40 additions & 18 deletions OpenCvSharp.sln
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.29503.13
# Visual Studio Version 17
VisualStudioVersion = 17.8.34330.188
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{E048D213-B3B9-453F-9A41-29FDEB0D496B}"
EndProject
@@ -24,8 +24,6 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "tool", "tool", "{A6E578C0-A
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OpenCvSharp.NupkgBetaRemover", "tool\OpenCvSharp.NupkgBetaRemover\OpenCvSharp.NupkgBetaRemover.csproj", "{CC19F9A5-01A7-4BDF-B34C-CF56F46A474A}"
EndProject
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "uwpOpenCvSharpExtern", "src\uwpOpenCvSharpExtern\uwpOpenCvSharpExtern.vcxproj", "{BD5471E5-7B55-5192-8DA4-042B66AF71AE}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OpenCvSharp.WpfExtensions", "src\OpenCvSharp.WpfExtensions\OpenCvSharp.WpfExtensions.csproj", "{01FD66CE-F81A-4641-BE30-3CF9DE84D6D5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OpenCvSharp.ReleaseMaker", "tool\OpenCvSharp.ReleaseMaker\OpenCvSharp.ReleaseMaker.csproj", "{1C399497-5240-439A-879A-4ACB34C409AE}"
@@ -35,6 +33,10 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
.editorconfig = .editorconfig
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "OpenCvSharp.DebuggerVisualizers.Tester", "test\OpenCvSharp.DebuggerVisualizers.Tester\OpenCvSharp.DebuggerVisualizers.Tester.csproj", "{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "OpenCvSharp.Tests.Windows", "test\OpenCvSharp.Tests.Windows\OpenCvSharp.Tests.Windows.csproj", "{36F6A125-3633-441E-9794-97EB91E50F20}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -140,19 +142,6 @@ Global
{CC19F9A5-01A7-4BDF-B34C-CF56F46A474A}.Release|x64.Build.0 = Release|Any CPU
{CC19F9A5-01A7-4BDF-B34C-CF56F46A474A}.Release|x86.ActiveCfg = Release|Any CPU
{CC19F9A5-01A7-4BDF-B34C-CF56F46A474A}.Release|x86.Build.0 = Release|Any CPU
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|Any CPU.ActiveCfg = Debug|Win32
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|ARM.ActiveCfg = Debug|ARM
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|x64.ActiveCfg = Release|x64
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|x64.Build.0 = Release|x64
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|x86.ActiveCfg = Release|Win32
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Debug|x86.Build.0 = Release|Win32
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|Any CPU.ActiveCfg = Release|Win32
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|ARM.ActiveCfg = Release|ARM
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|ARM.Build.0 = Release|ARM
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|x64.ActiveCfg = Release|x64
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|x64.Build.0 = Release|x64
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|x86.ActiveCfg = Release|Win32
{BD5471E5-7B55-5192-8DA4-042B66AF71AE}.Release|x86.Build.0 = Release|Win32
{01FD66CE-F81A-4641-BE30-3CF9DE84D6D5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{01FD66CE-F81A-4641-BE30-3CF9DE84D6D5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{01FD66CE-F81A-4641-BE30-3CF9DE84D6D5}.Debug|ARM.ActiveCfg = Debug|Any CPU
@@ -185,6 +174,38 @@ Global
{1C399497-5240-439A-879A-4ACB34C409AE}.Release|x64.Build.0 = Release|Any CPU
{1C399497-5240-439A-879A-4ACB34C409AE}.Release|x86.ActiveCfg = Release|Any CPU
{1C399497-5240-439A-879A-4ACB34C409AE}.Release|x86.Build.0 = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|Any CPU.Build.0 = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|ARM.ActiveCfg = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|ARM.Build.0 = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|x64.ActiveCfg = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|x64.Build.0 = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|x86.ActiveCfg = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Debug|x86.Build.0 = Debug|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|Any CPU.ActiveCfg = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|Any CPU.Build.0 = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|ARM.ActiveCfg = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|ARM.Build.0 = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|x64.ActiveCfg = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|x64.Build.0 = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|x86.ActiveCfg = Release|Any CPU
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC}.Release|x86.Build.0 = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|Any CPU.Build.0 = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|ARM.ActiveCfg = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|ARM.Build.0 = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|x64.ActiveCfg = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|x64.Build.0 = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|x86.ActiveCfg = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Debug|x86.Build.0 = Debug|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|Any CPU.ActiveCfg = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|Any CPU.Build.0 = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|ARM.ActiveCfg = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|ARM.Build.0 = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|x64.ActiveCfg = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|x64.Build.0 = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|x86.ActiveCfg = Release|Any CPU
{36F6A125-3633-441E-9794-97EB91E50F20}.Release|x86.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -196,9 +217,10 @@ Global
{8E7279F8-F801-4672-B42F-1ED2C68B16A4} = {E048D213-B3B9-453F-9A41-29FDEB0D496B}
{4232CB4A-DFE3-46CA-9503-C5F1798BAED3} = {E048D213-B3B9-453F-9A41-29FDEB0D496B}
{CC19F9A5-01A7-4BDF-B34C-CF56F46A474A} = {A6E578C0-A34A-4CCF-A808-CBAC81CB48C0}
{BD5471E5-7B55-5192-8DA4-042B66AF71AE} = {E048D213-B3B9-453F-9A41-29FDEB0D496B}
{01FD66CE-F81A-4641-BE30-3CF9DE84D6D5} = {E048D213-B3B9-453F-9A41-29FDEB0D496B}
{1C399497-5240-439A-879A-4ACB34C409AE} = {A6E578C0-A34A-4CCF-A808-CBAC81CB48C0}
{FFD602AA-0A08-40DD-8ACD-7F5A3BA51DEC} = {1F113DD0-E292-47A5-8EFF-3FB5D0869BF3}
{36F6A125-3633-441E-9794-97EB91E50F20} = {1F113DD0-E292-47A5-8EFF-3FB5D0869BF3}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {60DD551B-ED40-447E-AABE-B408178D29D1}
15 changes: 15 additions & 0 deletions OpenCvSharp.sln.DotSettings
Original file line number Diff line number Diff line change
@@ -1,15 +1,24 @@
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
<s:String x:Key="/Default/CodeStyle/Naming/CppNaming/Rules/=Local_0020variables/@EntryIndexedValue">&lt;NamingElement Priority="6"&gt;&lt;Descriptor Static="Indeterminate" Constexpr="Indeterminate" Const="Indeterminate" Volatile="Indeterminate" Accessibility="NOT_APPLICABLE"&gt;&lt;type Name="local variable" /&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;&lt;/NamingElement&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CppNaming/Rules/=Parameters/@EntryIndexedValue">&lt;NamingElement Priority="5"&gt;&lt;Descriptor Static="Indeterminate" Constexpr="Indeterminate" Const="Indeterminate" Volatile="Indeterminate" Accessibility="NOT_APPLICABLE"&gt;&lt;type Name="parameter" /&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;&lt;/NamingElement&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=LTRB/@EntryIndexedValue">LTRB</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=LUT/@EntryIndexedValue">LUT</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=PCA/@EntryIndexedValue">PCA</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=QR/@EntryIndexedValue">QR</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=RB/@EntryIndexedValue">RB</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=RNG/@EntryIndexedValue">RNG</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/Abbreviations/=SURF/@EntryIndexedValue">SURF</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateConstants/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateInstanceFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateStaticFields/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/PredefinedNamingRules/=PrivateStaticReadonly/@EntryIndexedValue">&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;</s:String>
<s:Boolean x:Key="/Default/GrammarAndSpelling/GrammarChecking/Exceptions/=multi_002Dchannel/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/GrammarAndSpelling/GrammarChecking/Exceptions/=multi_002Ddimensional/@EntryIndexedValue">True</s:Boolean>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=15b5b1f1_002D457c_002D4ca6_002Db278_002D5615aedc07d3/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Static" AccessRightKinds="Private" Description="Static readonly fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="READONLY_FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=236f7aa5_002D7b06_002D43ca_002Dbf2a_002D9b31bfcff09a/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Any" AccessRightKinds="Private" Description="Constant fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="CONSTANT_FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="AaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=4a98fdf6_002D7d98_002D4f5a_002Dafeb_002Dea44ad98c70c/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Instance" AccessRightKinds="Private" Description="Instance fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="FIELD" /&gt;&lt;Kind Name="READONLY_FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:String x:Key="/Default/CodeStyle/Naming/CSharpNaming/UserRules/=f9fce829_002De6f4_002D4cb2_002D80f1_002D5497c44f51df/@EntryIndexedValue">&lt;Policy&gt;&lt;Descriptor Staticness="Static" AccessRightKinds="Private" Description="Static fields (private)"&gt;&lt;ElementKinds&gt;&lt;Kind Name="FIELD" /&gt;&lt;/ElementKinds&gt;&lt;/Descriptor&gt;&lt;Policy Inspect="True" Prefix="" Suffix="" Style="aaBb" /&gt;&lt;/Policy&gt;</s:String>
<s:Boolean x:Key="/Default/Environment/SettingsMigration/IsMigratorApplied/=JetBrains_002EReSharper_002EPsi_002ECSharp_002ECodeStyle_002ESettingsUpgrade_002EPredefinedNamingRulesToUserRulesUpgrade/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=AGAST/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=AKAZE/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Argb/@EntryIndexedValue">True</s:Boolean>
@@ -64,7 +73,9 @@
<s:Boolean x:Key="/Default/UserDictionary/Words/=imgproc/@EntryIndexedValue">True</s:Boolean>

<s:Boolean x:Key="/Default/UserDictionary/Words/=imread/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=imreadmulti/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=imshow/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=imwrite/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=inlier/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=inliers/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=inliners/@EntryIndexedValue">True</s:Boolean>
@@ -88,6 +99,7 @@
<s:Boolean x:Key="/Default/UserDictionary/Words/=Mersenne/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Mertens/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=MSER/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=multipage/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=ndims/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=neighbourhood/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=neighbouring/@EntryIndexedValue">True</s:Boolean>
@@ -100,6 +112,7 @@
<s:Boolean x:Key="/Default/UserDictionary/Words/=ONNX/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=opencv/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Otsu/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=prms/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=PSNR/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Ptrs/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=RANSAC/@EntryIndexedValue">True</s:Boolean>
@@ -134,9 +147,11 @@
<s:Boolean x:Key="/Default/UserDictionary/Words/=uchar/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=umat/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Undistort/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=unmappable/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Vecs/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=videoio/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=Voronoi/@EntryIndexedValue">True</s:Boolean>

<s:Boolean x:Key="/Default/UserDictionary/Words/=Writeable/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=ximgproc/@EntryIndexedValue">True</s:Boolean>
<s:Boolean x:Key="/Default/UserDictionary/Words/=xphoto/@EntryIndexedValue">True</s:Boolean>
67 changes: 25 additions & 42 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,33 +1,35 @@
# OpenCvSharp
[![Github Actions Windows Status](https://github.com/shimat/opencvsharp/workflows/Windows%20Server%202019/badge.svg)](https://github.com/shimat/opencvsharp/actions) [![Github Actions Ubuntu Status](https://github.com/shimat/opencvsharp/workflows/Ubuntu%2018.04/badge.svg)](https://github.com/shimat/opencvsharp/actions) [![Github Actions MacOS Status](https://github.com/shimat/opencvsharp/workflows/macOS%2010.15/badge.svg)](https://github.com/shimat/opencvsharp/actions) [![GitHub license](https://img.shields.io/github/license/shimat/opencvsharp.svg)](https://github.com/shimat/opencvsharp/blob/master/LICENSE)
![opencvsharp](https://socialify.git.ci/shimat/opencvsharp/image?description=1&forks=1&language=1&owner=1&pattern=Plus&stargazers=1&theme=Light)

Wrapper of OpenCV for .NET
[![Github Actions Windows Status](https://github.com/shimat/opencvsharp/workflows/Windows%20Server%202022/badge.svg)](https://github.com/shimat/opencvsharp/actions) [![Github Actions Ubuntu Status](https://github.com/shimat/opencvsharp/workflows/Ubuntu%2022.04/badge.svg)](https://github.com/shimat/opencvsharp/actions) [![GitHub license](https://img.shields.io/github/license/shimat/opencvsharp.svg)](https://github.com/shimat/opencvsharp/blob/master/LICENSE)

Old versions of OpenCvSharp are stored in [opencvsharp_2410](https://github.com/shimat/opencvsharp_2410).

## NuGet

### Managed libraries
| Package | Description | Link |
|---------|-------------|------|
|**OpenCvSharp4**| OpenCvSharp core libraries | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.svg)](https://badge.fury.io/nu/OpenCvSharp4) |
|**OpenCvSharp4.Extensions**| GDI+ Extensions | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.Extensions.svg)](https://badge.fury.io/nu/OpenCvSharp4.Extensions) |
|**OpenCvSharp4.WpfExtensions**| WPF Extensions | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.WpfExtensions.svg)](https://badge.fury.io/nu/OpenCvSharp4.WpfExtensions) |
|**OpenCvSharp4.Windows**| All-in-one package for Windows (except UWP) | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.Windows.svg)](https://badge.fury.io/nu/OpenCvSharp4.Windows) |

### Native bindings
| Package | Description | Link |
|---------|-------------|------|
|**OpenCvSharp4.runtime.win**| Native bindings for Windows x64/x86 (except UWP) | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.win.svg)](https://badge.fury.io/nu/OpenCvSharp4.runtime.win) |
|**OpenCvSharp4.runtime.uwp**| Native bindings for UWP (Universal Windows Platform) x64/x86/ARM | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.uwp.svg)](https://badge.fury.io/nu/OpenCvSharp4.runtime.uwp) |
|**OpenCvSharp4.runtime.ubuntu.18.04-x64**| Native bindings for Ubuntu 18.04 x64 | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.ubuntu.18.04-x64.svg)](https://badge.fury.io/nu/OpenCvSharp4.runtime.ubuntu.18.04-x64) |
|**OpenCvSharp4.runtime.osx.10.15-x64**| Native bindings for macOS 10.15 x64 | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.osx.10.15-x64.svg)](https://www.nuget.org/packages/OpenCvSharp4.runtime.osx.10.15-x64/) |
|**OpenCvSharp4.official.runtime.linux-x64**| Native bindings for Linux x64 | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.official.runtime.linux-x64.svg)](https://badge.fury.io/nu/OpenCvSharp4.official.runtime.linux-x64) |
|**OpenCvSharp4.runtime.linux-arm**| Native bindings for Linux Arm | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.linux-arm.svg)](https://www.nuget.org/packages/OpenCvSharp4.runtime.linux-arm/) |
|**OpenCvSharp4.runtime.wasm**| Native bindings for WebAssembly | [![NuGet version](https://badge.fury.io/nu/OpenCvSharp4.runtime.wasm.svg)](https://www.nuget.org/packages/OpenCvSharp4.runtime.wasm/) |

Native binding (OpenCvSharpExtern.dll / libOpenCvSharpExtern.so) is required to work OpenCvSharp. To use OpenCvSharp, you should add both `OpenCvSharp4` and `OpenCvSharp4.runtime.*` packages to your project. Currently, native bindings for Windows, UWP, Ubuntu 18.04 and macOS are released.
Native binding (OpenCvSharpExtern.dll / libOpenCvSharpExtern.so) is required to work OpenCvSharp. To use OpenCvSharp, you should add both `OpenCvSharp4` and `OpenCvSharp4.runtime.*` packages to your project. Currently, native bindings for Windows, UWP and Ubuntu are released.

Packages named OpenCvSharp3-* and OpenCvSharp-* are deprecated.
> [OpenCvSharp3-AnyCPU](https://www.nuget.org/packages/OpenCvSharp3-AnyCPU/) / [OpenCvSharp3-WithoutDll](https://www.nuget.org/packages/OpenCvSharp3-WithoutDll/) / [OpenCvSharp-AnyCPU](https://www.nuget.org/packages/OpenCvSharp-AnyCPU/) / [OpenCvSharp-WithoutDll](https://www.nuget.org/packages/OpenCvSharp-WithoutDll/)
## Docker images
https://hub.docker.com/u/shimat
- Ubuntu 18.04 (.NET Core 3.1): [shimat/ubuntu18-dotnetcore3.1-opencv4.5.0](https://hub.docker.com/r/shimat/ubuntu18-dotnetcore3.1-opencv4.5.0)
- For Google App Engine Flexible (.NET Core 3.1): [shimat/appengine-aspnetcore3.1-opencv4.5.0](https://hub.docker.com/r/shimat/appengine-aspnetcore3.1-opencv4.5.0)
- For AWS Lambda (.NET 5): [shimat/al2-dotnet5-opencv4.5.0](https://hub.docker.com/r/shimat/al2-dotnet5-opencv4.5.0)
- Code sample: https://github.com/shimat/opencvsharp_AWSLambdaSample
https://github.com/shimat?tab=packages

## Installation

@@ -37,47 +39,31 @@ Add `OpenCvSharp4` and `OpenCvSharp4.runtime.win` NuGet packages to your project
### UWP
Add `OpenCvSharp4` and `OpenCvSharp4.runtime.uwp` NuGet packages to your project. Note that `OpenCvSharp4.runtime.win` and `OpenCvSharp4.Windows` don't work for UWP.

### Ubuntu 18.04
Add `OpenCvSharp4` and `OpenCvSharp4.runtime.ubuntu.18.04.x64` NuGet packages to your project.
### Ubuntu 22.04
Add `OpenCvSharp4` and `OpenCvSharp4.runtime.ubuntu.22.04.x64` NuGet packages to your project.
```
dotnet new console -n ConsoleApp01
cd ConsoleApp01
dotnet add package OpenCvSharp4
dotnet add package OpenCvSharp4.runtime.ubuntu.18.04-x64
dotnet add package OpenCvSharp4_.runtime.ubuntu.22.04-x64
# -- edit Program.cs --- #
dotnet run
```

### Google AppEngine Flexible (Ubuntu 16.04)
Some Docker images are provided to use OpenCvSharp with AppEngine Flexible. The native binding (libOpenCvSharpExtern) is already built in the docker image and you don't need to worry about it.
```
FROM shimat/appengine-aspnetcore3.1-opencv4.5.0:20201030
ADD ./ /app
ENV ASPNETCORE_URLS=http://*:${PORT}
WORKDIR /app
ENTRYPOINT [ "dotnet", "YourAspNetCoreProject.dll" ]
```

### Ubuntu 18.04 Docker image
You can use the `shimat/ubuntu18-dotnetcore3.1-opencv4.5.0` docker image.
This issue may be helpful: https://github.com/shimat/opencvsharp/issues/920

### Downloads
If you do not use NuGet, get DLL files from the [release page](https://github.com/shimat/opencvsharp/releases).

## Target OpenCV
* [OpenCV 4.5.1](http://opencv.org/) with [opencv_contrib](https://github.com/opencv/opencv_contrib)
* [OpenCV 4.10.0](http://opencv.org/) with [opencv_contrib](https://github.com/opencv/opencv_contrib)

## Requirements
* [.NET Framework 4.6.1](http://www.microsoft.com/ja-jp/download/details.aspx?id=1639) / [.NET Core 2.0](https://www.microsoft.com/net/download) / [Mono](http://www.mono-project.com/Main_Page)
* (Windows) [Visual C++ 2019 Redistributable Package](https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads)
* [.NET Framework 4.8](http://www.microsoft.com/ja-jp/download/details.aspx?id=1639) / [.NET 6](https://www.microsoft.com/net/download) or later / .NET Standard 2.0
* (Windows) [Visual C++ 2022 Redistributable Package](https://support.microsoft.com/en-us/help/2977003/the-latest-supported-visual-c-downloads)
* (Windows Server) Media Foundation
```
PS1> Install-WindowsFeature Server-Media-Foundation
```
* (Ubuntu, Mac) You must pre-install all the dependency packages needed to build OpenCV. Many packages such as libjpeg must be installed in order to work OpenCV.
* (Ubuntu) You must pre-install all the dependency packages needed to build OpenCV. Many packages such as libjpeg must be installed in order to work OpenCV.
https://www.learnopencv.com/install-opencv-4-on-ubuntu-18-04/


@@ -147,14 +133,14 @@ using (var t = new ResourcesTracker())
## Code samples
https://github.com/shimat/opencvsharp_samples/

## Documents
## API Documents
http://shimat.github.io/opencvsharp/api/OpenCvSharp.html

## OpenCvSharp Build Instructions
### Windows
- Install Visual Studio 2019 or later
- Install Visual Studio 2022 or later
- VC++ features are required.
- Run `download_opencv_windows.ps1` to download OpenCV libs and headers from https://github.com/shimat/opencv_files. Those lib files are precompiled by the owner of OpenCvSharp using AppVeyor CI.
- Run `download_opencv_windows.ps1` to download OpenCV libs and headers from https://github.com/shimat/opencv_files. Those lib files are precompiled by the owner of OpenCvSharp using GitHub Actions.
```
.\download_opencv_windows.ps1
```
@@ -168,10 +154,10 @@ If you want to use some OpenCV features that are not provided by default in Open
- Edit `build_windows.ps1` or `build_uwp.ps1` to customize the CMake parameters .
- Run the PowerShell script.

### Ubuntu 18.04
### Ubuntu
- Build OpenCV with opencv_contrib.
- https://www.learnopencv.com/install-opencv-4-on-ubuntu-18-04/
- Install .NET Core SDK. https://docs.microsoft.com/ja-jp/dotnet/core/install/linux-package-manager-ubuntu-1804
- Install .NET Core SDK. https://learn.microsoft.com/ja-jp/dotnet/core/install/linux-ubuntu
- Get OpenCvSharp source files
```
git clone https://github.com/shimat/opencvsharp.git
@@ -202,9 +188,6 @@ dotnet add package OpenCvSharp4
dotnet run
```

### Older Ubuntu
Refer to the [Dockerfile](https://github.com/shimat/opencvsharp/blob/master/docker/google-appengine-ubuntu.16.04-x64/Dockerfile) and [Wiki pages](https://github.com/shimat/opencvsharp/wiki).

## Donations
If you find the OpenCvSharp library useful and would like to show your gratitude by donating, here are some donation options. Thank you.

2 changes: 1 addition & 1 deletion docfx/docfx.json
Original file line number Diff line number Diff line change
@@ -12,7 +12,7 @@
"disableGitFeatures": false,
"disableDefaultFilter": false,
"properties": {
"TargetFramework": "net48"
"TargetFramework": "net6"
}
}
],
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
FROM public.ecr.aws/lambda/dotnet:5.0

ENV OPENCV_VERSION=4.5.1
ENV OPENCV_VERSION=4.6.0

WORKDIR /

@@ -32,11 +32,13 @@ RUN cd opencv && mkdir build && cd build && \
-D BUILD_TESTS=OFF \
-D BUILD_JAVA=OFF \
-D BUILD_opencv_app=OFF \
-D BUILD_opencv_barcode=OFF \
-D BUILD_opencv_java_bindings_generator=OFF \
-D BUILD_opencv_js_bindings_generator=OFF \
-D BUILD_opencv_python_bindings_generator=OFF \
-D BUILD_opencv_python_tests=OFF \
-D BUILD_opencv_ts=OFF \
-D BUILD_opencv_js=OFF \
-D BUILD_opencv_js=OFF \
-D BUILD_opencv_bioinspired=OFF \
-D BUILD_opencv_ccalib=OFF \
-D BUILD_opencv_datasets=OFF \
@@ -46,21 +48,23 @@ RUN cd opencv && mkdir build && cd build && \
-D BUILD_opencv_gapi=OFF \
-D BUILD_opencv_intensity_transform=OFF \
-D BUILD_opencv_mcc=OFF \
-D BUILD_opencv_objc_bindings_generator=OFF \
-D BUILD_opencv_rapid=OFF \
-D BUILD_opencv_reg=OFF \
-D BUILD_opencv_stereo=OFF \
-D BUILD_opencv_structured_light=OFF \
-D BUILD_opencv_surface_matching=OFF \
-D BUILD_opencv_videostab=OFF \
-D WITH_GSTREAMER=OFF \
-D BUILD_opencv_wechat_qrcode=ON \
-D WITH_GSTREAMER=OFF \
-D OPENCV_ENABLE_NONFREE=ON \
.. && make -j8 && make install
.. && make -j$(nproc) && make install

# Download OpenCvSharp
RUN wget https://github.com/shimat/opencvsharp/archive/master.zip && \
unzip master.zip && rm master.zip && \
mv opencvsharp-master opencvsharp && \
cd opencvsharp
cd opencvsharp

# Install the Extern lib.
RUN mkdir /opencvsharp/make && cd /opencvsharp/make && \
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
FROM mcr.microsoft.com/dotnet/sdk:3.1-bionic
FROM mcr.microsoft.com/dotnet/aspnet:6.0-jammy AS builder

ENV OPENCV_VERSION=4.5.1
ENV DEBIAN_FRONTEND=noninteractive
ENV OPENCV_VERSION=4.8.0

WORKDIR /

@@ -20,28 +21,27 @@ RUN apt-get update && apt-get -y install --no-install-recommends \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
libdc1394-22-dev \
libdc1394-dev \
libxine2-dev \
libv4l-dev \
libtheora-dev \
libvorbis-dev \
libxvidcore-dev \
libopencore-amrnb-dev \
libopencore-amrwb-dev \
libavresample-dev \
x264 \
libtesseract-dev \
libgdiplus \
&& apt-get -y clean \
&& rm -rf /var/lib/apt/lists/*

# Setup opencv and opencv-contrib source
RUN wget https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
unzip ${OPENCV_VERSION}.zip && \
RUN wget -q https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
unzip -q ${OPENCV_VERSION}.zip && \
rm ${OPENCV_VERSION}.zip && \
mv opencv-${OPENCV_VERSION} opencv && \
wget https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip && \
unzip ${OPENCV_VERSION}.zip && \
wget -q https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip && \
unzip -q ${OPENCV_VERSION}.zip && \
rm ${OPENCV_VERSION}.zip && \
mv opencv_contrib-${OPENCV_VERSION} opencv_contrib

@@ -58,7 +58,9 @@ RUN cd opencv && mkdir build && cd build && \
-D BUILD_TESTS=OFF \
-D BUILD_JAVA=OFF \
-D BUILD_opencv_app=OFF \
-D BUILD_opencv_barcode=OFF \
-D BUILD_opencv_java_bindings_generator=OFF \
-D BUILD_opencv_js_bindings_generator=OFF \
-D BUILD_opencv_python_bindings_generator=OFF \
-D BUILD_opencv_python_tests=OFF \
-D BUILD_opencv_ts=OFF \
@@ -72,31 +74,43 @@ RUN cd opencv && mkdir build && cd build && \
-D BUILD_opencv_gapi=OFF \
-D BUILD_opencv_intensity_transform=OFF \
-D BUILD_opencv_mcc=OFF \
-D BUILD_opencv_objc_bindings_generator=OFF \
-D BUILD_opencv_rapid=OFF \
-D BUILD_opencv_reg=OFF \
-D BUILD_opencv_stereo=OFF \
-D BUILD_opencv_structured_light=OFF \
-D BUILD_opencv_surface_matching=OFF \
-D BUILD_opencv_videostab=OFF \
-D BUILD_opencv_wechat_qrcode=ON \
-D WITH_GSTREAMER=OFF \
-D WITH_ADE=OFF \
-D OPENCV_ENABLE_NONFREE=ON \
.. && make -j6 && make install && ldconfig
.. && make -j$(nproc) && make install && ldconfig

# Download OpenCvSharp
RUN git clone https://github.com/shimat/opencvsharp.git && cd opencvsharp

# Install the Extern lib.
RUN mkdir /opencvsharp/make && cd /opencvsharp/make && \
cmake -D CMAKE_INSTALL_PREFIX=/opencvsharp/make /opencvsharp/src && \
make -j && make install && \
make -j$(nproc) && make install && \
rm -rf /opencv && \
rm -rf /opencv_contrib && \
cp /opencvsharp/make/OpenCvSharpExtern/libOpenCvSharpExtern.so /usr/lib/ && \
mkdir /artifacts && \
cp /opencvsharp/make/OpenCvSharpExtern/libOpenCvSharpExtern.so /artifacts/

# Test OpenCvSharpExtern
RUN cp artifacts/libOpenCvSharpExtern.so /usr/lib/ && \
echo "\n\

########## Test native .so file ##########

FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy
RUN apt-get update && apt-get -y install --no-install-recommends gcc
# /usr/lib/libOpenCvSharpExtern.so
# /usr/local/lib/libopencv_*.a
COPY --from=builder /usr/lib /usr/lib
#COPY --from=builder /usr/local/lib /usr/local/lib

RUN echo "\n\
#include <stdio.h> \n\
int core_Mat_sizeof(); \n\
int main(){ \n\
@@ -105,27 +119,24 @@ int main(){ \n\
return 0; \n\
}" > /test.c && \
gcc -I./ -L./ test.c -o test -lOpenCvSharpExtern && \
LD_LIBRARY_PATH=. ./test && \
rm -f /test*
LD_LIBRARY_PATH=. ./test

# Install Build the C# part of OpenCvSharp
#RUN cd /opencvsharp/src/OpenCvSharp && \
# dotnet build -c Release -f netstandard2.1 && \
# cd /opencvsharp/src/OpenCvSharp.Blob && \
# dotnet build -c Release -f netstandard2.1 && \
# cd /opencvsharp/src/OpenCvSharp.Extensions && \
# dotnet build -c Release -f netstandard2.1 && \
# cp /opencvsharp/src/OpenCvSharp/bin/Release/netstandard2.1/* /artifacts/ && \
# cp /opencvsharp/src/OpenCvSharp.Blob/bin/Release/netstandard2.1/* /artifacts/ && \
# cp /opencvsharp/src/OpenCvSharp.Extensions/bin/Release/netstandard2.1/* /artifacts/

# Test OpenCvSharp
#RUN dotnet test /opencvsharp/test/OpenCvSharp.Tests/OpenCvSharp.Tests.csproj -c Release -f netcoreapp3.1 --runtime ubuntu.18.04-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null
########## Test .NET class libraries ##########

RUN rm -rf /opencvsharp
FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy
COPY --from=builder /usr/lib /usr/lib
# Install Build the C# part of OpenCvSharp
RUN git clone https://github.com/shimat/opencvsharp.git && cd opencvsharp
RUN cd /opencvsharp/src/OpenCvSharp && \
dotnet build -c Release -f net6.0 && \
cd /opencvsharp/src/OpenCvSharp.Extensions && \
dotnet build -c Release -f net6.0

RUN dotnet test /opencvsharp/test/OpenCvSharp.Tests/OpenCvSharp.Tests.csproj -c Release -f net6.0 --runtime ubuntu.20.04-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null

# Simple console app test using NuGet
#RUN dotnet new console -f netcoreapp3.1 -o "ConsoleApp01" && cd /ConsoleApp01 && \
# RUN dotnet new console -f net6.0 -o "ConsoleApp01" && cd /ConsoleApp01 && \
# echo "\n\
#using System; \n\
#using OpenCvSharp; \n\
@@ -141,3 +152,11 @@ RUN rm -rf /opencvsharp
# rm -rf /ConsoleApp01

#RUN ldd /artifacts/libOpenCvSharpExtern.so



########## Final image ##########

FROM mcr.microsoft.com/dotnet/aspnet:6.0-jammy AS final
COPY --from=builder /usr/lib /usr/lib
COPY --from=builder /artifacts /artifacts
159 changes: 159 additions & 0 deletions docker/ubuntu22-dotnet6sdk-opencv4.7.0/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,159 @@
FROM mcr.microsoft.com/dotnet/aspnet:6.0-jammy AS builder

ENV DEBIAN_FRONTEND=noninteractive
ENV OPENCV_VERSION=4.7.0

WORKDIR /

# Install opencv dependencies
RUN apt-get update && apt-get -y install --no-install-recommends \
apt-transport-https \
software-properties-common \
wget \
unzip \
ca-certificates \
build-essential \
cmake \
git \
libtbb-dev \
libatlas-base-dev \
libgtk2.0-dev \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
libdc1394-dev \
libxine2-dev \
libv4l-dev \
libtheora-dev \
libvorbis-dev \
libxvidcore-dev \
libopencore-amrnb-dev \
libopencore-amrwb-dev \
x264 \
libtesseract-dev \
libgdiplus \
&& apt-get -y clean \
&& rm -rf /var/lib/apt/lists/*

# Setup opencv and opencv-contrib source
RUN wget -q https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip && \
unzip -q ${OPENCV_VERSION}.zip && \
rm ${OPENCV_VERSION}.zip && \
mv opencv-${OPENCV_VERSION} opencv && \
wget -q https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip && \
unzip -q ${OPENCV_VERSION}.zip && \
rm ${OPENCV_VERSION}.zip && \
mv opencv_contrib-${OPENCV_VERSION} opencv_contrib

# Build OpenCV
RUN cd opencv && mkdir build && cd build && \
cmake \
-D OPENCV_EXTRA_MODULES_PATH=/opencv_contrib/modules \
-D CMAKE_BUILD_TYPE=RELEASE \
-D BUILD_SHARED_LIBS=OFF \
-D ENABLE_CXX11=ON \
-D BUILD_EXAMPLES=OFF \
-D BUILD_DOCS=OFF \
-D BUILD_PERF_TESTS=OFF \
-D BUILD_TESTS=OFF \
-D BUILD_JAVA=OFF \
-D BUILD_opencv_app=OFF \
-D BUILD_opencv_barcode=OFF \
-D BUILD_opencv_java_bindings_generator=OFF \
-D BUILD_opencv_js_bindings_generator=OFF \
-D BUILD_opencv_python_bindings_generator=OFF \
-D BUILD_opencv_python_tests=OFF \
-D BUILD_opencv_ts=OFF \
-D BUILD_opencv_js=OFF \
-D BUILD_opencv_bioinspired=OFF \
-D BUILD_opencv_ccalib=OFF \
-D BUILD_opencv_datasets=OFF \
-D BUILD_opencv_dnn_objdetect=OFF \
-D BUILD_opencv_dpm=OFF \
-D BUILD_opencv_fuzzy=OFF \
-D BUILD_opencv_gapi=OFF \
-D BUILD_opencv_intensity_transform=OFF \
-D BUILD_opencv_mcc=OFF \
-D BUILD_opencv_objc_bindings_generator=OFF \
-D BUILD_opencv_rapid=OFF \
-D BUILD_opencv_reg=OFF \
-D BUILD_opencv_stereo=OFF \
-D BUILD_opencv_structured_light=OFF \
-D BUILD_opencv_surface_matching=OFF \
-D BUILD_opencv_videostab=OFF \
-D BUILD_opencv_wechat_qrcode=ON \
-D WITH_GSTREAMER=OFF \
-D WITH_ADE=OFF \
-D OPENCV_ENABLE_NONFREE=ON \
.. && make -j$(nproc) && make install && ldconfig

# Download OpenCvSharp
RUN git clone https://github.com/shimat/opencvsharp.git && cd opencvsharp

# Install the Extern lib.
RUN mkdir /opencvsharp/make && cd /opencvsharp/make && \
cmake -D CMAKE_INSTALL_PREFIX=/opencvsharp/make /opencvsharp/src && \
make -j$(nproc) && make install && \
rm -rf /opencv && \
rm -rf /opencv_contrib && \
cp /opencvsharp/make/OpenCvSharpExtern/libOpenCvSharpExtern.so /usr/lib/


########## Test native .so file ##########

FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy
RUN apt-get update && apt-get -y install --no-install-recommends gcc
# /usr/lib/libOpenCvSharpExtern.so
# /usr/local/lib/libopencv_*.a
COPY --from=builder /usr/lib /usr/lib
#COPY --from=builder /usr/local/lib /usr/local/lib

RUN echo "\n\
#include <stdio.h> \n\
int core_Mat_sizeof(); \n\
int main(){ \n\
int i = core_Mat_sizeof(); \n\
printf(\"sizeof(Mat) = %d\", i); \n\
return 0; \n\
}" > /test.c && \
gcc -I./ -L./ test.c -o test -lOpenCvSharpExtern && \
LD_LIBRARY_PATH=. ./test


########## Test .NET class libraries ##########

FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy
COPY --from=builder /usr/lib /usr/lib
# Install Build the C# part of OpenCvSharp
RUN git clone https://github.com/shimat/opencvsharp.git && cd opencvsharp
RUN cd /opencvsharp/src/OpenCvSharp && \
dotnet build -c Release -f net6.0 && \
cd /opencvsharp/src/OpenCvSharp.Extensions && \
dotnet build -c Release -f net6.0

RUN dotnet test /opencvsharp/test/OpenCvSharp.Tests/OpenCvSharp.Tests.csproj -c Release -f net6.0 --runtime ubuntu.20.04-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null

# Simple console app test using NuGet
# RUN dotnet new console -f net6.0 -o "ConsoleApp01" && cd /ConsoleApp01 && \
# echo "\n\
# using System; \n\
# using OpenCvSharp; \n\
# class Program{ \n\
# static void Main(){ \n\
# Console.WriteLine(Cv2.GetTickCount()); \n\
# using var mat = new Mat(1, 1, MatType.CV_8UC1); \n\
# Console.WriteLine(mat.CvPtr); \n\
# } \n\
# }" > Program.cs && \
# dotnet add package OpenCvSharp4 && \
# dotnet run && \
# rm -rf /ConsoleApp01

#RUN ldd /artifacts/libOpenCvSharpExtern.so



########## Final image ##########

FROM mcr.microsoft.com/dotnet/sdk:6.0-jammy AS final
COPY --from=builder /usr/lib /usr/lib
162 changes: 162 additions & 0 deletions docker/ubuntu24-dotnet8-opencv4.12.0/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
FROM ubuntu:noble AS builder

ARG OPENCV_VERSION=4.12.0
ENV DEBIAN_FRONTEND=noninteractive
ENV OPENCV_VERSION=${OPENCV_VERSION}
ENV CCACHE_DIR=/root/.ccache
ENV CCACHE_MAXSIZE=2G

WORKDIR /

# Install build and OpenCV dependencies (with BuildKit cache for apt)
RUN --mount=type=cache,target=/var/cache/apt \
--mount=type=cache,target=/var/lib/apt/lists \
set -eux; \
apt-get update; \
apt-get -y install --no-install-recommends \
apt-transport-https \
software-properties-common \
wget \
unzip \
ca-certificates \
build-essential \
cmake \
git \
ccache \
libtbb-dev \
libatlas-base-dev \
libgtk-3-dev \
libavcodec-dev \
libavformat-dev \
libswscale-dev \
libdc1394-dev \
libxine2-dev \
libv4l-dev \
libtheora-dev \
libvorbis-dev \
libxvidcore-dev \
libopencore-amrnb-dev \
libopencore-amrwb-dev \
x264 \
libtesseract-dev \
libgdiplus \
pkg-config \
libavutil-dev; \
apt-get -y clean; \
rm -rf /var/lib/apt/lists/*

# Fetch OpenCV and opencv_contrib sources
RUN set -eux; \
wget -q https://github.com/opencv/opencv/archive/${OPENCV_VERSION}.zip; \
unzip -q ${OPENCV_VERSION}.zip; \
rm ${OPENCV_VERSION}.zip; \
mv opencv-${OPENCV_VERSION} /opencv; \
wget -q https://github.com/opencv/opencv_contrib/archive/${OPENCV_VERSION}.zip; \
unzip -q ${OPENCV_VERSION}.zip; \
rm ${OPENCV_VERSION}.zip; \
mv opencv_contrib-${OPENCV_VERSION} /opencv_contrib

# Configure, build, and install OpenCV with ccache and parallel build
RUN --mount=type=cache,target=/root/.ccache \
set -eux; \
cmake -S /opencv -B /opencv/build \
-D OPENCV_EXTRA_MODULES_PATH=/opencv_contrib/modules \
-D CMAKE_BUILD_TYPE=RELEASE \
-D CMAKE_C_COMPILER_LAUNCHER=ccache \
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache \
-D BUILD_SHARED_LIBS=OFF \
-D ENABLE_CXX11=ON \
-D BUILD_EXAMPLES=OFF \
-D BUILD_DOCS=OFF \
-D BUILD_PERF_TESTS=OFF \
-D BUILD_TESTS=OFF \
-D BUILD_JAVA=OFF \
-D BUILD_opencv_app=OFF \
-D BUILD_opencv_barcode=OFF \
-D BUILD_opencv_java_bindings_generator=OFF \
-D BUILD_opencv_js_bindings_generator=OFF \
-D BUILD_opencv_python_bindings_generator=OFF \
-D BUILD_opencv_python_tests=OFF \
-D BUILD_opencv_ts=OFF \
-D BUILD_opencv_js=OFF \
-D BUILD_opencv_bioinspired=OFF \
-D BUILD_opencv_ccalib=OFF \
-D BUILD_opencv_datasets=OFF \
-D BUILD_opencv_dnn_objdetect=OFF \
-D BUILD_opencv_dpm=OFF \
-D BUILD_opencv_fuzzy=OFF \
-D BUILD_opencv_gapi=OFF \
-D BUILD_opencv_intensity_transform=OFF \
-D BUILD_opencv_mcc=OFF \
-D BUILD_opencv_objc_bindings_generator=OFF \
-D BUILD_opencv_rapid=OFF \
-D BUILD_opencv_reg=OFF \
-D BUILD_opencv_stereo=OFF \
-D BUILD_opencv_structured_light=OFF \
-D BUILD_opencv_surface_matching=OFF \
-D BUILD_opencv_videostab=OFF \
-D BUILD_opencv_wechat_qrcode=ON \
-D WITH_GSTREAMER=OFF \
-D WITH_ADE=OFF \
-D OPENCV_ENABLE_NONFREE=ON; \
cmake --build /opencv/build --parallel "$(nproc)"; \
cmake --install /opencv/build; \
ldconfig

# Get OpenCvSharp sources
RUN git clone https://github.com/shimat/opencvsharp.git /opencvsharp

# Build and install OpenCvSharp native extern with ccache
RUN --mount=type=cache,target=/root/.ccache \
set -eux; \
mkdir -p /opencvsharp/make; \
cmake -S /opencvsharp/src -B /opencvsharp/make \
-D CMAKE_INSTALL_PREFIX=/opencvsharp/make \
-D CMAKE_C_COMPILER_LAUNCHER=ccache \
-D CMAKE_CXX_COMPILER_LAUNCHER=ccache; \
cmake --build /opencvsharp/make --parallel "$(nproc)"; \
cmake --install /opencvsharp/make; \
rm -rf /opencv /opencv_contrib; \
cp /opencvsharp/make/OpenCvSharpExtern/libOpenCvSharpExtern.so /usr/lib/; \
mkdir -p /artifacts; \
cp /opencvsharp/make/OpenCvSharpExtern/libOpenCvSharpExtern.so /artifacts/


########## Test native .so file ##########

FROM mcr.microsoft.com/dotnet/sdk:8.0-noble AS test-native
RUN apt-get update && apt-get -y install --no-install-recommends gcc && rm -rf /var/lib/apt/lists/*
COPY --from=builder /usr/lib /usr/lib
RUN echo "\n\
#include <stdio.h> \n\
int core_Mat_sizeof(); \n\
int main(){ \n\
int i = core_Mat_sizeof(); \n\
printf(\"sizeof(Mat) = %d\", i); \n\
return 0; \n\
}" > /test.c && \
gcc -I./ -L./ test.c -o test -lOpenCvSharpExtern && \
LD_LIBRARY_PATH=. ./test


########## Test .NET class libraries ##########

FROM mcr.microsoft.com/dotnet/sdk:8.0-noble AS test-dotnet
COPY --from=builder /usr/lib /usr/lib
RUN git clone https://github.com/shimat/opencvsharp.git && cd opencvsharp
RUN cd /opencvsharp/src/OpenCvSharp && \
dotnet build -c Release -f net8.0 && \
cd /opencvsharp/src/OpenCvSharp.Extensions && \
dotnet build -c Release -f net8.0
RUN dotnet test /opencvsharp/test/OpenCvSharp.Tests/OpenCvSharp.Tests.csproj -c Release -f net8.0 --runtime ubuntu.20.04-x64 --logger "trx;LogFileName=test-results.trx" < /dev/null


########## Final image ##########

FROM mcr.microsoft.com/dotnet/sdk:8.0-noble AS final-sdk
COPY --from=builder /usr/lib /usr/lib
COPY --from=builder /artifacts /artifacts

FROM mcr.microsoft.com/dotnet/aspnet:8.0-noble AS final
COPY --from=builder /usr/lib /usr/lib
COPY --from=builder /artifacts /artifacts
16 changes: 6 additions & 10 deletions download_opencv_windows.ps1
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
$tag = "4.5.1.20201228"
$version = "451"
$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"
$tag = "4.11.0.20250505"
$uriArray = @(
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv_win_x64.zip"
"https://github.com/shimat/opencv_files/releases/download/${tag}/opencv_win_x86.zip"
)

function Download($uri, $outFile) {
@@ -18,9 +14,9 @@ function Download($uri, $outFile) {
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)
[Net.ServicePointManager]::SecurityProtocol = @([Net.SecurityProtocolType]::Tls, [Net.SecurityProtocolType]::Tls11, [Net.SecurityProtocolType]::Tls12)

foreach($uri in $uriArray){
foreach ($uri in $uriArray) {
$outFile = [System.IO.Path]::GetFileName($uri)
$outFileWithoutExtension = [System.IO.Path]::GetFileNameWithoutExtension($uri)
Download $uri $outFile
8 changes: 4 additions & 4 deletions download_tesseract_windows.ps1
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
$uriArray =@(
"https://github.com/shimat/tesseract_vcpkg/releases/download/2020.12.29/tesseract_vcpkg.0.0.6-beta.zip"
$uriArray = @(
"https://github.com/shimat/tesseract_vcpkg/releases/download/2023.07.06/tesseract_vcpkg.0.0.8-beta.nupkg"
)

function Download($uri, $outFile) {
@@ -12,9 +12,9 @@ function Download($uri, $outFile) {
mkdir tesseract_files -Force -ErrorAction Stop | Out-Null
cd tesseract_files

[Net.ServicePointManager]::SecurityProtocol = @([Net.SecurityProtocolType]::Tls,[Net.SecurityProtocolType]::Tls11,[Net.SecurityProtocolType]::Tls12)
[Net.ServicePointManager]::SecurityProtocol = @([Net.SecurityProtocolType]::Tls, [Net.SecurityProtocolType]::Tls11, [Net.SecurityProtocolType]::Tls12)

foreach($uri in $uriArray){
foreach ($uri in $uriArray) {
$outFile = "tesseract_vcpkg.zip"
$outFileWithoutExtension = [System.IO.Path]::GetFileNameWithoutExtension($outFile)
Download $uri $outFile
59 changes: 59 additions & 0 deletions nuget/OpenCvSharp4.Extensions.nuspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
<metadata>
<id>OpenCvSharp4.Extensions</id>
<version>4.6.0.20220607</version>
<title>OpenCvSharp GDI+ extension library.</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
<projectUrl>https://github.com/shimat/opencvsharp</projectUrl>
<iconUrl>https://raw.githubusercontent.com/shimat/opencvsharp/master/nuget/icon/opencvsharp.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>OpenCvSharp GDI+ extension library.</description>
<summary>OpenCvSharp GDI+ extension library.</summary>
<releaseNotes></releaseNotes>
<copyright>Copyright 2008-2020</copyright>
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="net48">
<dependency id="OpenCvSharp4" version="4.5.3.20211226" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
<group targetFramework="netstandard2.0">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
<group targetFramework="netstandard2.1">
<dependency id="OpenCvSharp4" version="4.5.3.20211226" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
<group targetFramework="net6.0">
<dependency id="OpenCvSharp4" version="4.5.3.20211226" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
</dependencies>
<frameworkAssemblies>
<frameworkAssembly assemblyName="System.Drawing" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Core" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Xaml" targetFramework="net48" />
</frameworkAssemblies>
</metadata>
<files>
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net48\OpenCvSharp.Extensions.dll" target="lib\net48" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net48\OpenCvSharp.Extensions.pdb" target="lib\net48" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net48\OpenCvSharp.Extensions.xml" target="lib\net48" />

<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.dll" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.pdb" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.xml" target="lib\netstandard2.0" />

<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.dll" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.pdb" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.xml" target="lib\netstandard2.1" />

<file src="..\src\OpenCvSharp.Extensions\bin\Release\net6.0\OpenCvSharp.Extensions.dll" target="lib\net6.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net6.0\OpenCvSharp.Extensions.pdb" target="lib\net6.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net6.0\OpenCvSharp.Extensions.xml" target="lib\net6.0" />
</files>
</package>
14 changes: 7 additions & 7 deletions nuget/OpenCvSharp4.Windows.nuspec
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>OpenCvSharp4.Windows</id>
<version>4.3.0.20190901</version>
<version>4.6.0.20220607</version>
<title>OpenCvSharp NuGet package for x64/x86 Windows (same as OpenCvSharp3-AnyCPU)</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
@@ -16,25 +16,25 @@
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="net461">
<group targetFramework="net48">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.WpfExtensions" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.runtime.win" version="4.3.0.20190901" />
</group>
<group targetFramework="netcoreapp3.1">
<group targetFramework="netstandard2.0">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.WpfExtensions" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.runtime.win" version="4.3.0.20190901" />
</group>
<group targetFramework="netcoreapp2.1">
<group targetFramework="netstandard2.1">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.runtime.win" version="4.3.0.20190901" />
</group>
<group targetFramework="netstandard2.0">
<group targetFramework="netcoreapp3.1">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.WpfExtensions" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.runtime.win" version="4.3.0.20190901" />
</group>
<group targetFramework="netstandard2.1">
<group targetFramework="net6.0">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="OpenCvSharp4.runtime.win" version="4.3.0.20190901" />
</group>
34 changes: 18 additions & 16 deletions nuget/OpenCvSharp4.WpfExtensions.nuspec
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
<metadata>
<id>OpenCvSharp4.WpfExtensions</id>
<version>4.3.0.20190901</version>
<version>4.6.0.20220607</version>
<title>OpenCvSharp WPF extension library.</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
@@ -16,29 +16,31 @@
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="net461">
<group targetFramework="net48">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
<group targetFramework="netcoreapp3.1">
<group targetFramework="net6.0">
<dependency id="OpenCvSharp4" version="4.3.0.20190901" />
<dependency id="System.Drawing.Common" version="8.0.11" />
</group>
</dependencies>
<frameworkAssemblies>
<frameworkAssembly assemblyName="System.Drawing" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="PresentationCore" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="PresentationFramework" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Core" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="WindowsBase" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Xaml" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Drawing" targetFramework="net48" />
<frameworkAssembly assemblyName="PresentationCore" targetFramework="net48" />
<frameworkAssembly assemblyName="PresentationFramework" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Core" targetFramework="net48" />
<frameworkAssembly assemblyName="WindowsBase" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Xaml" targetFramework="net48" />
</frameworkAssemblies>
</metadata>
<files>
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net461\OpenCvSharp.WpfExtensions.dll" target="lib\net461" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net461\OpenCvSharp.WpfExtensions.pdb" target="lib\net461" />
<file src="..\src\OpenCvSharp.WpfExtensions\OpenCvSharp.WpfExtensions.xml" target="lib\net461" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net48\OpenCvSharp.WpfExtensions.dll" target="lib\net48" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net48\OpenCvSharp.WpfExtensions.pdb" target="lib\net48" />
<file src="..\src\OpenCvSharp.WpfExtensions\OpenCvSharp.WpfExtensions.xml" target="lib\net48" />

<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\netcoreapp3.1\OpenCvSharp.WpfExtensions.dll" target="lib\netcoreapp3.1" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\netcoreapp3.1\OpenCvSharp.WpfExtensions.pdb" target="lib\netcoreapp3.1" />
<file src="..\src\OpenCvSharp.WpfExtensions\OpenCvSharp.WpfExtensions.xml" target="lib\netcoreapp3.1" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net6.0-windows\OpenCvSharp.WpfExtensions.dll" target="lib\net6.0" />
<file src="..\src\OpenCvSharp.WpfExtensions\bin\Release\net6.0-windows\OpenCvSharp.WpfExtensions.pdb" target="lib\net6.0" />
<file src="..\src\OpenCvSharp.WpfExtensions\OpenCvSharp.WpfExtensions.xml" target="lib\net6.0" />
</files>
</package>
</package>
56 changes: 18 additions & 38 deletions nuget/OpenCvSharp4.nuspec
Original file line number Diff line number Diff line change
@@ -2,7 +2,7 @@
<package xmlns="http://schemas.microsoft.com/packaging/2011/08/nuspec.xsd">
<metadata>
<id>OpenCvSharp4</id>
<version>4.3.0.20190901</version>
<version>4.6.0.20220607</version>
<title>OpenCvSharp core library. A package of separate native bindings for your OS is required.</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
@@ -16,62 +16,42 @@
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="net461">
<dependency id="System.Drawing.Common" version="5.0.2" />
<dependency id="System.Runtime.CompilerServices.Unsafe" version="5.0.0" />
<dependency id="System.Memory" version="4.5.4" />
<dependency id="System.ValueTuple" version="4.5.0" />
<group targetFramework="net48">
<dependency id="System.Memory" version="4.6.3" />
<dependency id="System.ValueTuple" version="4.6.1" />
</group>
<group targetFramework="netstandard2.0">
<dependency id="System.Drawing.Common" version="5.0.2" />
<dependency id="System.Runtime.CompilerServices.Unsafe" version="5.0.0" />
<dependency id="System.Memory" version="4.5.4" />
<dependency id="System.Memory" version="4.6.3" />
</group>
<group targetFramework="netstandard2.1">
<dependency id="System.Drawing.Common" version="5.0.2" />
<dependency id="System.Runtime.CompilerServices.Unsafe" version="5.0.0" />
<dependency id="System.Memory" version="4.5.4" />
<dependency id="System.Memory" version="4.6.3" />
<dependency id="System.Runtime.CompilerServices.Unsafe" version="6.1.2" />
</group>
<group targetFramework="netcoreapp2.1">
<dependency id="System.Drawing.Common" version="5.0.2" />
<dependency id="System.Runtime.CompilerServices.Unsafe" version="5.0.0" />
<dependency id="System.Memory" version="4.5.4" />
<group targetFramework="net6.0">
<dependency id="System.Memory" version="4.6.3" />
</group>
</dependencies>
<frameworkAssemblies>
<frameworkAssembly assemblyName="System.Security" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Web" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Drawing" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Core" targetFramework="net48, net461" />
<frameworkAssembly assemblyName="System.Security" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Web" targetFramework="net48" />
<frameworkAssembly assemblyName="System.Core" targetFramework="net48" />
</frameworkAssemblies>
</metadata>
<files>
<file src="..\src\OpenCvSharp\bin\Release\net461\OpenCvSharp.dll" target="lib\net461" />
<file src="..\src\OpenCvSharp\bin\Release\net461\OpenCvSharp.xml" target="lib\net461" />
<file src="..\src\OpenCvSharp\bin\Release\net461\OpenCvSharp.pdb" target="lib\net461" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net461\OpenCvSharp.Extensions.dll" target="lib\net461" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net461\OpenCvSharp.Extensions.pdb" target="lib\net461" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\net461\OpenCvSharp.Extensions.xml" target="lib\net461" />
<file src="..\src\OpenCvSharp\bin\Release\net48\OpenCvSharp.dll" target="lib\net48" />
<file src="..\src\OpenCvSharp\bin\Release\net48\OpenCvSharp.xml" target="lib\net48" />
<file src="..\src\OpenCvSharp\bin\Release\net48\OpenCvSharp.pdb" target="lib\net48" />

<file src="..\src\OpenCvSharp\bin\Release\netstandard2.0\OpenCvSharp.dll" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp\bin\Release\netstandard2.0\OpenCvSharp.pdb" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp\bin\Release\netstandard2.0\OpenCvSharp.xml" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.dll" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.pdb" target="lib\netstandard2.0" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.0\OpenCvSharp.Extensions.xml" target="lib\netstandard2.0" />

<file src="..\src\OpenCvSharp\bin\Release\netstandard2.1\OpenCvSharp.dll" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp\bin\Release\netstandard2.1\OpenCvSharp.pdb" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp\bin\Release\netstandard2.1\OpenCvSharp.xml" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.dll" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.pdb" target="lib\netstandard2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netstandard2.1\OpenCvSharp.Extensions.xml" target="lib\netstandard2.1" />

<file src="..\src\OpenCvSharp\bin\Release\netcoreapp2.1\OpenCvSharp.dll" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp\bin\Release\netcoreapp2.1\OpenCvSharp.pdb" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp\bin\Release\netcoreapp2.1\OpenCvSharp.xml" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netcoreapp2.1\OpenCvSharp.Extensions.dll" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netcoreapp2.1\OpenCvSharp.Extensions.pdb" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp.Extensions\bin\Release\netcoreapp2.1\OpenCvSharp.Extensions.xml" target="lib\netcoreapp2.1" />
<file src="..\src\OpenCvSharp\bin\Release\net6.0\OpenCvSharp.dll" target="lib\net6.0" />
<file src="..\src\OpenCvSharp\bin\Release\net6.0\OpenCvSharp.pdb" target="lib\net6.0" />
<file src="..\src\OpenCvSharp\bin\Release\net6.0\OpenCvSharp.xml" target="lib\net6.0" />
</files>
</package>
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFrameworks>netstandard2.0;netstandard2.1;netcoreapp2.1;</TargetFrameworks>
<TargetFrameworks>netstandard2.0;netstandard2.1;net6.0;</TargetFrameworks>
<NoBuild>true</NoBuild>
<IncludeBuildOutput>false</IncludeBuildOutput>
<NuspecFile>OpenCvSharp4.runtime.ubuntu.18.04-x64.nuspec</NuspecFile>
<NuspecFile>OpenCvSharp4.official.runtime.linux-x64.nuspec</NuspecFile>
<NuspecProperties></NuspecProperties>
<NuspecBasePath></NuspecBasePath>
<!--<IncludeSymbols>true</IncludeSymbols>
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>OpenCvSharp4.runtime.ubuntu.18.04-x64</id>
<version>4.3.0.20191030</version>
<title>OpenCvSharp native bindings for ubuntu.18.04-x64</title>
<id>OpenCvSharp4.official.runtime.linux-x64</id>
<version>4.6.0.20220608</version>
<title>OpenCvSharp native bindings for Linux-x64</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
<!--<licenseUrl>https://opensource.org/licenses/BSD-3-Clause</licenseUrl>-->
<projectUrl>https://github.com/shimat/opencvsharp</projectUrl>
<iconUrl>https://raw.githubusercontent.com/shimat/opencvsharp/master/nuget/icon/opencvsharp.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Internal implementation package for OpenCvSharp to work on Ubuntu 18.04</description>
<summary>Internal implementation package for OpenCvSharp to work on Ubuntu 18.04</summary>
<description>Internal implementation package for OpenCvSharp to work on Linux</description>
<summary>Internal implementation package for OpenCvSharp to work on Linux</summary>
<releaseNotes></releaseNotes>
<copyright>Copyright 2008-2019</copyright>
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="netstandard2.0"></group>
<group targetFramework="netstandard2.1"></group>
<group targetFramework="netcoreapp2.1"></group>
<group targetFramework="net6.0"></group>
</dependencies>
<frameworkAssemblies>
</frameworkAssemblies>
</metadata>
<files>
<file src="libOpenCvSharpExtern.so" target="runtimes/ubuntu.18.04-x64/native" />
<file src="libOpenCvSharpExtern.so" target="runtimes/linux-x64/native" />
</files>
</package>
Original file line number Diff line number Diff line change
@@ -3,10 +3,10 @@
<TargetFrameworks>netstandard2.0;netstandard2.1;netcoreapp2.1;</TargetFrameworks>
<NoBuild>true</NoBuild>
<IncludeBuildOutput>false</IncludeBuildOutput>
<NuspecFile>OpenCvSharp4.runtime.ubuntu.16.04-x64.nuspec</NuspecFile>
<NuspecFile>OpenCvSharp4.runtime.linux-arm.nuspec</NuspecFile>
<NuspecProperties></NuspecProperties>
<NuspecBasePath></NuspecBasePath>
<!--<IncludeSymbols>true</IncludeSymbols>
<SymbolPackageFormat>snupkg</SymbolPackageFormat>-->
</PropertyGroup>
</Project>
</Project>
Original file line number Diff line number Diff line change
@@ -1,30 +1,30 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<package xmlns="http://schemas.microsoft.com/packaging/2010/07/nuspec.xsd">
<metadata>
<id>OpenCvSharp4.runtime.ubuntu.16.04-x64</id>
<version>4.3.0.20191030-beta1</version>
<title>OpenCvSharp native bindings for ubuntu.16.04-x64</title>
<id>OpenCvSharp4.runtime.linux-arm</id>
<version>4.3.0.20191030</version>
<title>OpenCvSharp native bindings for linux-arm</title>
<authors>shimat</authors>
<license type="expression">Apache-2.0</license>
<!--<licenseUrl>https://opensource.org/licenses/BSD-3-Clause</licenseUrl>-->
<projectUrl>https://github.com/shimat/opencvsharp</projectUrl>
<iconUrl>https://raw.githubusercontent.com/shimat/opencvsharp/master/nuget/icon/opencvsharp.png</iconUrl>
<requireLicenseAcceptance>false</requireLicenseAcceptance>
<description>Internal implementation package for OpenCvSharp to work on Ubuntu 16.04</description>
<summary>Internal implementation package for OpenCvSharp to work on Ubuntu 16.04</summary>
<description>Internal implementation package for OpenCvSharp to work on Ubuntu 18.04 for ARM</description>
<summary>Internal implementation package for OpenCvSharp to work on Ubuntu 18.04 for ARM</summary>
<releaseNotes></releaseNotes>
<copyright>Copyright 2008-2019</copyright>
<tags>Image Processing OpenCV Wrapper FFI opencvsharp</tags>
<repository type="git" url="https://github.com/shimat/opencvsharp.git" />
<dependencies>
<group targetFramework="netstandard2.0"></group>
<group targetFramework="netstandard2.1"></group>
<group targetFramework="netcoreapp2.1"></group>
<group targetFramework="netcoreapp3.1"></group>
</dependencies>
<frameworkAssemblies>
</frameworkAssemblies>
</metadata>
<files>
<file src="libOpenCvSharpExtern.so" target="runtimes/ubuntu.16.04-x64/native" />
<file src="libOpenCvSharpExtern.so" target="runtimes/linux-arm/native" />
</files>
</package>
</package>
2 changes: 1 addition & 1 deletion nuget/OpenCvSharp4.runtime.osx.10.15-x64.nuspec
Original file line number Diff line number Diff line change
@@ -19,7 +19,7 @@
<dependencies>
<group targetFramework="netstandard2.0"></group>
<group targetFramework="netstandard2.1"></group>
<group targetFramework="netcoreapp2.1"></group>
<group targetFramework="netcoreapp3.1"></group>
</dependencies>
<frameworkAssemblies>
</frameworkAssemblies>
Loading