ImageDev

ImageDev C#

This section details how to start with ImageDev .NET.
The following information has been mostly tested on Windows with Visual 2017 on .NET Framework and .NET Core projects.

ImageDev C# can be installed with the NuGet package archives available in the ImageDev download page.

Prerequisites

Supported platforms

ImageDev requires a .NET platform compatible with .NET Standard 2.0 or 2.1, which means:

Package deployment

ImageDev C# is distributed as NuGet packages available in downloadable archives.

To launch ImageDev examples or to create a new ImageDev .NET project, you need to: Thereafter we will consider that:

NuGet package manager setup

To make ImageDev packages available for a .NET project, the appropriate package sources must be added.
On Windows, when using Visual Studio, they can be created from the option menu. In other cases, they can be created by command line or with a configuration file.

This section explains how to create two package sources: If you are using Visual Studio, the package manager must be set in PackageReference mode:

With Visual Studio

To add the new package source for all projects with Visual Studio:

With command line instructions

To add the new package source for all projects, execute the following command lines:
dotnet nuget add source "path_to_unzipped_ImageDev/nuget" --name "NuGet ImageDev archive"
dotnet nuget add source "path_to_unzipped_ImageDevExamples/nuget" --name "NuGet ImageDev Examples archive"
More information about the used command line is available on the Microsoft site.

With a configuration file

To add the new package source for only one project, you need to create a nuget.config file next to your project. This file should contain the following lines:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<packageSources>
  <add key="NuGet ImageDev archive" value="path_to_unzipped_ImageDev/nuget" />
  <add key="NuGet ImageDev Examples archive" value="path_to_unzipped_ImageDevExamples/nuget" />
</packageSources>
</configuration>
More information about the nuget.config file is available on the Microsoft site.

Launching the ImageDev examples

This section describes how to launch the examples of the ImageDev user guide tutorials.

A solution containing these examples is provided in the ImageDevExamplesNet package archive. This solution is already linked to the IOFormat library and ImageDev sample data. It is not necessary to add the NuGet ImageDev Examples archive package source to use it. You can now

Configuring a .NET project

To use ImageDev, you first need to open or create a .NET project and install the required packages.
On Windows, when using Visual Studio, they can be installed from the package manager tool. In other cases, they can be added by command line.

With Visual Studio

For a Visual Studio project, the ImageDev prepacks are managed by NuGet.

With command line instructions

To add the new package for your project, execute the following command lines from your project folder:
# Installation of ImageDev Windows package
dotnet add package ImageDev-win-x64
# or installation of ImageDev Ubuntu package
# dotnet add package ImageDev-ubuntu-x64
# To use IOFormat, for loading and saving image files, install also "IOFormat" NuGet package
dotnet add package IOFormat
# To access ImageDev sample data, install also "ImageDev.Data" NuGet package
dotnet add package ImageDev.Data
More information about the used command line is available on the Microsoft site.

Start using ImageDev

You need to add the using directives for ImageDev, and optionally for IOLink and IOFormat.
using ImageDev;
using IOLink;
using IOFormat; 
You are now ready to write your first ImageDev code.