blob: 726450b489bf68cf9a7f886474b85ec89780c472 [file]
#include <metal_stdlib>
using namespace metal;
[[max_total_threads_per_threadgroup(1)]]
kernel void v() {
float const low = 1.0f;
float const high = 0.0f;
float const x_val = 0.5f;
float const res = (clamp(((x_val - low) / (high - low)), 0.0f, 1.0f) * (clamp(((x_val - low) / (high - low)), 0.0f, 1.0f) * (3.0f - (2.0f * clamp(((x_val - low) / (high - low)), 0.0f, 1.0f)))));
}