diff --git a/packages/shared/src/contracts/model3d/image-to-model/Model3dImageToModelRequest.ts b/packages/shared/src/contracts/model3d/image-to-model/Model3dImageToModelRequest.ts index 3c140c820..5f0d9e56d 100644 --- a/packages/shared/src/contracts/model3d/image-to-model/Model3dImageToModelRequest.ts +++ b/packages/shared/src/contracts/model3d/image-to-model/Model3dImageToModelRequest.ts @@ -10,24 +10,24 @@ import type { Model3dTextureVersion } from '../common/Model3dTextureVersion'; export type Model3dImageToModelRequest = { input: string; - model: Model3dModelVersion | null; - enableImageAutofix: boolean | null; - modelSeed: number | null; - textureSeed: number | null; - texture: boolean | null; - pbr: boolean | null; - textureQuality: Model3dTextureQuality | null; - textureVersion: Model3dTextureVersion | null; - delight: boolean | null; - textureAlignment: Model3dTextureAlignment | null; - geometryQuality: Model3dGeometryQuality | null; - faceLimit: number | null; - autoSize: boolean | null; - orientation: Model3dInputOrientation | null; - quad: boolean | null; - smartLowPoly: boolean | null; - generateParts: boolean | null; - compress: Model3dCompression | null; - exportUv: boolean | null; - exportOrientation: Model3dExportOrientation | null; + model?: Model3dModelVersion | null; + enableImageAutofix?: boolean | null; + modelSeed?: number | null; + textureSeed?: number | null; + texture?: boolean | null; + pbr?: boolean | null; + textureQuality?: Model3dTextureQuality | null; + textureVersion?: Model3dTextureVersion | null; + delight?: boolean | null; + textureAlignment?: Model3dTextureAlignment | null; + geometryQuality?: Model3dGeometryQuality | null; + faceLimit?: number | null; + autoSize?: boolean | null; + orientation?: Model3dInputOrientation | null; + quad?: boolean | null; + smartLowPoly?: boolean | null; + generateParts?: boolean | null; + compress?: Model3dCompression | null; + exportUv?: boolean | null; + exportOrientation?: Model3dExportOrientation | null; }; diff --git a/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewInputs.ts b/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewInputs.ts index d5d145b9a..a3159a264 100644 --- a/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewInputs.ts +++ b/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewInputs.ts @@ -4,8 +4,8 @@ export type Model3dMultiviewInputs = | { kind: 'views'; front: string; - left: string | null; - back: string | null; - right: string | null; + left?: string | null; + back?: string | null; + right?: string | null; } | { kind: 'taskId'; taskId: string }; diff --git a/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewToModelRequest.ts b/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewToModelRequest.ts index 62efeddc9..1d44e7796 100644 --- a/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewToModelRequest.ts +++ b/packages/shared/src/contracts/model3d/multiview-to-model/Model3dMultiviewToModelRequest.ts @@ -11,23 +11,23 @@ import type { Model3dMultiviewInputs } from './Model3dMultiviewInputs'; export type Model3dMultiviewToModelRequest = { inputs: Model3dMultiviewInputs; - model: Model3dModelVersion | null; - modelSeed: number | null; - textureSeed: number | null; - texture: boolean | null; - pbr: boolean | null; - textureQuality: Model3dTextureQuality | null; - textureVersion: Model3dTextureVersion | null; - delight: boolean | null; - geometryQuality: Model3dGeometryQuality | null; - textureAlignment: Model3dTextureAlignment | null; - faceLimit: number | null; - autoSize: boolean | null; - orientation: Model3dInputOrientation | null; - quad: boolean | null; - smartLowPoly: boolean | null; - generateParts: boolean | null; - compress: Model3dCompression | null; - exportUv: boolean | null; - exportOrientation: Model3dExportOrientation | null; + model?: Model3dModelVersion | null; + modelSeed?: number | null; + textureSeed?: number | null; + texture?: boolean | null; + pbr?: boolean | null; + textureQuality?: Model3dTextureQuality | null; + textureVersion?: Model3dTextureVersion | null; + delight?: boolean | null; + geometryQuality?: Model3dGeometryQuality | null; + textureAlignment?: Model3dTextureAlignment | null; + faceLimit?: number | null; + autoSize?: boolean | null; + orientation?: Model3dInputOrientation | null; + quad?: boolean | null; + smartLowPoly?: boolean | null; + generateParts?: boolean | null; + compress?: Model3dCompression | null; + exportUv?: boolean | null; + exportOrientation?: Model3dExportOrientation | null; }; diff --git a/packages/shared/src/contracts/model3d/text-to-model/Model3dTextToModelRequest.ts b/packages/shared/src/contracts/model3d/text-to-model/Model3dTextToModelRequest.ts index f576d2990..d1e6633b0 100644 --- a/packages/shared/src/contracts/model3d/text-to-model/Model3dTextToModelRequest.ts +++ b/packages/shared/src/contracts/model3d/text-to-model/Model3dTextToModelRequest.ts @@ -8,23 +8,23 @@ import type { Model3dTextureVersion } from '../common/Model3dTextureVersion'; export type Model3dTextToModelRequest = { prompt: string; - model: Model3dModelVersion | null; - negativePrompt: string | null; - imageSeed: number | null; - modelSeed: number | null; - textureSeed: number | null; - texture: boolean | null; - pbr: boolean | null; - textureQuality: Model3dTextureQuality | null; - textureVersion: Model3dTextureVersion | null; - delight: boolean | null; - geometryQuality: Model3dGeometryQuality | null; - faceLimit: number | null; - autoSize: boolean | null; - quad: boolean | null; - smartLowPoly: boolean | null; - generateParts: boolean | null; - compress: Model3dCompression | null; - exportUv: boolean | null; - exportOrientation: Model3dExportOrientation | null; + model?: Model3dModelVersion | null; + negativePrompt?: string | null; + imageSeed?: number | null; + modelSeed?: number | null; + textureSeed?: number | null; + texture?: boolean | null; + pbr?: boolean | null; + textureQuality?: Model3dTextureQuality | null; + textureVersion?: Model3dTextureVersion | null; + delight?: boolean | null; + geometryQuality?: Model3dGeometryQuality | null; + faceLimit?: number | null; + autoSize?: boolean | null; + quad?: boolean | null; + smartLowPoly?: boolean | null; + generateParts?: boolean | null; + compress?: Model3dCompression | null; + exportUv?: boolean | null; + exportOrientation?: Model3dExportOrientation | null; }; diff --git a/server-rs/crates/shared-contracts/src/model3d/image_to_model/request.rs b/server-rs/crates/shared-contracts/src/model3d/image_to_model/request.rs index 4698f1ad0..4b5e15892 100644 --- a/server-rs/crates/shared-contracts/src/model3d/image_to_model/request.rs +++ b/server-rs/crates/shared-contracts/src/model3d/image_to_model/request.rs @@ -13,27 +13,47 @@ use super::MODEL3D_TS_EXPORT_DIR; #[ts(export, export_to = MODEL3D_TS_EXPORT_DIR)] pub struct Model3dImageToModelRequest { pub input: String, + #[ts(optional = nullable)] pub model: Option, + #[ts(optional = nullable)] pub enable_image_autofix: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub model_seed: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub texture_seed: Option, + #[ts(optional = nullable)] pub texture: Option, + #[ts(optional = nullable)] pub pbr: Option, + #[ts(optional = nullable)] pub texture_quality: Option, + #[ts(optional = nullable)] pub texture_version: Option, + #[ts(optional = nullable)] pub delight: Option, + #[ts(optional = nullable)] pub texture_alignment: Option, + #[ts(optional = nullable)] pub geometry_quality: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub face_limit: Option, + #[ts(optional = nullable)] pub auto_size: Option, + #[ts(optional = nullable)] pub orientation: Option, + #[ts(optional = nullable)] pub quad: Option, + #[ts(optional = nullable)] pub smart_low_poly: Option, + #[ts(optional = nullable)] pub generate_parts: Option, + #[ts(optional = nullable)] pub compress: Option, + #[ts(optional = nullable)] pub export_uv: Option, + #[ts(optional = nullable)] pub export_orientation: Option, } diff --git a/server-rs/crates/shared-contracts/src/model3d/multiview_to_model/request.rs b/server-rs/crates/shared-contracts/src/model3d/multiview_to_model/request.rs index ef7c0a330..958a0eda7 100644 --- a/server-rs/crates/shared-contracts/src/model3d/multiview_to_model/request.rs +++ b/server-rs/crates/shared-contracts/src/model3d/multiview_to_model/request.rs @@ -14,8 +14,11 @@ use super::MODEL3D_TS_EXPORT_DIR; pub enum Model3dMultiviewInputs { Views { front: String, + #[ts(optional = nullable)] left: Option, + #[ts(optional = nullable)] back: Option, + #[ts(optional = nullable)] right: Option, }, TaskId { @@ -30,26 +33,45 @@ pub enum Model3dMultiviewInputs { #[ts(export, export_to = MODEL3D_TS_EXPORT_DIR)] pub struct Model3dMultiviewToModelRequest { pub inputs: Model3dMultiviewInputs, + #[ts(optional = nullable)] pub model: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub model_seed: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub texture_seed: Option, + #[ts(optional = nullable)] pub texture: Option, + #[ts(optional = nullable)] pub pbr: Option, + #[ts(optional = nullable)] pub texture_quality: Option, + #[ts(optional = nullable)] pub texture_version: Option, + #[ts(optional = nullable)] pub delight: Option, + #[ts(optional = nullable)] pub geometry_quality: Option, + #[ts(optional = nullable)] pub texture_alignment: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub face_limit: Option, + #[ts(optional = nullable)] pub auto_size: Option, + #[ts(optional = nullable)] pub orientation: Option, + #[ts(optional = nullable)] pub quad: Option, + #[ts(optional = nullable)] pub smart_low_poly: Option, + #[ts(optional = nullable)] pub generate_parts: Option, + #[ts(optional = nullable)] pub compress: Option, + #[ts(optional = nullable)] pub export_uv: Option, + #[ts(optional = nullable)] pub export_orientation: Option, } diff --git a/server-rs/crates/shared-contracts/src/model3d/text_to_model/request.rs b/server-rs/crates/shared-contracts/src/model3d/text_to_model/request.rs index 76f9ed78d..62a690e3b 100644 --- a/server-rs/crates/shared-contracts/src/model3d/text_to_model/request.rs +++ b/server-rs/crates/shared-contracts/src/model3d/text_to_model/request.rs @@ -12,27 +12,46 @@ use crate::model3d::common::{ #[ts(export, export_to = MODEL3D_TS_EXPORT_DIR)] pub struct Model3dTextToModelRequest { pub prompt: String, + #[ts(optional = nullable)] pub model: Option, + #[ts(optional = nullable)] pub negative_prompt: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub image_seed: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub model_seed: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub texture_seed: Option, + #[ts(optional = nullable)] pub texture: Option, + #[ts(optional = nullable)] pub pbr: Option, + #[ts(optional = nullable)] pub texture_quality: Option, + #[ts(optional = nullable)] pub texture_version: Option, + #[ts(optional = nullable)] pub delight: Option, + #[ts(optional = nullable)] pub geometry_quality: Option, #[ts(type = "number | null")] + #[ts(optional = nullable)] pub face_limit: Option, + #[ts(optional = nullable)] pub auto_size: Option, + #[ts(optional = nullable)] pub quad: Option, + #[ts(optional = nullable)] pub smart_low_poly: Option, + #[ts(optional = nullable)] pub generate_parts: Option, + #[ts(optional = nullable)] pub compress: Option, + #[ts(optional = nullable)] pub export_uv: Option, + #[ts(optional = nullable)] pub export_orientation: Option, }