New ScreenPanel
This commit is contained in:
22
script/image11.py
Executable file
22
script/image11.py
Executable file
@@ -0,0 +1,22 @@
|
||||
run("pip")
|
||||
|
||||
orig = load_image("{data}/img/img2.png")
|
||||
|
||||
#orig.show()
|
||||
|
||||
#Resize
|
||||
resized = resize(orig, 300,300)
|
||||
|
||||
#Sub-image
|
||||
crop=sub_image(orig,10,20,50,30)
|
||||
|
||||
bin_im = bin_image(orig,2)
|
||||
new_im = new_image(256, 256, "color")
|
||||
pad_im = pad_image(orig, 1, 2, 3, 4, Color.RED)
|
||||
|
||||
|
||||
|
||||
stack=create_stack([orig,resized,crop, bin_im, new_im, pad_im])
|
||||
save_image(stack,context.setup.expandPath("{data}/img/out.tiff") ,"tiff")
|
||||
stack.show()
|
||||
|
||||
Reference in New Issue
Block a user