<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Simulation &#8211; Andromedabay Store</title>
	<atom:link href="https://andromedabay.ddns.net/category/simulation/feed/" rel="self" type="application/rss+xml" />
	<link>https://andromedabay.ddns.net</link>
	<description>Your source of Technical Insight and Interesting Stuff</description>
	<lastBuildDate>Sun, 19 Apr 2026 19:52:36 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0</generator>

<image>
	<url>https://andromedabay.ddns.net/wp-content/uploads/2015/08/cropped-myicon-32x32.png</url>
	<title>Simulation &#8211; Andromedabay Store</title>
	<link>https://andromedabay.ddns.net</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Using wx_bgi_graphics With OpenLB</title>
		<link>https://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/</link>
					<comments>https://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/#respond</comments>
		
		<dc:creator><![CDATA[Hammad Rauf]]></dc:creator>
		<pubDate>Sun, 19 Apr 2026 19:52:36 +0000</pubDate>
				<category><![CDATA[C Programming]]></category>
		<category><![CDATA[Graphics]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[macOS]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Simulation]]></category>
		<guid isPermaLink="false">https://andromedabay.ddns.net/?p=3023</guid>

					<description><![CDATA[Introduction This article walks through a compact but surprisingly fun combo: running an OpenLB flow simulation while using wx_bgi_graphics to paint the results live in]]></description>
										<content:encoded><![CDATA[<div class='booster-block booster-read-block'>
                <div class="twp-read-time">
                	<i class="booster-icon twp-clock"></i> <span>Read Time:</span>16 Minute, 24 Second                </div>

            </div><div class="WordSection1">
<h1>Introduction</h1>
<p class="MsoNormal">This article walks through a compact but surprisingly fun combo: running an OpenLB flow simulation while using wx_bgi_graphics to paint the results live in a window.</p>
<p class="MsoNormal">At a high level, the demo connects:</p>
<ul type="disc">
<li class="MsoNormal"><b>OpenLB</b>: an open-source C++ framework for computational fluid dynamics based on the Lattice Boltzmann Method (LBM).</li>
<li class="MsoNormal" style="line-height: 115%;"><b>wx_bgi_graphics</b>: a modern, cross-platform (Windows, Linux, macOS) BGI-style drawing API delivered as a shared library. It’s designed to make 2D (and simple 3D-style) rendering approachable from C/C++, Python and Free-Pascal (and potentially others, depending on bindings).</li>
</ul>
<p class="MsoNormal">The emphasis here is on <b>how the program uses wx_bgi_graphics</b> to open a window, draw frames, and update visuals in a simulation loop. OpenLB concepts are introduced only to the  extent needed to understand where the data comes from and how often the visualization updates.</p>
<ul>
<li class="MsoNormal"><b>Demo source (OpenLB + wx_bgi_graphics integration): </b><a href="https://github.com/Andromedabay/wx_bgi_graphics/tree/main/examples/cpp/openlb-demo">https://github.com/Andromedabay/wx_bgi_graphics/tree/main/examples/cpp/openlb-demo</a></li>
<li class="MsoNormal"><b>wx_bgi_graphics source:</b> <a href="https://github.com/Andromedabay/wx_bgi_graphics">https://github.com/Andromedabay/wx_bgi_graphics</a></li>
<li class="MsoNormal"><b>wx_bgi_graphics OpenLB-Support guide: </b><a href="https://github.com/Andromedabay/wx_bgi_graphics/blob/main/docs/user-guide/OpenLB-Support.md">https://github.com/Andromedabay/wx_bgi_graphics/blob/main/docs/user-guide/OpenLB-Support.md</a></li>
<li class="MsoNormal"><b>OpenLB homepage:</b> <a href="https://www.openlb.net/">https://www.openlb.net/</a></li>
</ul>
<p><iframe title="YouTube video player" src="https://www.youtube.com/embed/49VRy_b14Wg?si=SVUb0W71PpyQkAUM" width="560" height="315" frameborder="0" allowfullscreen="allowfullscreen"></iframe></p>
<h1>What the demo is doing (big picture)</h1>
<p class="MsoNormal">At runtime, the program keeps two gears turning: OpenLB<br />
advances the physics, and wx_bgi_graphics turns those numbers into something<br />
you can actually watch. Conceptually, it’s a tight loop:</p>
<ol style="margin-top: 0cm;" start="1" type="1">
<li class="MsoNormal" style="line-height: 115%;"><b>Initialize</b> the problem<br />
setup: build the demo geometry using wx_bgi_graphics primitives (and<br />
label/annotate it so it can be reused by external tooling such as OpenLB).</li>
<li class="MsoNormal"><b>Initialize</b> wx_bgi_graphics (open a window,<br />
configure drawing state).</li>
<li class="MsoNormal"><b>Time-step loop</b>: advance the CFD solution<br />
(collide-and-stream) and periodically extract scalar/vector quantities<br />
(e.g., velocity magnitude, density, vorticity).</li>
<li class="MsoNormal"><b>Render loop</b>: map simulation values to pixels/colors<br />
and draw primitives (points, lines, text, optional overlays) to form each<br />
frame.</li>
<li class="MsoNormal"><b>Handle input</b> (keys/mouse) and exit cleanly.</li>
</ol>
<p class="MsoNormal">OpenLB commonly outputs results for post-processing tools<br />
(e.g., VTK/ParaView). This demo instead emphasizes an <b>immediate-mode,<br />
interactive window</b> for learning, rapid iteration, and<br />
“see-it-while-it-runs” feedback—exactly the niche where a simple BGI-style API<br />
is convenient.</p>
<h1>Prerequisites and build ingredients</h1>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="line-height: 115%;"><b>C/C++ toolchain</b>: a recent<br />
GCC/Clang (recommended for this demo). wx_bgi_graphics itself supports<br />
MSVC, but the author could not compile the latest OpenLB release with<br />
MSVC—so this particular OpenLB demo is best treated as<br />
Linux/WSL2/macOS-oriented (tested on Linux).</li>
<li class="MsoNormal"><b>wxWidgets runtime/development files</b>:<br />
wx_bgi_graphics uses wxWidgets under the hood to create windows and draw.</li>
<li class="MsoNormal"><b>wx_bgi_graphics shared library</b>: built from<br />
https://github.com/Andromedabay/wx_bgi_graphics and made discoverable at<br />
runtime (e.g., via <i>LD_LIBRARY_PATH</i> on Linux/macOS or PATH on<br />
Windows).</li>
<li class="MsoNormal"><b>OpenLB</b>: obtained from https://www.openlb.net/ (or<br />
your preferred mirror). The demo’s build expects OpenLB headers and<br />
libraries in a known location.</li>
</ul>
<p class="MsoNormal"><b>Platform note:</b> wx_bgi_graphics is cross-platform, but<br />
this specific OpenLB integration demo is primarily intended for Linux, WSL2, or<br />
macOS due to the OpenLB/MSVC build limitation mentioned above.</p>
<h1>Architecture overview: OpenLB compute + wx_bgi_graphics render</h1>
<h2>Geometry from drawing primitives (and why labeling matters)</h2>
<p class="MsoNormal">In this workflow, wx_bgi_graphics isn’t only used to<br />
visualize results—it can also be used to <b>sketch the geometry itself</b><br />
using familiar primitives (lines, rectangles, circles, polygons). Those shapes<br />
can be <b>labeled</b> (e.g., “inlet”, “outlet”, “wall”, “obstacle”) so the same<br />
geometry description can be interpreted consistently when you hand it off to<br />
external software such as OpenLB for boundary assignment.</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm; line-height: 115%;"><b>Inlet</b><br />
label  choose inflow boundary (velocity or pressure)</li>
<li class="MsoNormal" style="margin-bottom: 0cm; line-height: 115%;"><b>Outlet</b><br />
label  choose outflow / pressure reference boundary</li>
<li class="MsoNormal" style="margin-bottom: 0cm; line-height: 115%;"><b>Wall</b><br />
label  choose no-slip (bounce-back) boundary</li>
<li class="MsoNormal" style="margin-bottom: 0cm; line-height: 115%;"><b>Solid<br />
obstacle</b> label  mark solid region inside the flow domain</li>
</ul>
<p class="MsoNormal">The cleanest way to think about this program is as two<br />
subsystems with a simple interface between them:</p>
<table class="MsoTable15Grid1LightAccent1" style="border-collapse: collapse; border: none;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="border: solid #83CAEB 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Simulation<br />
(OpenLB)</b></p>
</td>
<td style="border: solid #83CAEB 1.0pt; border-left: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Visualization<br />
(wx_bgi_graphics)</b></p>
</td>
</tr>
<tr>
<td style="border: solid #83CAEB 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Defines the<br />
lattice, physics, and boundary conditions; advances the solver in time steps.</p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #83CAEB 1.0pt; border-right: solid #83CAEB 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Creates a<br />
window; draws primitives each frame; optionally handles input and overlays<br />
(HUD text, axes, legends).</p>
</td>
</tr>
<tr>
<td style="border: solid #83CAEB 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Provides<br />
data fields (e.g., velocity magnitude at lattice nodes).</p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #83CAEB 1.0pt; border-right: solid #83CAEB 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Maps data<br />
values to colors/positions and draws them (pixels/points/rectangles/lines).</p>
</td>
</tr>
<tr>
<td style="border: solid #83CAEB 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Controls<br />
when to sample/output results (every N steps).</p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #83CAEB 1.0pt; border-right: solid #83CAEB 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Controls<br />
refresh rate and any interpolation/downsampling used for display.</p>
</td>
</tr>
</tbody>
</table>
<h1>wx_bgi_graphics OpenLB-Support: what it adds</h1>
<p class="MsoNormal">The demo doesn’t just “use wx_bgi_graphics for drawing.” It<br />
leans on wx_bgi_graphics’ <b>OpenLB-Support</b> layer to make the end-to-end<br />
workflow smooth: build a duct and sieve as labeled solids, materialize those<br />
labels into the OpenLB geometry, then render both a 3D preview and live slice<br />
diagnostics.</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Geometry authoring via<br />
primitives</b>: draw the domain (walls/obstacles) using the same API<br />
you’ll later use for visualization.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Labeling / tagging</b>:<br />
assign integer/material IDs (or named tags, depending on your workflow) to<br />
pixels/regions so external code can interpret “what is what”.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Bridging helpers</b>: small<br />
utilities that turn those labels into something OpenLB can consume<br />
(typically: material assignment and boundary selection).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Visualization helpers</b>:<br />
convenience routines/patterns to sample fields and render them efficiently<br />
(e.g., scaling, palettes, overlays).</li>
</ul>
<h1>Walkthrough of the demo’s key functions</h1>
<p class="MsoNormal">Instead of treating this as a generic “OpenLB + graphics”<br />
integration, let’s follow the demo the way the code does. These four functions<br />
are the backbone of the interactive experience:</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>main()</b> boots everything:<br />
window + cameras + DDS scenes, creates and validates the OpenLB geometry,<br />
runs the step/render loop, and presents frames.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>sampleLongitudinalSection()</b><br />
samples a 2D slice from the 3D simulation and produces the scalar/vector<br />
grids that the UI draws.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>rebuildFlowPerspectiveScene()</b><br />
rebuilds a 3D “height mesh” view of the slice using wx_bgi_graphics<br />
world-space line primitives.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>drawHud()</b> draws the<br />
right-hand info panel: controls, slice position, legend details, and<br />
materialization stats.</li>
</ul>
<h2>main(): session setup, simulation loop, and rendering</h2>
<p class="MsoNormal">The demo’s <code><span style="font-size: 10.0pt; line-height: 115%;">main()</span></code> is essentially a story in three acts:</p>
<ol style="margin-top: 0cm;" start="1" type="1">
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Parse flags</b> (test mode +<br />
shading mode) so the demo can run quickly in CI-like runs or with a<br />
preferred render style.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Start wx_bgi_graphics + build<br />
the DDS scene</b>: the window is created with <code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_openlb_begin_session()</span></code>,<br />
and the 3D duct geometry is built via DDS solids (boxes +<br />
union/difference) in <code><span style="font-size: 10.0pt; line-height: 115%;">buildDdsPipeScene()</span></code>.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Run the main step/render loop</b>:<br />
advance <code><span style="font-size: 10.0pt; line-height: 115%;">lattice.collideAndStream()</span></code><br />
a few steps per frame, sample a slice for 2D overlays, rebuild the 3D<br />
slice mesh scene, then draw everything (preview, 2D field grids, 3D mesh,<br />
HUD) and present.</li>
</ol>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">int main(int argc, char **argv)
{
    bool testMode = false;
    int solidMode = kModeSmooth;
    for (int i = 1; i &lt; argc; ++i)
    {
        if (std::strcmp(argv[i], "--test") == 0)
            testMode = true;
        else if (std::strcmp(argv[i], "--wireframe") == 0)
            solidMode = kModeWireframe;
        else if (std::strcmp(argv[i], "--flat") == 0)
            solidMode = kModeFlat;
        else if (std::strcmp(argv[i], "--shaded") == 0 || std::strcmp(argv[i], "--smooth") == 0)
            solidMode = kModeSmooth;
    }

    wxbgi_openlb_begin_session(windowW, windowH, "wx_bgi OpenLB 3D Duct Demo");
    setbkcolor(BLACK);
    cleardevice();

    const SieveLayout sieveLayout = buildDdsPipeScene(converter);
    wxbgi_cam_create("pipe3d_preview", WXBGI_CAM_PERSPECTIVE);
    wxbgi_cam_set_scene("pipe3d_preview", "default");

    wxbgi_dds_scene_create("flow3d");
    wxbgi_cam_create("pipe3d_flow3d", WXBGI_CAM_PERSPECTIVE);
    wxbgi_cam_set_scene("pipe3d_flow3d", "flow3d");

    // ... OpenLB geometry + lattice setup omitted here for brevity ...

    while (wxbgi_openlb_pump())
    {
        for (int step = 0; step &lt; stepsPerFrame; ++step, ++iT)
        {
            updateBoundaryValues(iT, converter, geometry, lattice);
            lattice.collideAndStream();
        }

        const float sliceValueMax = std::max(sampleLongitudinalSection(lattice,
                                                                       converter,
                                                                       geometry,
                                                                       sliceZ,
                                                                       sliceCols,
                                                                       sliceRows,
                                                                       scalar,
                                                                       vectors),
                                             1e-6f);
        const float sliceZPhys = static_cast&lt;float&gt;(converter.getPhysLength(sliceZ));
        rebuildFlowPerspectiveScene(converter, sliceCols, sliceRows, scalar, sliceValueMax, sliceZPhys);

        cleardevice();
        wxbgi_render_dds("pipe3d_preview");

        wxbgi_field_draw_scalar_grid(layout.fieldLeft, layout.fieldTop,
                                     sliceCols, sliceRows,
                                     scalar.data(), static_cast&lt;int&gt;(scalar.size()),
                                     kFieldCellPx,
                                     0.f, sliceValueMax,
                                     WXBGI_FIELD_PALETTE_TURBO);

        wxbgi_field_draw_vector_grid(layout.fieldLeft, layout.fieldTop,
                                     sliceCols, sliceRows,
                                     vectors.data(), static_cast&lt;int&gt;(vectors.size()),
                                     kFieldCellPx,
                                     12.f, 3, WHITE);

        wxbgi_render_dds("pipe3d_flow3d");
        drawHud(sliceZ, sliceZPhys, sliceIndexMin, sliceIndexMax,
                layout.hudLeft, layout.hudTop, layout.hudH,
                sliceValueMax, maxPhysVelocity, iT,
                materializeStats, solidMode, sieveLayout);

        if (!wxbgi_openlb_present())
            break;
    }

    return 0;
}
</pre>
<p class="MsoNormal">A few wx_bgi_graphics/OpenLB-support calls are doing a lot<br />
of heavy lifting here:</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_openlb_begin_session(...)</span></code><br />
creates the window and sets up an event/present loop that plays nicely<br />
with the OpenLB stepping.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">buildDdsPipeScene(converter)</span></code> builds<br />
the 3D duct/sieve geometry using wx_bgi_dds + wxbgi_solid primitives, and<br />
tags objects with external attributes (for example, the sieve is tagged<br />
with OpenLB role/material/boundary attributes).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_render_dds(cameraName)</span></code><br />
renders a DDS scene from the specified camera into the current frame<br />
buffer.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_field_draw_scalar_grid</span></code>, <code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_field_draw_vector_grid</span></code>,<br />
and <code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_field_draw_scalar_legend</span></code></li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_openlb_present()</span></code> presents the<br />
composed frame (and typically synchronizes with the windowing backend).</li>
</ul>
<h2>sampleLongitudinalSection(): turning a 3D lattice into 2D arrays</h2>
<p class="MsoNormal">This function is the bridge between “simulation space” and<br />
“UI space”. Given a Z index (<code><span style="font-size: 10.0pt; line-height: 115%;">sliceZ</span></code>), it walks an <code><span style="font-size: 10.0pt; line-height: 115%;">X×Y</span></code> plane, samples the OpenLB velocity, and<br />
fills two buffers:</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">scalar[y*cols + x]</span></code> stores the <b>velocity<br />
magnitude</b> at each cell (used for the colored grid and legend).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><code><span style="font-size: 10.0pt; line-height: 115%;">vectors[(y*cols + x)*2 + 0/1]</span></code><br />
stores <b>(v<sub>x</sub>, v<sub>y</sub>)</b> for a 2D vector overlay (used<br />
for the arrow/grid vectors panel).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;">The return value is <code><span style="font-size: 10.0pt; line-height: 115%;">maxMagnitude</span></code>, used<br />
to normalize colors and heights consistently for that frame.</li>
</ul>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">float sampleLongitudinalSection(SuperLattice&lt;T, DESCRIPTOR&gt; &amp;lattice,
                                const UnitConverter&lt;T, DESCRIPTOR&gt; &amp;converter,
                                const SuperGeometry&lt;T, 3&gt; &amp;geometry,
                                int sliceZ,
                                int cols,
                                int rows,
                                std::vector&lt;float&gt; &amp;scalar,
                                std::vector&lt;float&gt; &amp;vectors)
{
    lattice.setProcessingContext(ProcessingContext::Evaluation);
    SuperLatticePhysVelocity3D&lt;T, DESCRIPTOR&gt; velocity(lattice, converter);

    float maxMagnitude = 0.f;
    for (int y = 0; y &lt; rows; ++y)
    {
        for (int x = 0; x &lt; cols; ++x)
        {
            const std::size_t scalarIdx = static_cast&lt;std::size_t&gt;(y * cols + x);
            const std::size_t vectorIdx = scalarIdx * 2;

            scalar[scalarIdx] = 0.f;
            vectors[vectorIdx + 0] = 0.f;
            vectors[vectorIdx + 1] = 0.f;

            const int material = geometry.get(0, x, y, sliceZ);
            if (material != kMatFluid &amp;&amp; material != kMatInflow &amp;&amp;
                material != kMatOutflow &amp;&amp;
                material != kMatSideVent)
                continue;

            T output[3] = {};
            const int input[4] = {0, x, y, sliceZ};
            if (!velocity(output, input))
                continue;

            const float vx = static_cast&lt;float&gt;(output[0]);
            const float vy = static_cast&lt;float&gt;(output[1]);
            const float vz = static_cast&lt;float&gt;(output[2]);
            const float magnitude = std::sqrt(vx * vx + vy * vy + vz * vz);

            scalar[scalarIdx] = magnitude;
            vectors[vectorIdx + 0] = vx;
            vectors[vectorIdx + 1] = vy;
            maxMagnitude = std::max(maxMagnitude, magnitude);
        }
    }

    return maxMagnitude;
}
</pre>
<p class="MsoNormal">Notice the material check (<code><span style="font-size: 10.0pt; line-height: 115%;">geometry.get(...)</span></code>) before sampling<br />
velocity. This keeps the slice clean by ignoring walls/solids and only sampling<br />
the materials that represent flow regions (fluid, inflow, outflow, side vent).</p>
<h2>rebuildFlowPerspectiveScene(): building a 3D “slice mesh” with world lines</h2>
<p class="MsoNormal">This function creates the third row’s 3D view. Instead of<br />
drawing pixels, it rebuilds an entire DDS scene (named <code><span style="font-size: 10.0pt; line-height: 115%;">flow3d</span></code>) every frame<br />
using <b>world-space line primitives</b>:</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;">Switch to the <code><span style="font-size: 10.0pt; line-height: 115%;">flow3d</span></code> DDS scene<br />
and activate the dedicated camera (<code><span style="font-size: 10.0pt; line-height: 115%;">pipe3d_flow3d</span></code>).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;">Draw a rectangular outline on<br />
the slice plane (the duct footprint).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;">Draw a grid of line strips in X<br />
and Y where <b>height encodes speed</b>: each line endpoint gets a Z<br />
offset proportional to <code><span style="font-size: 10.0pt; line-height: 115%;">scalar[idx] / maxMagnitude</span></code>.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;">Add sparse vertical “spikes” as<br />
an extra cue for magnitude.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;">Restore the default scene/camera<br />
so the preview view continues to render normally.</li>
</ul>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">void rebuildFlowPerspectiveScene(const UnitConverter&lt;T, DESCRIPTOR&gt; &amp;converter,
                                 int cols,
                                 int rows,
                                 const std::vector&lt;float&gt; &amp;scalar,
                                 float maxMagnitude,
                                 float sliceZPhys)
{
    const float dx = static_cast&lt;float&gt;(converter.getPhysDeltaX());
    const float baseZ = sliceZPhys;
    const float heightScale = 0.18f;

    wxbgi_dds_scene_set_active("flow3d");
    wxbgi_dds_scene_clear("flow3d");
    wxbgi_cam_set_active("pipe3d_flow3d");

    setcolor(DARKGRAY);
    wxbgi_world_line(0.f, 0.f, baseZ, static_cast&lt;float&gt;(kPipeLength), 0.f, baseZ);
    wxbgi_world_line(static_cast&lt;float&gt;(kPipeLength), 0.f, baseZ,
                     static_cast&lt;float&gt;(kPipeLength), static_cast&lt;float&gt;(kPipeWidth), baseZ);
    wxbgi_world_line(static_cast&lt;float&gt;(kPipeLength), static_cast&lt;float&gt;(kPipeWidth), baseZ,
                     0.f, static_cast&lt;float&gt;(kPipeWidth), baseZ);
    wxbgi_world_line(0.f, static_cast&lt;float&gt;(kPipeWidth), baseZ, 0.f, 0.f, baseZ);

    for (int y = 0; y &lt; rows; ++y)
    {
        for (int x = 0; x &lt; cols - 1; ++x)
        {
            const std::size_t idx0 = static_cast&lt;std::size_t&gt;(y * cols + x);
            const std::size_t idx1 = idx0 + 1;
            const float x0 = (static_cast&lt;float&gt;(x) + 0.5f) * dx;
            const float x1 = (static_cast&lt;float&gt;(x + 1) + 0.5f) * dx;
            const float yw = (static_cast&lt;float&gt;(y) + 0.5f) * dx;
            const float z0 = baseZ + (maxMagnitude &gt; 1e-6f ? scalar[idx0] / maxMagnitude : 0.f) * heightScale;
            const float z1 = baseZ + (maxMagnitude &gt; 1e-6f ? scalar[idx1] / maxMagnitude : 0.f) * heightScale;
            setcolor(paletteColorForScalar(0.5f * (scalar[idx0] + scalar[idx1]), maxMagnitude));
            wxbgi_world_line(x0, yw, z0, x1, yw, z1);
        }
    }

    // ... second pass draws Y-direction strips; third pass adds sparse vertical lines ...

    wxbgi_dds_scene_set_active("default");
    wxbgi_cam_set_active("pipe3d_preview");
}

