public static AnimationChannel Deserialize(GLTFRoot root, JsonReader reader, Animation anim) { var animationChannel = new AnimationChannel(); while (reader.Read() && reader.TokenType == JsonToken.PropertyName) { var curProp = reader.Value.ToString(); switch (curProp) { case "sampler": animationChannel.Sampler = AnimationSamplerId.Deserialize(root, anim, reader); break; case "target": animationChannel.Target = AnimationChannelTarget.Deserialize(root, reader); break; default: animationChannel.DefaultPropertyDeserializer(root, reader); break; } } return(animationChannel); }
public AnimationChannel(AnimationChannel animationChannel, GLTFRoot root) : base(animationChannel) { if (animationChannel == null) { return; } Sampler = new AnimationSamplerId(animationChannel.Sampler, root); Target = new AnimationChannelTarget(animationChannel.Target, root); }
public AnimationSamplerId(AnimationSamplerId sampler, GLTFRoot root) { Id = sampler.Id; GLTFAnimation = sampler.GLTFAnimation; Root = root; }