<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Network compression: bitfields</title><link>http://blogs.msdn.com/shawnhar/archive/2007/12/28/network-compression-bitfields.aspx</link><description>Bitfields are just like this most totally awesome old-skool way of packing data, dude! C# programmers rarely have an excuse to mess with such things, but network packet compression offers an excuse par excellence, so let us mess away. A byte is 8 bits.</description><dc:language>en</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: Network compression: bitfields</title><link>http://blogs.msdn.com/shawnhar/archive/2007/12/28/network-compression-bitfields.aspx#6895545</link><pubDate>Sat, 29 Dec 2007 13:20:36 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6895545</guid><dc:creator>Ultrahead</dc:creator><description>&lt;p&gt;The best so far in the series. It has my five!&lt;/p&gt;
</description></item><item><title>re: Network compression: bitfields</title><link>http://blogs.msdn.com/shawnhar/archive/2007/12/28/network-compression-bitfields.aspx#6899310</link><pubDate>Sat, 29 Dec 2007 21:24:23 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6899310</guid><dc:creator>JoelMartinez</dc:creator><description>&lt;p&gt;wow man :-) this is mad crazy yo&lt;/p&gt;
</description></item><item><title>re: Network compression: bitfields</title><link>http://blogs.msdn.com/shawnhar/archive/2007/12/28/network-compression-bitfields.aspx#6906434</link><pubDate>Sun, 30 Dec 2007 11:11:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:6906434</guid><dc:creator>trayle</dc:creator><description>&lt;p&gt;This shows one of the few drawbacks of C#.&lt;/p&gt;
&lt;p&gt;In C and C++ you can use bitfields in structs something like:&lt;/p&gt;
&lt;p&gt;[code]&lt;/p&gt;
&lt;p&gt;struct Animal&lt;/p&gt;
&lt;p&gt;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp;bool isAlive: 1; &amp;nbsp; &amp;nbsp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp;bool isFiring: 1; &amp;nbsp; &amp;nbsp;&lt;/p&gt;
&lt;p&gt; &amp;nbsp;char Species: 4; &lt;/p&gt;
&lt;p&gt;};&lt;/p&gt;
&lt;p&gt;[/code] &lt;/p&gt;
&lt;p&gt;But in C# to get similar functionality you would have to create a class that handles things behind the scenes. &amp;nbsp;Probably a safer way to go.&lt;/p&gt;
</description></item></channel></rss>