// -*- C++ -*-

// ************************************************************************* //

// Transcribe volume fields to surfaces.
fieldTransfer
{
    type    surfMeshes;
    libs    ("libsampling.so");
    log     true;
    writeControl    none;
    createOnRead    true;
    executeControl  timeStep;
    executeInterval 1;

    fields      (p U);
    derived     (rhoU pTotal);

    rhoRef      1.25;

    _plane
    {
        type    plane;
        source  cells;

        planeType   pointAndNormal;

        pointAndNormalDict
        {
            normal (-1 0 0);
            point  (-0.04 0 0);
        }
    }

    surfaces
    (
        // Top channel
        plane1
        {
            ${_plane}
            bounds (-1 0 -1) (0 1 1);
        }

        // Bottom channel
        plane2
        {
            ${_plane}
            bounds (-1 -1 -1) (0 0 1);
        }

        // Angled plane - for general testing
        plane3
        {
            type        distanceSurface;
            distance    0;
            signed      true;

            surfaceType triSurfaceMesh;
            surfaceName angledPlane.obj;
        }
    );
}


// ************************************************************************* //
