2

我想使用色调和亮度方法在单张图片中绘制二维矢量场,即色调到方向(或者说,相位),亮度到幅度。这种方法通常用于可视化例如从洛伦兹显微镜重建的磁畴、涡流等。

作为输入,我有两个大小为 1024*1024 的图像,像素包含矢量场的 X 和 Y 分量的大小。

由于 DM 不支持原生 HSL 配色方案,所以我认为应该先使用一组自定义函数将 HSL 转换为 RGB...

4

1 回答 1

1

You can only use RGB images in DigitalMicrograph, so you will have to do the conversion from HSB to RGB in your script code, and then create the according RGB image. Luckily, there is a demonstration script on the Gatan script resources webpage which does exactly that! You can basically use the script as it is shown there.

Gatan Script Resources

Link to script-file: Display as HSB

Note, the script uses complex images as input - just as a convenient container to combine two images into a single one. The test function demonstrates this though.

于 2015-08-02T18:51:04.987 回答