Lines Matching refs:clamp
222 return static_cast<uint8>(round(clamp(v, 0.0f, 1.0f) * 255.0f));
233 u8vec2 Topack(round(clamp(v, 0.0f, 1.0f) * 255.0f));
246 int8 Topack(static_cast<int8>(round(clamp(v ,-1.0f, 1.0f) * 127.0f)));
254 return clamp(
261 i8vec2 Topack(round(clamp(v ,-1.0f, 1.0f) * 127.0f));
269 return clamp(
276 return static_cast<uint16>(round(clamp(s, 0.0f, 1.0f) * 65535.0f));
287 u16vec4 Topack(round(clamp(v , 0.0f, 1.0f) * 65535.0f));
300 int16 Topack = static_cast<int16>(round(clamp(v ,-1.0f, 1.0f) * 32767.0f));
308 return clamp(
315 i16vec4 Topack = static_cast<i16vec4>(round(clamp(v ,-1.0f, 1.0f) * 32767.0f));
323 return clamp(
410 Result.data.x = int(round(clamp(v.x,-1.0f, 1.0f) * 511.f));
411 Result.data.y = int(round(clamp(v.y,-1.0f, 1.0f) * 511.f));
412 Result.data.z = int(round(clamp(v.z,-1.0f, 1.0f) * 511.f));
413 Result.data.w = int(round(clamp(v.w,-1.0f, 1.0f) * 1.f));
422 Result.x = clamp(float(Unpack.data.x) / 511.f, -1.0f, 1.0f);
423 Result.y = clamp(float(Unpack.data.y) / 511.f, -1.0f, 1.0f);
424 Result.z = clamp(float(Unpack.data.z) / 511.f, -1.0f, 1.0f);
425 Result.w = clamp(float(Unpack.data.w) / 1.f, -1.0f, 1.0f);
432 Result.data.x = int(round(clamp(v.x, 0.0f, 1.0f) * 1023.f));
433 Result.data.y = int(round(clamp(v.y, 0.0f, 1.0f) * 1023.f));
434 Result.data.z = int(round(clamp(v.z, 0.0f, 1.0f) * 1023.f));
435 Result.data.w = int(round(clamp(v.w, 0.0f, 1.0f) * 3.f));