Sets float uniform in text shader (stored in floatParams map, uploaded to GPU during text rendering).
Takes shader (shader handle), name (uniform variable name in HLSL, string), value (float value, double converted to float).
Returns nothing.
Shaders
Parameters & Returns
Parameters
shaderInt
nameString
valueDouble
Returns
Void
Quick Summary
Sets float uniform in text shader (stored in floatParams map, uploaded to GPU during text rendering).
Takes shader (shader handle), name (uniform variable name in HLSL, string), value (float value, double converted to float).
Returns nothing.
Technical Exegesis...
Sets float uniform in text shader (stored in floatParams map, uploaded to GPU during text rendering). Takes shader (shader handle), name (uniform variable name in HLSL, string), value (float value, double converted to float). Returns nothing. Stores in shader.floatParams[name] map (CPU-side storage), uploaded to constant buffer during text draw (packed into cbuffer, sent to GPU with text draw command).
Sets float uniform in text shader (stored in floatParams map, uploaded to GPU during text rendering). Takes shader (shader handle), name (uniform variable name in HLSL, string), value (float value, double converted to float). Returns nothing. Stores in shader.floatParams[name] map (CPU-side storage), uploaded to constant buffer during text draw (packed into cbuffer, sent to GPU with text draw command). Use for shader parameters (intensity, time, speed), animation (update per-frame for animated text effects), or configuration (adjustable shader properties). Parameter storage: CPU map (shader.floatParams[name]=value), uploaded on use (when text with this shader drawn, params packed to cbuffer), persistent (remains until changed, survives across frames). Use cases: (1) Glow intensity (b2dSetTextShaderFloat(glowShader,"intensity",2.5) bright text glow), (2) Animation time (b2dSetTextShaderFloat(waveShader,"time",elapsed) animated wave text), (3) Outline thickness (b2dSetTextShaderFloat(outlineShader,"thickness",2.0) thick text outline), (4) Shadow offset (b2dSetTextShaderFloat(shadowShader,"offset",5.0) shadow distance). HLSL access: declare uniform (float intensity; in shader), use in shader (color.rgb *= intensity). Performance: cost zero (map insert/update, no GPU operation until draw), batched upload (all parameters uploaded together during text draw ~0.001ms). Validation: ignores if shader<=0, ignores if name null, silently ignored if not found in shader (HLSL doesn't need to use all set parameters). Related: b2dSetTextShaderInt (int parameters), b2dSetTextShaderFloat2/3/4 (vector parameters), b2dLoadTextShader (creates shader), b2dText (draws text with shader).