parupalu
parupalu

Reputation: 51

How to compute the 4 X 4 homogeneous transformation matrix for an image in python

I have an image and I want to obatain the homogeneous transformation matrix of that Image in python. Image. Can someone please help me?

Thank you very much.

Upvotes: 2

Views: 3007

Answers (1)

parthagar
parthagar

Reputation: 941

A translation matrix (a transformation matrix for translation) is of the form -

[[1, 0, 0, tx],
 [0, 1, 0, ty],
 [0, 0, 1, tz],
 [0, 0, 0, 1]]

You could use imutils library which has convenient implementations of these transformations or refer to the official opencv docs.

I hope this helps.

Upvotes: 1

Related Questions