19 #ifndef OST_GFX_IMPL_MAPPED_PROPERTY_HH
20 #define OST_GFX_IMPL_MAPPED_PROPERTY_HH
32 namespace ost {
namespace gfx {
namespace impl {
34 inline float Normalize(
float v,
float min_v,
float max_v)
36 return (v-min_v)/(max_v-min_v);
39 inline float Clamp(
float v,
float min_v,
float max_v)
41 return std::max(min_v,std::min(max_v,v));
49 const Gradient& g,
float minv,
float maxv,
56 const Gradient& g,
float minv,
float maxv,
#define DLLEXPORT_OST_GFX
float Normalize(float v, float min_v, float max_v)
Three dimensional vector class, using Real precision.
float DLLEXPORT_OST_GFX MappedProperty(const mol::EntityView &ev, const String &prop, const geom::Vec3 &pos)
Manage shared instances of images.
float Clamp(float v, float min_v, float max_v)