daavelar/php-runware-sdk
最新稳定版本:1.2.0
Composer 安装命令:
composer require daavelar/php-runware-sdk
包简介
README 文档
README
A PHP wrapper for the Runware AI API, allowing simple and efficient AI image generation.
Installation
composer require runware/php-runware-sdk
Usage
use Runware\Runware; $runware = new Runware('your_api_key'); $imageUrl = $runware ->withHeight(768) ->withWidth(1024) ->model('runware:realistic') ->withSteps(30) ->withCFGScale(8.5) ->withNumberResults(4) ->withOutputType('URL') ->withOutputFormat('PNG') ->withNegativePrompt('low quality, blurred') ->textToImage('A beautiful sunset over a calm ocean'); $transformedImageUrl = $runware ->withHeight(512) ->withWidth(512) ->withSteps(25) ->imageToImage( 'A beautiful sunset over a calm ocean', 'https://url-da-imagem-original.jpg', 0.7 ); $inpaintedImageUrl = $runware ->inpainting( 'A beautiful sunset over a calm ocean', 'https://url-da-imagem-original.jpg', 'https://url-da-mascara.jpg', 0.8 ); $outpaintedImageUrl = $runware ->outpainting( 'A beautiful sunset over a calm ocean', 'https://url-da-imagem-original.jpg', [ 'top' => 256, 'right' => 256, 'bottom' => 0, 'left' => 0 ], 0.8 );
Documentation
For more detailed information on the API, please refer to the Runware API Documentation.
License
This project is licensed under the MIT License. See the LICENSE file for details.
统计信息
- 总下载量: 725
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: Unknown
- 更新时间: 2025-03-11