library: texture: enum: add deserialization

This commit is contained in:
Bruno BELANYI 2020-03-18 15:42:37 +01:00
parent 3f1a166edf
commit 02874c9c22

View file

@ -1,10 +1,14 @@
use super::core::LinearColor;
use super::Point2D;
use serde::Deserialize;
/// All the existing `Texture` implementation.
#[serde(tag = "type")]
#[serde(rename_all = "lowercase")]
#[enum_dispatch::enum_dispatch]
#[derive(Debug, PartialEq)]
#[derive(Debug, PartialEq, Deserialize)]
pub enum TextureEnum {
#[serde(rename = "uniform")]
UniformTexture,
}