1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> 2<html> 3 4<head> 5<META http-equiv="Content-Type" content="text/html; charset=windows-1252"> 6<META name="GENERATOR" content="IBM WebSphere Studio Homepage Builder Version 8.0.0.0 for Windows"> 7<META http-equiv="Content-Style-Type" content="text/css"> 8<title>G2_SetBG2ControlText</title> 9<LINK rel="stylesheet" href="../../css/nitro.css" type="text/css"> 10</head> 11 12<body> 13 14<h1 align="left">G2_SetBG2ControlText <img src="../../image/NTR.gif"align="middle"><img src="../../image/TWL.gif" align="middle"></H1> 15<H2>Syntax</H2> 16 17<dl> 18 <dd> 19<CODE>#include <nitro/gx/gx_bgcnt.h></CODE><BR> 20 <PRE><CODE>void G2_SetBG2ControlText( 21 GXBGScrSizeText screenSize, 22 GXBGColorMode colorMode, 23 GXBGScrBase screenBase, 24 GXBGCharBase charBase 25);</CODE></PRE> 26 </dd> 27</dl><h2>Arguments</h2> 28<TABLE border="1" width="100%"> 29 <TBODY> 30 <TR> 31 <TD width="300"><em><strong><font face="Courier New">screenSize</font></strong></em></TD> 32 <TD width="700">Screen size</TD> 33 </TR> 34 <TR> 35 <TD><em><strong><font face="Courier New">colorMode</font></strong></em></TD> 36 <TD>Color mode</TD> 37 </TR> 38 <TR> 39 <TD><em><strong><font face="Courier New">screenBase</font></strong></em></TD> 40 <TD>Screen base block</TD> 41 </TR> 42 <TR> 43 <TD><em><strong><font face="Courier New">charBase</font></strong></em></TD> 44 <TD>Character base block</TD> 45 </TR> 46 </TBODY> 47</TABLE> 48<h2>Return Values</h2> 49<p>None.</p> 50<H2>Description</H2> 51<P>This function sets BG2 (for text BG).<BR> <B>Note:</B> When VRAM banks are allocated to the BG extended palette with the <CODE><A href="../gx/GX_SetBankForBGExtPltt.html">GX_SetBankForBGExtPltt</A></CODE> function, the BG extended palette will be referenced if 256-color mode is used. The standard palette is referenced in all other cases. 52</P> 53<TABLE border="1"> 54 <TBODY> 55 <TR> 56 <TD width="30%"><CODE>GX_BG_SCRSIZE_TEXT_256x256</CODE></TD> 57 <TD width="70%">Sets screen size to 256x256 pixels (2 kilobytes)</TD> 58 </TR> 59 <TR> 60 <TD width="30%"><CODE>GX_BG_SCRSIZE_TEXT_512x256</CODE></TD> 61 <TD width="70%">Sets screen size to 512x256 pixels (4 kilobytes)</TD> 62 </TR> 63 <TR> 64 <TD width="30%"><CODE>GX_BG_SCRSIZE_TEXT_256x512</CODE></TD> 65 <TD width="70%">Sets screen size to 256x512 pixels (4 kilobytes)</TD> 66 </TR> 67 <TR> 68 <TD width="30%"><CODE>GX_BG_SCRSIZE_TEXT_512x512</CODE></TD> 69 <TD width="70%">Sets the screen size to 512x512 pixels (8 kilobytes)</TD> 70 </TR> 71 </TBODY> 72</TABLE> 73<P></P> 74<TABLE border="1"> 75 <TBODY> 76 <TR> 77 <TD width="30%"><CODE>GX_BG_COLORMODE_16</CODE></TD> 78 <TD width="70%">16-color mode</TD> 79 </TR> 80 <TR> 81 <TD width="30%"><CODE>GX_BG_COLORMODE_256</CODE></TD> 82 <TD width="70%">256-color mode</TD> 83 </TR> 84 </TBODY> 85</TABLE> 86<P></P> 87<TABLE border="1"> 88 <TBODY> 89 <TR> 90 <TD width="30%"><CODE>GX_BG_SCRBASE_0xnnnn</CODE></TD> 91 <TD width="70%">Specifies BG2 screen base block. Refer to the <CODE><A href="../gx/GX_SetBGScrOffset.html">GX_SetBGScrOffset</A></CODE> function.</TD> 92 </TR> 93 </TBODY> 94</TABLE> 95<P> 96</P> 97<TABLE border="1"> 98 <TBODY> 99 <TR> 100 <TD width="30%"><CODE>GX_BG_CHARBASE_0xnnnnn</CODE></TD> 101 <TD width="70%">Specifies BG2 character base block. Refer to the <CODE><A href="../gx/GX_SetBGCharOffset.html">GX_SetBGCharOffset</A></CODE> function.</TD> 102 </TR> 103 </TBODY> 104</TABLE> 105<P>The following describes the enumerated type definitions of the arguments.</P> 106<PRE><CODE>typedef enum 107{ 108 GX_BG_SCRSIZE_TEXT_256x256 = 0, 109 GX_BG_SCRSIZE_TEXT_512x256 = 1, 110 GX_BG_SCRSIZE_TEXT_256x512 = 2, 111 GX_BG_SCRSIZE_TEXT_512x512 = 3 112} 113GXBGScrSizeText; 114 115typedef enum 116{ 117 GX_BG_COLORMODE_16 = 0, 118 GX_BG_COLORMODE_256 = 1 119} 120GXBGColorMode; 121 122typedef enum 123{ 124 GX_BG_SCRBASE_0x0000 = 0, 125 GX_BG_SCRBASE_0x0800 = 1, 126 GX_BG_SCRBASE_0x1000 = 2, 127 GX_BG_SCRBASE_0x1800 = 3, 128 GX_BG_SCRBASE_0x2000 = 4, 129 GX_BG_SCRBASE_0x2800 = 5, 130 GX_BG_SCRBASE_0x3000 = 6, 131 GX_BG_SCRBASE_0x3800 = 7, 132 GX_BG_SCRBASE_0x4000 = 8, 133 GX_BG_SCRBASE_0x4800 = 9, 134 GX_BG_SCRBASE_0x5000 = 10, 135 GX_BG_SCRBASE_0x5800 = 11, 136 GX_BG_SCRBASE_0x6000 = 12, 137 GX_BG_SCRBASE_0x6800 = 13, 138 GX_BG_SCRBASE_0x7000 = 14, 139 GX_BG_SCRBASE_0x7800 = 15, 140 GX_BG_SCRBASE_0x8000 = 16, 141 GX_BG_SCRBASE_0x8800 = 17, 142 GX_BG_SCRBASE_0x9000 = 18, 143 GX_BG_SCRBASE_0x9800 = 19, 144 GX_BG_SCRBASE_0xa000 = 20, 145 GX_BG_SCRBASE_0xa800 = 21, 146 GX_BG_SCRBASE_0xb000 = 22, 147 GX_BG_SCRBASE_0xb800 = 23, 148 GX_BG_SCRBASE_0xc000 = 24, 149 GX_BG_SCRBASE_0xc800 = 25, 150 GX_BG_SCRBASE_0xd000 = 26, 151 GX_BG_SCRBASE_0xd800 = 27, 152 GX_BG_SCRBASE_0xe000 = 28, 153 GX_BG_SCRBASE_0xe800 = 29, 154 GX_BG_SCRBASE_0xf000 = 30, 155 GX_BG_SCRBASE_0xf800 = 31 156} 157GXBGScrBase; 158 159typedef enum 160{ 161 GX_BG_CHARBASE_0x00000 = 0, 162 GX_BG_CHARBASE_0x04000 = 1, 163 GX_BG_CHARBASE_0x08000 = 2, 164 GX_BG_CHARBASE_0x0c000 = 3, 165 GX_BG_CHARBASE_0x10000 = 4, 166 GX_BG_CHARBASE_0x14000 = 5, 167 GX_BG_CHARBASE_0x18000 = 6, 168 GX_BG_CHARBASE_0x1c000 = 7, 169 GX_BG_CHARBASE_0x20000 = 8, 170 GX_BG_CHARBASE_0x24000 = 9, 171 GX_BG_CHARBASE_0x28000 = 10, 172 GX_BG_CHARBASE_0x2c000 = 11, 173 GX_BG_CHARBASE_0x30000 = 12, 174 GX_BG_CHARBASE_0x34000 = 13, 175 GX_BG_CHARBASE_0x38000 = 14, 176 GX_BG_CHARBASE_0x3c000 = 15 177} 178GXBGCharBase;</CODE></PRE> 179<h2>See Also</h2> 180<P><A href="G2_GetBG2ControlText.html">G2_GetBG2ControlText</A></P> 181<H2>Revision History</H2> 182<P>2004/01/19 Initial version.</P> 183<hr><p>CONFIDENTIAL</p></body> 184</html> 185