bit_lshift — 图像所有像素的左移。
bit_lshift(Image : ImageLShift : Shift : )
算子 bit_lshift 对输入图像的所有像素进行逐位“左移”运算。该“左移”运算符的语义对应于 C 语言中相应类型(有符号字符、无符号字符、短整型、无符号短整型、整型/长整型)的
“<<” 运算符。若发生溢出,结果将限制在相应像素类型的最大值范围内。仅处理图像定义范围内的像素。
单次调用可处理多张图像。每张输入图像将生成一张输出图像。
Image (输入对象) (multichannel-)image(-array) → object (byte / direction / cyclic / int1 / int2 / uint2 / int4)
输入图像。
ImageLShift (输出对象) (multichannel-)image(-array) → object (byte / direction / cyclic / int1 / int2 / uint2 / int4)
通过移位操作获得的结果图像。
Shift (输入控制) integer → (integer)
位移值。
默认值: 3
建议值: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 20, 24, 30, 31
最小增量: 1
建议增量: 1
read_image(&ByteImage,"fabrik"); convert_image_type(ByteImage,&Int2Image,"int2"); bit_lshift(Int2Image,&FullInt2Image,8);
如果图像类型正确且
Shift 具有有效值,则算子 bit_lshift 返回值 2 ( H_MSG_TRUE )。当输入为空(无可用输入图像)时,可设置行为通过算子 set_system(::'no_object_result',<Result>:)。如有必要,则抛出异常。
基础