v20191213

package
v1.0.129 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 5, 2021 License: Apache-2.0 Imports: 4 Imported by: 1

Documentation

Index

Constants

View Source
const APIVersion = "2019-12-13"

Variables

This section is empty.

Functions

This section is empty.

Types

type BeautifyPicRequest

type BeautifyPicRequest struct {
	*tchttp.BaseRequest

	// 图片 base64 数据,base64 编码后大小不可超过5M。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Image *string `json:"Image,omitempty" name:"Image"`

	// 图片的 Url 。对应图片 base64 编码后大小不可超过5M。
	// Url、Image必须提供一个,如果都提供,只使用 Url。
	// 图片存储于腾讯云的Url可保障更高下载速度和稳定性,建议图片存储于腾讯云。
	// 非腾讯云存储的Url速度和稳定性可能受一定影响。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Url *string `json:"Url,omitempty" name:"Url"`

	// 美白程度,取值范围[0,100]。0不美白,100代表最高程度。默认值30。
	Whitening *uint64 `json:"Whitening,omitempty" name:"Whitening"`

	// 磨皮程度,取值范围[0,100]。0不磨皮,100代表最高程度。默认值10。
	Smoothing *uint64 `json:"Smoothing,omitempty" name:"Smoothing"`

	// 瘦脸程度,取值范围[0,100]。0不瘦脸,100代表最高程度。默认值70。
	FaceLifting *uint64 `json:"FaceLifting,omitempty" name:"FaceLifting"`

	// 大眼程度,取值范围[0,100]。0不大眼,100代表最高程度。默认值70。
	EyeEnlarging *uint64 `json:"EyeEnlarging,omitempty" name:"EyeEnlarging"`

	// 返回图像方式(base64 或 url ) ,二选一。url有效期为1天。
	RspImgType *string `json:"RspImgType,omitempty" name:"RspImgType"`
}

func NewBeautifyPicRequest

func NewBeautifyPicRequest() (request *BeautifyPicRequest)

func (*BeautifyPicRequest) FromJsonString

func (r *BeautifyPicRequest) FromJsonString(s string) error

func (*BeautifyPicRequest) ToJsonString

func (r *BeautifyPicRequest) ToJsonString() string

type BeautifyPicResponse

type BeautifyPicResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// RspImgType 为 base64 时,返回处理后的图片 base64 数据。默认返回base64
		ResultImage *string `json:"ResultImage,omitempty" name:"ResultImage"`

		// RspImgType 为 url 时,返回处理后的图片 url 数据。
		ResultUrl *string `json:"ResultUrl,omitempty" name:"ResultUrl"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewBeautifyPicResponse

func NewBeautifyPicResponse() (response *BeautifyPicResponse)

func (*BeautifyPicResponse) FromJsonString

func (r *BeautifyPicResponse) FromJsonString(s string) error

func (*BeautifyPicResponse) ToJsonString

func (r *BeautifyPicResponse) ToJsonString() string

type BeautifyVideoOutput added in v1.0.5

type BeautifyVideoOutput struct {

	// 视频美颜输出的url
	// 注意:此字段可能返回 null,表示取不到有效值。
	VideoUrl *string `json:"VideoUrl,omitempty" name:"VideoUrl"`

	// 视频美颜输出的视频MD5,用于校验
	// 注意:此字段可能返回 null,表示取不到有效值。
	VideoMD5 *string `json:"VideoMD5,omitempty" name:"VideoMD5"`

	// 美颜输出的视频封面图base64字符串
	// 注意:此字段可能返回 null,表示取不到有效值。
	CoverImage *string `json:"CoverImage,omitempty" name:"CoverImage"`

	// 视频宽度
	// 注意:此字段可能返回 null,表示取不到有效值。
	Width *int64 `json:"Width,omitempty" name:"Width"`

	// 视频高度
	// 注意:此字段可能返回 null,表示取不到有效值。
	Height *int64 `json:"Height,omitempty" name:"Height"`

	// 每秒传输帧数
	// 注意:此字段可能返回 null,表示取不到有效值。
	Fps *float64 `json:"Fps,omitempty" name:"Fps"`

	// 视频播放时长,单位为秒
	// 注意:此字段可能返回 null,表示取不到有效值。
	DurationInSec *float64 `json:"DurationInSec,omitempty" name:"DurationInSec"`
}

type BeautifyVideoRequest added in v1.0.5

type BeautifyVideoRequest struct {
	*tchttp.BaseRequest

	// 视频url地址
	Url *string `json:"Url,omitempty" name:"Url"`

	// 美颜参数 - 美白、平滑、大眼和瘦脸。参数值范围[0, 100]。参数值为0,则不做美颜。参数默认值为0。目前默认取数组第一个元素是对所有人脸美颜。
	BeautyParam []*BeautyParam `json:"BeautyParam,omitempty" name:"BeautyParam" list`

	// 目前只支持mp4
	OutputVideoType *string `json:"OutputVideoType,omitempty" name:"OutputVideoType"`
}

func NewBeautifyVideoRequest added in v1.0.5

func NewBeautifyVideoRequest() (request *BeautifyVideoRequest)

func (*BeautifyVideoRequest) FromJsonString added in v1.0.5

func (r *BeautifyVideoRequest) FromJsonString(s string) error

func (*BeautifyVideoRequest) ToJsonString added in v1.0.5

func (r *BeautifyVideoRequest) ToJsonString() string

type BeautifyVideoResponse added in v1.0.5

type BeautifyVideoResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 视频美颜任务的Job id
		JobId *string `json:"JobId,omitempty" name:"JobId"`

		// 预估处理时间,粒度为秒
		EstimatedProcessTime *int64 `json:"EstimatedProcessTime,omitempty" name:"EstimatedProcessTime"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewBeautifyVideoResponse added in v1.0.5

