Remove colour attributes from body and strip most of the font tags out

This commit is contained in:
James Gregory 2013-12-30 13:57:02 +11:00
commit c1f88ddb41
362 changed files with 1632 additions and 1706 deletions

View file

@ -24,7 +24,7 @@
<!--CHAPTER=55//-->
<!--PAGES=1040-1044//-->
<!--UNASSIGNED1//-->
<!--UNASSIGNED2//--></HEAD><BODY LINK=#0000FF ALINK=#000099 VLINK=#0000FF BGCOLOR=#FFFFFF>
<!--UNASSIGNED2//--></HEAD><body>
<CENTER>
<TABLE BORDER>
@ -39,7 +39,7 @@
<P>This is where it gets a little complicated. In write mode 3 (which incidentally is not available on the EGA), each byte value that the CPU writes to the VGA does not get written to display memory. Instead, it turns into the bit mask. (Actually, it&rsquo;s ANDed with the Bit Mask register, and the result becomes the bit mask, but we&rsquo;ll leave the Bit Mask register set to 0xFF, so the CPU value will become the bit mask.) The bit mask selects, on a bit-by-bit basis, between the data in the latches for each plane (the previously loaded background color, in this case) and the foreground color. Where does the foreground color come from, if not from the CPU? From the Set/Reset register, as shown in Figure 55.3. Thus, each byte written by the CPU (font data, presumably) selects foreground or background color for each of eight pixels, all done with a single write to display memory.
</P>
<P><A NAME="Fig3"><!-- </A><A HREF="javascript:displayWindow('images/55-03.jpg',407,375 )"> --><IMG SRC="images/55-03.jpg"><BR><!-- </A>
<BR><A HREF="javascript:displayWindow('images/55-03.jpg',407,375)"> --><FONT COLOR="#000077"><B>Figure 55.3</B></FONT></A>&nbsp;&nbsp;<I>The data path in write mode 3.</I>
<BR><A HREF="javascript:displayWindow('images/55-03.jpg',407,375)"> --><B>Figure 55.3</B></A>&nbsp;&nbsp;<I>The data path in write mode 3.</I>
</P>
<P>I know this sounds pretty esoteric, but think of it this way: The latches hold the background color in a form suitable for writing eight background pixels (one full byte) at a pop. Write mode 3 allows each CPU byte to punch holes in the background color provided by the latches, holes through which the foreground color from the Set/Reset register can flow. The result is that a single write draws exactly the combination of foreground and background pixels described by each font byte written by the CPU. It may help to look at Listing 55.4, which shows The BitMan&rsquo;s technique in action. And yes, this technique is absolutely worth the trouble; it&rsquo;s about three times faster than the fill-then-draw approach described above, and about twice as fast as transparent text. So far as I know, there is no faster way to draw text on a VGA.
</P>
@ -231,7 +231,7 @@ DrawTextString endp
<hr width="90%" size="1" noshade>
<div align="center">
<font face="Verdana,sans-serif" size="1">Graphics Programming Black Book &copy; 2001 Michael Abrash</font>
Graphics Programming Black Book &copy; 2001 Michael Abrash
</div>
<!-- all of the reference materials (books) have the footer and subfoot reveresed -->
<!-- reference_subfoot = footer -->