An lightweight image resizing server written in C# .NET Core
Picfit is a reusable .NET Core server to upload images with scale preprocessing. I selected preprocessing workflow beacause postprocessing more expensive. Picfit will supports multiple storage backends and multiple processing implementations.
I could not come up with a good name for this application so I used picfit name
If you want to improve this application, join the team:)
Picfit has restfull interface with Swagger documentation.
- Download and install .net core 2.2, git
- Download it:
git clone https://github.com/spqr911/picfit.git
- Build it:
dotnet build
- Run it:
dotnet run
To configure application, you should change appsettings.json
{
"storage": {
"type": "fs",
"location": "D:\\git\\picfit\\_static"
},
"imagepreprocessing": {
"type": "imagesharp",
"scales": [
75,
100,
150,
200
]
},
}
storage
can be:
- type:fs - generated images stored in your File system
- type:s3 - generated images stored in Amazon S3 (in the future)
- type:... - you can write custom implementation
- location - folder location for
fs
type
imagepreprocessing
can be:
type:imagesharp
- use SixLabors/ImageSharp library to rescale imagestype:...
- you can write custom implementationscales: [75,100,150,200]
- how much rescale images you can store instorage
, the number of scales array is percentage of original image.
Picfit currently supports the following image formats:
image/jpeg
with the keywordjpg
orjpeg
image/png
with the keywordpng
image/gif
with the keywordgif
image/bmp
with the keywordbmp