static glTF_KHR_materials_emissive_strength Deserialize(JsonNode json) { var extension = new glTF_KHR_materials_emissive_strength(); if (json.TryGet(nameof(emissiveStrength), out JsonNode found)) { extension.emissiveStrength = found.GetSingle(); } return(extension); }
public static bool TryGet(glTFExtension src, out glTF_KHR_materials_emissive_strength extension) { if (src is UniGLTF.glTFExtensionImport extensions) { foreach (var kv in extensions.ObjectItems()) { if (kv.Key.GetUtf8String() == ExtensionNameUtf8) { extension = Deserialize(kv.Value); return(true); } } } extension = default; return(false); }