</pre>
<p class="MsoNormal">In the real demo, the function continues with two more<br />
loops: one draws the Y-direction strips (connecting <code><span style="font-size: 10.0pt; line-height: 115%;">(x, y)</span></code> to <code><span style="font-size: 10.0pt; line-height: 115%;">(x, y+1)</span></code>), and another<br />
draws sparse vertical lines. The excerpt above is kept short, but every line<br />
shown is copied directly from the demo.</p>
<h2>drawHud(): the right-hand status panel</h2>
<p class="MsoNormal">The HUD is a great example of why wx_bgi_graphics feels<br />
productive: it’s just immediate-mode drawing. <code><span style="font-size: 10.0pt; line-height: 115%;">drawHud()</span></code> draws a bordered panel and<br />
then prints a series of bullet lines that make the demo self-explanatory while<br />
it runs.</p>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Navigation</b>: tells you<br />
which row is which, and the orbit controls (I/J/K/L) and slice controls<br />
(+/-).</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Slice position</b>: shows<br />
both the lattice index and the physical Z location in meters.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Render mode</b>:<br />
wireframe/flat/smooth selection, matching keys 1/2/3.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>Legend</b>: clarifies that<br />
the color ramp represents speed in m/s, with the per-frame max.</li>
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>OpenLB materialization stats</b>:<br />
<code><span style="font-size: 10.0pt; line-height: 115%;">matched</span></code><br />
and <code><span style="font-size: 10.0pt; line-height: 115%;">updated</span></code><br />
counters from <code><span style="font-size: 10.0pt; line-height: 115%;">WxbgiOpenLbMaterializeStats</span></code><br />
show how the DDS geometry “hits” the lattice.</li>
</ul>
<pre class="EnlighterJSRAW" data-enlighter-language="generic">void drawHud(int sliceZ,
              float sliceZPhys,
              int sliceMin,
              int sliceMax,
              int hudLeft,
              int hudTop,
              int hudHeight,
              float maxMagnitude,
              float maxPhysVelocity,
              std::size_t steps,
               const WxbgiOpenLbMaterializeStats &amp;materializeStats,
               int renderMode,
               const SieveLayout &amp;sieveLayout)
{
    const int lineStep = 22;
    int lineY = hudTop;
    auto drawBullet = [&amp;](const char *text, int color = LIGHTGRAY)
    {
        setcolor(color);
        outtextxy(hudLeft, lineY, const_cast&lt;char *&gt;("-"));
        outtextxy(hudLeft + 14, lineY, const_cast&lt;char *&gt;(text));
        lineY += lineStep;
    };

    setcolor(DARKGRAY);
    rectangle(hudLeft - 10, hudTop - 8, hudLeft + kHudPanelWidth - 4, hudTop + hudHeight - 8);
    setcolor(WHITE);
    outtextxy(hudLeft, lineY, const_cast&lt;char *&gt;("3D OpenLB duct HUD"));
    lineY += lineStep + 4;

    drawBullet("row1 orbit preview");
    drawBullet("row2 XY slice");
    drawBullet("row3 3D slice mesh");

    char line[160] = {};
    std::snprintf(line, sizeof(line), "slice z: %d of %d", sliceZ, sliceMax);
    drawBullet(line, WHITE);

    std::snprintf(line, sizeof(line), "active: %s", renderModeLabel(renderMode));
    drawBullet(line);

    std::snprintf(line, sizeof(line), "DDS hits %d", materializeStats.matched);
    drawBullet(line);

    std::snprintf(line, sizeof(line), "steps %zu", steps);
    drawBullet(line);

    std::snprintf(line, sizeof(line), "flow max %.5f", maxPhysVelocity);
    drawBullet(line);
}
</pre>
<p class="MsoNormal">The demo’s full <code><span style="font-size: 10.0pt; line-height: 115%;">drawHud()</span></code> prints more detail (legend min/max,<br />
sieve grid dimensions, hole diameter, and the key list). The snippet above is a<br />
real excerpt, shortened to highlight the pattern: a reusable “bullet line”<br />
helper + straightforward <code><span style="font-size: 10.0pt; line-height: 115%;">outtextxy()</span></code><br />
calls.</p>
<h1>Dictionary of key terms (OpenLB + LBM)</h1>
<table class="MsoTable15Grid4Accent1" style="border-collapse: collapse; border: none;" border="1" cellspacing="0" cellpadding="0">
<tbody>
<tr>
<td style="border: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Term</b></p>
</td>
<td style="border: solid #45B0E1 1.0pt; border-left: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Meaning<br />
(in this demo’s context)</b></p>
</td>
</tr>
<tr>
<td style="border: solid #45B0E1 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Lattice<br />
(OpenLB)</b></p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #45B0E1 1.0pt; border-right: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">The regular<br />
grid of cells (and associated particle distribution functions) where the<br />
Lattice Boltzmann Method is solved. Think of it as the simulation’s<br />
“computational canvas”: every cell holds state used to compute density and<br />
velocity.</p>
</td>
</tr>
<tr>
<td style="border: solid #45B0E1 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Boundary<br />
conditions</b></p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #45B0E1 1.0pt; border-right: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">Rules<br />
applied at the edges of the domain (and on obstacles) that enforce physical<br />
behavior such as inflow velocity, outflow pressure, or no-slip walls. In<br />
practice, this is where geometry labels like <i>inlet</i>/<i>wall</i> turn<br />
into solver constraints.</p>
</td>
</tr>
<tr>
<td style="border: solid #45B0E1 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Collide-and-stream</b></p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #45B0E1 1.0pt; border-right: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">The core<br />
LBM update step: “collision” relaxes distributions toward equilibrium<br />
locally; “streaming” propagates distributions to neighboring cells. Repeating<br />
this over many iterations advances the flow in time.</p>
</td>
</tr>
<tr>
<td style="border: solid #45B0E1 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Parallelization<br />
(OpenLB)</b></p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #45B0E1 1.0pt; border-right: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">OpenLB can<br />
distribute the lattice across multiple CPU cores (and across multiple nodes<br />
via MPI in many setups). Parallel performance depends on domain<br />
decomposition, communication overhead, and how much work happens per cell per<br />
step.</p>
</td>
</tr>
<tr>
<td style="border: solid #45B0E1 1.0pt; border-top: none; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;"><b>Mesh /<br />
lattice cell size</b></p>
</td>
<td style="border-top: none; border-left: none; border-bottom: solid #45B0E1 1.0pt; border-right: solid #45B0E1 1.0pt; padding: 0cm 5.4pt 0cm 5.4pt;">
<p class="MsoNormal" style="margin-bottom: 8.0pt; line-height: normal;">The spatial<br />
resolution of the simulation. Smaller cells (finer lattice) capture more<br />
detail but increase cost roughly with the number of cells. For live<br />
rendering, you may downsample the lattice when drawing so the simulation can<br />
remain responsive.</p>
</td>
</tr>
</tbody>
</table>
<h1>Running the demo quickly (Bash scripts)</h1>
<p class="MsoNormal">The demo folder includes two helper scripts that are the<br />
quickest way to get from zero to a running window. The Linux script is fully<br />
automated (dependencies, cloning, CMake configure/build, and run), and it has<br />
been tested.</p>
<ul type="disc">
<li class="MsoNormal"><b>run_openlb_pipe_3d_demo.sh</b> (Linux / Debian / Ubuntu<br />
/ WSL.2)</li>
<li class="MsoNormal"><b>run_openlb_pipe_3d_demo_macos.sh</b> (macOS)</li>
</ul>
<ol style="margin-top: 0cm;" start="1" type="1">
<li class="MsoNormal" style="line-height: 115%;"><b>Install dependencies (Linux<br />
script)</b>: optionally installs required packages via <b>apt</b> (can be<br />
skipped with <code><span style="font-size: 10.0pt; line-height: 115%;">--skip-system-packages</span></code>).</li>
<li class="MsoNormal" style="line-height: 115%;"><b>Fetch sources</b>: reuses an<br />
existing checkout when possible, otherwise it can clone <code><span style="font-size: 10.0pt; line-height: 115%;">wx_bgi_graphics</span></code><br />
(and clones the public OpenLB release to <code><span style="font-size: 10.0pt; line-height: 115%;">${OPENLB_ROOT:-/tmp/openlb-release}</span></code>).</li>
<li class="MsoNormal" style="line-height: 115%;"><b>Configure, build, run</b>:<br />
configures CMake with <code><span style="font-size: 10.0pt; line-height: 115%;">-DWXBGI_ENABLE_OPENLB=ON</span></code>, builds the <code><span style="font-size: 10.0pt; line-height: 115%;">wxbgi_openlb_pipe_3d_demo</span></code><br />
target, then runs it (interactive: <code><span style="font-size: 10.0pt; line-height: 115%;">--smooth</span></code>, validation: <code><span style="font-size: 10.0pt; line-height: 115%;">--test</span></code>).</li>
</ol>
<pre class="EnlighterJSRAW" data-enlighter-language="generic"># Linux / WSL2 (Debian/Ubuntu family)
./run_openlb_pipe_3d_demo.sh

