예제 #1
0
 public Boolean Equals(ILFNode ilfNode)
 {
     if (this.Object != ilfNode.Object) {
       return false;
     }
     if (this.Cell != ilfNode.Cell) {
       return false;
     }
     if (this.RotationMatrix[0][0] != ilfNode.RotationMatrix[0][0]) {
       return false;
     }
     if (this.RotationMatrix[0][1] != ilfNode.RotationMatrix[0][1]) {
       return false;
     }
     if (this.RotationMatrix[0][2] != ilfNode.RotationMatrix[0][2]) {
       return false;
     }
     if (this.RotationMatrix[1][0] != ilfNode.RotationMatrix[1][0]) {
       return false;
     }
     if (this.RotationMatrix[1][1] != ilfNode.RotationMatrix[1][1]) {
       return false;
     }
     if (this.RotationMatrix[1][2] != ilfNode.RotationMatrix[1][2]) {
       return false;
     }
     if (this.RotationMatrix[2][0] != ilfNode.RotationMatrix[2][0]) {
       return false;
     }
     if (this.RotationMatrix[2][1] != ilfNode.RotationMatrix[2][1]) {
       return false;
     }
     if (this.RotationMatrix[2][2] != ilfNode.RotationMatrix[2][2]) {
       return false;
     }
     if (this.W1 != ilfNode.W1) {
       return false;
     }
     if (this.W2 != ilfNode.W2) {
       return false;
     }
     if (this.W3 != ilfNode.W3) {
       return false;
     }
     return true;
 }
예제 #2
0
        private void ParseStream(Stream Stream)
        {
            Stream.Seek(0L, SeekOrigin.Begin);
              BinaryReader binaryReader = new BinaryReader(Stream);

              String FORMID = new String(binaryReader.ReadChars(4));
              Int32 FORMLength = binaryReader.ReadInt32();
              String INLYFORMID = new String(binaryReader.ReadChars(8));
              Int32 INLYFORMLength = binaryReader.ReadInt32();
              String t0000 = new String(binaryReader.ReadChars(4));

              while (Stream.Position < Stream.Length) {
            String NODEID = new String(binaryReader.ReadChars(4));
            Int32 NODELength = binaryReader.ReadInt32();

            ILFNode ilfNode = new ILFNode();
            ilfNode.Object = Utilities.ReadString(binaryReader);
            ilfNode.Cell = Utilities.ReadString(binaryReader);
            ilfNode.RotationMatrix[0][0] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[0][1] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[0][2] = binaryReader.ReadSingle();
            ilfNode.W1 = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[1][0] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[1][1] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[1][2] = binaryReader.ReadSingle();
            ilfNode.W2 = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[2][0] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[2][1] = binaryReader.ReadSingle();
            ilfNode.RotationMatrix[2][2] = binaryReader.ReadSingle();
            ilfNode.W3 = binaryReader.ReadSingle();

            this.m_Nodes.Add(ilfNode);
              }

              binaryReader.Close();
        }