Esempio n. 1
0
        public override object Create(Stream fileStream, BinaryReader binaryReader, int offset, int endOffset)
        {
            NomalHeaderInfo info = new NomalHeaderInfo();

            fileStream.Seek(offset - 1, SeekOrigin.Begin);
            byte[] bits  = binaryReader.ReadBytes(2);
            int    bit0  = (bits[0] & (1 << 0));         //最右面
            int    bit15 = (bits[1] & (1 << 7));         //最左面

            info.DayOrNight = bit0 == 0 ? 0 : 1;         //bit0
            info.AscOrbit   = bit15 == 0 ? false : true; //bit15
            base.Create(fileStream, binaryReader, offset, endOffset);
            return(info);
        }
Esempio n. 2
0
 public D1BDHeader(object commonInfoFor1BD, object qualityCheckInfoFor1BD,
                   object scaleInfoFor1BD, object radiantionConvertArgsInfoFor1BD,
                   object geographEnvelopeInfoFor1BD,
                   object simluateRemoteMeasureMeasureInfoFor1BD,
                   object nomalHeaderInfo, bool isBigEndian)
 {
     _commonInfoFor1BD                = (CommonInfoFor1BD)commonInfoFor1BD;
     _qualityCheckInfoFor1BD          = (QualityCheckInfoFor1BD)qualityCheckInfoFor1BD;
     _sacleInfoFor1BD                 = (ScaleInfoFor1BD)scaleInfoFor1BD;
     _radiantionConvertArgsInfoFor1BD = (RadiantionConvertArgsInfoFor1BD)radiantionConvertArgsInfoFor1BD;
     _geographLocationInfoFor1BD      = (GeographLocationInfoFor1BD)geographEnvelopeInfoFor1BD;
     _simluateRemoteMeasureInfoFor1BD = (SimluateRemoteMeasureInfoFor1BD)simluateRemoteMeasureMeasureInfoFor1BD;
     _nomalHeaderInfo                 = (NomalHeaderInfo)nomalHeaderInfo;
     _isBigEndian = isBigEndian;
 }