1 <HTML 2 ><HEAD 3 ><TITLE 4 >SDL_UpdateRects</TITLE 5 ><META 6 NAME="GENERATOR" 7 CONTENT="Modular DocBook HTML Stylesheet Version 1.76b+ 8 "><LINK 9 REL="HOME" 10 TITLE="SDL Library Documentation" 11 HREF="index.html"><LINK 12 REL="UP" 13 TITLE="Video" 14 HREF="video.html"><LINK 15 REL="PREVIOUS" 16 TITLE="SDL_UpdateRect" 17 HREF="sdlupdaterect.html"><LINK 18 REL="NEXT" 19 TITLE="SDL_Flip" 20 HREF="sdlflip.html"></HEAD 21 ><BODY 22 CLASS="REFENTRY" 23 BGCOLOR="#FFF8DC" 24 TEXT="#000000" 25 LINK="#0000ee" 26 VLINK="#551a8b" 27 ALINK="#ff0000" 28 ><DIV 29 CLASS="NAVHEADER" 30 ><TABLE 31 SUMMARY="Header navigation table" 32 WIDTH="100%" 33 BORDER="0" 34 CELLPADDING="0" 35 CELLSPACING="0" 36 ><TR 37 ><TH 38 COLSPAN="3" 39 ALIGN="center" 40 >SDL Library Documentation</TH 41 ></TR 42 ><TR 43 ><TD 44 WIDTH="10%" 45 ALIGN="left" 46 VALIGN="bottom" 47 ><A 48 HREF="sdlupdaterect.html" 49 ACCESSKEY="P" 50 >Prev</A 51 ></TD 52 ><TD 53 WIDTH="80%" 54 ALIGN="center" 55 VALIGN="bottom" 56 ></TD 57 ><TD 58 WIDTH="10%" 59 ALIGN="right" 60 VALIGN="bottom" 61 ><A 62 HREF="sdlflip.html" 63 ACCESSKEY="N" 64 >Next</A 65 ></TD 66 ></TR 67 ></TABLE 68 ><HR 69 ALIGN="LEFT" 70 WIDTH="100%"></DIV 71 ><H1 72 ><A 73 NAME="SDLUPDATERECTS" 74 ></A 75 >SDL_UpdateRects</H1 76 ><DIV 77 CLASS="REFNAMEDIV" 78 ><A 79 NAME="AEN1392" 80 ></A 81 ><H2 82 >Name</H2 83 >SDL_UpdateRects -- Makes sure the given list of rectangles is updated on the given screen.</DIV 84 ><DIV 85 CLASS="REFSYNOPSISDIV" 86 ><A 87 NAME="AEN1395" 88 ></A 89 ><H2 90 >Synopsis</H2 91 ><DIV 92 CLASS="FUNCSYNOPSIS" 93 ><A 94 NAME="AEN1396" 95 ></A 96 ><P 97 ></P 98 ><PRE 99 CLASS="FUNCSYNOPSISINFO" 100 >#include "SDL.h"</PRE 101 ><P 102 ><CODE 103 ><CODE 104 CLASS="FUNCDEF" 105 >void <B 106 CLASS="FSFUNC" 107 >SDL_UpdateRects</B 108 ></CODE 109 >(SDL_Surface *screen, int numrects, SDL_Rect *rects);</CODE 110 ></P 111 ><P 112 ></P 113 ></DIV 114 ></DIV 115 ><DIV 116 CLASS="REFSECT1" 117 ><A 118 NAME="AEN1402" 119 ></A 120 ><H2 121 >Description</H2 122 ><P 123 >Makes sure the given list of rectangles is updated on the given screen. 124 The rectangles must all be confined within the screen boundaries (no 125 clipping is done).</P 126 ><P 127 >This function should not be called while <TT 128 CLASS="PARAMETER" 129 ><I 130 >screen</I 131 ></TT 132 > is 133 <A 134 HREF="sdllocksurface.html" 135 >locked</A 136 >.</P 137 ><DIV 138 CLASS="NOTE" 139 ><BLOCKQUOTE 140 CLASS="NOTE" 141 ><P 142 ><B 143 >Note: </B 144 >It is adviced to call this function only once per frame, since each 145 call has some processing overhead. This is no restriction since you 146 can pass any number of rectangles each time.</P 147 ><P 148 >The rectangles are not automatically merged or checked for overlap. In 149 general, the programmer can use his knowledge about his particular 150 rectangles to merge them in an efficient way, to avoid overdraw.</P 151 ></BLOCKQUOTE 152 ></DIV 153 ></DIV 154 ><DIV 155 CLASS="REFSECT1" 156 ><A 157 NAME="AEN1411" 158 ></A 159 ><H2 160 >See Also</H2 161 ><P 162 ><A 163 HREF="sdlupdaterect.html" 164 ><TT 165 CLASS="FUNCTION" 166 >SDL_UpdateRect</TT 167 ></A 168 >, 169 <A 170 HREF="sdlrect.html" 171 ><SPAN 172 CLASS="STRUCTNAME" 173 >SDL_Rect</SPAN 174 ></A 175 >, 176 <A 177 HREF="sdlsurface.html" 178 ><SPAN 179 CLASS="STRUCTNAME" 180 >SDL_Surface</SPAN 181 ></A 182 >, 183 <A 184 HREF="sdllocksurface.html" 185 ><TT 186 CLASS="FUNCTION" 187 >SDL_LockSurface</TT 188 ></A 189 ></P 190 ></DIV 191 ><DIV 192 CLASS="NAVFOOTER" 193 ><HR 194 ALIGN="LEFT" 195 WIDTH="100%"><TABLE 196 SUMMARY="Footer navigation table" 197 WIDTH="100%" 198 BORDER="0" 199 CELLPADDING="0" 200 CELLSPACING="0" 201 ><TR 202 ><TD 203 WIDTH="33%" 204 ALIGN="left" 205 VALIGN="top" 206 ><A 207 HREF="sdlupdaterect.html" 208 ACCESSKEY="P" 209 >Prev</A 210 ></TD 211 ><TD 212 WIDTH="34%" 213 ALIGN="center" 214 VALIGN="top" 215 ><A 216 HREF="index.html" 217 ACCESSKEY="H" 218 >Home</A 219 ></TD 220 ><TD 221 WIDTH="33%" 222 ALIGN="right" 223 VALIGN="top" 224 ><A 225 HREF="sdlflip.html" 226 ACCESSKEY="N" 227 >Next</A 228 ></TD 229 ></TR 230 ><TR 231 ><TD 232 WIDTH="33%" 233 ALIGN="left" 234 VALIGN="top" 235 >SDL_UpdateRect</TD 236 ><TD 237 WIDTH="34%" 238 ALIGN="center" 239 VALIGN="top" 240 ><A 241 HREF="video.html" 242 ACCESSKEY="U" 243 >Up</A 244 ></TD 245 ><TD 246 WIDTH="33%" 247 ALIGN="right" 248 VALIGN="top" 249 >SDL_Flip</TD 250 ></TR 251 ></TABLE 252 ></DIV 253 ></BODY 254 ></HTML 255 >