mirror of
https://github.com/boostorg/gil.git
synced 2026-01-29 19:42:11 +00:00
86 lines
4.8 KiB
HTML
86 lines
4.8 KiB
HTML
<!-- HTML header for doxygen 1.8.13-->
|
|
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
<head>
|
|
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
<meta name="generator" content="Doxygen 1.8.6"/>
|
|
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
<title>Generic Image Library: bit_aligned_pixel_reference</title>
|
|
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
<script type="text/javascript" src="jquery.js"></script>
|
|
<script type="text/javascript" src="dynsections.js"></script>
|
|
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
<link href="doxygen-boost.css" rel="stylesheet" type="text/css"/>
|
|
</head>
|
|
<body>
|
|
<div class="boost-header">
|
|
<table border="0" cellpadding="7" cellspacing="0" width="100%" summary="header">
|
|
<tr>
|
|
<td valign="top" width="300">
|
|
<h3><a href="../index.html"><img alt="Boost GIL" src="../_static/gil.png" border="0"></a></h3>
|
|
</td>
|
|
<td ><h1 align="center"><a href="../index.html"></a></h1></td>
|
|
<td></td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<hr/>
|
|
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
<!-- Generated by Doxygen 1.8.6 -->
|
|
<div id="navrow1" class="tabs">
|
|
<ul class="tablist">
|
|
<li><a href="index.html"><span>Main Page</span></a></li>
|
|
<li><a href="pages.html"><span>Related Pages</span></a></li>
|
|
<li><a href="modules.html"><span>Modules</span></a></li>
|
|
<li><a href="annotated.html"><span>Classes</span></a></li>
|
|
<li><a href="files.html"><span>Files</span></a></li>
|
|
</ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">bit_aligned_pixel_reference<div class="ingroups"><a class="el" href="group___pixel_model.html">Models</a> | <a class="el" href="group___color_base_model_non_aligned_pixel.html">bit_aligned_pixel_reference</a> | <a class="el" href="group___pixel_based_model.html">Models</a></div></div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
|
|
<p>A heterogeneous pixel reference used to represent non-byte-aligned pixels. Models PixelConcept.
|
|
<a href="#details">More...</a></p>
|
|
<p>A heterogeneous pixel reference used to represent non-byte-aligned pixels. Models PixelConcept. </p>
|
|
<p>Example: </p>
|
|
<div class="fragment"><div class="line"><span class="keywordtype">unsigned</span> <span class="keywordtype">char</span> data=0;</div>
|
|
<div class="line"></div>
|
|
<div class="line"><span class="comment">// A mutable reference to a 6-bit BGR pixel in "123" format (1 bit for red, 2 bits for green, 3 bits for blue)</span></div>
|
|
<div class="line"><span class="keyword">using</span> rgb123_ref_t = bit_aligned_pixel_reference<unsigned char, mpl::vector3_c<int,1,2,3>, rgb_layout_t, <span class="keyword">true</span>> <span class="keyword">const</span>;</div>
|
|
<div class="line"></div>
|
|
<div class="line"><span class="comment">// create the pixel reference at bit offset 2</span></div>
|
|
<div class="line"><span class="comment">// (i.e. red = [2], green = [3,4], blue = [5,6,7] bits)</span></div>
|
|
<div class="line">rgb123_ref_t ref(&data, 2);</div>
|
|
<div class="line"><a class="code" href="group___color_base_algorithm_color.html#gab2d1dda637cb2b7c32cc87f199ea1dc0">get_color</a>(ref, red_t()) = 1;</div>
|
|
<div class="line">assert(data == 0x04);</div>
|
|
<div class="line"><a class="code" href="group___color_base_algorithm_color.html#gab2d1dda637cb2b7c32cc87f199ea1dc0">get_color</a>(ref, green_t()) = 3;</div>
|
|
<div class="line">assert(data == 0x1C);</div>
|
|
<div class="line"><a class="code" href="group___color_base_algorithm_color.html#gab2d1dda637cb2b7c32cc87f199ea1dc0">get_color</a>(ref, blue_t()) = 7;</div>
|
|
<div class="line">assert(data == 0xFC);</div>
|
|
</div><!-- fragment --><p>Heterogeneous pixel reference corresponding to non-byte-aligned bit range. Models ColorBaseConcept, PixelConcept, PixelBasedConcept</p>
|
|
<dl class="tparams"><dt>Template Parameters</dt><dd>
|
|
<table class="tparams">
|
|
<tr><td class="paramname">BitField</td><td></td></tr>
|
|
<tr><td class="paramname">ChannelBitSizes</td><td>MPL integral vector defining the number of bits for each channel. For example, for 565RGB, vector_c<int,5,6,5> </td></tr>
|
|
<tr><td class="paramname">Layout</td><td></td></tr>
|
|
<tr><td class="paramname">IsMutable</td><td></td></tr>
|
|
</table>
|
|
</dd>
|
|
</dl>
|
|
</div><!-- contents -->
|
|
<!-- HTML footer for doxygen 1.8.13-->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/>
|
|
<address class="footer">
|
|
<small>
|
|
Generated on Wed Mar 6 2019 16:42:06 for Generic Image Library by  <a href="http://www.doxygen.org/index.html">doxygen</a> 1.8.6
|
|
</small>
|
|
</address>
|
|
</body>
|
|
</html>
|