File: Packed.html

package info (click to toggle)
openlayer 2.1-2.1
  • links: PTS
  • area: main
  • in suites: bullseye, buster, stretch
  • size: 3,392 kB
  • ctags: 2,317
  • sloc: ansic: 10,433; cpp: 9,890; xml: 109; makefile: 90; sh: 36
file content (9 lines) | stat: -rw-r--r-- 3,173 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transistional//EN"><html><head><title>OpenLayer Offline Manual</title><style type="text/css" media="all">@import "../CrystalStyle.css";</style><body bgcolor="FFFFFF" ><div align="center" style="pagestyle"><table width="60%"><tr><td><div class="parentLinks"><a href="../index.html">OpenLayer</a> | <a href="../Rgba.html">Rgba</a> | <a href="../Rgba/Packed.html">Packed</a></div><br><div class="BigHeader">Packed</div><br><div class=""><font color="#775500">Advanced function</font><br><br><div class="Surrounded"><table><tr valign="top"><td align="right"><div class="FuncDef"><strong><font color="#777733">int</font> <a href="../Rgba/Packed.html"><font color="#0000CC">Packed</font></a>() <font color="#777733">const</font>;
<br></strong></div></td></tr></table>
<br>Returns the color in a packed 32-bit integer.
<br></div>
<br>The returned color value is in the same format as the colors in Allegro are.
<br>
<br>The format is usually: AA|RR|GG|BB where a letter means a byte. The format depends on the current screen mode and several other factors, though. It's best to not to rely on that the components are always positioned the same way inside the integer. Use Allegro's functions to extract the color components if you need to.</div><br><div class="MediumHeader">Examples</div><br><div class="Code"><font color="#999922">//&nbsp;Convert&nbsp;the&nbsp;Rgba&nbsp;structure&nbsp;to&nbsp;Allegro's&nbsp;color&nbsp;value&nbsp;//</font>
<br><a href="../Rgba.html"><font color="#0000CC">Rgba</font></a>&nbsp;color(&nbsp;...&nbsp;);
<br><font color="#777733">int</font>&nbsp;colorPacked&nbsp;=&nbsp;color.<a href="../Rgba/Packed.html"><font color="#0000CC">Packed</font></a>();</div><div class=""><br><br><div class="MediumHeader">Other functions of the class <a href="../Rgba.html"><font color="#0000CC">Rgba</font></a></div><div class="Surrounded"><table size="100%" cellpadding="0" cellspacing="0"><tr><td halign="center" class="funclist"><a href="../Rgba/MixWith.html">MixWith</a></td><td width="65%" halign="center"><div class="smalltext">Mixes two colors together with the given factor</div></td></tr><tr><td halign="center" class="funclist"><a href="../Rgba/WithAlpha.html">WithAlpha</a></td><td width="65%" halign="center"><div class="smalltext">Creates a new color with the same color components but a different alpha value</div></td></tr><tr><td colspan="2"><br><div class="SmallHeader"><font color="#775500">Advanced functions</font></div><br></td></tr><tr><td halign="center" class="funclist"><a href="../Rgba/Packed.html">Packed</a></td><td width="65%" halign="center"><div class="smalltext">Returns the color packed in an integer</div></td></tr><tr><td halign="center" class="funclist"><a href="../Rgba/Select.html">Select</a></td><td width="65%" halign="center"><div class="smalltext">Selects the color as the active OpenGL color</div></td></tr></table></div><br><div class=""><a href="../index.html">Back to the main page of the manual</a></div><br>Questions about Packed? Click <a href="http://crystalstorm.ath.cx/index.php?lan=en&page=CreateFeedback&subject=Packed">here.</a></div></td></tr></table></body></html>