Documentation
¶
Index ¶
- Constants
- type Client
- func (c *Client) QueryHunyuanTo3DProJob(request *QueryHunyuanTo3DProJobRequest) (response *QueryHunyuanTo3DProJobResponse, err error)
- func (c *Client) QueryHunyuanTo3DProJobWithContext(ctx context.Context, request *QueryHunyuanTo3DProJobRequest) (response *QueryHunyuanTo3DProJobResponse, err error)
- func (c *Client) SubmitHunyuanTo3DProJob(request *SubmitHunyuanTo3DProJobRequest) (response *SubmitHunyuanTo3DProJobResponse, err error)
- func (c *Client) SubmitHunyuanTo3DProJobWithContext(ctx context.Context, request *SubmitHunyuanTo3DProJobRequest) (response *SubmitHunyuanTo3DProJobResponse, err error)
- type File3D
- type QueryHunyuanTo3DProJobRequest
- type QueryHunyuanTo3DProJobRequestParams
- type QueryHunyuanTo3DProJobResponse
- type QueryHunyuanTo3DProJobResponseParams
- type SubmitHunyuanTo3DProJobRequest
- type SubmitHunyuanTo3DProJobRequestParams
- type SubmitHunyuanTo3DProJobResponse
- type SubmitHunyuanTo3DProJobResponseParams
- type ViewImage
Constants ¶
const APIVersion = "2025-05-13"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
func NewClient ¶
func NewClient(credential common.CredentialIface, region string, clientProfile *profile.ClientProfile) (client *Client, err error)
func NewClientWithSecretId ¶
Deprecated
func (*Client) QueryHunyuanTo3DProJob ¶
func (c *Client) QueryHunyuanTo3DProJob(request *QueryHunyuanTo3DProJobRequest) (response *QueryHunyuanTo3DProJobResponse, err error)
QueryHunyuanTo3DProJob This API is used to intelligently generate 3D content based on the HunYuan Large Model and input text descriptions/images.
This API is used to provide 3 concurrent tasks by default, which can be processed simultaneously. The next task can be processed only after the previous task is completed.
func (*Client) QueryHunyuanTo3DProJobWithContext ¶
func (c *Client) QueryHunyuanTo3DProJobWithContext(ctx context.Context, request *QueryHunyuanTo3DProJobRequest) (response *QueryHunyuanTo3DProJobResponse, err error)
QueryHunyuanTo3DProJob This API is used to intelligently generate 3D content based on the HunYuan Large Model and input text descriptions/images.
This API is used to provide 3 concurrent tasks by default, which can be processed simultaneously. The next task can be processed only after the previous task is completed.
func (*Client) SubmitHunyuanTo3DProJob ¶
func (c *Client) SubmitHunyuanTo3DProJob(request *SubmitHunyuanTo3DProJobRequest) (response *SubmitHunyuanTo3DProJobResponse, err error)
SubmitHunyuanTo3DProJob This API is used to intelligently generate 3D content based on the HunYuan Large Model and input text descriptions/images.
This API is used to provide 3 concurrent tasks by default, which can be processed simultaneously. The next task can be processed only after the previous task is completed.
func (*Client) SubmitHunyuanTo3DProJobWithContext ¶
func (c *Client) SubmitHunyuanTo3DProJobWithContext(ctx context.Context, request *SubmitHunyuanTo3DProJobRequest) (response *SubmitHunyuanTo3DProJobResponse, err error)
SubmitHunyuanTo3DProJob This API is used to intelligently generate 3D content based on the HunYuan Large Model and input text descriptions/images.
This API is used to provide 3 concurrent tasks by default, which can be processed simultaneously. The next task can be processed only after the previous task is completed.
type File3D ¶
type File3D struct {
// Specifies the file format.
Type *string `json:"Type,omitnil,omitempty" name:"Type"`
// File Url (valid for 24 hours).
Url *string `json:"Url,omitnil,omitempty" name:"Url"`
// Preview image Url.
PreviewImageUrl *string `json:"PreviewImageUrl,omitnil,omitempty" name:"PreviewImageUrl"`
}
type QueryHunyuanTo3DProJobRequest ¶
type QueryHunyuanTo3DProJobRequest struct {
*tchttp.BaseRequest
// Task ID.
JobId *string `json:"JobId,omitnil,omitempty" name:"JobId"`
}
func NewQueryHunyuanTo3DProJobRequest ¶
func NewQueryHunyuanTo3DProJobRequest() (request *QueryHunyuanTo3DProJobRequest)
func (*QueryHunyuanTo3DProJobRequest) FromJsonString ¶
func (r *QueryHunyuanTo3DProJobRequest) FromJsonString(s string) error
FromJsonString It is highly **NOT** recommended to use this function because it has no param check, nor strict type check
func (*QueryHunyuanTo3DProJobRequest) ToJsonString ¶
func (r *QueryHunyuanTo3DProJobRequest) ToJsonString() string
type QueryHunyuanTo3DProJobRequestParams ¶
type QueryHunyuanTo3DProJobRequestParams struct {
// Task ID.
JobId *string `json:"JobId,omitnil,omitempty" name:"JobId"`
}
Predefined struct for user
type QueryHunyuanTo3DProJobResponse ¶
type QueryHunyuanTo3DProJobResponse struct {
*tchttp.BaseResponse
Response *QueryHunyuanTo3DProJobResponseParams `json:"Response"`
}
func NewQueryHunyuanTo3DProJobResponse ¶
func NewQueryHunyuanTo3DProJobResponse() (response *QueryHunyuanTo3DProJobResponse)
func (*QueryHunyuanTo3DProJobResponse) FromJsonString ¶
func (r *QueryHunyuanTo3DProJobResponse) FromJsonString(s string) error
FromJsonString It is highly **NOT** recommended to use this function because it has no param check, nor strict type check
func (*QueryHunyuanTo3DProJobResponse) ToJsonString ¶
func (r *QueryHunyuanTo3DProJobResponse) ToJsonString() string
type QueryHunyuanTo3DProJobResponseParams ¶
type QueryHunyuanTo3DProJobResponseParams struct {
// Task status. WAIT: waiting; RUN: running; FAIL: failed; DONE: successful.
Status *string `json:"Status,omitnil,omitempty" name:"Status"`
// Error code
ErrorCode *string `json:"ErrorCode,omitnil,omitempty" name:"ErrorCode"`
// Error message.
ErrorMessage *string `json:"ErrorMessage,omitnil,omitempty" name:"ErrorMessage"`
// Generated 3D file array.
ResultFile3Ds []*File3D `json:"ResultFile3Ds,omitnil,omitempty" name:"ResultFile3Ds"`
// The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
RequestId *string `json:"RequestId,omitnil,omitempty" name:"RequestId"`
}
Predefined struct for user
type SubmitHunyuanTo3DProJobRequest ¶
type SubmitHunyuanTo3DProJobRequest struct {
*tchttp.BaseRequest
// Generates 3D content, describes 3D content, chinese forward prompt content.
// Supports up to 1024 utf-8 characters.
// Text-To-3D. specifies image, image_url, or prompt is required. prompt and image/image_url cannot coexist.
Prompt *string `json:"Prompt,omitnil,omitempty" name:"Prompt"`
// Enter the Base64 code of the image.
// Size: specifies the unilateral resolution requirement, not less than 128 and not greater than 5000. size should not exceed 8m (after encoding, it increases by about 30%, recommend actual input image size no more than 6m).
// Valid values: jpg, png, jpeg, webp.
// ImageBase64, ImageUrl, or Prompt is required. Prompt and ImageBase64/ImageUrl cannot coexist.
ImageBase64 *string `json:"ImageBase64,omitnil,omitempty" name:"ImageBase64"`
// Input image Url.
// Size: specifies the unilateral resolution requirement, not less than 128 and not greater than 5000. size should not exceed 8m (after encoding, it increases by about 30%, recommend actual input image size no more than 6m).
// Valid values: jpg, png, jpeg, webp.
// Specifies either ImageBase64/ImageUrl or Prompt is required. Prompt and ImageBase64/ImageUrl cannot coexist.
ImageUrl *string `json:"ImageUrl,omitnil,omitempty" name:"ImageUrl"`
// Multi-Perspective model image. reference value for viewing angle:.
// left view.
// right view.
// back view.
//
// Each viewing angle allows only one image.
// Image size limit: must not exceed 8M after encoding.
// Image resolution limitation: specifies the unilateral resolution should be less than 5000 and greater than 128.
// ●Supported image format: JPG or PNG
MultiViewImages []*ViewImage `json:"MultiViewImages,omitnil,omitempty" name:"MultiViewImages"`
// Specifies whether PBR material generation is enabled, false by default.
EnablePBR *bool `json:"EnablePBR,omitnil,omitempty" name:"EnablePBR"`
// Specifies the face count of the generated 3D model. default value is 500000.
// Specifies the supported face count range. value range: 40000-1500000.
FaceCount *int64 `json:"FaceCount,omitnil,omitempty" name:"FaceCount"`
// Generation task type. default: Normal. valid values:.
// Generates a textured geometry model.
// LowPoly: specifies whether to generate a model with smart polygon reduction.
// Geometry: specifies whether to generate a Geometry model without texture (white model). when this task is selected, the EnablePBR parameter does not take effect.
// Sketch: enter a Sketch or line art to generate a model. in this mode, prompt and ImageUrl/ImageBase64 can be input together.
GenerateType *string `json:"GenerateType,omitnil,omitempty" name:"GenerateType"`
// This parameter only takes effect when LowPoly mode is selected from GenerateType.
//
// Polygon type, indicates the model surface is composed of polygon grids, defaults to triangle. valid values:.
// Specifies the triangle face.
// quadrilateral: generates a mix of quadrangle and triangle faces.
PolygonType *string `json:"PolygonType,omitnil,omitempty" name:"PolygonType"`
}
func NewSubmitHunyuanTo3DProJobRequest ¶
func NewSubmitHunyuanTo3DProJobRequest() (request *SubmitHunyuanTo3DProJobRequest)
func (*SubmitHunyuanTo3DProJobRequest) FromJsonString ¶
func (r *SubmitHunyuanTo3DProJobRequest) FromJsonString(s string) error
FromJsonString It is highly **NOT** recommended to use this function because it has no param check, nor strict type check
func (*SubmitHunyuanTo3DProJobRequest) ToJsonString ¶
func (r *SubmitHunyuanTo3DProJobRequest) ToJsonString() string
type SubmitHunyuanTo3DProJobRequestParams ¶
type SubmitHunyuanTo3DProJobRequestParams struct {
// Generates 3D content, describes 3D content, chinese forward prompt content.
// Supports up to 1024 utf-8 characters.
// Text-To-3D. specifies image, image_url, or prompt is required. prompt and image/image_url cannot coexist.
Prompt *string `json:"Prompt,omitnil,omitempty" name:"Prompt"`
// Enter the Base64 code of the image.
// Size: specifies the unilateral resolution requirement, not less than 128 and not greater than 5000. size should not exceed 8m (after encoding, it increases by about 30%, recommend actual input image size no more than 6m).
// Valid values: jpg, png, jpeg, webp.
// ImageBase64, ImageUrl, or Prompt is required. Prompt and ImageBase64/ImageUrl cannot coexist.
ImageBase64 *string `json:"ImageBase64,omitnil,omitempty" name:"ImageBase64"`
// Input image Url.
// Size: specifies the unilateral resolution requirement, not less than 128 and not greater than 5000. size should not exceed 8m (after encoding, it increases by about 30%, recommend actual input image size no more than 6m).
// Valid values: jpg, png, jpeg, webp.
// Specifies either ImageBase64/ImageUrl or Prompt is required. Prompt and ImageBase64/ImageUrl cannot coexist.
ImageUrl *string `json:"ImageUrl,omitnil,omitempty" name:"ImageUrl"`
// Multi-Perspective model image. reference value for viewing angle:.
// left view.
// right view.
// back view.
//
// Each viewing angle allows only one image.
// Image size limit: must not exceed 8M after encoding.
// Image resolution limitation: specifies the unilateral resolution should be less than 5000 and greater than 128.
// ●Supported image format: JPG or PNG
MultiViewImages []*ViewImage `json:"MultiViewImages,omitnil,omitempty" name:"MultiViewImages"`
// Specifies whether PBR material generation is enabled, false by default.
EnablePBR *bool `json:"EnablePBR,omitnil,omitempty" name:"EnablePBR"`
// Specifies the face count of the generated 3D model. default value is 500000.
// Specifies the supported face count range. value range: 40000-1500000.
FaceCount *int64 `json:"FaceCount,omitnil,omitempty" name:"FaceCount"`
// Generation task type. default: Normal. valid values:.
// Generates a textured geometry model.
// LowPoly: specifies whether to generate a model with smart polygon reduction.
// Geometry: specifies whether to generate a Geometry model without texture (white model). when this task is selected, the EnablePBR parameter does not take effect.
// Sketch: enter a Sketch or line art to generate a model. in this mode, prompt and ImageUrl/ImageBase64 can be input together.
GenerateType *string `json:"GenerateType,omitnil,omitempty" name:"GenerateType"`
// This parameter only takes effect when LowPoly mode is selected from GenerateType.
//
// Polygon type, indicates the model surface is composed of polygon grids, defaults to triangle. valid values:.
// Specifies the triangle face.
// quadrilateral: generates a mix of quadrangle and triangle faces.
PolygonType *string `json:"PolygonType,omitnil,omitempty" name:"PolygonType"`
}
Predefined struct for user
type SubmitHunyuanTo3DProJobResponse ¶
type SubmitHunyuanTo3DProJobResponse struct {
*tchttp.BaseResponse
Response *SubmitHunyuanTo3DProJobResponseParams `json:"Response"`
}
func NewSubmitHunyuanTo3DProJobResponse ¶
func NewSubmitHunyuanTo3DProJobResponse() (response *SubmitHunyuanTo3DProJobResponse)
func (*SubmitHunyuanTo3DProJobResponse) FromJsonString ¶
func (r *SubmitHunyuanTo3DProJobResponse) FromJsonString(s string) error
FromJsonString It is highly **NOT** recommended to use this function because it has no param check, nor strict type check
func (*SubmitHunyuanTo3DProJobResponse) ToJsonString ¶
func (r *SubmitHunyuanTo3DProJobResponse) ToJsonString() string
type SubmitHunyuanTo3DProJobResponseParams ¶
type SubmitHunyuanTo3DProJobResponseParams struct {
// Task ID (valid period: 24 hours).
JobId *string `json:"JobId,omitnil,omitempty" name:"JobId"`
// The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem.
RequestId *string `json:"RequestId,omitnil,omitempty" name:"RequestId"`
}
Predefined struct for user
type ViewImage ¶
type ViewImage struct {
// Viewing angle type.
// Valid values: back, left, right.
ViewType *string `json:"ViewType,omitnil,omitempty" name:"ViewType"`
// Image Url.
ViewImageUrl *string `json:"ViewImageUrl,omitnil,omitempty" name:"ViewImageUrl"`
// base64 image address.
ViewImageBase64 *string `json:"ViewImageBase64,omitnil,omitempty" name:"ViewImageBase64"`
}