fuckingtech/public/assets/glsl/lygia/sdf/opRevolve.msl
Elias Rhouzlane bf76c6b086 fix: code
2025-04-06 17:23:52 +02:00

15 lines
283 B
Text

/*
contributors: Inigo Quiles
description: revolve operation of a 2D SDFs into a 3D one
use: <float2> opRevolve( <float3> p, <float> w )
*/
#ifndef FNC_OPREVOLVE
#define FNC_OPREVOLVE
float2 opRevolve( float3 p, float w ) {
return float2( length(p.xz) - w, p.y );
}
#endif