Skip to content
Closed
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
20 changes: 0 additions & 20 deletions CI/job_templates/build_drawing_libraries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,26 +31,6 @@ jobs:
- checkout: self
displayName: Checkout IronSoftware.Drawing repository
lfs: true
- task: UseDotNet@2
displayName: 'Install .Netcoreapp3.1 Core sdk'
inputs:
packageType: 'sdk'
version: '3.x'
- task: UseDotNet@2
displayName: 'Install .NET5 sdk'
inputs:
packageType: 'sdk'
version: '5.x'
- task: UseDotNet@2
displayName: 'Install .NET6 sdk'
inputs:
packageType: 'sdk'
version: '6.x'
- task: UseDotNet@2
displayName: 'Install .NET7 sdk'
inputs:
packageType: 'sdk'
version: '7.x'
- task: UseDotNet@2
displayName: 'Install .NET7 sdk'
inputs:
Expand Down
54 changes: 3 additions & 51 deletions CI/stage_templates/run_tests_on_pool.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,59 +32,11 @@ stages:
framework: 'net472'
architecture: ''
buildConfiguration: $(Configuration)
# Windows .NET Core x64 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}netcore
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'netcoreapp3.1'
architecture: ''
buildConfiguration: $(Configuration)
# Windows .NET Core x86 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}netcorex86
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'netcoreapp3.1'
architecture: '.x86'
buildConfiguration: $(Configuration)
# Windows .NET 6.0 x86 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}net60x86
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'net60'
architecture: '.x86'
buildConfiguration: $(Configuration)
# Windows .NET 7.0 x86 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}net70x86
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'net70'
architecture: '.x86'
buildConfiguration: $(Configuration)
# .NET 5.0 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}net50
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'net50'
architecture: ''
buildConfiguration: $(Configuration)
# .NET 6.0 x64 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}net60
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'net60'
architecture: ''
buildConfiguration: $(Configuration)
# .NET 7.0 x64 Tests
# .NET 8.0 Tests
- template: ../job_templates/test_drawing_libraries.yml
parameters:
name: UnitTest${{ parameters.OSPlatform }}net70
name: UnitTest${{ parameters.OSPlatform }}net80
OSPlatform: ${{ parameters.OSPlatform }}
framework: 'net70'
framework: 'net80'
architecture: ''
buildConfiguration: $(Configuration)
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFrameworks>net472;netcoreapp3.1;net50;net60;net70</TargetFrameworks>
<TargetFrameworks>net472;net80</TargetFrameworks>
<LangVersion>latest</LangVersion>
<CheckEolTargetFramework>false</CheckEolTargetFramework>
<IsPackable>false</IsPackable>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ namespace IronSoftware.Drawing
/// self-memory-managing and does not need to be explicitly 'used'
/// or 'disposed'.</para>
/// </summary>
public partial class AnyBitmap : IDisposable
public partial class AnyBitmap : IDisposable, IAnyImage
{
private bool _disposed = false;
private Image Image { get; set; }
Expand Down Expand Up @@ -182,6 +182,12 @@ public byte[] ExportBytes(
return byteArray;
}

/// <inheritdoc/>
public byte[] ExportBytesAsJpg()
{
return this.ExportBytes(ImageFormat.Jpeg);
}

/// <summary>
/// Exports the Bitmap as a file encoded in the
/// <see cref="ImageFormat"/> of your choice.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<NoWarn>CS8002</NoWarn>
<Platforms>AnyCPU</Platforms>
<SignAssembly>true</SignAssembly>
<TargetFrameworks>netstandard2.0;netstandard2.1;net60</TargetFrameworks>
<TargetFrameworks>netstandard2.0;net60</TargetFrameworks>
<TransformOnBuild>true</TransformOnBuild>
</PropertyGroup>

Expand All @@ -24,7 +24,8 @@
<ItemGroup>
<PackageReference Include="BitMiracle.LibTiff.NET" Version="2.4.649" />
<PackageReference Include="Microsoft.Maui.Graphics" Version="7.0.92" />
<PackageReference Include="SkiaSharp" Version="2.88.7" />
<PackageReference Include="SkiaSharp" Version="2.88.7" />
<PackageReference Include="IronSoftware.Common" Version="2024.9.38" />
<PackageReference Include="SkiaSharp.Svg" Version="1.60.0" />
<PackageReference Include="System.Drawing.Common" Version="6.0.0" />
<PackageReference Include="System.Memory" Version="4.5.5" />
Expand All @@ -34,13 +35,13 @@
<Choose>
<When Condition="'$(TargetFramework)' == 'net60'">
<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.4" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.3" />
<PackageReference Include="SixLabors.ImageSharp" Version="3.1.5" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="2.1.4" />
</ItemGroup>
</When>
<Otherwise>
<ItemGroup>
<PackageReference Include="SixLabors.ImageSharp" Version="2.1.8" />
<PackageReference Include="SixLabors.ImageSharp" Version="2.1.9" />
<PackageReference Include="SixLabors.ImageSharp.Drawing" Version="1.0.0" />
</ItemGroup>
</Otherwise>
Expand Down
1 change: 1 addition & 0 deletions IronSoftware.Drawing/nuget.config
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
<packageSources>
<clear />
<add key="nuget.org" value="https://api.nuget.org/v3/index.json" />
<add key="Common" value="https://pkgs.dev.azure.com/ironcoders/IronCommon/_packaging/IronCommon/nuget/v3/index.json" />
</packageSources>
</configuration>
15 changes: 8 additions & 7 deletions NuGet/IronSoftware.Drawing.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -39,27 +39,28 @@ Supports:

For general support and technical inquiries, please email us at: support@ironsoftware.com</description>
<summary>IronSoftware.System.Drawing is an open-source solution for .NET developers to replace System.Drawing.Common with a universal and flexible library.</summary>
<releaseNotes>- Efficient compression significantly reduces output TIFF file size (Up to 80%).
- Automatic compression when creating multi-frame TIFFs.
- Fix the issue of exception error thrown when converting Bitmap to AnyBitmap.</releaseNotes>
<releaseNotes>- Internal improvement of the library functionality</releaseNotes>
<copyright>Copyright © Iron Software 2022-2024</copyright>
<tags>Images, Bitmap, SkiaSharp, SixLabors, BitMiracle, Maui, SVG, TIFF, TIF, GIF, JPEG, PNG, Color, Rectangle, Drawing, C#, VB.NET, ASPX, create, render, generate, standard, netstandard2.0, core, netcore</tags>
<repository type="git" url="https://github.com/iron-software/IronSoftware.Drawing.Common" commit="$commit$" />
<dependencies>
<group targetFramework="netstandard2.0">
<dependency id="SixLabors.ImageSharp" version="2.1.8" />
<dependency id="IronSoftware.Common" version="2024.9.38" />
<dependency id="SixLabors.ImageSharp" version="2.1.9" />
<dependency id="SixLabors.ImageSharp.Drawing" version="1.0.0" />
<dependency id="BitMiracle.LibTiff.NET" version="2.4.649" />
<dependency id="System.Memory" version="4.5.5" />
</group>
<group targetFramework="net60">
<dependency id="SixLabors.ImageSharp" version="3.1.4" />
<dependency id="SixLabors.ImageSharp.Drawing" version="2.1.3" />
<dependency id="IronSoftware.Common" version="2024.9.38" />
<dependency id="SixLabors.ImageSharp" version="3.1.5" />
<dependency id="SixLabors.ImageSharp.Drawing" version="2.1.4" />
<dependency id="BitMiracle.LibTiff.NET" version="2.4.649" />
<dependency id="System.Memory" version="4.5.5" />
</group>
<group targetFramework="MonoAndroid10.0">
<dependency id="SixLabors.ImageSharp" version="2.1.8" />
<dependency id="IronSoftware.Common" version="2024.9.38" />
<dependency id="SixLabors.ImageSharp" version="2.1.9" />
<dependency id="SixLabors.ImageSharp.Drawing" version="1.0.0" />
<dependency id="BitMiracle.LibTiff.NET" version="2.4.649" />
<dependency id="System.Memory" version="4.5.5" />
Expand Down
Loading