summaryrefslogtreecommitdiff
path: root/macros/copymakeborder.sci
diff options
context:
space:
mode:
Diffstat (limited to 'macros/copymakeborder.sci')
-rw-r--r--macros/copymakeborder.sci20
1 files changed, 20 insertions, 0 deletions
diff --git a/macros/copymakeborder.sci b/macros/copymakeborder.sci
new file mode 100644
index 0000000..3f1d567
--- /dev/null
+++ b/macros/copymakeborder.sci
@@ -0,0 +1,20 @@
+function new_image = copymakeborder(image, top, bottom, left, right, borderType, varargin)
+
+ [lhs, rhs] = argn(0)
+
+ image_list = mattolist(image)
+
+ select rhs
+ case 6 then
+ out = opencv_copymakeborder(image_list, top, bottom, left, right, borderType)
+
+ case 7 then
+ out = opencv_copymakeborder(image_list, top, bottom, left, right, borderType, varargin(1))
+ end
+
+ sz = size(out)
+ for i = 1 : sz
+ new_image(:, :, i) = out(i)
+ end
+
+endfunction