func NewBeautifyVideoResponse() (response *BeautifyVideoResponse)

func (*BeautifyVideoResponse) FromJsonString added in v1.0.5

func (r *BeautifyVideoResponse) FromJsonString(s string) error

func (*BeautifyVideoResponse) ToJsonString added in v1.0.5

func (r *BeautifyVideoResponse) ToJsonString() string

type BeautyParam added in v1.0.5

type BeautyParam struct {

	// 美白程度,取值范围[0,100]。0不美白,100代表最高程度。默认值30。
	WhitenLevel *uint64 `json:"WhitenLevel,omitempty" name:"WhitenLevel"`

	// 磨皮程度,取值范围[0,100]。0不磨皮,100代表最高程度。默认值30。
	SmoothingLevel *uint64 `json:"SmoothingLevel,omitempty" name:"SmoothingLevel"`

	// 大眼程度,取值范围[0,100]。0不大眼,100代表最高程度。默认值70。
	EyeEnlargeLevel *uint64 `json:"EyeEnlargeLevel,omitempty" name:"EyeEnlargeLevel"`

	// 瘦脸程度,取值范围[0,100]。0不瘦脸,100代表最高程度。默认值70。
	FaceShrinkLevel *uint64 `json:"FaceShrinkLevel,omitempty" name:"FaceShrinkLevel"`
}

type CancelBeautifyVideoJobRequest added in v1.0.5

type CancelBeautifyVideoJobRequest struct {
	*tchttp.BaseRequest

	// 美颜视频的Job id
	JobId *string `json:"JobId,omitempty" name:"JobId"`
}

func NewCancelBeautifyVideoJobRequest added in v1.0.5

func NewCancelBeautifyVideoJobRequest() (request *CancelBeautifyVideoJobRequest)

func (*CancelBeautifyVideoJobRequest) FromJsonString added in v1.0.5

func (r *CancelBeautifyVideoJobRequest) FromJsonString(s string) error

func (*CancelBeautifyVideoJobRequest) ToJsonString added in v1.0.5

func (r *CancelBeautifyVideoJobRequest) ToJsonString() string

type CancelBeautifyVideoJobResponse added in v1.0.5

type CancelBeautifyVideoJobResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewCancelBeautifyVideoJobResponse added in v1.0.5

func NewCancelBeautifyVideoJobResponse() (response *CancelBeautifyVideoJobResponse)

