public void WriteAsModel(System.IO.Stream fileStream)
{
XmlDocument pssg = new XmlDocument();
pssg.AppendChild(pssg.CreateXmlDeclaration("1.0", "utf-8", string.Empty));
pssg.AppendChild(pssg.CreateElement("COLLADA", "http://www.collada.org/2008/03/COLLADASchema"));
pssg.DocumentElement.AppendChild(pssg.CreateAttribute("version"));
pssg.DocumentElement.Attributes["version"].InnerText = "1.5.0";
if (rootNode.HasAttributes)
{
XmlElement asset = pssg.CreateElement("asset");
if (rootNode.HasAttribute("creator"))
{
asset.AppendChild(pssg.CreateElement("contributor"));
asset.LastChild.AppendChild(pssg.CreateElement("author"));
asset.LastChild.LastChild.InnerText = rootNode["creator"].ToString();
}
// TODO: unit meter 1, created, up axis, scale?, creatorMachine
}
}