Cycles: OSL Camera: Use title case for parameters in the UI

This is an alternate solution to !146889 to improve labels in the
camera UI, while being much less invasive. It doesn't take custom
labels into account, but it simply uses the parameter names with title
case.

Pull Request: https://projects.blender.org/blender/blender/pulls/148141
This commit is contained in:
Damien Picard
2025-10-16 15:38:59 +02:00
committed by Lukas Stockner
parent b597c0f1ed
commit 0a0d3678a6
2 changed files with 3 additions and 3 deletions

View File

@@ -35,7 +35,7 @@ shader camera(float focal_length = 50.0 [[ float min = 0.0, float sensitivity =
float distortion_k3 = 0.0,
float swirl_scale = 100.0,
float swirl_amplitude = 0.01,
float swirl_W = 0.0 [[ float sensitivity = 1]],
float swirl_w = 0.0 [[ float sensitivity = 1]],
output point position = 0.0,
output vector direction = 0.0,
output color throughput = 1.0)
@@ -59,7 +59,7 @@ shader camera(float focal_length = 50.0 [[ float min = 0.0, float sensitivity =
Pcam = Pcam * sensor_size / focal_length;
if (do_swirl) {
Pcam += swirl_amplitude * noise("perlin", Pcam * swirl_scale, swirl_W);
Pcam += swirl_amplitude * noise("perlin", Pcam * swirl_scale, swirl_w);
}
direction = normalize(vector(Pcam.x, Pcam.y, 1.0));