# macOS
./run_openlb_pipe_3d_demo_macos.sh

# Optional quick validation run (Linux script)
./run_openlb_pipe_3d_demo.sh --test
</pre>
<h2>Quick troubleshooting</h2>
<ul type="disc">
<li class="MsoNormal"><b>“Library not found” on startup</b>: confirm the loader<br />
path (LD_LIBRARY_PATH / PATH) includes the wx_bgi_graphics shared library<br />
directory.</li>
<li class="MsoNormal"><b>Window opens but nothing changes</b>: check whether the<br />
simulation is rendering every N steps (render interval too large can look<br />
frozen).</li>
<li class="MsoNormal"><b>Low FPS</b>: reduce the number of lattice cells drawn<br />
per frame (downsample) or render less frequently.</li>
<li class="MsoNormal"><b>Remote/headless machines</b>: GUI rendering typically<br />
needs an active display server (e.g., X11/Wayland on Linux).</li>
</ul>
<h1>Further Readings</h1>
<ul style="margin-top: 0cm;" type="disc">
<li class="MsoNormal" style="margin-bottom: 0cm;"><b>wx_bgi_graphics<br />
OpenLB-Support guide:</b><br />
<a href="https://github.com/Andromedabay/wx_bgi_graphics/blob/main/docs/user-guide/OpenLB-Support.md">https://github.com/Andromedabay/wx_bgi_graphics/blob/main/docs/user-guide/OpenLB-Support.md</a><br />
The key document for this article: explains the helper functions and<br />
conventions for building/labelling geometry and bridging that into OpenLB<br />
workflows.</li>
<li class="MsoNormal"><b>wx_bgi_graphics (source + examples):</b><br />
<a href="https://github.com/Andromedabay/wx_bgi_graphics">https://github.com/Andromedabay/wx_bgi_graphics</a><br />
Start here for the library’s API, build instructions, and additional<br />
demos.</li>
<li class="MsoNormal"><b>OpenLB project homepage:</b><a href="https://www.openlb.net/"> https://www.openlb.net/</a><br />
Official entry point for downloads, documentation, FAQs, and showcase<br />
applications.</li>
<li class="MsoNormal"><b>OpenLB meshing &amp; visualization page:</b><br />
<a href="https://www.openlb.net/meshing-visualization/">https://www.openlb.net/meshing-visualization/</a><br />
Background on OpenLB’s typical post-processing workflow (e.g.,<br />
ParaView/VTK), useful for comparing with “live” windowed visualization.</li>
<li class="MsoNormal"><b>OpenLB overview at KIT (LBRG):</b><br />
<a href="https://www.lbrg.kit.edu/openlb/">https://www.lbrg.kit.edu/openlb/</a><br />
A concise institutional overview of OpenLB’s goals, architecture, and<br />
parallel capabilities.</li>
<li class="MsoNormal"><b>OpenLB User Guide (Zenodo record):</b><br />
<a href="https://zenodo.org/records/13293033">https://zenodo.org/records/13293033</a><br />
A citable user guide PDF that covers concepts, workflow, and many<br />
practical details for setting up cases.</li>
</ul>
<h1>Wrap-up</h1>
<p class="MsoNormal">This demo is a handy template for pairing a heavyweight CFD engine (OpenLB) with a lightweight, approachable drawing API (wx_bgi_graphics). Once the “fields to pixels” bridge is in place, you can iterate fast: add new view modes, draw vectors or streamlines, drop in a color legend, and make the display interactive—without waiting for a full post-processing round-trip.</p>
<p class="MsoNormal">
</div>
<p>&nbsp;</p>
<p>&nbsp;</p>


		<div class=" twp-social-share  booster-clear">

						    <header class="twp-plugin-title twp-share-title">
			        <h2>Share</h2>
			    </header>
			
		    <div class="twp-share-container">
				<div class="twp-social-icons twp-social-facebook">										<a class="twp-icon-holder" rel="nofollow"  onclick="twp_be_popup_new_window( event,'https://www.facebook.com/sharer/sharer.php?u=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/'); "  href="https://www.facebook.com/sharer/sharer.php?u=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/" >
			                                <span class="twp-social-count"><span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M 23.25 9 L 15 9 L 15 0.75 C 15 0.335938 14.664062 0 14.25 0 L 9.75 0 C 9.335938 0 9 0.335938 9 0.75 L 9 9 L 0.75 9 C 0.335938 9 0 9.335938 0 9.75 L 0 14.25 C 0 14.664062 0.335938 15 0.75 15 L 9 15 L 9 23.25 C 9 23.664062 9.335938 24 9.75 24 L 14.25 24 C 14.664062 24 15 23.664062 15 23.25 L 15 15 L 23.25 15 C 23.664062 15 24 14.664062 24 14.25 L 24 9.75 C 24 9.335938 23.664062 9 23.25 9 Z M 23.25 9" /></svg></span></span>												<span class="twp-share-media">

													<span class="twp-share-label">
                                                        <span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M22.675 0h-21.35c-.732 0-1.325.593-1.325 1.325v21.351c0 .731.593 1.324 1.325 1.324h11.495v-9.294h-3.128v-3.622h3.128v-2.671c0-3.1 1.893-4.788 4.659-4.788 1.325 0 2.463.099 2.795.143v3.24l-1.918.001c-1.504 0-1.795.715-1.795 1.763v2.313h3.587l-.467 3.622h-3.12v9.293h6.116c.73 0 1.323-.593 1.323-1.325v-21.35c0-.732-.593-1.325-1.325-1.325z" /></svg></span>
				                                        <span class="twp-label-title">
				                                            Facebook				                                        </span>
				                                    </span>
												</span>
																					</a>
									</div><div class="twp-social-icons twp-social-twitter">										<a class="twp-icon-holder" rel="nofollow"  onclick="twp_be_popup_new_window( event,'https://twitter.com/intent/tweet?text=Using%20wx_bgi_graphics%20With%20OpenLB&#038;url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/'); "  href="https://twitter.com/intent/tweet?text=Using%20wx_bgi_graphics%20With%20OpenLB&#038;url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/" >
			                                <span class="twp-social-count"><span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M 23.25 9 L 15 9 L 15 0.75 C 15 0.335938 14.664062 0 14.25 0 L 9.75 0 C 9.335938 0 9 0.335938 9 0.75 L 9 9 L 0.75 9 C 0.335938 9 0 9.335938 0 9.75 L 0 14.25 C 0 14.664062 0.335938 15 0.75 15 L 9 15 L 9 23.25 C 9 23.664062 9.335938 24 9.75 24 L 14.25 24 C 14.664062 24 15 23.664062 15 23.25 L 15 15 L 23.25 15 C 23.664062 15 24 14.664062 24 14.25 L 24 9.75 C 24 9.335938 23.664062 9 23.25 9 Z M 23.25 9" /></svg></span></span>												<span class="twp-share-media">
													<span class="twp-share-label">
                                                        <span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M18.244 2.25h3.308l-7.227 8.26 8.502 11.24H16.17l-5.214-6.817L4.99 21.75H1.68l7.73-8.835L1.254 2.25H8.08l4.713 6.231zm-1.161 17.52h1.833L7.084 4.126H5.117z"></path></svg></span>
				                                        <span class="twp-label-title">
				                                            Twitter				                                        </span>
												    </span>
												</span>
																					</a>
									</div><div class="twp-social-icons twp-social-pinterest">										<a class="twp-icon-holder" rel="nofollow" href="javascript:twp_be_pinterest()">
											<span class="twp-social-count"><span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M 23.25 9 L 15 9 L 15 0.75 C 15 0.335938 14.664062 0 14.25 0 L 9.75 0 C 9.335938 0 9 0.335938 9 0.75 L 9 9 L 0.75 9 C 0.335938 9 0 9.335938 0 9.75 L 0 14.25 C 0 14.664062 0.335938 15 0.75 15 L 9 15 L 9 23.25 C 9 23.664062 9.335938 24 9.75 24 L 14.25 24 C 14.664062 24 15 23.664062 15 23.25 L 15 15 L 23.25 15 C 23.664062 15 24 14.664062 24 14.25 L 24 9.75 C 24 9.335938 23.664062 9 23.25 9 Z M 23.25 9" /></svg></span></span>				                                <span class="twp-share-media">
													<span class="twp-share-label">
                                                        <span class="booster-svg-icon"><svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M12.289,2C6.617,2,3.606,5.648,3.606,9.622c0,1.846,1.025,4.146,2.666,4.878c0.25,0.111,0.381,0.063,0.439-0.169 c0.044-0.175,0.267-1.029,0.365-1.428c0.032-0.128,0.017-0.237-0.091-0.362C6.445,11.911,6.01,10.75,6.01,9.668 c0-2.777,2.194-5.464,5.933-5.464c3.23,0,5.49,2.108,5.49,5.122c0,3.407-1.794,5.768-4.13,5.768c-1.291,0-2.257-1.021-1.948-2.277 c0.372-1.495,1.089-3.112,1.089-4.191c0-0.967-0.542-1.775-1.663-1.775c-1.319,0-2.379,1.309-2.379,3.059 c0,1.115,0.394,1.869,0.394,1.869s-1.302,5.279-1.54,6.261c-0.405,1.666,0.053,4.368,0.094,4.604 c0.021,0.126,0.167,0.169,0.25,0.063c0.129-0.165,1.699-2.419,2.142-4.051c0.158-0.59,0.817-2.995,0.817-2.995 c0.43,0.784,1.681,1.446,3.013,1.446c3.963,0,6.822-3.494,6.822-7.833C20.394,5.112,16.849,2,12.289,2"></path></svg></span>
				                                        <span class="twp-label-title">
				                                            Pinterest				                                        </span>
				                                    </span>
												</span>
																					</a>
									</div><div class="twp-social-icons twp-social-linkedin">										<a class="twp-icon-holder" rel="nofollow"  onclick="twp_be_popup_new_window( event,'http://www.linkedin.com/shareArticle?mini=true&#038;title=Using%20wx_bgi_graphics%20With%20OpenLB&#038;url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/'); "  href="http://www.linkedin.com/shareArticle?mini=true&#038;title=Using%20wx_bgi_graphics%20With%20OpenLB&#038;url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/" >
																							<span class="twp-share-media">
				                                    <span class="share-media-nocount">
													    <svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M19.7,3H4.3C3.582,3,3,3.582,3,4.3v15.4C3,20.418,3.582,21,4.3,21h15.4c0.718,0,1.3-0.582,1.3-1.3V4.3 C21,3.582,20.418,3,19.7,3z M8.339,18.338H5.667v-8.59h2.672V18.338z M7.004,8.574c-0.857,0-1.549-0.694-1.549-1.548 c0-0.855,0.691-1.548,1.549-1.548c0.854,0,1.547,0.694,1.547,1.548C8.551,7.881,7.858,8.574,7.004,8.574z M18.339,18.338h-2.669 v-4.177c0-0.996-0.017-2.278-1.387-2.278c-1.389,0-1.601,1.086-1.601,2.206v4.249h-2.667v-8.59h2.559v1.174h0.037 c0.356-0.675,1.227-1.387,2.526-1.387c2.703,0,3.203,1.779,3.203,4.092V18.338z"></path></svg>				                                    </span>
													<span class="twp-share-label twp-label-title">
				                                        LinkedIn				                                    </span>
												</span>
																					</a>
										</div><div class="twp-social-icons twp-social-email">										<a class="twp-icon-holder" rel="nofollow"  href="mailto:?subject=:&amp;body= Using wx_bgi_graphics With OpenLB http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/">
																							<span class="twp-share-media">
				                                    <span class="share-media-nocount">
													    <svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M0 3v18h24v-18h-24zm6.623 7.929l-4.623 5.712v-9.458l4.623 3.746zm-4.141-5.929h19.035l-9.517 7.713-9.518-7.713zm5.694 7.188l3.824 3.099 3.83-3.104 5.612 6.817h-18.779l5.513-6.812zm9.208-1.264l4.616-3.741v9.348l-4.616-5.607z" /></svg>				                                    </span>
				                                    <span class="twp-share-label twp-label-title">
				                                        Email				                                    </span>
												</span>
																					</a>
										</div><div class="twp-social-icons twp-social-vk">										<a class="twp-icon-holder" rel="nofollow"  onclick="twp_be_popup_new_window( event,'http://vk.com/share.php?url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/&#038;caption=Using%20wx_bgi_graphics%20With%20OpenLB'); "  href="http://vk.com/share.php?url=http://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/&#038;caption=Using%20wx_bgi_graphics%20With%20OpenLB" >
																							<span class="twp-share-media">
				                                    <span class="share-media-nocount">
													    <svg class="booster-svg" aria-hidden="true" role="img" focusable="false" viewbox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" width="24" height="24"><path fill="currentColor" d="M22,7.1c0.2,0.4-0.4,1.5-1.6,3.1c-0.2,0.2-0.4,0.5-0.7,0.9c-0.5,0.7-0.9,1.1-0.9,1.4c-0.1,0.3-0.1,0.6,0.1,0.8 c0.1,0.1,0.4,0.4,0.8,0.9h0l0,0c1,0.9,1.6,1.7,2,2.3c0,0,0,0.1,0.1,0.1c0,0.1,0,0.1,0.1,0.3c0,0.1,0,0.2,0,0.4 c0,0.1-0.1,0.2-0.3,0.3c-0.1,0.1-0.4,0.1-0.6,0.1l-2.7,0c-0.2,0-0.4,0-0.6-0.1c-0.2-0.1-0.4-0.1-0.5-0.2l-0.2-0.1 c-0.2-0.1-0.5-0.4-0.7-0.7s-0.5-0.6-0.7-0.8c-0.2-0.2-0.4-0.4-0.6-0.6C14.8,15,14.6,15,14.4,15c0,0,0,0-0.1,0c0,0-0.1,0.1-0.2,0.2 c-0.1,0.1-0.2,0.2-0.2,0.3c-0.1,0.1-0.1,0.3-0.2,0.5c-0.1,0.2-0.1,0.5-0.1,0.8c0,0.1,0,0.2,0,0.3c0,0.1-0.1,0.2-0.1,0.2l0,0.1 c-0.1,0.1-0.3,0.2-0.6,0.2h-1.2c-0.5,0-1,0-1.5-0.2c-0.5-0.1-1-0.3-1.4-0.6s-0.7-0.5-1.1-0.7s-0.6-0.4-0.7-0.6l-0.3-0.3 c-0.1-0.1-0.2-0.2-0.3-0.3s-0.4-0.5-0.7-0.9s-0.7-1-1.1-1.6c-0.4-0.6-0.8-1.3-1.3-2.2C2.9,9.4,2.5,8.5,2.1,7.5C2,7.4,2,7.3,2,7.2 c0-0.1,0-0.1,0-0.2l0-0.1c0.1-0.1,0.3-0.2,0.6-0.2l2.9,0c0.1,0,0.2,0,0.2,0.1S5.9,6.9,5.9,7L6,7c0.1,0.1,0.2,0.2,0.3,0.3 C6.4,7.7,6.5,8,6.7,8.4C6.9,8.8,7,9,7.1,9.2l0.2,0.3c0.2,0.4,0.4,0.8,0.6,1.1c0.2,0.3,0.4,0.5,0.5,0.7s0.3,0.3,0.4,0.4 c0.1,0.1,0.3,0.1,0.4,0.1c0.1,0,0.2,0,0.3-0.1c0,0,0,0,0.1-0.1c0,0,0.1-0.1,0.1-0.2c0.1-0.1,0.1-0.3,0.1-0.5c0-0.2,0.1-0.5,0.1-0.8 c0-0.4,0-0.8,0-1.3c0-0.3,0-0.5-0.1-0.8c0-0.2-0.1-0.4-0.1-0.5L9.6,7.6C9.4,7.3,9.1,7.2,8.7,7.1C8.6,7.1,8.6,7,8.7,6.9 C8.9,6.7,9,6.6,9.1,6.5c0.4-0.2,1.2-0.3,2.5-0.3c0.6,0,1,0.1,1.4,0.1c0.1,0,0.3,0.1,0.3,0.1c0.1,0.1,0.2,0.1,0.2,0.3 c0,0.1,0.1,0.2,0.1,0.3s0,0.3,0,0.5c0,0.2,0,0.4,0,0.6c0,0.2,0,0.4,0,0.7c0,0.3,0,0.6,0,0.9c0,0.1,0,0.2,0,0.4c0,0.2,0,0.4,0,0.5 c0,0.1,0,0.3,0,0.4s0.1,0.3,0.1,0.4c0.1,0.1,0.1,0.2,0.2,0.3c0.1,0,0.1,0,0.2,0c0.1,0,0.2,0,0.3-0.1c0.1-0.1,0.2-0.2,0.4-0.4 s0.3-0.4,0.5-0.7c0.2-0.3,0.5-0.7,0.7-1.1c0.4-0.7,0.8-1.5,1.1-2.3c0-0.1,0.1-0.1,0.1-0.2c0-0.1,0.1-0.1,0.1-0.1l0,0l0.1,0 c0,0,0,0,0.1,0s0.2,0,0.2,0l3,0c0.3,0,0.5,0,0.7,0S21.9,7,21.9,7L22,7.1z"></path></svg>				                                    </span>
													<span class="twp-share-label twp-label-title">
				                                        VK				                                    </span>
												</span>
																					</a>
										</div>			</div>
		</div>

	]]></content:encoded>
					
					<wfw:commentRss>https://andromedabay.ddns.net/using-wx_bgi_graphics-with-openlb/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>

<!--
Performance optimized by W3 Total Cache. Learn more: https://www.boldgrid.com/w3-total-cache/?utm_source=w3tc&utm_medium=footer_comment&utm_campaign=free_plugin

Page Caching using Disk: Enhanced 
Lazy Loading (feed)

Served from: andromedabay.ddns.net @ 2026-06-20 16:31:11 by W3 Total Cache
-->