|
|
|
|
|
GenerateGeometricImage (Function) In french: GénèreImageGéométrique Randomly generates an image with geometric shapes. This image can be used to temporarily fill an Image control, for example. This allows you to fill a user's "photo" field, while the user uploads one of their own. // Generate a geometric image MyImage is Image = GenerateGeometricImage()
Syntax
<Result> = GenerateGeometricImage([<Width> [, <Height> [, <Color> [, <Background color>]]]])
<Result>: Image variable Image variable that contains the generated image. <Width>: Optional integer Width of the generated image, in pixels. By default, the width of the generated image is 80 pixels. <Height>: Optional integer Height of the generated image, in pixels. By default, the height of the generated image is the same as the width. <Color>: Optional integer Default background color of the different geometric shapes. This color can correspond to:- an RGB color (returned by RGB),
- an HSL color (returned by HSL),
- a WLanguage preset color.
- a variable of type Color. In this case, the opacity specified in the variable is taken into account.
If this parameter is not specified, a random color will be used. <Background color>: Optional integer Default background color of the different geometric shapes. This color can correspond to:- an RGB color (returned by RGB),
- an HSL color (returned by HSL),
- a WLanguage preset color.
- a variable of type Color. In this case, the opacity specified in the variable is taken into account.
If this parameter is not specified, a transparent background will be used. Remarks The randomness of the image generation is based on the Random function. To avoid getting the same images each time the program is run, call InitRandom in the project initialization event.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|