132 references to Native
PresentationCore (132)
MS\Internal\Ink\InkSerializedFormat\AlgoModule.cs (1)
182bitCount = Native.BitsPerInt;//32
MS\Internal\Ink\InkSerializedFormat\CustomAttributeSerializer.cs (5)
597int count = (int)(memStream.Length - 2) / Native.BitsPerByte; // size of one element 605int count = (int)(memStream.Length - 2) / Native.BitsPerByte; // size of one element 621int count = (int)(memStream.Length - 2) / Native.BitsPerByte; // size of one element 629int count = (int)(memStream.Length - 2) / Native.BitsPerByte; // size of one element 647int count = (int)((memStream.Length - 2) / Native.SizeOfDecimal); // size of one element
MS\Internal\Ink\InkSerializedFormat\DrawingAttributeSerializer.cs (5)
266Color color = Color.FromRgb((byte)(dw & 0xff), (byte)((dw & 0xff00) >> Native.BitsPerByte), (byte)((dw & 0xff0000) >> (Native.BitsPerByte * 2))); 502uint colorVal = r + (g << Native.BitsPerByte) + (b << (Native.BitsPerByte * 2)); 667uint cb = Native.SizeOfUShort; // For header NO_COMPRESS
MS\Internal\Ink\InkSerializedFormat\GorillaCodec.cs (19)
221maxShort = Math.Max((ushort)shortReader.ReadUInt16Reverse(Native.BitsPerShort), maxShort); 222UpdateMinMax((int)intReader.ReadUInt32Reverse(Native.BitsPerInt), ref maxInt, ref minInt); 232maxShort = Math.Max((ushort)shortReader.ReadUInt16Reverse(Native.BitsPerShort), maxShort); 247while ((0 != (ulAbsMax >> bitCount)) && (bitCount < (uint)Native.BitsPerByte)) 260while ((0 != (ulAbsMax >> shortBitCount)) && (shortBitCount < (uint)Native.BitsPerShort)) 370bitCount = (int)(Native.SizeOfInt << 3); 423bitCount = Native.BitsPerInt; 428bitCount = Native.BitsPerShort; 433bitCount = Native.BitsPerByte; 466return (int)reader.ReadUInt32Reverse(Native.BitsPerInt); 470return (int)reader.ReadUInt16Reverse(Native.BitsPerShort); 474return (int)reader.ReadByte(Native.BitsPerByte); 507bitCount = (int)(Native.SizeOfInt << 3); 592bitCount = Native.BitsPerInt; 594bitsToWrite = Native.BitsPerInt; 603bitCount = Native.BitsPerShort; 605bitsToWrite = Native.BitsPerShort; 614bitCount = Native.BitsPerByte; 616bitsToWrite = Native.BitsPerByte;
MS\Internal\Ink\InkSerializedFormat\GuidTagList.cs (6)
207uint ul = (uint)(_customGuids.Count * Native.SizeOfGuid); 233stream.Write(guid.ToByteArray(), 0, (int)Native.SizeOfGuid); 253uint count = size / Native.SizeOfGuid; 254byte[] guids = new byte[Native.SizeOfGuid]; 260uint bytesRead = StrokeCollectionSerializer.ReliableRead(strm, guids, Native.SizeOfGuid); 263if ( bytesRead == Native.SizeOfGuid )
MS\Internal\Ink\InkSerializedFormat\InkSerializer.cs (8)
1289cbRead = xform.Size * Native.SizeOfDouble; 1293cbRead = xform.Size * Native.SizeOfFloat; 1528cbEntry += Native.SizeOfFloat; 2054uint cbStrokeId = (uint)(strokes.Count * Native.SizeOfInt + 1 + SerializationHelper.VarSize((uint)strokes.Count)); // 1 is for the compression header 2067cbWrote += Native.SizeOfInt; 2343cbLocal = xform.Size * Native.SizeOfFloat; 2415cbData += Native.SizeOfDouble; 2420cbData += Native.SizeOfFloat;
MS\Internal\Ink\InkSerializedFormat\ISFTagAndGuidCache.cs (35)
56Native.SizeOfInt, // X 0 57Native.SizeOfInt, // Y 1 58Native.SizeOfInt, // Z 2 59Native.SizeOfInt, // PACKET_STATUS 3 602 * Native.SizeOfUInt, // FILETIME : TIMER_TICK 4 61Native.SizeOfUInt, // SERIAL_NUMBER 5 62Native.SizeOfUShort, // NORMAL_PRESSURE 6 63Native.SizeOfUShort, // TANGENT_PRESSURE 7 64Native.SizeOfUShort, // BUTTON_PRESSURE 8 65Native.SizeOfFloat, // X_TILT_ORIENTATION 9 66Native.SizeOfFloat, // Y_TILT_ORIENTATION 10 67Native.SizeOfFloat, // AZIMUTH_ORIENTATION 11 68Native.SizeOfInt, // ALTITUDE_ORIENTATION 12 69Native.SizeOfInt, // TWIST_ORIENTATION 13 70Native.SizeOfUShort, // PITCH_ROTATION 14 71Native.SizeOfUShort, // ROLL_ROTATION 15 72Native.SizeOfUShort, // YAW_ROTATION 16 73Native.SizeOfUShort, // PEN_STYLE 17 74Native.SizeOfUInt, // COLORREF: COLORREF 18 75Native.SizeOfUInt, // PEN_WIDTH 19 76Native.SizeOfUInt, // PEN_HEIGHT 20 77Native.SizeOfByte, // PEN_TIP 21 78Native.SizeOfUInt, // DRAWING_FLAGS 22 79Native.SizeOfUInt, // CURSORID 23 825 * Native.SizeOfUInt, // INKMETRICS 26 833 * Native.SizeOfUInt, // GUIDE_STRUCTURE 27 848 * Native.SizeOfUShort, // SYSTEMTIME TIME_STAMP 28 85Native.SizeOfUShort, // LANGUAGE 29 86Native.SizeOfByte, // TRANSPARENCY 30 87Native.SizeOfUInt, // CURVE_FITTING_ERROR 31 89Native.SizeOfInt, // CURSORDOWN 33 90Native.SizeOfInt, // SECONDARYTIPSWITCH 34 91Native.SizeOfInt, // BARRELDOWN 35 92Native.SizeOfInt, // TABLETPICK 36 93Native.SizeOfInt, // ROP 37
MS\Internal\Ink\InkSerializedFormat\LZCodec.cs (5)
53byte1 = reader.ReadByte(Native.BitsPerByte); 62byte1 = reader.ReadByte(Native.BitsPerByte); 68writer.Write(byte1, Native.BitsPerByte); 76byte2 = reader.ReadByte(Native.BitsPerByte); 85writer.Write(byte1, Native.BitsPerByte);
MS\Internal\Ink\InkSerializedFormat\StrokeSerializer.cs (14)
477int fullBytesForButtonsPerPacket = buttonCount / Native.BitsPerByte; 480int partialBitsForButtonsPerPacket = buttonCount % Native.BitsPerByte; 483localBytesRead = (uint)((buttonCount * pointCount + 7) / Native.BitsPerByte); 490int buttonSizeInBytes = (buttonCount + 7)/Native.BitsPerByte; 506buttonData[byteCounter++] = bitReader.ReadByte(Native.BitsPerByte); 571int nBtnDim = (buttonCount + 7) / Native.BitsPerByte; 574int pointCountOfFullIntegers = (int)(nBtnDim / Native.SizeOfInt); 577int pointCountOfPartialBytes = (int)(nBtnDim % Native.SizeOfInt); 586iBtnByte = (int)(iInt * Native.SizeOfInt); 592packets[iPacket] = ((int)((uint)((buttonData[iBtnByte] << (Native.BitsPerByte * 3)) | (buttonData[iBtnByte + 1] << (Native.BitsPerByte * 2)) | (buttonData[iBtnByte + 2] << Native.BitsPerByte) | (buttonData[iBtnByte + 3])))); 601iBtnByte = (int)(pointCountOfFullIntegers * Native.SizeOfInt); 613btn = (btn << Native.BitsPerByte) | (buttonData[iBtnByte + iPart]);
src\Microsoft.DotNet.Wpf\src\Shared\MS\Internal\Ink\BitStream.cs (34)
25_bufferLengthInBits = (uint)buffer.Length * (uint)Native.BitsPerByte; 42_bufferLengthInBits = (uint)(buffer.Length - startIndex) * (uint)Native.BitsPerByte; 54if (bufferLengthInBits > (buffer.Length * Native.BitsPerByte)) 68if (countOfBits > Native.BitsPerLong || countOfBits <= 0) 75int countToRead = (int)Native.BitsPerByte; 97if (countOfBits > Native.BitsPerShort || countOfBits <= 0) 105int countToRead = (int)Native.BitsPerByte; 125if (countOfBits > Native.BitsPerShort|| countOfBits <= 0) 134int countToRead = (int)Native.BitsPerByte; 141b <<= (fullBytesRead * Native.BitsPerByte); 155if (countOfBits > Native.BitsPerInt || countOfBits <= 0) 163int countToRead = (int)Native.BitsPerByte; 183if (countOfBits > Native.BitsPerInt || countOfBits <= 0) 192int countToRead = (int)Native.BitsPerByte; 199b <<= (fullBytesRead * Native.BitsPerByte); 234if (countOfBits > Native.BitsPerByte || countOfBits <= 0) 255int rightShiftPartialByteBy = Native.BitsPerByte - countOfBits; 275int rightShiftPartialByteBy = Native.BitsPerByte - countOfBits; 279int rightShiftNextByteBy = Math.Abs((countOfBits - _cbitsInPartialByte) - Native.BitsPerByte); 289_cbitsInPartialByte = Native.BitsPerByte - (countOfBits - _cbitsInPartialByte); 369if (countOfBits <= 0 || countOfBits > Native.BitsPerInt) 375int fullBytes = countOfBits / Native.BitsPerByte; 379int bitsToWrite = countOfBits % Native.BitsPerByte; 383byte byteOfData = (byte)(bits >> (fullBytes * Native.BitsPerByte)); 395bitsToWrite = Native.BitsPerByte; 408if (countOfBits <= 0 || countOfBits > Native.BitsPerInt) 413int fullBytes = countOfBits / Native.BitsPerByte; 417int bitsToWrite = countOfBits % Native.BitsPerByte; 424byte byteOfData = (byte)(bits >> (x * Native.BitsPerByte)); 425Write(byteOfData, Native.BitsPerByte); 437if (countOfBits <= 0 || countOfBits > Native.BitsPerByte) 451buffer |= (byte)((bits & (0xFF >> (Native.BitsPerByte - countOfBits))) >> (countOfBits - _remaining)); 456buffer |= (byte)((bits & (0xFF >> (Native.BitsPerByte - countOfBits))) << (_remaining - countOfBits)); 465_remaining = Native.BitsPerByte - (countOfBits - _remaining);