Skip to content

Extending examples #99

Open
Open
@lofcz

Description

@lofcz

Issue
Current index page with tutorials https://kleisauke.github.io/net-vips/tutorial/getting_started.html could be improved with more snippets which would save new users (like me) some time. These are some basic things most web app devs need:

  1. Resizing to exact size:
    First try after migrating to libvips from another image library: image.ThumbnailImage(width: w, height: h);
    Actual way to do it: image.ThumbnailImage(width: w, height: h, size: "force");

2) Saving gif image:
First attempt: image.WriteToFile('somepath.gif');
Actual way to do it: 1) Uninstall nuget with dll binaries. 2) Download binaries from libvips, mark as embedded resources 3) image.Magicksave("somepath.gif", "gif");

Since v8.12.0-rc1: https://www.libvips.org/2021/11/14/What's-new-in-8.12.html#better-gif-save

Describe the solution you'd like
Consider adding these to the examples.

Describe alternatives you've considered
Do nothing, keep things as is. It was hard to write, it should be hard to use.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions