Superimpose image

From UBot Studio
(Difference between revisions)
Jump to: navigation, search
(Created page with "'''superimpose image''' is a command that superimposes one image over another. The command can also resize the foreground image before superimposing, and the resulting image i...")
 
(Example)
 
(One intermediate revision by one user not shown)
Line 3: Line 3:
 
== Parameters ==
 
== Parameters ==
  
* '''Background File:''' The path to the image that will serve as the background. This needs to be a valid file path on your system.
+
'''Background File:''' The path to the image that will serve as the background. This needs to be a valid file path on your system.
  
* '''Foreground File:''' The path to the image that will be superimposed onto the background image. This too needs to be a valid file path on your system.
+
'''Foreground File:''' The path to the image that will be superimposed onto the background image. This too needs to be a valid file path on your system.
  
* '''Output Image:''' The path where the modified image will be saved. This needs to be a valid location on your system.
+
'''Output Image:''' The path where the modified image will be saved. This needs to be a valid location on your system.
  
* '''Resize:''' (optional) A flag determining whether the foreground image should be resized to match the background image before superimposing. The default option is True, meaning the foreground image will be resized.
+
'''Resize:''' (optional) A flag determining whether the foreground image should be resized to match the background image before superimposing. The default option is True, meaning the foreground image will be resized.
  
 
== Example ==
 
== Example ==
 
<pre>
 
<pre>
superimpose image("background.jpg", "foreground.png", "output.jpg", true)
+
superimpose image("background.jpg", "foreground.png", "output.jpg", True)
 
</pre>
 
</pre>
  
 
The output will be a new image saved at "output.jpg", which consists of "foreground.png" superimposed over "background.jpg". If the dimensions of the two images are not the same, "foreground.png" will be resized to match "background.jpg" before superimposing. The original images will not be altered.
 
The output will be a new image saved at "output.jpg", which consists of "foreground.png" superimposed over "background.jpg". If the dimensions of the two images are not the same, "foreground.png" will be resized to match "background.jpg" before superimposing. The original images will not be altered.

Latest revision as of 02:57, 4 July 2023

superimpose image is a command that superimposes one image over another. The command can also resize the foreground image before superimposing, and the resulting image is saved to a specified path.

[edit] Parameters

Background File: The path to the image that will serve as the background. This needs to be a valid file path on your system.

Foreground File: The path to the image that will be superimposed onto the background image. This too needs to be a valid file path on your system.

Output Image: The path where the modified image will be saved. This needs to be a valid location on your system.

Resize: (optional) A flag determining whether the foreground image should be resized to match the background image before superimposing. The default option is True, meaning the foreground image will be resized.

[edit] Example

superimpose image("background.jpg", "foreground.png", "output.jpg", True)

The output will be a new image saved at "output.jpg", which consists of "foreground.png" superimposed over "background.jpg". If the dimensions of the two images are not the same, "foreground.png" will be resized to match "background.jpg" before superimposing. The original images will not be altered.

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox