Script Library: 1241 scripts
 

ai-image.r

REBOL[ title: "AI image" File: %ai-image.r Date: 21-11-2024 Version: 0.0.1 Author: "Sergey Pochinok" Purpose: "Demonstration of using AI to obtain an image." EMail: [%pochinok--bk--ru] History: [ 0.0.1 [21-11-2024 "Started"] ] Category: [demo] library: [ level: 'intermediate platform: 'all type: 'demo domain: [ai graphics external-library] tested-under: [core & view 2.7.8.3.1 win & linux] support: none license: 'BSD see-also: ai-geteway.r ] ] do http://www.rebol.org/download-a-script.r?script-name=ai-geteway.r main: layout[ across choice "400x400" "600x600" "800x800" "1024x1024" [ pic/size: to-pair value main/size: 40x70 + to-pair value ] request: field button "generate image" #"^M" [ wait_banner: flash "Make..." pic/image: ai/image request/text unview wait_banner show pic ] return pic: image 400x400 logo.gif [ file: request-file/only/save/file %ai_image.png save/png file pic/image ] ] view center-face main
halt ;; to terminate script if DO'ne from webpage
Notes
  • email address(es) have been munged to protect them from spam harvesters. If you are a Library member, you can log on and view this script without the munging.
  • (pochinok:bk:ru)