55 references to BitsPerByte
PresentationCore (55)
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\CustomAttributeSerializer.cs (4)
639
int count = (int)(memStream.Length - 2) / Native.
BitsPerByte
; // size of one element
647
int count = (int)(memStream.Length - 2) / Native.
BitsPerByte
; // size of one element
663
int count = (int)(memStream.Length - 2) / Native.
BitsPerByte
; // size of one element
671
int count = (int)(memStream.Length - 2) / Native.
BitsPerByte
; // size of one element
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\DrawingAttributeSerializer.cs (4)
287
Color color = Color.FromRgb((byte)(dw & 0xff), (byte)((dw & 0xff00) >> Native.
BitsPerByte
), (byte)((dw & 0xff0000) >> (Native.
BitsPerByte
* 2)));
534
uint colorVal = r + (g << Native.
BitsPerByte
) + (b << (Native.
BitsPerByte
* 2));
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\GorillaCodec.cs (5)
264
while ((0 != (ulAbsMax >> bitCount)) && (bitCount < (uint)Native.
BitsPerByte
))
459
bitCount = Native.
BitsPerByte
;
500
return (int)reader.ReadByte(Native.
BitsPerByte
);
664
bitCount = Native.
BitsPerByte
;
666
bitsToWrite = Native.
BitsPerByte
;
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\LZCodec.cs (5)
67
byte1 = reader.ReadByte(Native.
BitsPerByte
);
76
byte1 = reader.ReadByte(Native.
BitsPerByte
);
82
writer.Write(byte1, Native.
BitsPerByte
);
90
byte2 = reader.ReadByte(Native.
BitsPerByte
);
99
writer.Write(byte1, Native.
BitsPerByte
);
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\StrokeSerializer.cs (10)
513
int fullBytesForButtonsPerPacket = buttonCount / Native.
BitsPerByte
;
516
int partialBitsForButtonsPerPacket = buttonCount % Native.
BitsPerByte
;
519
localBytesRead = (uint)((buttonCount * pointCount + 7) / Native.
BitsPerByte
);
526
int buttonSizeInBytes = (buttonCount + 7)/Native.
BitsPerByte
;
542
buttonData[byteCounter++] = bitReader.ReadByte(Native.
BitsPerByte
);
607
int nBtnDim = (buttonCount + 7) / Native.
BitsPerByte
;
628
packets[iPacket] = ((int)((uint)((buttonData[iBtnByte] << (Native.
BitsPerByte
* 3)) | (buttonData[iBtnByte + 1] << (Native.
BitsPerByte
* 2)) | (buttonData[iBtnByte + 2] << Native.
BitsPerByte
) | (buttonData[iBtnByte + 3]))));
649
btn = (btn << Native.
BitsPerByte
) | (buttonData[iBtnByte + iPart]);
Shared\MS\Internal\Ink\BitStream.cs (27)
33
_bufferLengthInBits = (uint)buffer.Length * (uint)Native.
BitsPerByte
;
51
_bufferLengthInBits = (uint)(buffer.Length - startIndex) * (uint)Native.
BitsPerByte
;
63
if (bufferLengthInBits > (buffer.Length * Native.
BitsPerByte
))
84
int countToRead = (int)Native.
BitsPerByte
;
114
int countToRead = (int)Native.
BitsPerByte
;
143
int countToRead = (int)Native.
BitsPerByte
;
150
b <<= (fullBytesRead * Native.
BitsPerByte
);
172
int countToRead = (int)Native.
BitsPerByte
;
201
int countToRead = (int)Native.
BitsPerByte
;
208
b <<= (fullBytesRead * Native.
BitsPerByte
);
243
if (countOfBits > Native.
BitsPerByte
|| countOfBits <= 0)
264
int rightShiftPartialByteBy = Native.
BitsPerByte
- countOfBits;
284
int rightShiftPartialByteBy = Native.
BitsPerByte
- countOfBits;
288
int rightShiftNextByteBy = Math.Abs((countOfBits - _cbitsInPartialByte) - Native.
BitsPerByte
);
298
_cbitsInPartialByte = Native.
BitsPerByte
- (countOfBits - _cbitsInPartialByte);
387
int fullBytes = countOfBits / Native.
BitsPerByte
;
391
int bitsToWrite = countOfBits % Native.
BitsPerByte
;
395
byte byteOfData = (byte)(bits >> (fullBytes * Native.
BitsPerByte
));
407
bitsToWrite = Native.
BitsPerByte
;
425
int fullBytes = countOfBits / Native.
BitsPerByte
;
429
int bitsToWrite = countOfBits % Native.
BitsPerByte
;
436
byte byteOfData = (byte)(bits >> (x * Native.
BitsPerByte
));
437
Write(byteOfData, Native.
BitsPerByte
);
449
if (countOfBits <= 0 || countOfBits > Native.
BitsPerByte
)
463
buffer |= (byte)((bits & (0xFF >> (Native.
BitsPerByte
- countOfBits))) >> (countOfBits - _remaining));
468
buffer |= (byte)((bits & (0xFF >> (Native.
BitsPerByte
- countOfBits))) << (_remaining - countOfBits));
477
_remaining = Native.
BitsPerByte
- (countOfBits - _remaining);