Table of Contents

TTMSMCPCloudImageAI Class

Non-visual component that generates and edits images through a cloud image service.

API unit family: TMS.MCP.CloudImageAI Inherits from: TTMSMCPCustomCloudImageAI

Syntax

TTMSMCPCloudImageAI = class(TTMSMCPCustomCloudImageAI)

Remarks

Publishes the settings and events of its base class for use at design time. Set the authentication key, pick a service, optionally set a model name and extra parameters, then start an operation and wait for the image or error event; both are raised on the main thread.

Properties

Name Description
APIKey Key used to authenticate against the selected image service. (inherited from TTMSMCPCustomCloudImageAI)
CloudImageAIInstance The service implementation currently in use for building requests and reading responses. (inherited from TTMSMCPCustomCloudImageAI)
CloudImageAIProperties This component's own settings, in the read-only form handed to the active service implementation. (inherited from TTMSMCPCustomCloudImageAI)
CustomOptions Extra parameters merged into the body of every outgoing request. (inherited from TTMSMCPCustomCloudImageAI)
Images Reference images sent together with the prompt when an image is generated. (inherited from TTMSMCPCustomCloudImageAI)
Model Name of the model the selected service should use. (inherited from TTMSMCPCustomCloudImageAI)
Service Image service the component sends its requests to. (inherited from TTMSMCPCustomCloudImageAI)

Methods

Name Description
Execute Starts creating an image from a prompt. (inherited from TTMSMCPCustomCloudImageAI)
RemoveBackground Starts removing the background of a base64-encoded image. (inherited from TTMSMCPCustomCloudImageAI)
ReplaceBackground Starts placing the subject of one base64-encoded image onto the background of another. (inherited from TTMSMCPCustomCloudImageAI)

Events

Name Description
OnImageGenerated Fires when a request has produced an image. (inherited from TTMSMCPCustomCloudImageAI)
OnRequestError Fires when a request has failed. (inherited from TTMSMCPCustomCloudImageAI)

Used by