2018-09-28 17:54:21 +02:00
|
|
|
// OpenSTA, Static Timing Analyzer
|
2024-01-12 01:34:49 +01:00
|
|
|
// Copyright (c) 2024, Parallax Software, Inc.
|
2018-09-28 17:54:21 +02:00
|
|
|
//
|
|
|
|
|
// This program is free software: you can redistribute it and/or modify
|
|
|
|
|
// it under the terms of the GNU General Public License as published by
|
|
|
|
|
// the Free Software Foundation, either version 3 of the License, or
|
|
|
|
|
// (at your option) any later version.
|
|
|
|
|
//
|
|
|
|
|
// This program is distributed in the hope that it will be useful,
|
|
|
|
|
// but WITHOUT ANY WARRANTY; without even the implied warranty of
|
2022-01-04 18:17:08 +01:00
|
|
|
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
2018-09-28 17:54:21 +02:00
|
|
|
// GNU General Public License for more details.
|
|
|
|
|
//
|
|
|
|
|
// You should have received a copy of the GNU General Public License
|
2022-01-04 18:17:08 +01:00
|
|
|
// along with this program. If not, see <https://www.gnu.org/licenses/>.
|
2018-09-28 17:54:21 +02:00
|
|
|
|
2024-07-27 00:10:43 +02:00
|
|
|
%module util
|
2024-07-22 03:18:35 +02:00
|
|
|
|
|
|
|
|
%{
|
2024-07-27 00:10:43 +02:00
|
|
|
|
|
|
|
|
#include "Sta.hh"
|
2020-04-05 23:53:44 +02:00
|
|
|
#include "StaConfig.hh" // STA_VERSION
|
|
|
|
|
#include "Stats.hh"
|
|
|
|
|
#include "Report.hh"
|
|
|
|
|
#include "Error.hh"
|
|
|
|
|
#include "Fuzzy.hh"
|
|
|
|
|
#include "Units.hh"
|
2018-09-28 17:54:21 +02:00
|
|
|
|
|
|
|
|
using namespace sta;
|
|
|
|
|
|
|
|
|
|
%}
|
|
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
//
|
2024-07-27 00:10:43 +02:00
|
|
|
// Empty class definitions to make swig happy.
|
|
|
|
|
// Private constructor/destructor so swig doesn't emit them.
|
2018-09-28 17:54:21 +02:00
|
|
|
//
|
|
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
%inline %{
|
|
|
|
|
|
2018-11-09 19:04:16 +01:00
|
|
|
float float_inf = INF;
|
|
|
|
|
|
2018-09-28 17:54:21 +02:00
|
|
|
const char *
|
|
|
|
|
version()
|
|
|
|
|
{
|
2019-02-16 21:07:59 +01:00
|
|
|
return STA_VERSION;
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
2019-07-07 18:58:47 +02:00
|
|
|
const char *
|
|
|
|
|
git_sha1()
|
|
|
|
|
{
|
|
|
|
|
return STA_GIT_SHA1;
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-22 20:42:34 +02:00
|
|
|
// Elapsed run time (in seconds).
|
|
|
|
|
double
|
|
|
|
|
elapsed_run_time()
|
|
|
|
|
{
|
|
|
|
|
return elapsedRunTime();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// User run time (in seconds).
|
|
|
|
|
double
|
|
|
|
|
user_run_time()
|
|
|
|
|
{
|
|
|
|
|
return userRunTime();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// User run time (in seconds).
|
|
|
|
|
unsigned long
|
|
|
|
|
cputime()
|
|
|
|
|
{
|
|
|
|
|
return static_cast<unsigned long>(userRunTime() + .5);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Peak memory usage in bytes.
|
|
|
|
|
unsigned long
|
|
|
|
|
memory_usage()
|
|
|
|
|
{
|
|
|
|
|
return memoryUsage();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int
|
|
|
|
|
processor_count()
|
|
|
|
|
{
|
|
|
|
|
return processorCount();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
int
|
|
|
|
|
thread_count()
|
|
|
|
|
{
|
|
|
|
|
return Sta::sta()->threadCount();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
set_thread_count(int count)
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->setThreadCount(count);
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-22 04:14:31 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2020-12-25 23:00:11 +01:00
|
|
|
void
|
|
|
|
|
report_error(int id,
|
|
|
|
|
const char *msg)
|
|
|
|
|
{
|
2020-12-26 01:55:46 +01:00
|
|
|
Report *report = Sta::sta()->report();
|
|
|
|
|
report->error(id, "%s", msg);
|
2020-12-25 23:00:11 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
report_file_error(int id,
|
|
|
|
|
const char *filename,
|
|
|
|
|
int line,
|
|
|
|
|
const char *msg)
|
|
|
|
|
{
|
2020-12-26 01:55:46 +01:00
|
|
|
Report *report = Sta::sta()->report();
|
|
|
|
|
report->error(id, filename, line, "%s", msg);
|
2020-12-25 23:00:11 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
report_warn(int id,
|
|
|
|
|
const char *msg)
|
|
|
|
|
{
|
2020-12-26 01:55:46 +01:00
|
|
|
Report *report = Sta::sta()->report();
|
|
|
|
|
report->warn(id, "%s", msg);
|
2020-12-25 23:00:11 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
report_file_warn(int id,
|
|
|
|
|
const char *filename,
|
|
|
|
|
int line,
|
|
|
|
|
const char *msg)
|
|
|
|
|
{
|
2020-12-26 01:55:46 +01:00
|
|
|
Report *report = Sta::sta()->report();
|
|
|
|
|
report->fileWarn(id, filename, line, "%s", msg);
|
2020-12-25 23:00:11 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
2020-12-26 01:55:46 +01:00
|
|
|
report_line(const char *msg)
|
2020-12-25 23:00:11 +01:00
|
|
|
{
|
2022-06-25 19:08:33 +02:00
|
|
|
Sta *sta = Sta::sta();
|
|
|
|
|
if (sta)
|
|
|
|
|
sta->report()->reportLineString(msg);
|
|
|
|
|
else
|
|
|
|
|
// After sta::delete_all_memory souce -echo prints the cmd file line
|
|
|
|
|
printf("%s\n", msg);
|
2020-12-25 23:00:11 +01:00
|
|
|
}
|
|
|
|
|
|
2020-03-09 00:58:10 +01:00
|
|
|
void
|
|
|
|
|
fflush()
|
|
|
|
|
{
|
|
|
|
|
fflush(stdout);
|
|
|
|
|
fflush(stderr);
|
|
|
|
|
}
|
|
|
|
|
|
2018-09-28 17:54:21 +02:00
|
|
|
void
|
|
|
|
|
redirect_file_begin(const char *filename)
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->redirectFileBegin(filename);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
redirect_file_append_begin(const char *filename)
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->redirectFileAppendBegin(filename);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
redirect_file_end()
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->redirectFileEnd();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
redirect_string_begin()
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->redirectStringBegin();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
redirect_string_end()
|
|
|
|
|
{
|
|
|
|
|
return Sta::sta()->report()->redirectStringEnd();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
2020-12-25 01:31:52 +01:00
|
|
|
log_begin_cmd(const char *filename)
|
2018-09-28 17:54:21 +02:00
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->logBegin(filename);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
log_end()
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->report()->logEnd();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
set_debug(const char *what,
|
|
|
|
|
int level)
|
|
|
|
|
{
|
|
|
|
|
Sta::sta()->setDebugLevel(what, level);
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-22 20:42:34 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2018-09-28 17:54:21 +02:00
|
|
|
bool
|
|
|
|
|
is_object(const char *obj)
|
|
|
|
|
{
|
|
|
|
|
// _hexaddress_p_type
|
|
|
|
|
const char *s = obj;
|
|
|
|
|
char ch = *s++;
|
|
|
|
|
if (ch != '_')
|
|
|
|
|
return false;
|
|
|
|
|
while (*s && isxdigit(*s))
|
|
|
|
|
s++;
|
|
|
|
|
if ((s - obj - 1) == sizeof(void*) * 2
|
|
|
|
|
&& *s && *s++ == '_'
|
|
|
|
|
&& *s && *s++ == 'p'
|
|
|
|
|
&& *s && *s++ == '_') {
|
|
|
|
|
while (*s && *s != ' ')
|
|
|
|
|
s++;
|
|
|
|
|
return *s == '\0';
|
|
|
|
|
}
|
|
|
|
|
else
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
// Assumes is_object is true.
|
|
|
|
|
const char *
|
|
|
|
|
object_type(const char *obj)
|
|
|
|
|
{
|
|
|
|
|
return &obj[1 + sizeof(void*) * 2 + 3];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
bool
|
|
|
|
|
is_object_list(const char *list,
|
|
|
|
|
const char *type)
|
|
|
|
|
{
|
|
|
|
|
const char *s = list;
|
|
|
|
|
while (s) {
|
|
|
|
|
bool type_match;
|
|
|
|
|
const char *next;
|
|
|
|
|
objectListNext(s, type, type_match, next);
|
|
|
|
|
if (type_match)
|
|
|
|
|
s = next;
|
|
|
|
|
else
|
|
|
|
|
return false;
|
|
|
|
|
}
|
|
|
|
|
return true;
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-22 20:42:34 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
2024-07-23 01:50:44 +02:00
|
|
|
//
|
|
|
|
|
// Units
|
|
|
|
|
//
|
2019-07-08 20:50:41 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2022-04-04 05:40:49 +02:00
|
|
|
// <unit>_sta_ui conversion from sta units to user interface units.
|
|
|
|
|
// <unit>_ui_sta conversion from user interface units to sta units.
|
|
|
|
|
|
2018-09-28 17:54:21 +02:00
|
|
|
double
|
|
|
|
|
time_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->timeUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
time_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->timeUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
capacitance_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->capacitanceUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
capacitance_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->capacitanceUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
resistance_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->resistanceUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
resistance_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->resistanceUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
voltage_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->voltageUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
voltage_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->voltageUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
current_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->currentUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
current_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->currentUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
power_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->powerUnit()->userToSta(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
power_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->powerUnit()->staToUser(value);
|
2018-09-28 17:54:21 +02:00
|
|
|
}
|
|
|
|
|
|
2019-07-08 20:50:41 +02:00
|
|
|
double
|
|
|
|
|
distance_ui_sta(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->distanceUnit()->userToSta(value);
|
2019-07-08 20:50:41 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
distance_sta_ui(double value)
|
|
|
|
|
{
|
2022-04-04 05:40:49 +02:00
|
|
|
return Sta::sta()->units()->distanceUnit()->staToUser(value);
|
2019-07-08 20:50:41 +02:00
|
|
|
}
|
|
|
|
|
|
2019-08-17 02:34:48 +02:00
|
|
|
double
|
|
|
|
|
area_ui_sta(double value)
|
|
|
|
|
{
|
|
|
|
|
double scale = Sta::sta()->units()->distanceUnit()->scale();
|
|
|
|
|
return value * scale * scale;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
double
|
|
|
|
|
area_sta_ui(double value)
|
|
|
|
|
{
|
|
|
|
|
double scale = Sta::sta()->units()->distanceUnit()->scale();
|
|
|
|
|
return value / (scale * scale);
|
|
|
|
|
}
|
|
|
|
|
|
2019-07-08 20:50:41 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
set_cmd_unit_scale(const char *unit_name,
|
|
|
|
|
float scale)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
|
|
|
|
unit->setScale(scale);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
set_cmd_unit_digits(const char *unit_name,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
|
|
|
|
unit->setDigits(digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void
|
|
|
|
|
set_cmd_unit_suffix(const char *unit_name,
|
|
|
|
|
const char *suffix)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit) {
|
|
|
|
|
unit->setSuffix(suffix);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
2020-06-24 02:11:48 +02:00
|
|
|
const char *
|
2023-04-17 17:52:20 +02:00
|
|
|
unit_scale_abbreviation (const char *unit_name)
|
2020-06-24 02:11:48 +02:00
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
2023-04-17 17:52:20 +02:00
|
|
|
return unit->scaleAbbreviation();
|
2020-06-24 02:11:48 +02:00
|
|
|
else
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
unit_suffix(const char *unit_name)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
|
|
|
|
return unit->suffix();
|
|
|
|
|
else
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
|
2023-04-17 17:52:20 +02:00
|
|
|
const char *
|
|
|
|
|
unit_scaled_suffix(const char *unit_name)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
|
|
|
|
return unit->scaledSuffix();
|
|
|
|
|
else
|
|
|
|
|
return "";
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-22 21:29:17 +02:00
|
|
|
float
|
|
|
|
|
unit_scale(const char *unit_name)
|
|
|
|
|
{
|
|
|
|
|
Unit *unit = Sta::sta()->units()->find(unit_name);
|
|
|
|
|
if (unit)
|
|
|
|
|
return unit->scale();
|
|
|
|
|
else
|
|
|
|
|
return 1.0F;
|
|
|
|
|
}
|
|
|
|
|
|
2019-07-08 20:50:41 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2024-07-23 01:50:44 +02:00
|
|
|
// format_unit functions print with fixed digits and suffix.
|
|
|
|
|
// Pass value arg as string to support NaNs.
|
|
|
|
|
const char *
|
|
|
|
|
format_time(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->timeUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_capacitance(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->capacitanceUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_resistance(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->resistanceUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_voltage(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->voltageUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_current(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->currentUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_power(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
return Sta::sta()->units()->powerUnit()->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_distance(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
Unit *dist_unit = Sta::sta()->units()->distanceUnit();
|
|
|
|
|
return dist_unit->asString(value1, digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
format_area(const char *value,
|
|
|
|
|
int digits)
|
|
|
|
|
{
|
|
|
|
|
float value1 = strtof(value, nullptr);
|
|
|
|
|
Unit *dist_unit = Sta::sta()->units()->distanceUnit();
|
|
|
|
|
return dist_unit->asString(value1 / dist_unit->scale(), digits);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2024-07-22 19:54:57 +02:00
|
|
|
const char *
|
|
|
|
|
rise_short_name()
|
|
|
|
|
{
|
|
|
|
|
return RiseFall::rise()->shortName();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *
|
|
|
|
|
fall_short_name()
|
|
|
|
|
{
|
|
|
|
|
return RiseFall::fall()->shortName();
|
|
|
|
|
}
|
|
|
|
|
|
2024-07-23 01:50:44 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
2024-07-22 19:54:57 +02:00
|
|
|
|
2024-07-27 00:10:43 +02:00
|
|
|
bool
|
|
|
|
|
fuzzy_equal(float value1,
|
|
|
|
|
float value2)
|
2024-07-22 19:54:57 +02:00
|
|
|
{
|
2024-07-27 00:10:43 +02:00
|
|
|
return fuzzyEqual(value1, value2);
|
2024-07-22 19:54:57 +02:00
|
|
|
}
|
|
|
|
|
|
2024-07-27 00:10:43 +02:00
|
|
|
%} // inline
|
2024-07-22 19:54:57 +02:00
|
|
|
|
|
|
|
|
////////////////////////////////////////////////////////////////
|
2024-07-22 22:16:49 +02:00
|
|
|
//
|
2024-07-27 00:10:43 +02:00
|
|
|
// Object Methods
|
2024-07-22 22:16:49 +02:00
|
|
|
//
|
2024-07-22 19:54:57 +02:00
|
|
|
////////////////////////////////////////////////////////////////
|
|
|
|
|
|
2018-09-28 17:54:21 +02:00
|
|
|
|