godot/thirdparty/graphite/src/Intervals.cpp

// SPDX-License-Identifier: MIT OR MPL-2.0 OR LGPL-2.1-or-later OR GPL-2.0-or-later
// Copyright 2010, SIL International, All rights reserved.

#include <algorithm>
#include <cmath>
#include <limits>

#include "inc/Intervals.h"
#include "inc/Segment.h"
#include "inc/Slot.h"
#include "inc/debug.h"
#include "inc/bits.h"

usingnamespacegraphite2;

#include <cmath>

inline
Zones::Exclusion  Zones::Exclusion::split_at(float p) {}

inline
void Zones::Exclusion::left_trim(float p) {}

inline
Zones::Exclusion & Zones::Exclusion::operator += (Exclusion const & rhs) {}

inline
uint8 Zones::Exclusion::outcode(float val) const {}

void Zones::exclude_with_margins(float xmin, float xmax, int axis) {}

namespace
{

inline
bool separated(float a, float b) {}

}

void Zones::insert(Exclusion e)
{}


void Zones::remove(float x, float xm)
{}


Zones::const_iterator Zones::find_exclusion_under(float x) const
{}


float Zones::closest(float origin, float & cost) const
{}


// Cost and test position functions

bool Zones::Exclusion::track_cost(float & best_cost, float & best_pos, float origin) const {}

inline
float Zones::Exclusion::cost(float p) const {}


float Zones::Exclusion::test_position(float origin) const {}


#if !defined GRAPHITE2_NTRACING

void Zones::jsonDbgOut(Segment *seg) const {

    if (_dbg)
    {
        for (Zones::idebugs s = dbgs_begin(), e = dbgs_end(); s != e; ++s)
        {
            *_dbg << json::flat << json::array
                << objectid(dslot(seg, (Slot *)(s->_env[0])))
                << reinterpret_cast<ptrdiff_t>(s->_env[1]);
            if (s->_isdel)
                *_dbg << "remove" << Position(s->_excl.x, s->_excl.xm);
            else
                *_dbg << "exclude" << json::flat << json::array
                    << s->_excl.x << s->_excl.xm
                    << s->_excl.sm << s->_excl.smx << s->_excl.c
                    << json::close;
            *_dbg << json::close;
        }
    }
}

#endif