예제 #1
0
파일: Element.cs 프로젝트: mcguirepr/bmff
        static Element FromStream(Stream source)
        {
            var     identifier  = new ClassIdentifier(source);
            var     elementType = ElementDefinitions[identifier];
            Element element     = elementType != null ? (Element)Activator.CreateInstance(elementType) : new UnknownElement(identifier);

            element.Initialize(source);
            return(element);
        }
예제 #2
0
 public ElementAttribute(ClassIdentifier identifier, ElementTypes type, string description = null) : this(type, description)
 {
     ClassIdentifier = identifier;
 }
예제 #3
0
 public ElementAttribute(byte a, byte b, byte c, byte d, ElementTypes type, string description = null) : this(type, description)
 {
     ClassIdentifier = new ClassIdentifier(a, b, c, d);
 }
예제 #4
0
 public ElementAttribute(int identifier, ElementTypes type, string description = null) : this(type, description)
 {
     ClassIdentifier = new ClassIdentifier(identifier);
 }
예제 #5
0
파일: Element.cs 프로젝트: mcguirepr/bmff
        protected Element(Stream source)
        {
            var identifier = new ClassIdentifier(source);

            Initialize(source);
        }