Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 13 additions & 14 deletions .github/workflows/docfx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,22 +22,21 @@ jobs:
with:
dotnet-version: 8.0.x

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

- name: DocFX
shell: cmd
- name: Clean build outputs
shell: pwsh
run: |
choco install docfx -y
docfx docfx\docfx.json

- name: Upload DocFX packages
uses: actions/upload-artifact@v4
with:
name: docfx_site
path: ${{ github.workspace }}\docfx\_site
Get-ChildItem -Path . -Include bin,obj -Recurse -Directory | Remove-Item -Recurse -Force

- name: Install DocFX
shell: pwsh
run: dotnet tool install -g docfx

- name: Build Documentation
shell: pwsh
run: docfx docfx/docfx.json

- uses: actions/upload-pages-artifact@v3
- name: Upload GitHub Pages artifact
uses: actions/upload-pages-artifact@v4
with:
path: docfx/_site

Expand Down
25 changes: 24 additions & 1 deletion docfx/api/index.md
Original file line number Diff line number Diff line change
@@ -1 +1,24 @@
# **[OpenCvSharp](https://github.com/shimat/opencvsharp) API Reference**
# OpenCvSharp API Reference

Browse the complete API documentation for OpenCvSharp.

## Namespaces

The API is organized into the following namespaces:

- **OpenCvSharp** - Core classes and fundamental types
- **OpenCvSharp.Dnn** - Deep Neural Networks module
- **OpenCvSharp.Features2D** - 2D Features framework
- **OpenCvSharp.Face** - Face recognition
- **OpenCvSharp.Flann** - Clustering and search in multi-dimensional spaces
- **OpenCvSharp.ImgHash** - Image hashing algorithms
- **OpenCvSharp.ML** - Machine Learning
- **OpenCvSharp.Tracking** - Object tracking algorithms
- **OpenCvSharp.VideoIO** - Video I/O
- **OpenCvSharp.XFeatures2D** - Extra 2D features framework
- **OpenCvSharp.XImgProc** - Extended image processing
- **OpenCvSharp.XPhoto** - Additional photo processing algorithms

## Getting Started

See the [Introduction](../articles/intro.md) for getting started with OpenCvSharp.
57 changes: 56 additions & 1 deletion docfx/articles/intro.md
Original file line number Diff line number Diff line change
@@ -1 +1,56 @@
# Add your introductions here!
# Introduction to OpenCvSharp

OpenCvSharp is a .NET wrapper for OpenCV, one of the most popular open-source computer vision libraries.

## What is OpenCvSharp?

OpenCvSharp provides cross-platform .NET bindings for OpenCV, allowing you to use OpenCV's powerful computer vision and image processing capabilities in your .NET applications.

## Supported Platforms

- **Windows**: x64, x86, UWP
- **Linux**: Ubuntu 22.04, 24.04, ARM
- **macOS**: x64
- **WebAssembly**: Browser-based applications

## Getting Started

### Installation

Install OpenCvSharp via NuGet Package Manager:

```bash
# Core library
dotnet add package OpenCvSharp4

# Native bindings (choose one based on your platform)
dotnet add package OpenCvSharp4.runtime.win # Windows
dotnet add package OpenCvSharp4.runtime.ubuntu.24.04-x64 # Ubuntu 24.04
dotnet add package OpenCvSharp4.official.runtime.linux-x64 # Linux (generic)
```

### Quick Example

```csharp
using OpenCvSharp;

// Load an image
using var src = Cv2.ImRead("sample.jpg");

// Convert to grayscale
using var gray = new Mat();
Cv2.CvtColor(src, gray, ColorConversionCodes.BGR2GRAY);

// Apply Gaussian blur
using var blurred = new Mat();
Cv2.GaussianBlur(gray, blurred, new Size(5, 5), 0);

// Save the result
Cv2.ImWrite("output.jpg", blurred);
```

## Next Steps

- Explore the [API Reference](../api/index.md) for detailed documentation
- Check out [sample projects](https://github.com/shimat/opencvsharp/tree/main/samples)
- Join the community on [GitHub](https://github.com/shimat/opencvsharp)
44 changes: 26 additions & 18 deletions docfx/docfx.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,15 @@
{
"src": [
{
"files": ["**/*.csproj"],
"exclude": [ "**/bin/**", "**/obj/**", "**/OpenCvSharp.DebuggerVisualizers/**" ],
"files": ["OpenCvSharp/OpenCvSharp.csproj"],
"src": "../src"
}
],
"dest": "api",
"disableGitFeatures": false,
"disableDefaultFilter": false,
"properties": {
"TargetFramework": "net6"
"TargetFramework": "net8"
}
}
],
Expand All @@ -30,39 +29,48 @@
"articles/**/toc.yml",
"toc.yml",
"*.md",
"../*.md",
"../*.md"
]
}
],
"resource": [
{
"files": [
"images/**"
]
}
],
"overwrite": [
{
"files": [
"apidoc/**.md"
],
"exclude": [
"obj/**",
"_site/**"
"images/**",
"../web/img/**"
]
}
],
"dest": "_site",
"globalMetadata": {
"_appName": "OpenCvSharp",
"_appTitle": "OpenCvSharp Documentation",
"_appFooter": "OpenCvSharp - .NET wrapper for OpenCV",
"_enableSearch": true,
"_enableNewTab": true,
"_disableContribution": false,
"_gitContribute": {
"repo": "https://github.com/shimat/opencvsharp",
"branch": "main"
},
"_gitUrlPattern": "github",
"pdf": false
},
"globalMetadataFiles": [],
"fileMetadataFiles": [],
"template": [
"default"
"default",
"modern",
"templates/material"
],
"postProcessors": [],
"markdownEngineName": "markdig",
"noLangKeyword": false,
"keepFileLink": false,
"cleanupCacheHistory": false,
"disableGitFeatures": false
"disableGitFeatures": false,
"xref": [
"https://xref.docs.microsoft.com/query?uid={uid}"
]
}
}
35 changes: 34 additions & 1 deletion docfx/index.md
Original file line number Diff line number Diff line change
@@ -1 +1,34 @@
# **[OpenCvSharp](https://github.com/shimat/opencvsharp) API Reference**
# OpenCvSharp Documentation

Welcome to the **OpenCvSharp** documentation!

OpenCvSharp is a cross-platform .NET wrapper for OpenCV, providing a rich set of APIs for computer vision and image processing.

## Quick Links

- [Introduction](articles/intro.md) - Get started with OpenCvSharp
- [API Reference](api/index.md) - Complete API documentation
- [GitHub Repository](https://github.com/shimat/opencvsharp) - Source code and issues

## Features

- ✅ Cross-platform support (Windows, Linux, macOS, WebAssembly)
- ✅ .NET 8, 10, and later support
- ✅ Comprehensive OpenCV API coverage
- ✅ WPF and GDI+ extensions
- ✅ NuGet packages for easy installation

## Installation

Install via NuGet:

```bash
dotnet add package OpenCvSharp4
dotnet add package OpenCvSharp4.runtime.win # For Windows
```

## Resources

- [NuGet Packages](https://www.nuget.org/packages?q=opencvsharp)
- [GitHub Issues](https://github.com/shimat/opencvsharp/issues)
- [OpenCV Official Documentation](https://docs.opencv.org/)
Loading
Loading