API & Integration -> RenderScript

Image properties in RenderScript

These properties extend the base element properties.

Source

URL or GUID of the image file. When using AI generation (via 'provider' property), this becomes the text prompt for image generation.

Example

"source": "https://...",

Default

"source": null,

Provider

Generates the image from the 'source' text with an AI provider, using your own key from Project Settings, Integration. OpenAI: 'openai model=gpt-image-2' (also gpt-image-1.5, gpt-image-1 and gpt-image-1-mini; the DALL·E models are discontinued), with 'size=' 1024x1024 (the default), 1536x1024 or 1024x1536 (gpt-image-2 also takes larger sizes up to 3840 pixels and auto) and 'quality=' low, medium (the default) or high. Stability AI: 'stabilityai model=sic' (Stable Image Core), sd3 or sd3-turbo, with 'aspect_ratio=' 1:1 (the default), 16:9, 9:16, 21:9, 9:21, 2:3, 3:2, 4:5 or 5:4, and for sic a 'style_preset=' such as photographic, cinematic, anime, digital-art, line-art or pixel-art. Write the options after the provider name, separated by spaces.

Example

"provider": "openai model=gpt-image-2 size=1024x1536", "source": "A beautiful sunset"

Default

"provider": null,

Fit

Controls how the image is resized within the element bounds: 'cover' (fills area, may crop), 'contain' (fits entirely, may letterbox), or 'fill' (stretches to fill).

Example

"fit": "contain",

Default

"fit": "cover",