Yarhl icon indicating copy to clipboard operation
Yarhl copied to clipboard

Implement API for Images

Open pleonex opened this issue 7 years ago • 2 comments

This API will go under namespace Yarhl.Media.Graphic and it should provide API to implement palette and image based formats. Including indexed image and RGB image. It would be able to export and import PNG files.

Proof-of-concept / Experimental implementation: https://github.com/SceneGate/Texim It has proved to be valid and we could implement several file formats, including the ones from NDS.

TODO:

  • [x] Support sprites in the framework
  • [x] Implement NCER
  • [ ] Validate the framework with 3DS NDS textures
  • [ ] Validate the framework with PS2 graphics (TIM?)
  • [ ] Move the code of Texim between a new library Yarhl.Media.Graphics and Ekona repository
  • [x] Validate the framework with the SceneGate UIs
  • [ ] Implement tests
  • [ ] Add documentation

pleonex avatar Oct 06 '18 19:10 pleonex

Since System.Drawing is not part of .NET Standard and it uses a very old technology with limitations (GDI+) we should consider other alternatives. In the past I used EmguCV but it was really tricky to compile and use. ImageSharp looks like a great candidate.

pleonex avatar Dec 08 '18 11:12 pleonex

As ImageSharp is gonna be AGPLv3 license we need to think about alternatives, this is the list @pleonex did the 2nd of August:

  • https://github.com/matgr1/FreeImage-dotnet-core/ (not likely, port from C, not very active, poor docs).
  • https://github.com/dlemstra/Magick.NET/
  • https://github.com/mono/SkiaSharp/

More info: https://devblogs.microsoft.com/dotnet/net-core-image-processing/

priverop avatar Oct 19 '19 12:10 priverop