[英]Image processing and Computer Vision
I would like to use Smalltalk (Pharo) to better refactor my image processing and computer vision code/algorithms, written in other languages.我想使用 Smalltalk (Pharo) 来更好地重构我用其他语言编写的图像处理和计算机视觉代码/算法。 I have not found a lot of examples online where Smalltalk is used for processing images (or video frames).
我还没有在网上找到很多使用 Smalltalk 处理图像(或视频帧)的例子。 I would like to know whether
我想知道是否
i) there is an opencv/image/computer vision library available for Smalltalk that is easily installed or i) 有一个可用于 Smalltalk 的 opencv/图像/计算机视觉库,它易于安装或
ii) someone could give an example of how to access the pixel data in an image and threshold it using Smalltalk. ii) 有人可以举例说明如何访问图像中的像素数据并使用 Smalltalk 对其进行阈值处理。
最近在https://github.com/feenkcom/gt4opencv 上绑定了 OpenCV(用于 Pharo 7 atm)
For the first question, you can maybe write your own interface using FFI to the OpenCV C-API. 对于第一个问题,您可以使用FFI将自己的界面编写到OpenCV C-API。 For the second question, I think it's easy to use
ImageReadWriter formFromFileNamed
and then can use pixelValueAt:
to read the value, threshold, and then write back by pixelValueAt:put:
. 对于第二个问题,我认为使用
ImageReadWriter formFromFileNamed
很容易,然后可以使用pixelValueAt:
读取值,阈值,然后通过pixelValueAt:put:
回写pixelValueAt:put:
.
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.