func (*CancelBeautifyVideoJobResponse) FromJsonString added in v1.0.5

func (r *CancelBeautifyVideoJobResponse) FromJsonString(s string) error

func (*CancelBeautifyVideoJobResponse) ToJsonString added in v1.0.5

func (r *CancelBeautifyVideoJobResponse) ToJsonString() string

type Client

type Client struct {
	common.Client
}

func NewClient

func NewClient(credential *common.Credential, region string, clientProfile *profile.ClientProfile) (client *Client, err error)

func NewClientWithSecretId

func NewClientWithSecretId(secretId, secretKey, region string) (client *Client, err error)

Deprecated

func (*Client) BeautifyPic

func (c *Client) BeautifyPic(request *BeautifyPicRequest) (response *BeautifyPicResponse, err error)

用户上传一张人脸图片,精准定位五官,实现美肤、亮肤、祛痘等美颜功能。

func (*Client) BeautifyVideo added in v1.0.5

func (c *Client) BeautifyVideo(request *BeautifyVideoRequest) (response *BeautifyVideoResponse, err error)

视频美颜

func (*Client) CancelBeautifyVideoJob added in v1.0.5

func (c *Client) CancelBeautifyVideoJob(request *CancelBeautifyVideoJobRequest) (response *CancelBeautifyVideoJobResponse, err error)

撤销视频美颜任务请求

func (*Client) CreateModel

func (c *Client) CreateModel(request *CreateModelRequest) (response *CreateModelResponse, err error)

