# include "config.h"
#endif
+#include <cstring>
+
+#include <simgear/math/SGMath.hxx>
#include <simgear/nasal/nasal.h>
#include <simgear/props/props.hxx>
#include "NasalSys.hxx"
+using namespace std;
+
// Implementation of a Nasal wrapper for the SGPropertyNode class,
// using the Nasal "ghost" (er... Garbage collection Handle for
// OutSide Thingy) facility.
case props::UNSPECIFIED: t = "UNSPECIFIED"; break;
case props::VEC3D: t = "VEC3D"; break;
case props::VEC4D: t = "VEC4D"; break;
+ case props::EXTENDED: t = "EXTENDED"; break; // shouldn't happen
}
return NASTR(t);
}
template<typename T>
naRef makeVectorFromVec(naContext c, const T& vec)
{
- const unsigned num_components
+ const int num_components
= sizeof(vec.data()) / sizeof(typename T::value_type);
naRef vector = naNewVector(c);
naVec_setsize(vector, num_components);
T makeVecFromVector(naRef vector)
{
T vec;
- const unsigned num_components
+ const int num_components
= sizeof(vec.data()) / sizeof(typename T::value_type);
int size = naVec_size(vector);