![]() |
VOOZH | about |
dotnet add package Plugin.Toolkit.Image --version 1.1.2
NuGet\Install-Package Plugin.Toolkit.Image -Version 1.1.2
<PackageReference Include="Plugin.Toolkit.Image" Version="1.1.2" />
<PackageVersion Include="Plugin.Toolkit.Image" Version="1.1.2" />Directory.Packages.props
<PackageReference Include="Plugin.Toolkit.Image" />Project file
paket add Plugin.Toolkit.Image --version 1.1.2
#r "nuget: Plugin.Toolkit.Image, 1.1.2"
#:package Plugin.Toolkit.Image@1.1.2
#addin nuget:?package=Plugin.Toolkit.Image&version=1.1.2Install as a Cake Addin
#tool nuget:?package=Plugin.Toolkit.Image&version=1.1.2Install as a Cake Tool
👁 NuGet
👁 .NET MAUI
👁 License: MIT
👁 Platform
👁 Platform
👁 Platform
👁 Platform
Plugin.Toolkit.Image is a .NET MAUI library that provides an enhanced image viewing experience by leveraging native platform capabilities. This approach ensures optimal performance and a seamless user experience. Currently, the library supports Android and features pinch-to-zoom functionality. Future updates will include support for iOS and additional image manipulation features.
You can install the plugin via NuGet:
Install-Package Plugin.Toolkit.Image
Register:
In your `MauiProgram.cs` file:
using Plugin.Toolkit.Image; // <-- add this
public static class MauiProgram
{
public static MauiApp CreateMauiApp()
{
var builder = MauiApp.CreateBuilder();
builder
.UseMauiApp<App>()
.UseImageToolkit() // <-- add this
.ConfigureFonts(fonts =>
{
fonts.AddFont("OpenSans-Regular.ttf", "OpenSansRegular");
fonts.AddFont("OpenSans-Semibold.ttf", "OpenSansSemibold");
});
return builder.Build();
}
}
Using Local Image:
string imagePath = "dotnet_bot.png";
ImageToolkit.FromLocal(imagePath);
Using Url:
string imagePath = "https://example.com/image";
ImageToolkit.FromUrl(imagePath, ImageToolkit.CacheType.Disk);
Using Base64:
string base64 = "data:image/png;base64,iVBORw0KGgoAAAANSU....";
ImageToolkit.FromBase64(base64);
Take Image From Camera:
ImageToolkit imageToolkit = new ImageToolkit();
var imgStream = await imageToolkit.ImageRequest.TakeImage();
image_sources.Source = ImageSource.FromStream(() => imgStream);
Take Image From Camera With Resize:
ImageToolkit imageToolkit = new ImageToolkit();
var imgStream = await imageToolkit.ImageRequest.TakeImage(new TakePickOptions()
{
Height = 1280,
Width = 720
});
image_sources.Source = ImageSource.FromStream(() => imgStream);
Pick Image From Gallery:
ImageToolkit imageToolkit = new ImageToolkit();
var imgStream = await imageToolkit.ImageRequest.PickImage();
image_sources.Source = ImageSource.FromStream(() => imgStream);
Take Image From Camera As Base64:
ImageToolkit imageToolkit = new ImageToolkit();
string base64 = await imageToolkit.ImageRequest.TakeImageAsBase64();
Pick Image From Gallery As Base64:
ImageToolkit imageToolkit = new ImageToolkit();
string base64 = await imageToolkit.ImageRequest.PickImageAsBase64();
The repository includes a sample MAUI project demonstrating the usage of the plugin. You can find it in the samples directory.
Contributions are welcome! Please open an issue or submit a pull request.
If you have any questions or suggestions, please feel free to contact me at andyapin@gmail.com
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net8.0 net8.0 is compatible. net8.0-android net8.0-android was computed. net8.0-android34.0 net8.0-android34.0 is compatible. net8.0-browser net8.0-browser was computed. net8.0-ios net8.0-ios was computed. net8.0-ios18.0 net8.0-ios18.0 is compatible. net8.0-maccatalyst net8.0-maccatalyst was computed. net8.0-macos net8.0-macos was computed. net8.0-tvos net8.0-tvos was computed. net8.0-windows net8.0-windows was computed. net8.0-windows10.0.19041 net8.0-windows10.0.19041 is compatible. net9.0 net9.0 is compatible. net9.0-android net9.0-android was computed. net9.0-android35.0 net9.0-android35.0 is compatible. net9.0-browser net9.0-browser was computed. net9.0-ios net9.0-ios was computed. net9.0-ios18.0 net9.0-ios18.0 is compatible. net9.0-maccatalyst net9.0-maccatalyst was computed. net9.0-macos net9.0-macos was computed. net9.0-tvos net9.0-tvos was computed. net9.0-windows net9.0-windows was computed. net9.0-windows10.0.19041 net9.0-windows10.0.19041 is compatible. net10.0 net10.0 was computed. net10.0-android net10.0-android was computed. net10.0-browser net10.0-browser was computed. net10.0-ios net10.0-ios was computed. net10.0-maccatalyst net10.0-maccatalyst was computed. net10.0-macos net10.0-macos was computed. net10.0-tvos net10.0-tvos was computed. net10.0-windows net10.0-windows was computed. |
This package is not used by any NuGet packages.
This package is not used by any popular GitHub repositories.