在使用LUT素材的modelid实现试唇色前,您需要先上传 LUT 格式的cube文件注册唇色ID。查看 [LUT文件的使用说明](https://cloud.tencent.com/document/product/1172/41701)。

注:您也可以直接使用 [试唇色接口](https://cloud.tencent.com/document/product/1172/40706),通过输入RGBA模型数值的方式指定唇色,更简单易用。

func (*Client) DeleteModel

func (c *Client) DeleteModel(request *DeleteModelRequest) (response *DeleteModelResponse, err error)

删除已注册的唇色素材。

func (*Client) GetModelList

func (c *Client) GetModelList(request *GetModelListRequest) (response *GetModelListResponse, err error)

查询已注册的唇色素材。

func (*Client) QueryBeautifyVideoJob added in v1.0.5

func (c *Client) QueryBeautifyVideoJob(request *QueryBeautifyVideoJobRequest) (response *QueryBeautifyVideoJobResponse, err error)

查询视频美颜处理进度

func (*Client) StyleImage added in v1.0.47

func (c *Client) StyleImage(request *StyleImageRequest) (response *StyleImageResponse, err error)

上传一张照片,输出滤镜处理后的图片。

func (*Client) StyleImagePro added in v1.0.47

func (c *Client) StyleImagePro(request *StyleImageProRequest) (response *StyleImageProResponse, err error)

上传一张照片,输出滤镜处理后的图片。

func (*Client) TryLipstickPic

func (c *Client) TryLipstickPic(request *TryLipstickPicRequest) (response *TryLipstickPicResponse, err error)

对图片中的人脸嘴唇进行着色,最多支持同时对一张图中的3张人脸进行试唇色。

您可以通过事先注册在腾讯云的唇色素材(LUT文件)改变图片中的人脸唇色,也可以输入RGBA模型数值。

为了更好的效果,建议您使用事先注册在腾讯云的唇色素材(LUT文件)。

> - 公共参数中的签名方式请使用V3版本,即配置SignatureMethod参数为TC3-HMAC-SHA256。

type CreateModelRequest

type CreateModelRequest struct {
	*tchttp.BaseRequest

	// 图片base64数据,用于试唇色,要求必须是LUT 格式的cube文件转换成512*512的PNG图片。查看 [LUT文件的使用说明](https://cloud.tencent.com/document/product/1172/41701)。了解 [cube文件转png图片小工具](http://yyb.gtimg.com/aiplat/static/qcloud-cube-to-png.html)。
	LUTFile *string `json:"LUTFile,omitempty" name:"LUTFile"`

	// 文件描述信息,可用于备注。
	Description *string `json:"Description,omitempty" name:"Description"`
}

func NewCreateModelRequest

func NewCreateModelRequest() (request *CreateModelRequest)

func (*CreateModelRequest) FromJsonString

func (r *CreateModelRequest) FromJsonString(s string) error

func (*CreateModelRequest) ToJsonString

func (r *CreateModelRequest) ToJsonString() string

type CreateModelResponse

type CreateModelResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唇色素材ID。
		ModelId *string `json:"ModelId,omitempty" name:"ModelId"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewCreateModelResponse

func NewCreateModelResponse() (response *CreateModelResponse)

func (*CreateModelResponse) FromJsonString

func (r *CreateModelResponse) FromJsonString(s string) error

func (*CreateModelResponse) ToJsonString

func (r *CreateModelResponse) ToJsonString() string

type DeleteModelRequest

type DeleteModelRequest struct {
	*tchttp.BaseRequest

	// 素材ID。
	ModelId *string `json:"ModelId,omitempty" name:"ModelId"`
}

func NewDeleteModelRequest

func NewDeleteModelRequest() (request *DeleteModelRequest)

func (*DeleteModelRequest) FromJsonString

func (r *DeleteModelRequest) FromJsonString(s string) error

func (*DeleteModelRequest) ToJsonString

func (r *DeleteModelRequest) ToJsonString() string

type DeleteModelResponse

type DeleteModelResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewDeleteModelResponse

func NewDeleteModelResponse() (response *DeleteModelResponse)

func (*DeleteModelResponse) FromJsonString

func (r *DeleteModelResponse) FromJsonString(s string) error

func (*DeleteModelResponse) ToJsonString

func (r *DeleteModelResponse) ToJsonString() string

type FaceRect

type FaceRect struct {

	// 人脸框左上角横坐标。
	X *int64 `json:"X,omitempty" name:"X"`

	// 人脸框左上角纵坐标。
	Y *int64 `json:"Y,omitempty" name:"Y"`

	// 人脸框宽度。
	Width *int64 `json:"Width,omitempty" name:"Width"`

	// 人脸框高度。
	Height *int64 `json:"Height,omitempty" name:"Height"`
}

type GetModelListRequest

type GetModelListRequest struct {
	*tchttp.BaseRequest

	// 起始序号,默认值为0。
	Offset *int64 `json:"Offset,omitempty" name:"Offset"`

	// 返回数量,默认值为10,最大值为100。
	Limit *int64 `json:"Limit,omitempty" name:"Limit"`
}

func NewGetModelListRequest

func NewGetModelListRequest() (request *GetModelListRequest)

func (*GetModelListRequest) FromJsonString

func (r *GetModelListRequest) FromJsonString(s string) error

func (*GetModelListRequest) ToJsonString

func (r *GetModelListRequest) ToJsonString() string

type GetModelListResponse

type GetModelListResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 唇色素材总数量。
		ModelIdNum *int64 `json:"ModelIdNum,omitempty" name:"ModelIdNum"`

		// 素材数据
		// 注意:此字段可能返回 null,表示取不到有效值。
		ModelInfos []*ModelInfo `json:"ModelInfos,omitempty" name:"ModelInfos" list`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewGetModelListResponse

func NewGetModelListResponse() (response *GetModelListResponse)

func (*GetModelListResponse) FromJsonString

func (r *GetModelListResponse) FromJsonString(s string) error

func (*GetModelListResponse) ToJsonString

func (r *GetModelListResponse) ToJsonString() string

type LipColorInfo

type LipColorInfo struct {

	// 使用RGBA模型试唇色。
	RGBA *RGBAInfo `json:"RGBA,omitempty" name:"RGBA"`

	// 使用已注册的 LUT 文件试唇色。
	// ModelId 和 RGBA 两个参数只需提供一个,若都提供只使用 ModelId。
	ModelId *string `json:"ModelId,omitempty" name:"ModelId"`

	// 人脸框位置。若不输入则选择 Image 或 Url 中面积最大的人脸。
	// 您可以通过 [人脸检测与分析](https://cloud.tencent.com/document/api/867/32800)  接口获取人脸框位置信息。
	FaceRect *FaceRect `json:"FaceRect,omitempty" name:"FaceRect"`

	// 涂妆浓淡[0,100]。建议取值50。本参数仅控制ModelId对应的涂妆浓淡。
	ModelAlpha *int64 `json:"ModelAlpha,omitempty" name:"ModelAlpha"`
}

type ModelInfo

type ModelInfo struct {

	// 唇色素材ID
	ModelId *string `json:"ModelId,omitempty" name:"ModelId"`

	// 唇色素材 url 。 LUT 文件 url 5分钟有效。
	LUTFileUrl *string `json:"LUTFileUrl,omitempty" name:"LUTFileUrl"`

	// 文件描述信息。
	Description *string `json:"Description,omitempty" name:"Description"`
}

type QueryBeautifyVideoJobRequest added in v1.0.5

type QueryBeautifyVideoJobRequest struct {
	*tchttp.BaseRequest

	// 视频美颜Job id
	JobId *string `json:"JobId,omitempty" name:"JobId"`
}

func NewQueryBeautifyVideoJobRequest added in v1.0.5

func NewQueryBeautifyVideoJobRequest() (request *QueryBeautifyVideoJobRequest)

func (*QueryBeautifyVideoJobRequest) FromJsonString added in v1.0.5

func (r *QueryBeautifyVideoJobRequest) FromJsonString(s string) error

func (*QueryBeautifyVideoJobRequest) ToJsonString added in v1.0.5

func (r *QueryBeautifyVideoJobRequest) ToJsonString() string

type QueryBeautifyVideoJobResponse added in v1.0.5

type QueryBeautifyVideoJobResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// 当前任务状态:排队中、处理中、处理失败或者处理完成
		JobStatus *string `json:"JobStatus,omitempty" name:"JobStatus"`

		// 视频美颜输出的结果信息
		// 注意:此字段可能返回 null,表示取不到有效值。
		BeautifyVideoOutput *BeautifyVideoOutput `json:"BeautifyVideoOutput,omitempty" name:"BeautifyVideoOutput"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewQueryBeautifyVideoJobResponse added in v1.0.5

func NewQueryBeautifyVideoJobResponse() (response *QueryBeautifyVideoJobResponse)

func (*QueryBeautifyVideoJobResponse) FromJsonString added in v1.0.5

func (r *QueryBeautifyVideoJobResponse) FromJsonString(s string) error

func (*QueryBeautifyVideoJobResponse) ToJsonString added in v1.0.5

func (r *QueryBeautifyVideoJobResponse) ToJsonString() string

type RGBAInfo

type RGBAInfo struct {

	// R通道数值。[0,255]。
	R *int64 `json:"R,omitempty" name:"R"`

	// G通道数值。[0,255]。
	G *int64 `json:"G,omitempty" name:"G"`

	// B通道数值。[0,255]。
	B *int64 `json:"B,omitempty" name:"B"`

	// A通道数值。[0,100]。建议取值50。
	A *int64 `json:"A,omitempty" name:"A"`
}

type StyleImageProRequest added in v1.0.47

type StyleImageProRequest struct {
	*tchttp.BaseRequest

	// 滤镜类型,取值如下:
	// 1.白茶;2 白皙;3.初夏;4.东京;5.告白;6.暖阳;7.蔷薇;8.清澄;9.清透;10.甜薄荷;11.默认;12.心动;13.哑灰;14.樱桃布丁;15.自然;16.清逸;17.黑白;18.水果;19.爱情;20.冬日;21.相片;22.夏日;23.香氛;24.魅惑;25.悸动;26.沙滩;27.街拍;28.甜美;29.初吻;30.午后;31.活力;32.朦胧;33.悦动;34.时尚;35.气泡;36.柠檬;37.棉花糖;38.小溪;39.丽人;40.咖啡;41.嫩芽;42.热情;43.渐暖;44.早餐;45.白茶;46.白嫩;47.圣代;48.森林;49.冲浪;50.奶咖;51.清澈;52.微风;53.日落;54.水光;55.日系;56.星光;57.阳光;58.落叶;59.生机;60.甜心;61.清逸;62.春意;63.罗马;64.青涩;65.清风;66.暖心;67.海水;68.神秘;69.旧调1;70.旧调2;71.雪顶;72.日光;73.浮云;74.流彩;75.胶片;76.回味;77.奶酪;78.蝴蝶。
	FilterType *int64 `json:"FilterType,omitempty" name:"FilterType"`

	// 图片 base64 数据,base64 编码后大小不可超过5M。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Image *string `json:"Image,omitempty" name:"Image"`

	// 图片的 Url ,对应图片 base64 编码后大小不可超过5M。
	// 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
	// 图片存储于腾讯云的 Url 可保障更高下载速度和稳定性,建议图片存储于腾讯云。
	// 非腾讯云存储的Url速度和稳定性可能受一定影响。
	// 支持PNG、JPG、JPEG、BMP 等图片格式,不支持 GIF 图片。
	Url *string `json:"Url,omitempty" name:"Url"`

	// 滤镜效果,取值[0,100],0表示无效果,100表示满滤镜效果。默认值为80。
	FilterDegree *int64 `json:"FilterDegree,omitempty" name:"FilterDegree"`

	// 返回图像方式(base64 或 url ) ,二选一。url有效期为1天。
	RspImgType *string `json:"RspImgType,omitempty" name:"RspImgType"`
}

func NewStyleImageProRequest added in v1.0.47

func NewStyleImageProRequest() (request *StyleImageProRequest)

func (*StyleImageProRequest) FromJsonString added in v1.0.47

func (r *StyleImageProRequest) FromJsonString(s string) error

func (*StyleImageProRequest) ToJsonString added in v1.0.47

func (r *StyleImageProRequest) ToJsonString() string

type StyleImageProResponse added in v1.0.47

type StyleImageProResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// RspImgType 为 base64 时,返回处理后的图片 base64 数据。默认返回base64
		// 注意:此字段可能返回 null,表示取不到有效值。
		ResultImage *string `json:"ResultImage,omitempty" name:"ResultImage"`

		// RspImgType 为 url 时,返回处理后的图片 url 数据。
		// 注意:此字段可能返回 null,表示取不到有效值。
		ResultUrl *string `json:"ResultUrl,omitempty" name:"ResultUrl"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewStyleImageProResponse added in v1.0.47

func NewStyleImageProResponse() (response *StyleImageProResponse)

func (*StyleImageProResponse) FromJsonString added in v1.0.47

func (r *StyleImageProResponse) FromJsonString(s string) error

func (*StyleImageProResponse) ToJsonString added in v1.0.47

func (r *StyleImageProResponse) ToJsonString() string

type StyleImageRequest added in v1.0.47

type StyleImageRequest struct {
	*tchttp.BaseRequest

	// 滤镜类型,取值如下:
	// 1.白茶;2 白皙;3.初夏;4.东京;5.告白;6.暖阳;7.蔷薇;8.清澄;9.清透;10.甜薄荷;11.默认;12.心动;13.哑灰;14.樱桃布丁;15.自然;16.清逸;17.黑白;18.水果;19.爱情;20.冬日;21.相片;22.夏日;23.香氛;24.魅惑;25.悸动;26.沙滩;27.街拍;28.甜美;29.初吻;30.午后。
	FilterType *int64 `json:"FilterType,omitempty" name:"FilterType"`

	// 图片 base64 数据,base64 编码后大小不可超过5M。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Image *string `json:"Image,omitempty" name:"Image"`

	// 图片的 Url ,对应图片 base64 编码后大小不可超过5M。
	// 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
	// 图片存储于腾讯云的 Url 可保障更高下载速度和稳定性,建议图片存储于腾讯云。
	// 非腾讯云存储的Url速度和稳定性可能受一定影响。
	// 支持PNG、JPG、JPEG、BMP 等图片格式,不支持 GIF 图片。
	Url *string `json:"Url,omitempty" name:"Url"`

	// 滤镜效果,取值[0,100],0表示无效果,100表示满滤镜效果。默认值为80。
	FilterDegree *int64 `json:"FilterDegree,omitempty" name:"FilterDegree"`

	// 返回图像方式(base64 或 url ) ,二选一。url有效期为1天。
	RspImgType *string `json:"RspImgType,omitempty" name:"RspImgType"`
}

func NewStyleImageRequest added in v1.0.47

func NewStyleImageRequest() (request *StyleImageRequest)

func (*StyleImageRequest) FromJsonString added in v1.0.47

func (r *StyleImageRequest) FromJsonString(s string) error

func (*StyleImageRequest) ToJsonString added in v1.0.47

func (r *StyleImageRequest) ToJsonString() string

type StyleImageResponse added in v1.0.47

type StyleImageResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// RspImgType 为 base64 时,返回处理后的图片 base64 数据。默认返回base64
		// 注意:此字段可能返回 null,表示取不到有效值。
		ResultImage *string `json:"ResultImage,omitempty" name:"ResultImage"`

		// RspImgType 为 url 时,返回处理后的图片 url 数据。
		// 注意:此字段可能返回 null,表示取不到有效值。
		ResultUrl *string `json:"ResultUrl,omitempty" name:"ResultUrl"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewStyleImageResponse added in v1.0.47

func NewStyleImageResponse() (response *StyleImageResponse)

func (*StyleImageResponse) FromJsonString added in v1.0.47

func (r *StyleImageResponse) FromJsonString(s string) error

func (*StyleImageResponse) ToJsonString added in v1.0.47

func (r *StyleImageResponse) ToJsonString() string

type TryLipstickPicRequest

type TryLipstickPicRequest struct {
	*tchttp.BaseRequest

	// 唇色信息。
	// 您可以输入最多3个 LipColorInfo 来实现给一张图中的最多3张人脸试唇色。
	LipColorInfos []*LipColorInfo `json:"LipColorInfos,omitempty" name:"LipColorInfos" list`

	// 图片 base64 数据,base64 编码后大小不可超过6M。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Image *string `json:"Image,omitempty" name:"Image"`

	// 图片的 Url ,对应图片 base64 编码后大小不可超过6M。
	// 图片的 Url、Image必须提供一个,如果都提供,只使用 Url。
	// 图片存储于腾讯云的 Url 可保障更高下载速度和稳定性,建议图片存储于腾讯云。
	// 非腾讯云存储的Url速度和稳定性可能受一定影响。
	// 支持PNG、JPG、JPEG、BMP,不支持 GIF 图片。
	Url *string `json:"Url,omitempty" name:"Url"`

	// 返回图像方式(base64 或 url ) ,二选一。url有效期为1天。
	RspImgType *string `json:"RspImgType,omitempty" name:"RspImgType"`
}

func NewTryLipstickPicRequest

func NewTryLipstickPicRequest() (request *TryLipstickPicRequest)

func (*TryLipstickPicRequest) FromJsonString

func (r *TryLipstickPicRequest) FromJsonString(s string) error

func (*TryLipstickPicRequest) ToJsonString

func (r *TryLipstickPicRequest) ToJsonString() string

type TryLipstickPicResponse

type TryLipstickPicResponse struct {
	*tchttp.BaseResponse
	Response *struct {

		// RspImgType 为 base64 时,返回处理后的图片 base64 数据。默认返回base64
		ResultImage *string `json:"ResultImage,omitempty" name:"ResultImage"`

		// RspImgType 为 url 时,返回处理后的图片 url 数据。
		ResultUrl *string `json:"ResultUrl,omitempty" name:"ResultUrl"`

		// 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
		RequestId *string `json:"RequestId,omitempty" name:"RequestId"`
	} `json:"Response"`
}

func NewTryLipstickPicResponse

func NewTryLipstickPicResponse() (response *TryLipstickPicResponse)

func (*TryLipstickPicResponse) FromJsonString

func (r *TryLipstickPicResponse) FromJsonString(s string) error

func (*TryLipstickPicResponse) ToJsonString

func (r *TryLipstickPicResponse) ToJsonString() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL