<story><title>Quake 2 Source Code Review</title><url>http://fabiensanglard.net/quake2/index.php</url></story><parent_chain></parent_chain><comment><author>xedarius</author><text>I really respect Carmack, he is one of the few programmers I&apos;d describe as an industry trend setter. I&apos;ve worked on many games in my career, and seen a lot of engines. When you read through the Q2 and perhaps a better example is the Q3 engine source, you sit there and think, hang on .. where&apos;s the rest of the code? He takes a complex problem and reduces it to a set of simple components, and reuses those components. This is incredibly hard to do.&lt;p&gt;What the article doesn&apos;t impress upon people is the effect Carmacks code has on the industry. The shaders in Quake 3 were a huge thing, now seems so obvious. I have no evidence for this, however I wouldn&apos;t be surprised if Q3 shaders are the reason we have vertex/pixel shaders in hardware today.</text></comment>
<story><title>Quake 2 Source Code Review</title><url>http://fabiensanglard.net/quake2/index.php</url></story><parent_chain></parent_chain><comment><author>0x0</author><text>I noticed this comment in the &quot;notes.html&quot;:&lt;p&gt;&lt;pre&gt;&lt;code&gt;  // Set the floating point precision ...
  _controlfp                           
  // Question: Why do that for every frames ? Probably because precision is altered during the loop execution.
  // Answer: The is no other call to this function. It appears that floating point precision remains the same during program execution.
&lt;/code&gt;&lt;/pre&gt;
I seem to vaguely recall reading something about some versions of Windows not preserving the FPU state across task switches. Could it be that this call to configure the FPU for every frame is a workaround for that?</text></comment>