Image shape can be customized in various ways, here is the list of parameters you may change:
- Width - the width of the image
- Height - the height of the image
- Thickness - the thickness of the image, please use small values.
- Corner - the amount of the image corners to be rounded in percents
- Border - the amount of the image surface to be replaced with border. This shrinks the image, keeping its proportions.
- Bend - defines how to bend the image. 0 means no bending, negative and positive values bend to front or back side.
You may use the “Fit to images” button to adjust the shape automatically.
Here is a sample script that creates an image object:
var m = scene.root.addMesh("image", "generator.Images.Image"); var g = m.generator; g.width = 10; g.length = 5; g.thickness = 0.03; g.corner = 0.02; g.border = 0; g.bend = 0.5; g.material("Image").diffuseTexture = "/path/to/image.png"; g.fitToImages();