-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
3dtiles: EXT_texture_webpを利用する (#604)
<!-- Close or Related Issues --> Close #597 ### Description(変更内容) <!-- Please describe the motivation behind this PR and the changes it introduces. --> <!-- 何のために、どのような変更をしますか? --> - テクスチャにwebpが含まれている場合、EXT_texture_webpの拡張機能を利用するように変更 ### Notes(連絡事項) <!-- If manual testing is required, please describe the procedure. --> <!-- 手動の動作確認が必要なら、手順を簡単に伝えてください。その他連絡事項など。 --> - None / なし
- Loading branch information
1 parent
11e5a8b
commit 944b234
Showing
6 changed files
with
76 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,3 @@ | ||
pub mod gltf; | ||
pub mod mesh; | ||
pub mod texture; |
19 changes: 19 additions & 0 deletions
19
nusamai-gltf/nusamai-gltf-json/src/models/extensions/texture/mod.rs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use serde::{Deserialize, Serialize}; | ||
use serde_json::Value; | ||
use std::collections::HashMap; | ||
|
||
#[derive(Serialize, Deserialize, Debug, Default, PartialEq)] | ||
pub struct ExtTextureWebp { | ||
pub source: u32, | ||
} | ||
|
||
#[derive(Serialize, Deserialize, Debug, Default, PartialEq)] | ||
|
||
pub struct TextureExtensions { | ||
#[serde(skip_serializing_if = "Option::is_none")] | ||
#[serde(rename = "EXT_texture_webp")] | ||
pub ext_texture_webp: Option<ExtTextureWebp>, | ||
|
||
#[serde(flatten)] | ||
pub others: HashMap<String, Value>, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters