Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create and composite linear gradients over image #287

Open
lukestoward opened this issue Jun 7, 2022 · 0 comments
Open

Create and composite linear gradients over image #287

lukestoward opened this issue Jun 7, 2022 · 0 comments

Comments

@lukestoward
Copy link

lukestoward commented Jun 7, 2022

I have been experimenting with govips and I can't seem to figure out how to create a linear gradient of black fading to transparent that I can composite on top of another image.

The equivalent of running these vips commands:

$ vipsheader nina.png 
nina.jpg: 6048x4032 uchar, 3 bands, srgb, pngload
$ vips grey t1.v 4032 6048 --uchar
$ vips rot t1.v t2.v d270
$ vips bandjoin "nina.png t2.v" x.png

It appears this is possible with the php-vips package as John Cupitt recently described how in this thread (near the bottom), however the php API is quite different to the govips API.

I've also seen a similar question here where it's possible in Python.

Is anyone able to suggest a way that I could achieve this? I recently raised the question on StackOverflow, but I've had no help thus far, so I would be super grateful for any assistance.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant