B
B
binore2015-12-20 00:15:32
PHP
binore, 2015-12-20 00:15:32

How to insert an image in php under "slanted"?

I have two images. It is necessary to impose the first on the second, but not just as a rectangle, but with a "slope". That is, the area is set by 4 points into which the distorted image should be inserted. What is the best way to do this (and maybe there are ready-made libraries)?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Stalker_RED, 2015-12-20
@binore

GD doesn't know perspective. Imagemagick - www.imagemagick.org/Usage/distorts/#perspective

P
Pavel K, 2015-12-20
@PavelK

php.net/manual/ru/book.image.php

A
Alexander Taratin, 2015-12-20
@Taraflex

I am writing a similar thing now, but as part of another application.
You will need to implement an extension for php based on opencv
Here is a comprehensive article opencv-code.com/tutorials/automatic-perspective-co ... ::getPerspectiveTransform its coordinates)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question