openjpeg/doxygen/sparse__array_8h.html

447 lines
31 KiB
HTML
Raw Permalink Normal View History

2022-05-13 20:21:13 +02:00
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
2017-10-05 00:57:21 +02:00
<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"/>
2022-05-13 20:21:13 +02:00
<meta name="generator" content="Doxygen 1.8.17"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
2017-10-05 00:57:21 +02:00
<title>OpenJPEG: sparse_array.h File 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" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">OpenJPEG
2022-05-13 20:21:13 +02:00
&#160;<span id="projectnumber">2.5.0</span>
2017-10-05 00:57:21 +02:00
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
2022-05-13 20:21:13 +02:00
<!-- Generated by Doxygen 1.8.17 -->
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',false,false,'search.php','Search');
});
/* @license-end */</script>
<div id="main-nav"></div>
2017-10-05 00:57:21 +02:00
<div id="nav-path" class="navpath">
<ul>
2020-12-28 22:12:25 +01:00
<li class="navelem"><a class="el" href="dir_43e0a1f539e00dcfa1a6bc4d4fee4fc2.html">home</a></li><li class="navelem"><a class="el" href="dir_cb9b2b419d92b64f7cee83d8faf7a4ab.html">even</a></li><li class="navelem"><a class="el" href="dir_f75d9a0165d6564a1e04793ef847d41d.html">openjpeg</a></li><li class="navelem"><a class="el" href="dir_5f588d7ea139c1aae751d03c13a16064.html">openjpeg</a></li><li class="navelem"><a class="el" href="dir_378f732e812ef6cbaaae22e96a4fa79f.html">src</a></li><li class="navelem"><a class="el" href="dir_19dcb5713315405a27e1bde75a489a4c.html">lib</a></li><li class="navelem"><a class="el" href="dir_54e5bc4f0640fea590afaf04f4d9c88d.html">openjp2</a></li> </ul>
2017-10-05 00:57:21 +02:00
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#typedef-members">Typedefs</a> &#124;
<a href="#func-members">Functions</a> </div>
<div class="headertitle">
<div class="title">sparse_array.h File Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Sparse array management.
<a href="#details">More...</a></p>
<div class="textblock"><code>#include &quot;<a class="el" href="opj__includes_8h_source.html">opj_includes.h</a>&quot;</code><br />
</div>
<p><a href="sparse__array_8h_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="typedef-members"></a>
Typedefs</h2></td></tr>
2022-05-13 20:21:13 +02:00
<tr class="memitem:ab63770624f4ec03e6e022c6a0b80e6ff"><td class="memItemLeft" align="right" valign="top">typedef struct <a class="el" href="structopj__sparse__array__int32.html">opj_sparse_array_int32</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a></td></tr>
<tr class="memdesc:ab63770624f4ec03e6e022c6a0b80e6ff"><td class="mdescLeft">&#160;</td><td class="mdescRight">Opaque type for sparse arrays that contain int32 values. <a href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">More...</a><br /></td></tr>
<tr class="separator:ab63770624f4ec03e6e022c6a0b80e6ff"><td class="memSeparator" colspan="2">&#160;</td></tr>
2017-10-05 00:57:21 +02:00
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
2022-05-13 20:21:13 +02:00
<tr class="memitem:a41953de4fab74677337c2597a67c9843"><td class="memItemLeft" align="right" valign="top"><a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#a41953de4fab74677337c2597a67c9843">opj_sparse_array_int32_create</a> (<a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> width, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> height, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> block_width, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> block_height)</td></tr>
<tr class="memdesc:a41953de4fab74677337c2597a67c9843"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new sparse array. <a href="sparse__array_8h.html#a41953de4fab74677337c2597a67c9843">More...</a><br /></td></tr>
<tr class="separator:a41953de4fab74677337c2597a67c9843"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad70f920d05b4915853b474d010a9a336"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#ad70f920d05b4915853b474d010a9a336">opj_sparse_array_int32_free</a> (<a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *sa)</td></tr>
<tr class="memdesc:ad70f920d05b4915853b474d010a9a336"><td class="mdescLeft">&#160;</td><td class="mdescRight">Frees a sparse array. <a href="sparse__array_8h.html#ad70f920d05b4915853b474d010a9a336">More...</a><br /></td></tr>
<tr class="separator:ad70f920d05b4915853b474d010a9a336"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2b5c5075af6a30d35569e4378931ed4c"><td class="memItemLeft" align="right" valign="top"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#a2b5c5075af6a30d35569e4378931ed4c">opj_sparse_array_is_region_valid</a> (const <a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *sa, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x1, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y1)</td></tr>
<tr class="memdesc:a2b5c5075af6a30d35569e4378931ed4c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns whether region bounds are valid (non empty and within array bounds) <a href="sparse__array_8h.html#a2b5c5075af6a30d35569e4378931ed4c">More...</a><br /></td></tr>
<tr class="separator:a2b5c5075af6a30d35569e4378931ed4c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a092675bfa99d062ce36fa45aff4766da"><td class="memItemLeft" align="right" valign="top"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#a092675bfa99d062ce36fa45aff4766da">opj_sparse_array_int32_read</a> (const <a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *sa, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x1, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y1, <a class="el" href="openjpeg_8h.html#a3cec91ef9e73677f0dbd60d4e42401b9">OPJ_INT32</a> *dest, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> dest_col_stride, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> dest_line_stride, <a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a> forgiving)</td></tr>
<tr class="memdesc:a092675bfa99d062ce36fa45aff4766da"><td class="mdescLeft">&#160;</td><td class="mdescRight">Read the content of a rectangular region of the sparse array into a user buffer. <a href="sparse__array_8h.html#a092675bfa99d062ce36fa45aff4766da">More...</a><br /></td></tr>
<tr class="separator:a092675bfa99d062ce36fa45aff4766da"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a174b3ef4cb89af58cdd7c2b9f0a20559"><td class="memItemLeft" align="right" valign="top"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="sparse__array_8h.html#a174b3ef4cb89af58cdd7c2b9f0a20559">opj_sparse_array_int32_write</a> (<a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *sa, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y0, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> x1, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> y1, const <a class="el" href="openjpeg_8h.html#a3cec91ef9e73677f0dbd60d4e42401b9">OPJ_INT32</a> *src, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> src_col_stride, <a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a> src_line_stride, <a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a> forgiving)</td></tr>
<tr class="memdesc:a174b3ef4cb89af58cdd7c2b9f0a20559"><td class="mdescLeft">&#160;</td><td class="mdescRight">Write the content of a rectangular region into the sparse array from a user buffer. <a href="sparse__array_8h.html#a174b3ef4cb89af58cdd7c2b9f0a20559">More...</a><br /></td></tr>
<tr class="separator:a174b3ef4cb89af58cdd7c2b9f0a20559"><td class="memSeparator" colspan="2">&#160;</td></tr>
2017-10-05 00:57:21 +02:00
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Sparse array management. </p>
<p>The functions in this file manage sparse arrays. Sparse arrays are arrays with potential big dimensions, but with very few samples actually set. Such sparse arrays require allocating a low amount of memory, by just allocating memory for blocks of the array that are set. The minimum memory allocation unit is a a block. There is a trade-off to pick up an appropriate dimension for blocks. If it is too big, and pixels set are far from each other, too much memory will be used. If blocks are too small, the book-keeping costs of blocks will raise. </p>
2022-05-13 20:21:13 +02:00
</div><h2 class="groupheader">Typedef Documentation</h2>
<a id="ab63770624f4ec03e6e022c6a0b80e6ff"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab63770624f4ec03e6e022c6a0b80e6ff">&#9670;&nbsp;</a></span>opj_sparse_array_int32_t</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">typedef struct <a class="el" href="structopj__sparse__array__int32.html">opj_sparse_array_int32</a> <a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a></td>
</tr>
</table>
</div><div class="memdoc">
<p>Opaque type for sparse arrays that contain int32 values. </p>
</div>
</div>
<h2 class="groupheader">Function Documentation</h2>
<a id="a41953de4fab74677337c2597a67c9843"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a41953de4fab74677337c2597a67c9843">&#9670;&nbsp;</a></span>opj_sparse_array_int32_create()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a>* opj_sparse_array_int32_create </td>
<td>(</td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>width</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>height</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>block_width</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>block_height</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new sparse array. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">width</td><td>total width of the array. </td></tr>
<tr><td class="paramname">height</td><td>total height of the array </td></tr>
<tr><td class="paramname">block_width</td><td>width of a block. </td></tr>
<tr><td class="paramname">block_height</td><td>height of a block. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>a new sparse array instance, or NULL in case of failure. </dd></dl>
<p class="reference">References <a class="el" href="structopj__sparse__array__int32.html#a3e4065eb08fe228175101035b6f218ed">opj_sparse_array_int32::block_count_hor</a>, <a class="el" href="structopj__sparse__array__int32.html#aee2f11c522fd981408e3ae164c142baf">opj_sparse_array_int32::block_count_ver</a>, <a class="el" href="structopj__sparse__array__int32.html#a8879d3a7726f3f6ff228d5e341ada8b3">opj_sparse_array_int32::block_height</a>, <a class="el" href="structopj__sparse__array__int32.html#a97a62a6f3c09048f6fd8ec4192d71b5f">opj_sparse_array_int32::block_width</a>, <a class="el" href="structopj__sparse__array__int32.html#aa8740069e9f55f024b69b0e96b6f4f56">opj_sparse_array_int32::data_blocks</a>, <a class="el" href="structopj__sparse__array__int32.html#acbfd23999d0b817fb40ed58073bb6cf2">opj_sparse_array_int32::height</a>, <a class="el" href="opj__malloc_8c.html#a3fe08bb7876e393dd04332d049a4d53e">opj_calloc()</a>, <a class="el" href="opj__malloc_8c.html#a9d7d909f8dc1a2c23313c48645341e81">opj_free()</a>, <a class="el" href="opj__intmath_8h.html#ae4b2e5a7c8b8f09faacc4a895f866ea1">opj_uint_ceildiv()</a>, and <a class="el" href="structopj__sparse__array__int32.html#a427c80944840803fd7f5592317ad8564">opj_sparse_array_int32::width</a>.</p>
<p class="reference">Referenced by <a class="el" href="test__sparse__array_8c.html#ae66f6b31b5ad750f1fe042a706a4e3d4">main()</a>, and <a class="el" href="dwt_8c.html#a57c042791753ac46c7bb073abcc245ba">opj_dwt_init_sparse_array()</a>.</p>
</div>
</div>
<a id="ad70f920d05b4915853b474d010a9a336"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad70f920d05b4915853b474d010a9a336">&#9670;&nbsp;</a></span>opj_sparse_array_int32_free()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void opj_sparse_array_int32_free </td>
<td>(</td>
<td class="paramtype"><a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *&#160;</td>
<td class="paramname"><em>sa</em></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Frees a sparse array. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">sa</td><td>sparse array instance. </td></tr>
</table>
</dd>
</dl>
<p class="reference">References <a class="el" href="structopj__sparse__array__int32.html#a3e4065eb08fe228175101035b6f218ed">opj_sparse_array_int32::block_count_hor</a>, <a class="el" href="structopj__sparse__array__int32.html#aee2f11c522fd981408e3ae164c142baf">opj_sparse_array_int32::block_count_ver</a>, <a class="el" href="structopj__sparse__array__int32.html#aa8740069e9f55f024b69b0e96b6f4f56">opj_sparse_array_int32::data_blocks</a>, and <a class="el" href="opj__malloc_8c.html#a9d7d909f8dc1a2c23313c48645341e81">opj_free()</a>.</p>
<p class="reference">Referenced by <a class="el" href="test__sparse__array_8c.html#ae66f6b31b5ad750f1fe042a706a4e3d4">main()</a>, <a class="el" href="dwt_8c.html#a75cd080404aadce6662457dec7cc9d21">opj_dwt_decode_partial_97()</a>, <a class="el" href="dwt_8c.html#a74b827f7914de05bf5bfc52894894803">opj_dwt_decode_partial_tile()</a>, and <a class="el" href="dwt_8c.html#a57c042791753ac46c7bb073abcc245ba">opj_dwt_init_sparse_array()</a>.</p>
</div>
</div>
<a id="a092675bfa99d062ce36fa45aff4766da"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a092675bfa99d062ce36fa45aff4766da">&#9670;&nbsp;</a></span>opj_sparse_array_int32_read()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a> opj_sparse_array_int32_read </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *&#160;</td>
<td class="paramname"><em>sa</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a3cec91ef9e73677f0dbd60d4e42401b9">OPJ_INT32</a> *&#160;</td>
<td class="paramname"><em>dest</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>dest_col_stride</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>dest_line_stride</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a>&#160;</td>
<td class="paramname"><em>forgiving</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Read the content of a rectangular region of the sparse array into a user buffer. </p>
<p>Regions not written with <a class="el" href="sparse__array_8h.html#a174b3ef4cb89af58cdd7c2b9f0a20559" title="Write the content of a rectangular region into the sparse array from a user buffer.">opj_sparse_array_int32_write()</a> are read as 0.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">sa</td><td>sparse array instance. </td></tr>
<tr><td class="paramname">x0</td><td>left x coordinate of the region to read in the sparse array. </td></tr>
<tr><td class="paramname">y0</td><td>top x coordinate of the region to read in the sparse array. </td></tr>
<tr><td class="paramname">x1</td><td>right x coordinate (not included) of the region to read in the sparse array. Must be greater than x0. </td></tr>
<tr><td class="paramname">y1</td><td>bottom y coordinate (not included) of the region to read in the sparse array. Must be greater than y0. </td></tr>
<tr><td class="paramname">dest</td><td>user buffer to fill. Must be at least sizeof(int32) * ( (y1 - y0 - 1) * dest_line_stride + (x1 - x0 - 1) * dest_col_stride + 1) bytes large. </td></tr>
<tr><td class="paramname">dest_col_stride</td><td>spacing (in elements, not in bytes) in x dimension between consecutive elements of the user buffer. </td></tr>
<tr><td class="paramname">dest_line_stride</td><td>spacing (in elements, not in bytes) in y dimension between consecutive elements of the user buffer. </td></tr>
<tr><td class="paramname">forgiving</td><td>if set to TRUE and the region is invalid, OPJ_TRUE will still be returned. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>OPJ_TRUE in case of success. </dd></dl>
<p class="reference">References <a class="el" href="sparse__array_8c.html#a175c52e28cac6cad5ccdc24200e67a60">opj_sparse_array_int32_read_or_write()</a>, and <a class="el" href="openjpeg_8h.html#a04830036d767cba56cbf5ae5bdc481d3">OPJ_TRUE</a>.</p>
<p class="reference">Referenced by <a class="el" href="test__sparse__array_8c.html#ae66f6b31b5ad750f1fe042a706a4e3d4">main()</a>, <a class="el" href="dwt_8c.html#a75cd080404aadce6662457dec7cc9d21">opj_dwt_decode_partial_97()</a>, <a class="el" href="dwt_8c.html#a74b827f7914de05bf5bfc52894894803">opj_dwt_decode_partial_tile()</a>, <a class="el" href="dwt_8c.html#aa9f1030974db43df751380437e5167af">opj_dwt_interleave_partial_h()</a>, <a class="el" href="dwt_8c.html#ad7a304bcf13f2427c0a6835e6c527d3e">opj_dwt_interleave_partial_v()</a>, <a class="el" href="dwt_8c.html#a9caacdf7450ad73f0023e864f3a74cf1">opj_v8dwt_interleave_partial_h()</a>, and <a class="el" href="dwt_8c.html#a4d4acbc44226a14f02cff29831301f8e">opj_v8dwt_interleave_partial_v()</a>.</p>
</div>
</div>
<a id="a174b3ef4cb89af58cdd7c2b9f0a20559"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a174b3ef4cb89af58cdd7c2b9f0a20559">&#9670;&nbsp;</a></span>opj_sparse_array_int32_write()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a> opj_sparse_array_int32_write </td>
<td>(</td>
<td class="paramtype"><a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *&#160;</td>
<td class="paramname"><em>sa</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="openjpeg_8h.html#a3cec91ef9e73677f0dbd60d4e42401b9">OPJ_INT32</a> *&#160;</td>
<td class="paramname"><em>src</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>src_col_stride</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>src_line_stride</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a>&#160;</td>
<td class="paramname"><em>forgiving</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Write the content of a rectangular region into the sparse array from a user buffer. </p>
<p>Blocks intersecting the region are allocated, if not already done.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">sa</td><td>sparse array instance. </td></tr>
<tr><td class="paramname">x0</td><td>left x coordinate of the region to write into the sparse array. </td></tr>
<tr><td class="paramname">y0</td><td>top x coordinate of the region to write into the sparse array. </td></tr>
<tr><td class="paramname">x1</td><td>right x coordinate (not included) of the region to write into the sparse array. Must be greater than x0. </td></tr>
<tr><td class="paramname">y1</td><td>bottom y coordinate (not included) of the region to write into the sparse array. Must be greater than y0. </td></tr>
<tr><td class="paramname">src</td><td>user buffer to fill. Must be at least sizeof(int32) * ( (y1 - y0 - 1) * src_line_stride + (x1 - x0 - 1) * src_col_stride + 1) bytes large. </td></tr>
<tr><td class="paramname">src_col_stride</td><td>spacing (in elements, not in bytes) in x dimension between consecutive elements of the user buffer. </td></tr>
<tr><td class="paramname">src_line_stride</td><td>spacing (in elements, not in bytes) in y dimension between consecutive elements of the user buffer. </td></tr>
<tr><td class="paramname">forgiving</td><td>if set to TRUE and the region is invalid, OPJ_TRUE will still be returned. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>OPJ_TRUE in case of success. </dd></dl>
<p class="reference">References <a class="el" href="openjpeg_8h.html#ac672bfd7db39c609e828acb07a321964">OPJ_FALSE</a>, and <a class="el" href="sparse__array_8c.html#a175c52e28cac6cad5ccdc24200e67a60">opj_sparse_array_int32_read_or_write()</a>.</p>
<p class="reference">Referenced by <a class="el" href="test__sparse__array_8c.html#ae66f6b31b5ad750f1fe042a706a4e3d4">main()</a>, <a class="el" href="dwt_8c.html#a75cd080404aadce6662457dec7cc9d21">opj_dwt_decode_partial_97()</a>, <a class="el" href="dwt_8c.html#a74b827f7914de05bf5bfc52894894803">opj_dwt_decode_partial_tile()</a>, and <a class="el" href="dwt_8c.html#a57c042791753ac46c7bb073abcc245ba">opj_dwt_init_sparse_array()</a>.</p>
</div>
</div>
<a id="a2b5c5075af6a30d35569e4378931ed4c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2b5c5075af6a30d35569e4378931ed4c">&#9670;&nbsp;</a></span>opj_sparse_array_is_region_valid()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="openjpeg_8h.html#abb5dad6294f4611f1925388e919b16f4">OPJ_BOOL</a> opj_sparse_array_is_region_valid </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="sparse__array_8h.html#ab63770624f4ec03e6e022c6a0b80e6ff">opj_sparse_array_int32_t</a> *&#160;</td>
<td class="paramname"><em>sa</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y0</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>x1</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype"><a class="el" href="openjpeg_8h.html#a4cb1e6e6b6ef2df499d5c02f7df54cbb">OPJ_UINT32</a>&#160;</td>
<td class="paramname"><em>y1</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns whether region bounds are valid (non empty and within array bounds) </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">sa</td><td>sparse array instance. </td></tr>
<tr><td class="paramname">x0</td><td>left x coordinate of the region. </td></tr>
<tr><td class="paramname">y0</td><td>top x coordinate of the region. </td></tr>
<tr><td class="paramname">x1</td><td>right x coordinate (not included) of the region. Must be greater than x0. </td></tr>
<tr><td class="paramname">y1</td><td>bottom y coordinate (not included) of the region. Must be greater than y0. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>OPJ_TRUE or OPJ_FALSE. </dd></dl>
<p class="reference">References <a class="el" href="structopj__sparse__array__int32.html#acbfd23999d0b817fb40ed58073bb6cf2">opj_sparse_array_int32::height</a>, and <a class="el" href="structopj__sparse__array__int32.html#a427c80944840803fd7f5592317ad8564">opj_sparse_array_int32::width</a>.</p>
<p class="reference">Referenced by <a class="el" href="sparse__array_8c.html#a175c52e28cac6cad5ccdc24200e67a60">opj_sparse_array_int32_read_or_write()</a>.</p>
</div>
</div>
</div><!-- contents -->
2017-10-05 00:57:21 +02:00
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by &#160;<a href="http://www.doxygen.org/index.html">
<img class="footer" src="doxygen.png" alt="doxygen"/>
2022-05-13 20:21:13 +02:00
</a> 1.8.17
2017-10-05 00:57:21 +02:00
</small></address>
</body>
</html>