本文整理汇总了C#中DDW.Swf.SwfWriter.AppendFixedNBits方法的典型用法代码示例。如果您正苦于以下问题:C# SwfWriter.AppendFixedNBits方法的具体用法?C# SwfWriter.AppendFixedNBits怎么用?C# SwfWriter.AppendFixedNBits使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类DDW.Swf.SwfWriter
的用法示例。
在下文中一共展示了SwfWriter.AppendFixedNBits方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: ToSwf
public void ToSwf(SwfWriter w)
{
w.AppendByte((byte)NumZoneData);
w.AppendFixedNBits(AlignmentCoordinate1, 16);
w.AppendFixedNBits(Range1, 16);
w.AppendFixedNBits(AlignmentCoordinate2, 16);
w.AppendFixedNBits(Range2, 16);
w.AppendBits(0, 6); // reserved
w.AppendBit(ZoneMaskX);
w.AppendBit(ZoneMaskY);
w.Align();
}
示例2: ToSwf
public void ToSwf(SwfWriter w)
{
uint len = 12;
w.AppendTagIDAndLength(this.TagType, len, false);
w.AppendUI16(TextId);
w.AppendBits(UseFlashType, 2);
w.AppendBits(GridFit, 3);
w.AppendBits(0, 3); // reserved
w.Align();
w.AppendFixedNBits(Thickness, 32);
w.AppendFixedNBits(Sharpness, 32);
w.AppendByte(0); // reserved
}
示例3: ToSwf
public void ToSwf(SwfWriter w)
{
w.AppendByte((byte)PrimitiveType);
w.AppendFixedNBits(FloatValue, 32);
}
示例4: ToSwf
public void ToSwf(SwfWriter w)
{
bool scale = (this.ScaleX != 1) || (this.ScaleY != 1);
w.AppendBit(scale);
if (scale)
{
uint bits = SwfWriter.MinimumBits((int)(this.ScaleX * 0x10000), (int)(this.ScaleY * 0x10000));
w.AppendBits(bits, 5);
w.AppendFixedNBits(this.ScaleX, bits);
w.AppendFixedNBits(this.ScaleY, bits);
}
bool rotate = (this.Rotate0 != 0) || (this.Rotate1 != 0);
w.AppendBit(rotate);
if (rotate)
{
uint bits = SwfWriter.MinimumBits((int)(this.Rotate0 * 0x10000), (int)(this.Rotate1 * 0x10000));
w.AppendBits(bits, 5);
w.AppendFixedNBits(this.Rotate0, bits);
w.AppendFixedNBits(this.Rotate1, bits);
}
// translate
uint minbits = 0;
if (this.TranslateX != 0 || this.TranslateY != 0)
{
minbits = SwfWriter.MinimumBits((int)this.TranslateX, (int)this.TranslateY);
}
w.AppendBits(minbits, 5);
w.AppendBits((uint)(this.TranslateX), minbits);
w.AppendBits((uint)(this.TranslateY), minbits);
w.Align();
}