P
P
Phoen1xx2020-11-23 00:35:18
Node.js
Phoen1xx, 2020-11-23 00:35:18

How to crop images using opencv4nodejs?

Hello. Tell me who knows, I connected the opencv4nodejs library, I get an image from a file using imread, which returns a Mat object. I need to crop exactly 200px from the bottom of the image, I've searched through all the documentation and all the class methods, but I can't find how to do it.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
Phoen1xx, 2020-11-23
@Phoen1xx

Answer:

const region = img.getRegion(new cv.Rect(x, y, width, height))

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question