Changeset 2860 in ntrip
- Timestamp:
- Jan 19, 2011, 11:06:41 AM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/rtcm3torinex/lib/rtcm3torinex.c
r2850 r2860 131 131 bitfield = (bitfield<<8)|*(data++); \ 132 132 numbits += 8; \ 133 } \ 134 } 135 136 /* extract bits from data stream 137 b = variable to store result, a = number of bits */ 138 #define GETBITS64(b, a) \ 139 { \ 140 if(((a) > 56) && ((a)-56) > numbits) \ 141 { \ 142 uint64_t x; \ 143 GETBITS(x, 56) \ 144 LOADBITS((a)-56) \ 145 b = ((x<<((a)-56)) | (bitfield<<(sizeof(bitfield)*8-numbits)) \ 146 >>(sizeof(bitfield)*8-((a)-56))); \ 147 numbits -= ((a)-56); \ 148 } \ 149 else \ 150 { \ 151 GETBITS(b, a) \ 133 152 } \ 134 153 } … … 1060 1079 GETBITS(syncf, 1) 1061 1080 SKIPBITS(3+7+1) 1062 GETBITS (satmask, RTCM3_MSM_NUMSAT)1081 GETBITS64(satmask, RTCM3_MSM_NUMSAT) 1063 1082 1064 1083 /* http://gurmeetsingh.wordpress.com/2008/08/05/fast-bit-counting-routines/ */ … … 1069 1088 ++numsig; 1070 1089 i = numsat*numsig; 1071 GETBITS (cellmask, (unsigned)i)1090 GETBITS64(cellmask, (unsigned)i) 1072 1091 1073 1092 switch(type % 10)
Note:
See TracChangeset
for help on using the changeset viewer.