vmt_parser/material/
sky.rs

1use super::deserialize_path;
2use crate::TextureTransform;
3use serde::{Deserialize, Serialize};
4
5#[derive(Debug, Clone, Serialize, Deserialize)]
6pub struct SkyMaterial {
7    /// Defines an albedo texture.
8    #[serde(rename = "$basetexture", deserialize_with = "deserialize_path")]
9    pub base_texture: String,
10    /// Defines an albedo texture.
11    #[serde(
12        rename = "$hdrbasetexture",
13        default,
14        deserialize_with = "deserialize_path"
15    )]
16    pub hdr_base_texture: Option<String>,
17    /// Links the surface to a set of physical properties.
18    #[serde(rename = "$surfaceprop", default)]
19    pub surface_prop: Option<String>,
20    /// Transforms the texture before use in the material. This does not affect lightmaps on the surface.
21    #[serde(rename = "$basetexturetransform", default)]
22    pub base_texture_transform: TextureTransform,
23
24    /// Ignore z filtering
25    #[serde(rename = "$ignorez", default)]
26    pub ignore_z: bool,
27
28    /// Prevents fog from overdrawing a material.
29    #[serde(rename = "$nofog", default)]
30    pub no_fog: bool,
31
32    #[serde(rename = "$nomip", default)]
33    pub no_mip: bool,
34}