Skip to content

Runnung MagicScaler API in .net core middleware #99

Answered by saucecontrol
Astatira asked this question in Q&A
Discussion options

You must be logged in to vote

Howdy!

You shouldn't have any issue at all using MagicScaler in a middleware component. You don't need to save to a file, just pass any writeable Stream (e.g. MemoryStream, or even better, RecyclableMemoryStream) for the output parameter to ProcessImage.

The tutorial mentioned in that MSDN social post should have everything you need to get started. You can ignore all the Skia code and particularly the workarounds for Skia quirks and limitations, as MagicScaler will do the correct thing by default when you use ProcessImage.

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@Astatira
Comment options

@saucecontrol
Comment options

@Astatira
Comment options

Answer selected by Astatira
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants