#include "lib/$fileTransformUv" void mx_image_float(textureresource file, string layer, float default_value, vector2 texcoord, string uaddressmode, string vaddressmode, string filtertype, string framerange, int frameoffset, string frameendaction, output float out) { if (file.filename == "" || (uaddressmode == "constant" && (texcoord.x<0.0 || texcoord.x>1.0)) || (vaddressmode == "constant" && (texcoord.y<0.0 || texcoord.y>1.0))) { out = default_value; return; } color missingColor = color(default_value); vector2 st = mx_transform_uv(texcoord); color rgb = texture(file.filename, st.x, st.y, "subimage", layer, "missingcolor", missingColor, "swrap", uaddressmode, "twrap", vaddressmode); out = rgb[0]; }