# CSJ2K.j2k.entropy.encoder.PostCompRateAllocator.createInstance

## Content

<div class="doc-site-dotnet-api-container">



<h1 id="CSJ2K_j2k_entropy_encoder_PostCompRateAllocator_createInstance_" data-uid="CSJ2K.j2k.entropy.encoder.PostCompRateAllocator.createInstance*">createInstance Method
</h1>
<div class="markdown level0 summary"></div>
<div class="markdown level0 conceptual"></div>



<a id="CSJ2K_j2k_entropy_encoder_PostCompRateAllocator_createInstance_" data-uid="CSJ2K.j2k.entropy.encoder.PostCompRateAllocator.createInstance*"></a>
<h4 id="CSJ2K_j2k_entropy_encoder_PostCompRateAllocator_createInstance_CSJ2K_j2k_entropy_encoder_CodedCBlkDataSrcEnc_CSJ2K_j2k_util_ParameterList_System_Single_CSJ2K_j2k_codestream_writer_CodestreamWriter_CSJ2K_j2k_encoder_EncoderSpecs_" data-uid="CSJ2K.j2k.entropy.encoder.PostCompRateAllocator.createInstance(CSJ2K.j2k.entropy.encoder.CodedCBlkDataSrcEnc,CSJ2K.j2k.util.ParameterList,System.Single,CSJ2K.j2k.codestream.writer.CodestreamWriter,CSJ2K.j2k.encoder.EncoderSpecs)">createInstance(CodedCBlkDataSrcEnc, ParameterList, float, CodestreamWriter, EncoderSpecs)</h4>
<div class="markdown level1 summary"><p>Creates a PostCompRateAllocator object for the appropriate rate
allocation parameters in the parameter list 'pl', having 'src' as the
source of entropy coded data, 'rate' as the target bitrate and 'bw' as
the bit stream writer object.</p>
</div>
<div class="markdown level1 conceptual"></div>
<h5 class="declaration">Declaration</h5>
<div class="codewrapper">
  <pre><code class="lang-csharp hljs">public static PostCompRateAllocator createInstance(CodedCBlkDataSrcEnc src, ParameterList pl, float rate, CodestreamWriter bw, EncoderSpecs encSpec)</code></pre>
</div>
<div class="codewrapper">
  <pre><code class="lang-vbnet hljs">Public Shared Function createInstance(src As CodedCBlkDataSrcEnc, pl As ParameterList, rate As Single, bw As CodestreamWriter, encSpec As EncoderSpecs) As PostCompRateAllocator</code></pre>
</div>
<h5 class="parameters">Parameters</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Name</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="CSJ2K.j2k.entropy.encoder.CodedCBlkDataSrcEnc.html">CodedCBlkDataSrcEnc</a></td>
      <td><span class="parametername">src</span></td>
      <td><p>The source of entropy coded data.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="CSJ2K.j2k.util.ParameterList.html">ParameterList</a></td>
      <td><span class="parametername">pl</span></td>
      <td><p>The parameter lis (or options).</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="https://learn.microsoft.com/dotnet/api/system.single">float</a></td>
      <td><span class="parametername">rate</span></td>
      <td><p>The target bitrate for the rate allocation</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="CSJ2K.j2k.codestream.writer.CodestreamWriter.html">CodestreamWriter</a></td>
      <td><span class="parametername">bw</span></td>
      <td><p>The bit stream writer object, where the bit stream data will
be written.</p>
</td>
    </tr>
    <tr>
      <td><a class="xref" href="CSJ2K.j2k.encoder.EncoderSpecs.html">EncoderSpecs</a></td>
      <td><span class="parametername">encSpec</span></td>
      <td></td>
    </tr>
  </tbody>
</table>
<h5 class="returns">Returns</h5>
<table class="table table-bordered table-condensed">
  <thead>
    <tr>
      <th>Type</th>
      <th>Description</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td><a class="xref" href="CSJ2K.j2k.entropy.encoder.PostCompRateAllocator.html">PostCompRateAllocator</a></td>
      <td></td>
    </tr>
  </tbody>
</table>
</div>
