[Gimp-user] How can I specify the tranformation matrix for a perpsective directly
Sven Neumann
sven at gimp.org
Tue Mar 11 13:56:51 PDT 2008
Hi,
On Mon, 2008-03-10 at 18:22 -0500, Leonard Evens wrote:
> I don't see a way to specify the matrix used to perform a desired
> perspective transformation manually. Of course, I can adjust it by
> dragging handles, but it would be much easier for me to calculate what I
> need and then enter the elements of the matrix by hand.
There's a PDB procedure that allows you to specify the corners of the
perspective transformation, but it doesn't allow you to give the matrix
directly. It wouldn't be difficult to add this functionality to the
Procedural Database. We would certainly consider a patch to do this.
If you want to give it a try, please have a look at the code in
tools/pdbgen/pdb/drawable_transform.pdb. From this source the wrapper
code for the procedure is generated into
app/pdb/drawable_transform_cmds.c. As you can see in
drawable_transform.pdb, all you need to do is to initialize the
transformation matrix with values taken from the procedure call.
Sven
More information about the Gimp-user
mailing list