pub struct Appearance {
pub materials: Option<Vec<MaterialObject>>,
pub textures: Option<Vec<TextureObject>>,
pub vertices_texture: Option<Vec<[f64; 2]>>,
pub default_theme_texture: Option<String>,
pub default_theme_material: Option<String>,
}Expand description
The document-level appearance library.
cityjson.schema.json#/properties/appearance names five members and then
declares "additionalProperties": false, exactly as the MaterialObject
and TextureObject it contains do —
cityjsonfeature.schema.json#/properties/appearance carries the same
clause verbatim, so the rule holds at both document levels. Hence
deny_unknown_fields here too: an extra member is not CityJSON, and
dropping it silently at this level while rejecting it one level down would
be inconsistent as well as lossy.
Fields§
§materials: Option<Vec<MaterialObject>>§textures: Option<Vec<TextureObject>>§vertices_texture: Option<Vec<[f64; 2]>>The (u, v) texture vertices. The schema pins each one to
minItems: 2, maxItems: 2, so it is [f64; 2] and not Vec<f64>:
a fixed-size array rejects a 1- or 3-element vertex on read and makes
one unwritable, exactly as [f64; 3] does for a colour and [f64; 6]
for a geographical extent.
default_theme_texture: Option<String>§default_theme_material: Option<String>Trait Implementations§
Source§impl Clone for Appearance
impl Clone for Appearance
Source§fn clone(&self) -> Appearance
fn clone(&self) -> Appearance
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more