Expand asset browser subasset workflow
CI / Format, lint, test, build (push) Waiting to run

This commit is contained in:
Rbanh committed 2026-06-06 01:38:27 -04:00
1 parent f29712d158
commit 3e053a81ab
123 files changed
+31930 -1404

No files matched your search

+34 -1
View File
@@ -1,7 +1,40 @@
//! Thumbnail generation job descriptor.
use shared::MaterialDesc;
#[derive(Debug, Clone)]
pub struct ThumbnailJob {
pub cache_key: String,
pub model_path: String,
pub source: ThumbnailJobSource,
}
#[derive(Debug, Clone)]
pub enum ThumbnailJobSource {
Model {
model_path: String,
},
MeshSubAsset {
model_path: String,
mesh_label: String,
material_label: Option<String>,
},
SourceMaterial {
model_path: String,
material_label: String,
},
MaterialAsset {
label: String,
material: MaterialDesc,
},
}
impl ThumbnailJobSource {
pub fn label(&self) -> &str {
match self {
Self::Model { model_path }
| Self::MeshSubAsset { model_path, .. }
| Self::SourceMaterial { model_path, .. } => model_path,
Self::MaterialAsset { label, .. } => label,
}
}
}