(BGR)</strong> and <strong>32-bit (BGRA)</strong> pixel formats. The <cite>format_32</cite>
flag must be set accordingly:</p>
<ul class="simple">
<li><p><strong>`format_32=False`</strong> â†’ for <strong>BGR (24-bit)</strong> format.</p></li>
<li><p><strong>`format_32=True`</strong> â†’ for <strong>BGRA (32-bit)</strong> format (includes an alpha channel).</p></li>
</ul>
<p><strong>Example Usage:</strong></p>
<p><strong>For a 24-bit image (BGR format):</strong></p>
<div class="highlight-py